verbs can be sal_Int32 instead of tools::Long

Change-Id: I51c88b837928760c72b77de1535f7843b4fd575e
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/110318
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
This commit is contained in:
Caolán McNamara
2021-02-02 17:56:38 +01:00
parent 43fadd3bea
commit a2e533767b
17 changed files with 24 additions and 30 deletions
+1 -1
View File
@@ -81,7 +81,7 @@ public:
static SfxInPlaceClient* GetClient( SfxObjectShell const * pDoc, const css::uno::Reference < css::embed::XEmbeddedObject >& xObject );
sal_Int64 GetAspect() const;
sal_Int64 GetObjectMiscStatus() const;
ErrCode DoVerb( tools::Long nVerb );
ErrCode DoVerb(sal_Int32 nVerb);
void VisAreaChanged();
void ResetObject();
bool IsUIActive() const;
+1 -1
View File
@@ -206,7 +206,7 @@ public:
SfxInPlaceClient* GetUIActiveClient() const;
SfxInPlaceClient* FindIPClient( const css::uno::Reference < css::embed::XEmbeddedObject >& xObj, vcl::Window *pObjParentWin ) const;
virtual ErrCode DoVerb(tools::Long nVerb);
virtual ErrCode DoVerb(sal_Int32 nVerb);
void OutplaceActivated( bool bActive );
virtual void UIActivating( SfxInPlaceClient* pClient );
+2 -2
View File
@@ -297,7 +297,7 @@ public:
ObjectSelectionType GetCurObjectSelectionType() const { return eCurOST; }
virtual ErrCode DoVerb(tools::Long nVerb) override;
virtual ErrCode DoVerb(sal_Int32 nVerb) override;
void StopEditShell();
bool IsDrawTextShell() const;
@@ -320,7 +320,7 @@ public:
virtual std::unique_ptr<SfxTabPage> CreatePrintOptionsPage(weld::Container* pPage, weld::DialogController* pController, const SfxItemSet &rOptions) override;
void ConnectObject( const SdrOle2Obj* pObj );
void ActivateObject( SdrOle2Obj* pObj, tools::Long nVerb );
void ActivateObject(SdrOle2Obj* pObj, sal_Int32 nVerb);
void DeactivateOle();
+2 -2
View File
@@ -142,7 +142,7 @@ public:
}
void ScTabViewShell::ActivateObject( SdrOle2Obj* pObj, tools::Long nVerb )
void ScTabViewShell::ActivateObject(SdrOle2Obj* pObj, sal_Int32 nVerb)
{
// Do not leave the hint message box on top of the object
RemoveHintWindow();
@@ -260,7 +260,7 @@ void ScTabViewShell::ActivateObject( SdrOle2Obj* pObj, tools::Long nVerb )
//xIPObj->SetDocumentName( GetViewData().GetDocShell()->GetTitle() );
}
ErrCode ScTabViewShell::DoVerb(tools::Long nVerb)
ErrCode ScTabViewShell::DoVerb(sal_Int32 nVerb)
{
SdrView* pView = GetScDrawView();
if (!pView)
+2 -2
View File
@@ -264,8 +264,8 @@ public:
virtual void ReadFrameViewData(FrameView* pView) override;
virtual void WriteFrameViewData() override;
virtual ErrCode DoVerb(::tools::Long nVerb) override;
virtual bool ActivateObject(SdrOle2Obj* pObj, ::tools::Long nVerb) override;
virtual ErrCode DoVerb(sal_Int32 nVerb) override;
virtual bool ActivateObject(SdrOle2Obj* pObj, sal_Int32 nVerb) override;
void SetZoomOnPage( bool bZoom ) { mbZoomOnPage = bZoom; }
bool IsZoomOnPage() const { return mbZoomOnPage; }
+2 -2
View File
@@ -229,7 +229,7 @@ public:
void WriteUserData();
void ReadUserData();
virtual bool ActivateObject(SdrOle2Obj* pObj, ::tools::Long nVerb);
virtual bool ActivateObject(SdrOle2Obj* pObj, sal_Int32 nVerb);
/** @returns
current or selected page or 0. This method
@@ -370,7 +370,7 @@ public:
/** This function is called from the underlying ViewShellBase
object to handle a verb execution request.
*/
virtual ErrCode DoVerb (::tools::Long nVerb);
virtual ErrCode DoVerb(sal_Int32 nVerb);
virtual void UIActivating( SfxInPlaceClient* );
virtual void UIDeactivated( SfxInPlaceClient* );
+1 -1
View File
@@ -118,7 +118,7 @@ public:
/** This call is forwarded to the main sub-shell.
*/
virtual ErrCode DoVerb (::tools::Long nVerb) override;
virtual ErrCode DoVerb(sal_Int32 nVerb) override;
/** Return a new renderer that can be used for example for printing the
document.
+2 -2
View File
@@ -506,13 +506,13 @@ void ViewShellBase::Rearrange()
GetViewFrame()->Resize(true);
}
ErrCode ViewShellBase::DoVerb (::tools::Long nVerb)
ErrCode ViewShellBase::DoVerb(sal_Int32 nVerb)
{
ErrCode aResult = ERRCODE_NONE;
::sd::ViewShell* pShell = GetMainViewShell().get();
if (pShell != nullptr)
aResult = pShell->DoVerb (nVerb);
aResult = pShell->DoVerb(nVerb);
return aResult;
}
+2 -4
View File
@@ -709,8 +709,7 @@ void DrawViewShell::ResetActualPage()
/**
* Apply "Verb" on OLE-object.
*/
ErrCode DrawViewShell::DoVerb(::tools::Long nVerb)
ErrCode DrawViewShell::DoVerb(sal_Int32 nVerb)
{
if ( mpDrawView->AreObjectsMarked() )
{
@@ -737,8 +736,7 @@ ErrCode DrawViewShell::DoVerb(::tools::Long nVerb)
/**
* Activate OLE-object
*/
bool DrawViewShell::ActivateObject(SdrOle2Obj* pObj, ::tools::Long nVerb)
bool DrawViewShell::ActivateObject(SdrOle2Obj* pObj, sal_Int32 nVerb)
{
bool bActivated = false;
+1 -1
View File
@@ -627,7 +627,7 @@ void ViewShell::WriteFrameViewData()
{
}
bool ViewShell::ActivateObject(SdrOle2Obj* pObj, ::tools::Long nVerb)
bool ViewShell::ActivateObject(SdrOle2Obj* pObj, sal_Int32 nVerb)
{
ErrCode aErrCode = ERRCODE_NONE;
+1 -1
View File
@@ -1399,7 +1399,7 @@ SdDrawDocument* ViewShell::GetDoc() const
return GetViewShellBase().GetDocument();
}
ErrCode ViewShell::DoVerb (::tools::Long )
ErrCode ViewShell::DoVerb(sal_Int32 /*nVerb*/)
{
return ERRCODE_NONE;
}
+1 -1
View File
@@ -876,7 +876,7 @@ sal_Int64 SfxInPlaceClient::GetAspect() const
return m_xImp->m_nAspect;
}
ErrCode SfxInPlaceClient::DoVerb( tools::Long nVerb )
ErrCode SfxInPlaceClient::DoVerb(sal_Int32 nVerb)
{
SfxErrorContext aEc(ERRCTX_SO_DOVERB, m_pViewSh->GetFrameWeld(), RID_SO_ERRCTX);
ErrCode nError = ERRCODE_NONE;
+1 -5
View File
@@ -731,7 +731,6 @@ void SfxViewShell::GetState_Impl( SfxItemSet &rSet )
}
}
void SfxViewShell::SetZoomFactor( const Fraction &rZoomX,
const Fraction &rZoomY )
{
@@ -742,8 +741,7 @@ void SfxViewShell::SetZoomFactor( const Fraction &rZoomX,
GetWindow()->SetMapMode( aMap );
}
ErrCode SfxViewShell::DoVerb(tools::Long /*nVerb*/)
ErrCode SfxViewShell::DoVerb(sal_Int32 /*nVerb*/)
/* [Description]
@@ -756,14 +754,12 @@ ErrCode SfxViewShell::DoVerb(tools::Long /*nVerb*/)
return ERRCODE_SO_NOVERBS;
}
void SfxViewShell::OutplaceActivated( bool bActive )
{
if ( !bActive )
GetFrame()->GetFrame().Appear();
}
void SfxViewShell::UIActivating( SfxInPlaceClient* /*pClient*/ )
{
uno::Reference < frame::XFrame > xOwnFrame( pFrame->GetFrame().GetFrameInterface() );
+1 -1
View File
@@ -373,7 +373,7 @@ public:
virtual SdrView* GetDrawView() const override;
virtual bool HasUIFeature(SfxShellFeature nFeature) const override;
virtual void ShowCursor( bool bOn = true ) override;
virtual ErrCode DoVerb( tools::Long nVerb ) override;
virtual ErrCode DoVerb(sal_Int32 nVerb) override;
virtual sal_uInt16 SetPrinter( SfxPrinter* pNew,
SfxPrinterChangeFlags nDiff = SFX_PRINTER_ALL) override;
+2 -1
View File
@@ -25,6 +25,7 @@
#include <IMark.hxx>
#include "navmgr.hxx"
#include <optional>
#include <com/sun/star/embed/EmbedVerbs.hpp>
#include <o3tl/typed_flags_set.hxx>
#include <svx/swframetypes.hxx>
#include <vcl/weld.hxx>
@@ -338,7 +339,7 @@ typedef bool (SwWrtShell::*FNSimpleMove)();
sal_uInt16 nSlotId = 0); // SlotId for dialog
bool InsertOleObject( const svt::EmbeddedObjectRef& xObj, SwFlyFrameFormat **pFlyFrameFormat = nullptr );
void LaunchOLEObj( tools::Long nVerb = 0 ); // start server
void LaunchOLEObj(sal_Int32 nVerb = css::embed::EmbedVerbs::MS_OLEVERB_PRIMARY); // start server
virtual void MoveObjectIfActive( svt::EmbeddedObjectRef& xObj, const Point& rOffset ) override;
virtual void CalcAndSetScale( svt::EmbeddedObjectRef& xObj,
const SwRect *pFlyPrtRect = nullptr,
+1 -1
View File
@@ -1567,7 +1567,7 @@ void SwView::ShowCursor( bool bOn )
m_pWrtShell->LockView( false );
}
ErrCode SwView::DoVerb( tools::Long nVerb )
ErrCode SwView::DoVerb(sal_Int32 nVerb)
{
if ( !GetViewFrame()->GetFrame().IsInPlace() )
{
+1 -2
View File
@@ -603,8 +603,7 @@ bool SwWrtShell::InsertOleObject( const svt::EmbeddedObjectRef& xRef, SwFlyFrame
// The current selected OLE object will be loaded with the
// verb into the server.
void SwWrtShell::LaunchOLEObj( tools::Long nVerb )
void SwWrtShell::LaunchOLEObj(sal_Int32 nVerb)
{
if ( GetCntType() != CNT_OLE ||
GetView().GetViewFrame()->GetFrame().IsInPlace() )