loplugin:constantparam in sfx2
Change-Id: I53e690ab8d50fb3ce43ba633fc018e7b66e591cd Reviewed-on: https://gerrit.libreoffice.org/23321 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noelgrandin@gmail.com>
This commit is contained in:
parent
336d816176
commit
db93b92d78
@ -86,7 +86,7 @@ SfxPrinter* Shell::GetPrinter( bool bCreate )
|
|||||||
return nullptr;
|
return nullptr;
|
||||||
}
|
}
|
||||||
|
|
||||||
sal_uInt16 Shell::SetPrinter( SfxPrinter *pNewPrinter, SfxPrinterChangeFlags , bool )
|
sal_uInt16 Shell::SetPrinter( SfxPrinter *pNewPrinter, SfxPrinterChangeFlags )
|
||||||
{
|
{
|
||||||
DocShell* pDocShell = static_cast<DocShell*>(GetViewFrame()->GetObjectShell());
|
DocShell* pDocShell = static_cast<DocShell*>(GetViewFrame()->GetObjectShell());
|
||||||
assert(pDocShell && "DocShell ?!");
|
assert(pDocShell && "DocShell ?!");
|
||||||
|
@ -170,7 +170,7 @@ public:
|
|||||||
|
|
||||||
// virtual sal_uInt16 Print( SfxProgress &rProgress, sal_Bool bIsAPI, PrintDialog *pPrintDialog = 0 );
|
// virtual sal_uInt16 Print( SfxProgress &rProgress, sal_Bool bIsAPI, PrintDialog *pPrintDialog = 0 );
|
||||||
virtual SfxPrinter* GetPrinter( bool bCreate ) override;
|
virtual SfxPrinter* GetPrinter( bool bCreate ) override;
|
||||||
virtual sal_uInt16 SetPrinter( SfxPrinter *pNewPrinter, SfxPrinterChangeFlags nDiffFlags = SFX_PRINTER_ALL, bool bIsAPI=false ) override;
|
virtual sal_uInt16 SetPrinter( SfxPrinter *pNewPrinter, SfxPrinterChangeFlags nDiffFlags = SFX_PRINTER_ALL ) override;
|
||||||
virtual OUString GetSelectionText( bool bCompleteWords ) override;
|
virtual OUString GetSelectionText( bool bCompleteWords ) override;
|
||||||
virtual bool HasSelection( bool bText ) const override;
|
virtual bool HasSelection( bool bText ) const override;
|
||||||
|
|
||||||
|
@ -404,7 +404,7 @@ IMPL_LINK_NOARG_TYPED(SvxHyperlinkInternetTp, ClickBrowseHdl_Impl, Button*, void
|
|||||||
SfxBoolItem aBrowse( SID_BROWSE, true );
|
SfxBoolItem aBrowse( SID_BROWSE, true );
|
||||||
|
|
||||||
const SfxPoolItem *ppItems[] = { &aName, &aNewView, &aSilent, &aReadOnly, &aRefererItem, &aBrowse, nullptr };
|
const SfxPoolItem *ppItems[] = { &aName, &aNewView, &aSilent, &aReadOnly, &aRefererItem, &aBrowse, nullptr };
|
||||||
static_cast<SvxHpLinkDlg*>(mpDialog.get())->GetBindings()->Execute( SID_OPENDOC, ppItems, 0, SfxCallMode::ASYNCHRON | SfxCallMode::RECORD );
|
static_cast<SvxHpLinkDlg*>(mpDialog.get())->GetBindings()->Execute( SID_OPENDOC, ppItems, SfxCallMode::ASYNCHRON | SfxCallMode::RECORD );
|
||||||
}
|
}
|
||||||
|
|
||||||
void SvxHyperlinkInternetTp::RefreshMarkWindow()
|
void SvxHyperlinkInternetTp::RefreshMarkWindow()
|
||||||
|
@ -1006,9 +1006,9 @@ AbstractDialogFactory_Impl::CreateScriptErrorDialog(const css::uno::Any& rExcept
|
|||||||
|
|
||||||
AbstractScriptSelectorDialog*
|
AbstractScriptSelectorDialog*
|
||||||
AbstractDialogFactory_Impl::CreateScriptSelectorDialog(
|
AbstractDialogFactory_Impl::CreateScriptSelectorDialog(
|
||||||
vcl::Window* pParent, bool bShowSlots, const Reference< frame::XFrame >& _rxFrame )
|
vcl::Window* pParent, const Reference< frame::XFrame >& _rxFrame )
|
||||||
{
|
{
|
||||||
VclPtrInstance<SvxScriptSelectorDialog> pDlg(pParent, bShowSlots, _rxFrame);
|
VclPtrInstance<SvxScriptSelectorDialog> pDlg(pParent, false/*bShowSlots*/, _rxFrame);
|
||||||
return new AbstractScriptSelectorDialog_Impl(pDlg);
|
return new AbstractScriptSelectorDialog_Impl(pDlg);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -627,7 +627,6 @@ public:
|
|||||||
virtual AbstractScriptSelectorDialog*
|
virtual AbstractScriptSelectorDialog*
|
||||||
CreateScriptSelectorDialog(
|
CreateScriptSelectorDialog(
|
||||||
vcl::Window* pParent,
|
vcl::Window* pParent,
|
||||||
bool bShowSlots,
|
|
||||||
const css::uno::Reference< css::frame::XFrame >& _rxFrame
|
const css::uno::Reference< css::frame::XFrame >& _rxFrame
|
||||||
) override;
|
) override;
|
||||||
|
|
||||||
|
@ -147,7 +147,7 @@ public:
|
|||||||
/**
|
/**
|
||||||
* @param pArgs Takes ownership
|
* @param pArgs Takes ownership
|
||||||
*/
|
*/
|
||||||
sal_uIntPtr LoadTemplate( SfxObjectShellLock& xDoc, const OUString& rFileName, bool bCopy=true, SfxItemSet* pArgs = nullptr );
|
sal_uIntPtr LoadTemplate( SfxObjectShellLock& xDoc, const OUString& rFileName, SfxItemSet* pArgs = nullptr );
|
||||||
vcl::Window* GetTopWindow() const;
|
vcl::Window* GetTopWindow() const;
|
||||||
|
|
||||||
// members
|
// members
|
||||||
|
@ -170,11 +170,9 @@ public:
|
|||||||
|
|
||||||
const SfxPoolItem* ExecuteSynchron( sal_uInt16 nSlot,
|
const SfxPoolItem* ExecuteSynchron( sal_uInt16 nSlot,
|
||||||
const SfxPoolItem **pArgs = nullptr,
|
const SfxPoolItem **pArgs = nullptr,
|
||||||
sal_uInt16 nModi = 0,
|
|
||||||
const SfxPoolItem **pInternalArgs = nullptr);
|
const SfxPoolItem **pInternalArgs = nullptr);
|
||||||
bool Execute( sal_uInt16 nSlot,
|
bool Execute( sal_uInt16 nSlot,
|
||||||
const SfxPoolItem **pArgs = nullptr,
|
const SfxPoolItem **pArgs = nullptr,
|
||||||
sal_uInt16 nModi = 0,
|
|
||||||
SfxCallMode nCall = SfxCallMode::SLOT,
|
SfxCallMode nCall = SfxCallMode::SLOT,
|
||||||
const SfxPoolItem **pInternalArgs = nullptr);
|
const SfxPoolItem **pInternalArgs = nullptr);
|
||||||
|
|
||||||
|
@ -82,7 +82,7 @@ class SFX2_DLLPUBLIC SfxDispatcher
|
|||||||
|
|
||||||
private:
|
private:
|
||||||
// Search for temporary evaluated Todos
|
// Search for temporary evaluated Todos
|
||||||
SAL_DLLPRIVATE bool CheckVirtualStack( const SfxShell& rShell, bool bDeep );
|
SAL_DLLPRIVATE bool CheckVirtualStack( const SfxShell& rShell );
|
||||||
|
|
||||||
friend class SfxApplication;
|
friend class SfxApplication;
|
||||||
friend class SfxViewFrame;
|
friend class SfxViewFrame;
|
||||||
@ -137,11 +137,6 @@ public:
|
|||||||
SfxCallMode nCall,
|
SfxCallMode nCall,
|
||||||
const SfxItemSet &rArgs );
|
const SfxItemSet &rArgs );
|
||||||
|
|
||||||
const SfxPoolItem* Execute( sal_uInt16 nSlot,
|
|
||||||
SfxCallMode nCall,
|
|
||||||
sal_uInt16 nModi,
|
|
||||||
const SfxItemSet &rArgs );
|
|
||||||
|
|
||||||
const SfxSlot* GetSlot( const OUString& rCommand );
|
const SfxSlot* GetSlot( const OUString& rCommand );
|
||||||
|
|
||||||
bool IsActive( const SfxShell& rShell );
|
bool IsActive( const SfxShell& rShell );
|
||||||
|
@ -97,7 +97,7 @@ public:
|
|||||||
|
|
||||||
sal_uInt32 GuessFilterIgnoringContent( SfxMedium& rMedium, std::shared_ptr<const SfxFilter>& ) const;
|
sal_uInt32 GuessFilterIgnoringContent( SfxMedium& rMedium, std::shared_ptr<const SfxFilter>& ) const;
|
||||||
sal_uInt32 GuessFilter( SfxMedium& rMedium, std::shared_ptr<const SfxFilter>& , SfxFilterFlags nMust = SfxFilterFlags::IMPORT, SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED ) const;
|
sal_uInt32 GuessFilter( SfxMedium& rMedium, std::shared_ptr<const SfxFilter>& , SfxFilterFlags nMust = SfxFilterFlags::IMPORT, SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED ) const;
|
||||||
sal_uInt32 GuessFilterControlDefaultUI( SfxMedium& rMedium, std::shared_ptr<const SfxFilter>&, SfxFilterFlags nMust = SfxFilterFlags::IMPORT, SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED, bool bDefUI = true ) const;
|
sal_uInt32 GuessFilterControlDefaultUI( SfxMedium& rMedium, std::shared_ptr<const SfxFilter>&, SfxFilterFlags nMust = SfxFilterFlags::IMPORT, SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED ) const;
|
||||||
sal_uInt32 DetectFilter( SfxMedium& rMedium, std::shared_ptr<const SfxFilter>& ) const;
|
sal_uInt32 DetectFilter( SfxMedium& rMedium, std::shared_ptr<const SfxFilter>& ) const;
|
||||||
|
|
||||||
std::shared_ptr<const SfxFilter> GetFilter4Mime( const OUString& rMime, SfxFilterFlags nMust = SfxFilterFlags::IMPORT, SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED) const;
|
std::shared_ptr<const SfxFilter> GetFilter4Mime( const OUString& rMime, SfxFilterFlags nMust = SfxFilterFlags::IMPORT, SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED) const;
|
||||||
|
@ -109,7 +109,7 @@ protected:
|
|||||||
SAL_DLLPRIVATE void RemoveChildFrame_Impl( SfxFrame* );
|
SAL_DLLPRIVATE void RemoveChildFrame_Impl( SfxFrame* );
|
||||||
|
|
||||||
SfxFrame( ); // not implemented
|
SfxFrame( ); // not implemented
|
||||||
SAL_DLLPRIVATE SfxFrame( vcl::Window& i_rContainerWindow, bool bHidden );
|
SAL_DLLPRIVATE SfxFrame( vcl::Window& i_rContainerWindow );
|
||||||
|
|
||||||
public:
|
public:
|
||||||
static SfxFrame* Create( const css::uno::Reference< css::frame::XFrame >& xFrame );
|
static SfxFrame* Create( const css::uno::Reference< css::frame::XFrame >& xFrame );
|
||||||
|
@ -139,7 +139,6 @@ public:
|
|||||||
virtual AbstractScriptSelectorDialog*
|
virtual AbstractScriptSelectorDialog*
|
||||||
CreateScriptSelectorDialog(
|
CreateScriptSelectorDialog(
|
||||||
vcl::Window* pParent,
|
vcl::Window* pParent,
|
||||||
bool bShowSlots,
|
|
||||||
const css::uno::Reference< css::frame::XFrame >& _rxFrame
|
const css::uno::Reference< css::frame::XFrame >& _rxFrame
|
||||||
) = 0;
|
) = 0;
|
||||||
|
|
||||||
|
@ -27,7 +27,7 @@ public:
|
|||||||
|
|
||||||
virtual void showRegion (ThumbnailViewItem *pItem) override;
|
virtual void showRegion (ThumbnailViewItem *pItem) override;
|
||||||
|
|
||||||
bool loadRepository (TemplateRepository* pRepository, bool bRefresh);
|
bool loadRepository (TemplateRepository* pRepository);
|
||||||
|
|
||||||
virtual sal_uInt16 createRegion (const OUString &rName) override;
|
virtual sal_uInt16 createRegion (const OUString &rName) override;
|
||||||
|
|
||||||
|
@ -238,7 +238,7 @@ public:
|
|||||||
|
|
||||||
// Printing Interface
|
// Printing Interface
|
||||||
virtual SfxPrinter* GetPrinter( bool bCreate = false );
|
virtual SfxPrinter* GetPrinter( bool bCreate = false );
|
||||||
virtual sal_uInt16 SetPrinter( SfxPrinter *pNewPrinter, SfxPrinterChangeFlags nDiffFlags = SFX_PRINTER_ALL, bool bIsAPI=false );
|
virtual sal_uInt16 SetPrinter( SfxPrinter *pNewPrinter, SfxPrinterChangeFlags nDiffFlags = SFX_PRINTER_ALL );
|
||||||
virtual bool HasPrintOptionsPage() const;
|
virtual bool HasPrintOptionsPage() const;
|
||||||
virtual VclPtr<SfxTabPage> CreatePrintOptionsPage( vcl::Window *pParent, const SfxItemSet &rOptions );
|
virtual VclPtr<SfxTabPage> CreatePrintOptionsPage( vcl::Window *pParent, const SfxItemSet &rOptions );
|
||||||
static JobSetup GetJobSetup();
|
static JobSetup GetJobSetup();
|
||||||
@ -248,7 +248,7 @@ public:
|
|||||||
virtual void WriteUserData( OUString&, bool bBrowse = false );
|
virtual void WriteUserData( OUString&, bool bBrowse = false );
|
||||||
virtual void ReadUserData( const OUString&, bool bBrowse = false );
|
virtual void ReadUserData( const OUString&, bool bBrowse = false );
|
||||||
virtual void WriteUserDataSequence ( css::uno::Sequence < css::beans::PropertyValue >& );
|
virtual void WriteUserDataSequence ( css::uno::Sequence < css::beans::PropertyValue >& );
|
||||||
virtual void ReadUserDataSequence ( const css::uno::Sequence < css::beans::PropertyValue >&, bool bBrowse = false );
|
virtual void ReadUserDataSequence ( const css::uno::Sequence < css::beans::PropertyValue >& );
|
||||||
virtual void QueryObjAreaPixel( Rectangle& rRect ) const;
|
virtual void QueryObjAreaPixel( Rectangle& rRect ) const;
|
||||||
|
|
||||||
virtual SfxObjectShell* GetObjectShell() override;
|
virtual SfxObjectShell* GetObjectShell() override;
|
||||||
|
@ -405,7 +405,6 @@ public:
|
|||||||
virtual AbstractScriptSelectorDialog*
|
virtual AbstractScriptSelectorDialog*
|
||||||
CreateScriptSelectorDialog(
|
CreateScriptSelectorDialog(
|
||||||
vcl::Window* pParent,
|
vcl::Window* pParent,
|
||||||
bool bShowSlots,
|
|
||||||
const css::uno::Reference< css::frame::XFrame >& _rxFrame
|
const css::uno::Reference< css::frame::XFrame >& _rxFrame
|
||||||
) override = 0;
|
) override = 0;
|
||||||
|
|
||||||
|
@ -72,7 +72,7 @@ protected:
|
|||||||
virtual void ReadUserData(const OUString &, bool bBrowse = false) override;
|
virtual void ReadUserData(const OUString &, bool bBrowse = false) override;
|
||||||
|
|
||||||
virtual void WriteUserDataSequence (css::uno::Sequence < css::beans::PropertyValue >& ) override;
|
virtual void WriteUserDataSequence (css::uno::Sequence < css::beans::PropertyValue >& ) override;
|
||||||
virtual void ReadUserDataSequence (const css::uno::Sequence < css::beans::PropertyValue >&, bool bBrowse = false ) override;
|
virtual void ReadUserDataSequence (const css::uno::Sequence < css::beans::PropertyValue >& ) override;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
SFX_DECL_INTERFACE(SCID_PREVIEW_SHELL)
|
SFX_DECL_INTERFACE(SCID_PREVIEW_SHELL)
|
||||||
@ -104,7 +104,7 @@ public:
|
|||||||
virtual void Notify( SfxBroadcaster& rBC, const SfxHint& rHint ) override;
|
virtual void Notify( SfxBroadcaster& rBC, const SfxHint& rHint ) override;
|
||||||
|
|
||||||
virtual SfxPrinter* GetPrinter( bool bCreate = false ) override;
|
virtual SfxPrinter* GetPrinter( bool bCreate = false ) override;
|
||||||
virtual sal_uInt16 SetPrinter( SfxPrinter* pNewPrinter, SfxPrinterChangeFlags nDiffFlags = SFX_PRINTER_ALL, bool bIsAPI=false ) override;
|
virtual sal_uInt16 SetPrinter( SfxPrinter* pNewPrinter, SfxPrinterChangeFlags nDiffFlags = SFX_PRINTER_ALL ) override;
|
||||||
virtual bool HasPrintOptionsPage() const override;
|
virtual bool HasPrintOptionsPage() const override;
|
||||||
virtual VclPtr<SfxTabPage> CreatePrintOptionsPage( vcl::Window *pParent, const SfxItemSet &rOptions ) override;
|
virtual VclPtr<SfxTabPage> CreatePrintOptionsPage( vcl::Window *pParent, const SfxItemSet &rOptions ) override;
|
||||||
|
|
||||||
|
@ -205,7 +205,7 @@ protected:
|
|||||||
virtual void WriteUserData(OUString &, bool bBrowse = false) override;
|
virtual void WriteUserData(OUString &, bool bBrowse = false) override;
|
||||||
virtual void ReadUserData(const OUString &, bool bBrowse = false) override;
|
virtual void ReadUserData(const OUString &, bool bBrowse = false) override;
|
||||||
virtual void WriteUserDataSequence (css::uno::Sequence < css::beans::PropertyValue >& ) override;
|
virtual void WriteUserDataSequence (css::uno::Sequence < css::beans::PropertyValue >& ) override;
|
||||||
virtual void ReadUserDataSequence (const css::uno::Sequence < css::beans::PropertyValue >&, bool bBrowse = false ) override;
|
virtual void ReadUserDataSequence (const css::uno::Sequence < css::beans::PropertyValue >& ) override;
|
||||||
|
|
||||||
virtual void UIDeactivated( SfxInPlaceClient* pClient ) override;
|
virtual void UIDeactivated( SfxInPlaceClient* pClient ) override;
|
||||||
|
|
||||||
@ -322,7 +322,7 @@ public:
|
|||||||
// Drucken:
|
// Drucken:
|
||||||
virtual SfxPrinter* GetPrinter( bool bCreate = false ) override;
|
virtual SfxPrinter* GetPrinter( bool bCreate = false ) override;
|
||||||
virtual sal_uInt16 SetPrinter( SfxPrinter* pNewPrinter,
|
virtual sal_uInt16 SetPrinter( SfxPrinter* pNewPrinter,
|
||||||
SfxPrinterChangeFlags nDiffFlags = SFX_PRINTER_ALL, bool bIsApi=false ) override;
|
SfxPrinterChangeFlags nDiffFlags = SFX_PRINTER_ALL ) override;
|
||||||
|
|
||||||
virtual bool HasPrintOptionsPage() const override;
|
virtual bool HasPrintOptionsPage() const override;
|
||||||
virtual VclPtr<SfxTabPage> CreatePrintOptionsPage( vcl::Window *pParent, const SfxItemSet &rOptions ) override;
|
virtual VclPtr<SfxTabPage> CreatePrintOptionsPage( vcl::Window *pParent, const SfxItemSet &rOptions ) override;
|
||||||
|
@ -518,7 +518,7 @@ SfxPrinter* ScPreviewShell::GetPrinter( bool bCreate )
|
|||||||
return pDocShell->GetPrinter(bCreate);
|
return pDocShell->GetPrinter(bCreate);
|
||||||
}
|
}
|
||||||
|
|
||||||
sal_uInt16 ScPreviewShell::SetPrinter( SfxPrinter *pNewPrinter, SfxPrinterChangeFlags nDiffFlags, bool )
|
sal_uInt16 ScPreviewShell::SetPrinter( SfxPrinter *pNewPrinter, SfxPrinterChangeFlags nDiffFlags )
|
||||||
{
|
{
|
||||||
return pDocShell->SetPrinter( pNewPrinter, nDiffFlags );
|
return pDocShell->SetPrinter( pNewPrinter, nDiffFlags );
|
||||||
}
|
}
|
||||||
@ -953,7 +953,7 @@ void ScPreviewShell::WriteUserDataSequence(uno::Sequence < beans::PropertyValue
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void ScPreviewShell::ReadUserDataSequence(const uno::Sequence < beans::PropertyValue >& rSeq, bool /* bBrowse */)
|
void ScPreviewShell::ReadUserDataSequence(const uno::Sequence < beans::PropertyValue >& rSeq)
|
||||||
{
|
{
|
||||||
sal_Int32 nCount(rSeq.getLength());
|
sal_Int32 nCount(rSeq.getLength());
|
||||||
if (nCount)
|
if (nCount)
|
||||||
|
@ -483,7 +483,7 @@ void ScTabViewShell::ReadUserData(const OUString& rData, bool /* bBrowse */)
|
|||||||
DoReadUserData( rData );
|
DoReadUserData( rData );
|
||||||
}
|
}
|
||||||
|
|
||||||
void ScTabViewShell::ReadUserDataSequence (const uno::Sequence < beans::PropertyValue >& rSettings, bool /* bBrowse */ )
|
void ScTabViewShell::ReadUserDataSequence (const uno::Sequence < beans::PropertyValue >& rSettings )
|
||||||
{
|
{
|
||||||
if ( !GetViewData().GetDocShell()->IsPreview() )
|
if ( !GetViewData().GetDocShell()->IsPreview() )
|
||||||
DoReadUserDataSequence( rSettings );
|
DoReadUserDataSequence( rSettings );
|
||||||
@ -1040,7 +1040,7 @@ SfxPrinter* ScTabViewShell::GetPrinter( bool bCreate )
|
|||||||
return GetViewData().GetDocShell()->GetPrinter(bCreate);
|
return GetViewData().GetDocShell()->GetPrinter(bCreate);
|
||||||
}
|
}
|
||||||
|
|
||||||
sal_uInt16 ScTabViewShell::SetPrinter( SfxPrinter *pNewPrinter, SfxPrinterChangeFlags nDiffFlags, bool )
|
sal_uInt16 ScTabViewShell::SetPrinter( SfxPrinter *pNewPrinter, SfxPrinterChangeFlags nDiffFlags )
|
||||||
{
|
{
|
||||||
return GetViewData().GetDocShell()->SetPrinter( pNewPrinter, nDiffFlags );
|
return GetViewData().GetDocShell()->SetPrinter( pNewPrinter, nDiffFlags );
|
||||||
}
|
}
|
||||||
|
@ -497,7 +497,7 @@ SfxFrame* SdModule::CreateFromTemplate( const OUString& rTemplatePath, const Ref
|
|||||||
SfxItemSet* pSet = new SfxAllItemSet( SfxGetpApp()->GetPool() );
|
SfxItemSet* pSet = new SfxAllItemSet( SfxGetpApp()->GetPool() );
|
||||||
pSet->Put( SfxBoolItem( SID_TEMPLATE, true ) );
|
pSet->Put( SfxBoolItem( SID_TEMPLATE, true ) );
|
||||||
|
|
||||||
sal_uLong lErr = SfxGetpApp()->LoadTemplate( xDocShell, rTemplatePath, true, pSet );
|
sal_uLong lErr = SfxGetpApp()->LoadTemplate( xDocShell, rTemplatePath, pSet );
|
||||||
|
|
||||||
SfxObjectShell* pDocShell = xDocShell;
|
SfxObjectShell* pDocShell = xDocShell;
|
||||||
|
|
||||||
|
@ -1469,7 +1469,7 @@ void AssistentDlgImpl::UpdatePreview( bool bDocPreview )
|
|||||||
if(bDocPreview)
|
if(bDocPreview)
|
||||||
pSet->Put( SfxBoolItem( SID_PREVIEW, true ) );
|
pSet->Put( SfxBoolItem( SID_PREVIEW, true ) );
|
||||||
RestorePassword( pSet, aDocFile );
|
RestorePassword( pSet, aDocFile );
|
||||||
if( (lErr = pSfxApp->LoadTemplate( xDocShell, aDocFile, true, pSet )) != 0 )
|
if( (lErr = pSfxApp->LoadTemplate( xDocShell, aDocFile, pSet )) != 0 )
|
||||||
ErrorHandler::HandleError(lErr);
|
ErrorHandler::HandleError(lErr);
|
||||||
else
|
else
|
||||||
SavePassword( xDocShell, aDocFile );
|
SavePassword( xDocShell, aDocFile );
|
||||||
@ -1513,7 +1513,7 @@ void AssistentDlgImpl::UpdatePreview( bool bDocPreview )
|
|||||||
pSet->Put( SfxBoolItem( SID_PREVIEW, true ) );
|
pSet->Put( SfxBoolItem( SID_PREVIEW, true ) );
|
||||||
|
|
||||||
RestorePassword( pSet, aLayoutFile );
|
RestorePassword( pSet, aLayoutFile );
|
||||||
if( (lErr = pSfxApp->LoadTemplate( xLayoutDocShell, aLayoutFile, true, pSet )) != 0 )
|
if( (lErr = pSfxApp->LoadTemplate( xLayoutDocShell, aLayoutFile, pSet )) != 0 )
|
||||||
ErrorHandler::HandleError(lErr);
|
ErrorHandler::HandleError(lErr);
|
||||||
SavePassword( xLayoutDocShell, aLayoutFile );
|
SavePassword( xLayoutDocShell, aLayoutFile );
|
||||||
}
|
}
|
||||||
|
@ -136,7 +136,7 @@ public:
|
|||||||
/// Forwarded to the print manager.
|
/// Forwarded to the print manager.
|
||||||
virtual sal_uInt16 SetPrinter (
|
virtual sal_uInt16 SetPrinter (
|
||||||
SfxPrinter* pNewPrinter,
|
SfxPrinter* pNewPrinter,
|
||||||
SfxPrinterChangeFlags nDiffFlags = SFX_PRINTER_ALL, bool bIsApi=false) override;
|
SfxPrinterChangeFlags nDiffFlags = SFX_PRINTER_ALL) override;
|
||||||
|
|
||||||
/// Forward methods to main sub shell.
|
/// Forward methods to main sub shell.
|
||||||
virtual void WriteUserDataSequence (
|
virtual void WriteUserDataSequence (
|
||||||
@ -147,8 +147,7 @@ public:
|
|||||||
pane.
|
pane.
|
||||||
*/
|
*/
|
||||||
virtual void ReadUserDataSequence (
|
virtual void ReadUserDataSequence (
|
||||||
const css::uno::Sequence< css::beans::PropertyValue >&,
|
const css::uno::Sequence< css::beans::PropertyValue >&) override;
|
||||||
bool bBrowse = false) override;
|
|
||||||
|
|
||||||
virtual void UIActivating( SfxInPlaceClient* ) override;
|
virtual void UIActivating( SfxInPlaceClient* ) override;
|
||||||
virtual void UIDeactivated( SfxInPlaceClient* ) override;
|
virtual void UIDeactivated( SfxInPlaceClient* ) override;
|
||||||
|
@ -155,7 +155,7 @@ SdPage* TemplatePageObjectProvider::operator() (SdDrawDocument* pContainerDocume
|
|||||||
SfxItemSet* pSet = new SfxAllItemSet (pSfxApp->GetPool());
|
SfxItemSet* pSet = new SfxAllItemSet (pSfxApp->GetPool());
|
||||||
pSet->Put (SfxBoolItem (SID_TEMPLATE, true));
|
pSet->Put (SfxBoolItem (SID_TEMPLATE, true));
|
||||||
pSet->Put (SfxBoolItem (SID_PREVIEW, true));
|
pSet->Put (SfxBoolItem (SID_PREVIEW, true));
|
||||||
if (pSfxApp->LoadTemplate (mxDocumentShell, sFileName, true, pSet))
|
if (pSfxApp->LoadTemplate (mxDocumentShell, sFileName, pSet))
|
||||||
{
|
{
|
||||||
mxDocumentShell = nullptr;
|
mxDocumentShell = nullptr;
|
||||||
}
|
}
|
||||||
|
@ -528,8 +528,7 @@ SfxPrinter* ViewShellBase::GetPrinter (bool bCreate)
|
|||||||
|
|
||||||
sal_uInt16 ViewShellBase::SetPrinter (
|
sal_uInt16 ViewShellBase::SetPrinter (
|
||||||
SfxPrinter* pNewPrinter,
|
SfxPrinter* pNewPrinter,
|
||||||
SfxPrinterChangeFlags nDiffFlags,
|
SfxPrinterChangeFlags nDiffFlags)
|
||||||
bool bIsAPI)
|
|
||||||
{
|
{
|
||||||
OSL_ASSERT(mpImpl.get()!=nullptr);
|
OSL_ASSERT(mpImpl.get()!=nullptr);
|
||||||
|
|
||||||
@ -545,14 +544,6 @@ sal_uInt16 ViewShellBase::SetPrinter (
|
|||||||
Size aNewSize = pNewPrinter->GetOutputSize();
|
Size aNewSize = pNewPrinter->GetOutputSize();
|
||||||
|
|
||||||
bool bScaleAll = false;
|
bool bScaleAll = false;
|
||||||
if ( bIsAPI )
|
|
||||||
{
|
|
||||||
ScopedVclPtrInstance<WarningBox> aWarnBox (
|
|
||||||
GetWindow(),
|
|
||||||
(WinBits)(WB_YES_NO | WB_DEF_YES),
|
|
||||||
SD_RESSTR(STR_SCALE_OBJS_TO_PAGE));
|
|
||||||
bScaleAll = (aWarnBox->Execute() == RET_YES);
|
|
||||||
}
|
|
||||||
|
|
||||||
std::shared_ptr<DrawViewShell> pDrawViewShell (
|
std::shared_ptr<DrawViewShell> pDrawViewShell (
|
||||||
std::dynamic_pointer_cast<DrawViewShell>(GetMainViewShell()));
|
std::dynamic_pointer_cast<DrawViewShell>(GetMainViewShell()));
|
||||||
@ -696,14 +687,13 @@ void ViewShellBase::WriteUserDataSequence (
|
|||||||
}
|
}
|
||||||
|
|
||||||
void ViewShellBase::ReadUserDataSequence (
|
void ViewShellBase::ReadUserDataSequence (
|
||||||
const css::uno::Sequence< css::beans::PropertyValue >& rSequence,
|
const css::uno::Sequence< css::beans::PropertyValue >& rSequence)
|
||||||
bool bBrowse)
|
|
||||||
{
|
{
|
||||||
// Forward call to main sub shell.
|
// Forward call to main sub shell.
|
||||||
ViewShell* pShell = GetMainViewShell().get();
|
ViewShell* pShell = GetMainViewShell().get();
|
||||||
if (pShell != nullptr)
|
if (pShell != nullptr)
|
||||||
{
|
{
|
||||||
pShell->ReadUserDataSequence (rSequence, bBrowse);
|
pShell->ReadUserDataSequence (rSequence, true/*bBrowse*/);
|
||||||
|
|
||||||
// For certain shell types ReadUserDataSequence may have changed the
|
// For certain shell types ReadUserDataSequence may have changed the
|
||||||
// type to another one. Make sure that the center pane shows the
|
// type to another one. Make sure that the center pane shows the
|
||||||
|
@ -535,7 +535,7 @@ SfxApplication::ChooseScript()
|
|||||||
uno::Reference< frame::XFrame > xFrame( pFrame ? pFrame->GetFrameInterface() : uno::Reference< frame::XFrame >() );
|
uno::Reference< frame::XFrame > xFrame( pFrame ? pFrame->GetFrameInterface() : uno::Reference< frame::XFrame >() );
|
||||||
|
|
||||||
std::unique_ptr<AbstractScriptSelectorDialog> pDlg(
|
std::unique_ptr<AbstractScriptSelectorDialog> pDlg(
|
||||||
pFact->CreateScriptSelectorDialog( nullptr, false, xFrame ));
|
pFact->CreateScriptSelectorDialog( nullptr, xFrame ));
|
||||||
|
|
||||||
SAL_INFO( "sfx.appl", "done, now exec it");
|
SAL_INFO( "sfx.appl", "done, now exec it");
|
||||||
|
|
||||||
|
@ -278,7 +278,7 @@ sal_uInt32 CheckPasswd_Impl
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
sal_uIntPtr SfxApplication::LoadTemplate( SfxObjectShellLock& xDoc, const OUString &rFileName, bool bCopy, SfxItemSet* pSet )
|
sal_uIntPtr SfxApplication::LoadTemplate( SfxObjectShellLock& xDoc, const OUString &rFileName, SfxItemSet* pSet )
|
||||||
{
|
{
|
||||||
std::shared_ptr<const SfxFilter> pFilter;
|
std::shared_ptr<const SfxFilter> pFilter;
|
||||||
SfxMedium aMedium( rFileName, ( StreamMode::READ | StreamMode::SHARE_DENYNONE ) );
|
SfxMedium aMedium( rFileName, ( StreamMode::READ | StreamMode::SHARE_DENYNONE ) );
|
||||||
@ -348,34 +348,29 @@ sal_uIntPtr SfxApplication::LoadTemplate( SfxObjectShellLock& xDoc, const OUStri
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if( bCopy )
|
try
|
||||||
{
|
{
|
||||||
try
|
// TODO: introduce error handling
|
||||||
{
|
|
||||||
// TODO: introduce error handling
|
|
||||||
|
|
||||||
uno::Reference< embed::XStorage > xTempStorage = ::comphelper::OStorageHelper::GetTemporaryStorage();
|
uno::Reference< embed::XStorage > xTempStorage = ::comphelper::OStorageHelper::GetTemporaryStorage();
|
||||||
if( !xTempStorage.is() )
|
if( !xTempStorage.is() )
|
||||||
throw uno::RuntimeException();
|
throw uno::RuntimeException();
|
||||||
|
|
||||||
xDoc->GetStorage()->copyToStorage( xTempStorage );
|
xDoc->GetStorage()->copyToStorage( xTempStorage );
|
||||||
|
|
||||||
if ( !xDoc->DoSaveCompleted( new SfxMedium( xTempStorage, OUString() ) ) )
|
if ( !xDoc->DoSaveCompleted( new SfxMedium( xTempStorage, OUString() ) ) )
|
||||||
throw uno::RuntimeException();
|
throw uno::RuntimeException();
|
||||||
}
|
|
||||||
catch( uno::Exception& )
|
|
||||||
{
|
|
||||||
xDoc->DoClose();
|
|
||||||
xDoc.Clear();
|
|
||||||
|
|
||||||
// TODO: transfer correct error outside
|
|
||||||
return ERRCODE_SFX_GENERAL;
|
|
||||||
}
|
|
||||||
|
|
||||||
SetTemplate_Impl( rFileName, OUString(), xDoc );
|
|
||||||
}
|
}
|
||||||
else
|
catch( uno::Exception& )
|
||||||
SetTemplate_Impl( rFileName, OUString(), xDoc );
|
{
|
||||||
|
xDoc->DoClose();
|
||||||
|
xDoc.Clear();
|
||||||
|
|
||||||
|
// TODO: transfer correct error outside
|
||||||
|
return ERRCODE_SFX_GENERAL;
|
||||||
|
}
|
||||||
|
|
||||||
|
SetTemplate_Impl( rFileName, OUString(), xDoc );
|
||||||
|
|
||||||
xDoc->SetNoName();
|
xDoc->SetNoName();
|
||||||
xDoc->InvalidateName();
|
xDoc->InvalidateName();
|
||||||
|
@ -1151,7 +1151,7 @@ void SfxApplication::OfaExec_Impl( SfxRequest& rReq )
|
|||||||
do // artificial loop for flow control
|
do // artificial loop for flow control
|
||||||
{
|
{
|
||||||
std::unique_ptr<AbstractScriptSelectorDialog> pDlg(pFact->CreateScriptSelectorDialog(
|
std::unique_ptr<AbstractScriptSelectorDialog> pDlg(pFact->CreateScriptSelectorDialog(
|
||||||
lcl_getDialogParent( xFrame, GetTopWindow() ), false, xFrame ));
|
lcl_getDialogParent( xFrame, GetTopWindow() ), xFrame ));
|
||||||
OSL_ENSURE( pDlg, "SfxApplication::OfaExec_Impl( SID_RUNMACRO ): no dialog!" );
|
OSL_ENSURE( pDlg, "SfxApplication::OfaExec_Impl( SID_RUNMACRO ): no dialog!" );
|
||||||
if ( !pDlg )
|
if ( !pDlg )
|
||||||
break;
|
break;
|
||||||
|
@ -398,7 +398,7 @@ sal_uInt32 SfxFilterMatcher::GuessFilter( SfxMedium& rMedium, std::shared_ptr<c
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
sal_uInt32 SfxFilterMatcher::GuessFilterControlDefaultUI( SfxMedium& rMedium, std::shared_ptr<const SfxFilter>& rpFilter, SfxFilterFlags nMust, SfxFilterFlags nDont, bool /*bDefUI*/ ) const
|
sal_uInt32 SfxFilterMatcher::GuessFilterControlDefaultUI( SfxMedium& rMedium, std::shared_ptr<const SfxFilter>& rpFilter, SfxFilterFlags nMust, SfxFilterFlags nDont ) const
|
||||||
{
|
{
|
||||||
std::shared_ptr<const SfxFilter> pOldFilter = rpFilter;
|
std::shared_ptr<const SfxFilter> pOldFilter = rpFilter;
|
||||||
|
|
||||||
|
@ -1038,7 +1038,7 @@ void SfxBindings::Release( SfxControllerItem& rItem )
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
const SfxPoolItem* SfxBindings::ExecuteSynchron( sal_uInt16 nId, const SfxPoolItem** ppItems, sal_uInt16 nModi,
|
const SfxPoolItem* SfxBindings::ExecuteSynchron( sal_uInt16 nId, const SfxPoolItem** ppItems,
|
||||||
const SfxPoolItem **ppInternalArgs )
|
const SfxPoolItem **ppInternalArgs )
|
||||||
{
|
{
|
||||||
DBG_ASSERT( pImp->pCaches != nullptr, "SfxBindings not initialized" );
|
DBG_ASSERT( pImp->pCaches != nullptr, "SfxBindings not initialized" );
|
||||||
@ -1046,10 +1046,10 @@ const SfxPoolItem* SfxBindings::ExecuteSynchron( sal_uInt16 nId, const SfxPoolIt
|
|||||||
if( !nId || !pDispatcher )
|
if( !nId || !pDispatcher )
|
||||||
return nullptr;
|
return nullptr;
|
||||||
|
|
||||||
return Execute_Impl( nId, ppItems, nModi, SfxCallMode::SYNCHRON, ppInternalArgs );
|
return Execute_Impl( nId, ppItems, 0, SfxCallMode::SYNCHRON, ppInternalArgs );
|
||||||
}
|
}
|
||||||
|
|
||||||
bool SfxBindings::Execute( sal_uInt16 nId, const SfxPoolItem** ppItems, sal_uInt16 nModi, SfxCallMode nCallMode,
|
bool SfxBindings::Execute( sal_uInt16 nId, const SfxPoolItem** ppItems, SfxCallMode nCallMode,
|
||||||
const SfxPoolItem **ppInternalArgs )
|
const SfxPoolItem **ppInternalArgs )
|
||||||
{
|
{
|
||||||
DBG_ASSERT( pImp->pCaches != nullptr, "SfxBindings not initialized" );
|
DBG_ASSERT( pImp->pCaches != nullptr, "SfxBindings not initialized" );
|
||||||
@ -1057,7 +1057,7 @@ bool SfxBindings::Execute( sal_uInt16 nId, const SfxPoolItem** ppItems, sal_uInt
|
|||||||
if( !nId || !pDispatcher )
|
if( !nId || !pDispatcher )
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
const SfxPoolItem* pRet = Execute_Impl( nId, ppItems, nModi, nCallMode, ppInternalArgs );
|
const SfxPoolItem* pRet = Execute_Impl( nId, ppItems, 0, nCallMode, ppInternalArgs );
|
||||||
return ( pRet != nullptr );
|
return ( pRet != nullptr );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -179,13 +179,13 @@ void SfxDispatcher::Push(SfxShell& rShell)
|
|||||||
/** This method checks whether a particular <SfxShell> instance is
|
/** This method checks whether a particular <SfxShell> instance is
|
||||||
on the SfxDispatcher.
|
on the SfxDispatcher.
|
||||||
|
|
||||||
@returns sal_True The SfxShell instance is on the SfxDispatcher.
|
@returns true The SfxShell instance is on the SfxDispatcher.
|
||||||
sal_False The SfxShell instance is not on the SfxDispatcher.
|
false The SfxShell instance is not on the SfxDispatcher.
|
||||||
*/
|
*/
|
||||||
bool SfxDispatcher::IsActive(const SfxShell& rShell)
|
bool SfxDispatcher::IsActive(const SfxShell& rShell)
|
||||||
|
|
||||||
{
|
{
|
||||||
return CheckVirtualStack(rShell, true);
|
return CheckVirtualStack(rShell);
|
||||||
}
|
}
|
||||||
|
|
||||||
/** With this method it can be determined whether the SfxDispatcher is
|
/** With this method it can be determined whether the SfxDispatcher is
|
||||||
@ -515,7 +515,7 @@ IMPL_LINK_NOARG_TYPED( SfxDispatcher, EventHdl_Impl, Idle *, void )
|
|||||||
This method is intended among other things to make assertions possible
|
This method is intended among other things to make assertions possible
|
||||||
without the side effect of having to flush the SfxDispathcer.
|
without the side effect of having to flush the SfxDispathcer.
|
||||||
*/
|
*/
|
||||||
bool SfxDispatcher::CheckVirtualStack(const SfxShell& rShell, bool bDeep)
|
bool SfxDispatcher::CheckVirtualStack(const SfxShell& rShell)
|
||||||
{
|
{
|
||||||
SFX_STACK(SfxDispatcher::CheckVirtualStack);
|
SFX_STACK(SfxDispatcher::CheckVirtualStack);
|
||||||
|
|
||||||
@ -538,11 +538,7 @@ bool SfxDispatcher::CheckVirtualStack(const SfxShell& rShell, bool bDeep)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
bool bReturn;
|
bool bReturn = std::find(aStack.begin(), aStack.end(), &rShell) != aStack.end();
|
||||||
if ( bDeep )
|
|
||||||
bReturn = std::find(aStack.begin(), aStack.end(), &rShell) != aStack.end();
|
|
||||||
else
|
|
||||||
bReturn = aStack.back() == &rShell;
|
|
||||||
return bReturn;
|
return bReturn;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -989,12 +985,6 @@ const SfxPoolItem* SfxDispatcher::Execute(sal_uInt16 nSlot, SfxCallMode eCall,
|
|||||||
*/
|
*/
|
||||||
const SfxPoolItem* SfxDispatcher::Execute(sal_uInt16 nSlot, SfxCallMode eCall,
|
const SfxPoolItem* SfxDispatcher::Execute(sal_uInt16 nSlot, SfxCallMode eCall,
|
||||||
const SfxItemSet &rArgs)
|
const SfxItemSet &rArgs)
|
||||||
{
|
|
||||||
return Execute( nSlot, eCall, 0, rArgs );
|
|
||||||
}
|
|
||||||
|
|
||||||
const SfxPoolItem* SfxDispatcher::Execute(sal_uInt16 nSlot, SfxCallMode eCall,
|
|
||||||
sal_uInt16 nModi, const SfxItemSet &rArgs)
|
|
||||||
{
|
{
|
||||||
if ( IsLocked(nSlot) )
|
if ( IsLocked(nSlot) )
|
||||||
return nullptr;
|
return nullptr;
|
||||||
@ -1011,7 +1001,7 @@ const SfxPoolItem* SfxDispatcher::Execute(sal_uInt16 nSlot, SfxCallMode eCall,
|
|||||||
pArg = aIter.NextItem() )
|
pArg = aIter.NextItem() )
|
||||||
MappedPut_Impl( aSet, *pArg );
|
MappedPut_Impl( aSet, *pArg );
|
||||||
SfxRequest aReq( nSlot, eCall, aSet );
|
SfxRequest aReq( nSlot, eCall, aSet );
|
||||||
aReq.SetModifier( nModi );
|
aReq.SetModifier( 0 );
|
||||||
_Execute( *pShell, *pSlot, aReq, eCall );
|
_Execute( *pShell, *pSlot, aReq, eCall );
|
||||||
return aReq.GetReturnValue();
|
return aReq.GetReturnValue();
|
||||||
}
|
}
|
||||||
|
@ -59,10 +59,10 @@ struct SfxObjectUI_Impl
|
|||||||
bool bContext;
|
bool bContext;
|
||||||
sal_uInt32 nFeature;
|
sal_uInt32 nFeature;
|
||||||
|
|
||||||
SfxObjectUI_Impl(sal_uInt16 n, sal_uInt32 nId, bool bVis, sal_uInt32 nFeat) :
|
SfxObjectUI_Impl(sal_uInt16 n, sal_uInt32 nId, sal_uInt32 nFeat) :
|
||||||
nPos(n),
|
nPos(n),
|
||||||
nResId(nId),
|
nResId(nId),
|
||||||
bVisible(bVis),
|
bVisible(true),
|
||||||
bContext(false),
|
bContext(false),
|
||||||
nFeature(nFeat)
|
nFeature(nFeat)
|
||||||
{
|
{
|
||||||
@ -381,7 +381,7 @@ SfxObjectUI_Impl* CreateObjectBarUI_Impl(sal_uInt16 nPos, sal_uInt32 nResId, sal
|
|||||||
if ((nPos & SFX_VISIBILITY_MASK) == 0)
|
if ((nPos & SFX_VISIBILITY_MASK) == 0)
|
||||||
nPos |= SFX_VISIBILITY_STANDARD;
|
nPos |= SFX_VISIBILITY_STANDARD;
|
||||||
|
|
||||||
return new SfxObjectUI_Impl(nPos, nResId, true, nFeature);
|
return new SfxObjectUI_Impl(nPos, nResId, nFeature);
|
||||||
}
|
}
|
||||||
|
|
||||||
sal_uInt32 SfxInterface::GetObjectBarId(sal_uInt16 nNo) const
|
sal_uInt32 SfxInterface::GetObjectBarId(sal_uInt16 nNo) const
|
||||||
@ -437,7 +437,7 @@ void SfxInterface::RegisterChildWindow(sal_uInt16 nId, bool bContext)
|
|||||||
|
|
||||||
void SfxInterface::RegisterChildWindow(sal_uInt16 nId, bool bContext, sal_uInt32 nFeature)
|
void SfxInterface::RegisterChildWindow(sal_uInt16 nId, bool bContext, sal_uInt32 nFeature)
|
||||||
{
|
{
|
||||||
SfxObjectUI_Impl* pUI = new SfxObjectUI_Impl(0, nId, true, nFeature);
|
SfxObjectUI_Impl* pUI = new SfxObjectUI_Impl(0, nId, nFeature);
|
||||||
pUI->bContext = bContext;
|
pUI->bContext = bContext;
|
||||||
pImpData->aChildWindows.push_back(pUI);
|
pImpData->aChildWindows.push_back(pUI);
|
||||||
}
|
}
|
||||||
|
@ -70,12 +70,12 @@ void TemplateRemoteView::showRegion(ThumbnailViewItem * /*pItem*/)
|
|||||||
//TODO:
|
//TODO:
|
||||||
}
|
}
|
||||||
|
|
||||||
bool TemplateRemoteView::loadRepository (TemplateRepository* pItem, bool bRefresh)
|
bool TemplateRemoteView::loadRepository (TemplateRepository* pItem)
|
||||||
{
|
{
|
||||||
if (!pItem)
|
if (!pItem)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
if (!pItem->getTemplates().empty() && !bRefresh)
|
if (!pItem->getTemplates().empty())
|
||||||
{
|
{
|
||||||
insertItems(pItem->getTemplates());
|
insertItems(pItem->getTemplates());
|
||||||
return true;
|
return true;
|
||||||
|
@ -223,7 +223,7 @@ IMPL_LINK_NOARG_TYPED(SfxNewFileDialog_Impl, Update, Idle*, void)
|
|||||||
SfxItemSet* pSet = new SfxAllItemSet(pSfxApp->GetPool());
|
SfxItemSet* pSet = new SfxAllItemSet(pSfxApp->GetPool());
|
||||||
pSet->Put(SfxBoolItem(SID_TEMPLATE, true));
|
pSet->Put(SfxBoolItem(SID_TEMPLATE, true));
|
||||||
pSet->Put(SfxBoolItem(SID_PREVIEW, true));
|
pSet->Put(SfxBoolItem(SID_PREVIEW, true));
|
||||||
lErr = pSfxApp->LoadTemplate(xDocShell, aFileName, true, pSet);
|
lErr = pSfxApp->LoadTemplate(xDocShell, aFileName, pSet);
|
||||||
if (lErr)
|
if (lErr)
|
||||||
ErrorHandler::HandleError(lErr);
|
ErrorHandler::HandleError(lErr);
|
||||||
Application::SetDefDialogParent(pParent);
|
Application::SetDefDialogParent(pParent);
|
||||||
|
@ -448,14 +448,12 @@ class SfxSaveGuard
|
|||||||
|
|
||||||
public:
|
public:
|
||||||
SfxSaveGuard(const Reference< frame::XModel >& xModel ,
|
SfxSaveGuard(const Reference< frame::XModel >& xModel ,
|
||||||
IMPL_SfxBaseModel_DataContainer* pData ,
|
IMPL_SfxBaseModel_DataContainer* pData);
|
||||||
bool bRejectConcurrentSaveRequest);
|
|
||||||
~SfxSaveGuard();
|
~SfxSaveGuard();
|
||||||
};
|
};
|
||||||
|
|
||||||
SfxSaveGuard::SfxSaveGuard(const Reference< frame::XModel >& xModel ,
|
SfxSaveGuard::SfxSaveGuard(const Reference< frame::XModel >& xModel ,
|
||||||
IMPL_SfxBaseModel_DataContainer* pData ,
|
IMPL_SfxBaseModel_DataContainer* pData)
|
||||||
bool bRejectConcurrentSaveRequest)
|
|
||||||
: m_xModel (xModel)
|
: m_xModel (xModel)
|
||||||
, m_pData (pData )
|
, m_pData (pData )
|
||||||
, m_pFramesLock(nullptr )
|
, m_pFramesLock(nullptr )
|
||||||
@ -463,13 +461,6 @@ SfxSaveGuard::SfxSaveGuard(const Reference< frame::XModel >& xModel
|
|||||||
if ( m_pData->m_bClosed )
|
if ( m_pData->m_bClosed )
|
||||||
throw lang::DisposedException("Object already disposed.");
|
throw lang::DisposedException("Object already disposed.");
|
||||||
|
|
||||||
if (
|
|
||||||
bRejectConcurrentSaveRequest &&
|
|
||||||
m_pData->m_bSaving
|
|
||||||
)
|
|
||||||
throw io::IOException(
|
|
||||||
"Concurrent save requests on the same document are not possible.");
|
|
||||||
|
|
||||||
m_pData->m_bSaving = true;
|
m_pData->m_bSaving = true;
|
||||||
m_pFramesLock = new SfxOwnFramesLocker(m_pData->m_pObjectShell);
|
m_pFramesLock = new SfxOwnFramesLocker(m_pData->m_pObjectShell);
|
||||||
}
|
}
|
||||||
@ -1522,7 +1513,7 @@ void SAL_CALL SfxBaseModel::storeSelf( const Sequence< beans::PropertyValue >
|
|||||||
if ( m_pData->m_pObjectShell.Is() )
|
if ( m_pData->m_pObjectShell.Is() )
|
||||||
{
|
{
|
||||||
m_pData->m_pObjectShell->AddLog( OSL_LOG_PREFIX "storeSelf" );
|
m_pData->m_pObjectShell->AddLog( OSL_LOG_PREFIX "storeSelf" );
|
||||||
SfxSaveGuard aSaveGuard(this, m_pData, false);
|
SfxSaveGuard aSaveGuard(this, m_pData);
|
||||||
|
|
||||||
bool bCheckIn = false;
|
bool bCheckIn = false;
|
||||||
for ( sal_Int32 nInd = 0; nInd < aSeqArgs.getLength(); nInd++ )
|
for ( sal_Int32 nInd = 0; nInd < aSeqArgs.getLength(); nInd++ )
|
||||||
@ -1651,7 +1642,7 @@ void SAL_CALL SfxBaseModel::storeAsURL( const OUString& rURL
|
|||||||
if ( m_pData->m_pObjectShell.Is() )
|
if ( m_pData->m_pObjectShell.Is() )
|
||||||
{
|
{
|
||||||
m_pData->m_pObjectShell->AddLog( OSL_LOG_PREFIX "storeAsURL" );
|
m_pData->m_pObjectShell->AddLog( OSL_LOG_PREFIX "storeAsURL" );
|
||||||
SfxSaveGuard aSaveGuard(this, m_pData, false);
|
SfxSaveGuard aSaveGuard(this, m_pData);
|
||||||
|
|
||||||
impl_store( rURL, rArgs, false );
|
impl_store( rURL, rArgs, false );
|
||||||
|
|
||||||
@ -1692,7 +1683,7 @@ void SAL_CALL SfxBaseModel::storeToURL( const OUString& rURL
|
|||||||
if ( m_pData->m_pObjectShell.Is() )
|
if ( m_pData->m_pObjectShell.Is() )
|
||||||
{
|
{
|
||||||
m_pData->m_pObjectShell->AddLog( OSL_LOG_PREFIX "storeToURL" );
|
m_pData->m_pObjectShell->AddLog( OSL_LOG_PREFIX "storeToURL" );
|
||||||
SfxSaveGuard aSaveGuard(this, m_pData, false);
|
SfxSaveGuard aSaveGuard(this, m_pData);
|
||||||
try {
|
try {
|
||||||
impl_store(rURL, rArgs, true);
|
impl_store(rURL, rArgs, true);
|
||||||
}
|
}
|
||||||
@ -1717,7 +1708,7 @@ void SAL_CALL SfxBaseModel::storeToRecoveryFile( const OUString& i_TargetLocatio
|
|||||||
SfxModelGuard aGuard( *this );
|
SfxModelGuard aGuard( *this );
|
||||||
|
|
||||||
// delegate
|
// delegate
|
||||||
SfxSaveGuard aSaveGuard( this, m_pData, false );
|
SfxSaveGuard aSaveGuard( this, m_pData );
|
||||||
impl_store( i_TargetLocation, i_MediaDescriptor, true );
|
impl_store( i_TargetLocation, i_MediaDescriptor, true );
|
||||||
|
|
||||||
// no need for subsequent calls to storeToRecoveryFile, unless we're modified, again
|
// no need for subsequent calls to storeToRecoveryFile, unless we're modified, again
|
||||||
|
@ -644,7 +644,7 @@ IMPL_LINK_TYPED(SfxTemplateManagerDlg, RepositoryMenuSelectHdl, Menu*, pMenu, bo
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (mpRemoteView->loadRepository(pRepository,false))
|
if (mpRemoteView->loadRepository(pRepository))
|
||||||
switchMainView(false);
|
switchMainView(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -41,7 +41,7 @@ class CntStaticPoolDefaults_Impl: private boost::noncopyable
|
|||||||
SfxItemInfo* m_pItemInfos;
|
SfxItemInfo* m_pItemInfos;
|
||||||
|
|
||||||
private:
|
private:
|
||||||
inline void Insert( SfxPoolItem* pItem, sal_uInt16 nSID, bool bPoolable );
|
inline void Insert( SfxPoolItem* pItem );
|
||||||
|
|
||||||
public:
|
public:
|
||||||
explicit CntStaticPoolDefaults_Impl( CntItemPool* pPool );
|
explicit CntStaticPoolDefaults_Impl( CntItemPool* pPool );
|
||||||
@ -157,14 +157,13 @@ sal_uInt16 CntItemPool::Release()
|
|||||||
|
|
||||||
|
|
||||||
inline void CntStaticPoolDefaults_Impl::Insert(
|
inline void CntStaticPoolDefaults_Impl::Insert(
|
||||||
SfxPoolItem* pItem, /* Static Pool Default Item */
|
SfxPoolItem* pItem /* Static Pool Default Item */ )
|
||||||
sal_uInt16 nSID, bool bPoolable /* Item Info */ )
|
|
||||||
{
|
{
|
||||||
sal_uInt16 nPos = pItem->Which() - WID_CHAOS_START;
|
sal_uInt16 nPos = pItem->Which() - WID_CHAOS_START;
|
||||||
|
|
||||||
m_ppDefaults[ nPos ] = pItem;
|
m_ppDefaults[ nPos ] = pItem;
|
||||||
m_pItemInfos[ nPos ]._nSID = nSID;
|
m_pItemInfos[ nPos ]._nSID = 0;
|
||||||
m_pItemInfos[ nPos ]._bPoolable = bPoolable;
|
m_pItemInfos[ nPos ]._bPoolable = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -185,10 +184,7 @@ CntStaticPoolDefaults_Impl::CntStaticPoolDefaults_Impl( CntItemPool* /*pPool*/ )
|
|||||||
{
|
{
|
||||||
memset( m_ppDefaults, 0, sizeof( SfxPoolItem* ) * m_nItems );
|
memset( m_ppDefaults, 0, sizeof( SfxPoolItem* ) * m_nItems );
|
||||||
memset( m_pItemInfos, 0, sizeof( SfxItemInfo ) * m_nItems );
|
memset( m_pItemInfos, 0, sizeof( SfxItemInfo ) * m_nItems );
|
||||||
Insert(
|
Insert( new SfxStringItem( WID_CHAOS_START, OUString() ) );
|
||||||
new SfxStringItem( WID_CHAOS_START, OUString() ),
|
|
||||||
0,
|
|
||||||
true );
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
|
||||||
|
@ -285,12 +285,12 @@ SfxFrame* SfxFrame::Create( const Reference < XFrame >& i_rFrame )
|
|||||||
vcl::Window* pWindow = VCLUnoHelper::GetWindow( i_rFrame->getContainerWindow() );
|
vcl::Window* pWindow = VCLUnoHelper::GetWindow( i_rFrame->getContainerWindow() );
|
||||||
ENSURE_OR_THROW( pWindow, "frame without container window not allowed" );
|
ENSURE_OR_THROW( pWindow, "frame without container window not allowed" );
|
||||||
|
|
||||||
SfxFrame* pFrame = new SfxFrame( *pWindow, false );
|
SfxFrame* pFrame = new SfxFrame( *pWindow );
|
||||||
pFrame->SetFrameInterface_Impl( i_rFrame );
|
pFrame->SetFrameInterface_Impl( i_rFrame );
|
||||||
return pFrame;
|
return pFrame;
|
||||||
}
|
}
|
||||||
|
|
||||||
SfxFrame::SfxFrame( vcl::Window& i_rContainerWindow, bool i_bHidden )
|
SfxFrame::SfxFrame( vcl::Window& i_rContainerWindow )
|
||||||
:SvCompatWeakBase<SfxFrame>( this )
|
:SvCompatWeakBase<SfxFrame>( this )
|
||||||
,pParentFrame( nullptr )
|
,pParentFrame( nullptr )
|
||||||
,pChildArr( nullptr )
|
,pChildArr( nullptr )
|
||||||
@ -299,7 +299,7 @@ SfxFrame::SfxFrame( vcl::Window& i_rContainerWindow, bool i_bHidden )
|
|||||||
{
|
{
|
||||||
Construct_Impl();
|
Construct_Impl();
|
||||||
|
|
||||||
pImp->bHidden = i_bHidden;
|
pImp->bHidden = false;
|
||||||
InsertTopFrame_Impl( this );
|
InsertTopFrame_Impl( this );
|
||||||
pImp->pExternalContainerWindow = &i_rContainerWindow;
|
pImp->pExternalContainerWindow = &i_rContainerWindow;
|
||||||
|
|
||||||
|
@ -73,9 +73,9 @@ class SfxBooleanFlagGuard
|
|||||||
bool& m_rFlag;
|
bool& m_rFlag;
|
||||||
bool m_bLifeValue;
|
bool m_bLifeValue;
|
||||||
public:
|
public:
|
||||||
SfxBooleanFlagGuard( bool& bFlag, bool bLifeValue )
|
SfxBooleanFlagGuard( bool& bFlag )
|
||||||
: m_rFlag( bFlag )
|
: m_rFlag( bFlag )
|
||||||
, m_bLifeValue( bLifeValue )
|
, m_bLifeValue( true )
|
||||||
{
|
{
|
||||||
m_rFlag = m_bLifeValue;
|
m_rFlag = m_bLifeValue;
|
||||||
}
|
}
|
||||||
@ -499,7 +499,7 @@ void SAL_CALL SfxInPlaceClient_Impl::changedPlacement( const awt::Rectangle& aPo
|
|||||||
{
|
{
|
||||||
// the calculation of the object area has not changed the object size
|
// the calculation of the object area has not changed the object size
|
||||||
// it should be done here then
|
// it should be done here then
|
||||||
SfxBooleanFlagGuard aGuard( m_bResizeNoScale, true );
|
SfxBooleanFlagGuard aGuard( m_bResizeNoScale );
|
||||||
|
|
||||||
// new size of the object area without scaling
|
// new size of the object area without scaling
|
||||||
Size aNewObjSize( Fraction( aNewLogicRect.GetWidth() ) / m_aScaleWidth,
|
Size aNewObjSize( Fraction( aNewLogicRect.GetWidth() ) / m_aScaleWidth,
|
||||||
|
@ -1416,7 +1416,7 @@ void SfxBaseController::ConnectSfxFrame_Impl( const ConnectSfxFrame i_eConnect )
|
|||||||
Sequence< PropertyValue > aViewData;
|
Sequence< PropertyValue > aViewData;
|
||||||
OSL_VERIFY( xViewData->getByIndex( nViewDataIndex ) >>= aViewData );
|
OSL_VERIFY( xViewData->getByIndex( nViewDataIndex ) >>= aViewData );
|
||||||
if ( aViewData.getLength() > 0 )
|
if ( aViewData.getLength() > 0 )
|
||||||
m_pData->m_pViewShell->ReadUserDataSequence( aViewData, true );
|
m_pData->m_pViewShell->ReadUserDataSequence( aViewData );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
catch (const Exception&)
|
catch (const Exception&)
|
||||||
|
@ -884,7 +884,7 @@ SfxPrinter* SfxViewShell::GetPrinter( bool /*bCreate*/ )
|
|||||||
return nullptr;
|
return nullptr;
|
||||||
}
|
}
|
||||||
|
|
||||||
sal_uInt16 SfxViewShell::SetPrinter( SfxPrinter* /*pNewPrinter*/, SfxPrinterChangeFlags /*nDiffFlags*/, bool )
|
sal_uInt16 SfxViewShell::SetPrinter( SfxPrinter* /*pNewPrinter*/, SfxPrinterChangeFlags /*nDiffFlags*/ )
|
||||||
{
|
{
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
@ -1399,7 +1399,7 @@ void SfxViewShell::ReadUserData(const OUString&, bool )
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
void SfxViewShell::ReadUserDataSequence ( const uno::Sequence < beans::PropertyValue >&, bool )
|
void SfxViewShell::ReadUserDataSequence ( const uno::Sequence < beans::PropertyValue >& )
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -266,7 +266,7 @@ protected:
|
|||||||
|
|
||||||
virtual SfxPrinter *GetPrinter(bool bCreate = false) override;
|
virtual SfxPrinter *GetPrinter(bool bCreate = false) override;
|
||||||
virtual sal_uInt16 SetPrinter(SfxPrinter *pNewPrinter,
|
virtual sal_uInt16 SetPrinter(SfxPrinter *pNewPrinter,
|
||||||
SfxPrinterChangeFlags nDiffFlags = SFX_PRINTER_ALL, bool bIsAPI=false) override;
|
SfxPrinterChangeFlags nDiffFlags = SFX_PRINTER_ALL) override;
|
||||||
|
|
||||||
void Insert( SfxMedium& rMedium );
|
void Insert( SfxMedium& rMedium );
|
||||||
void InsertFrom(SfxMedium &rMedium);
|
void InsertFrom(SfxMedium &rMedium);
|
||||||
|
@ -1277,7 +1277,7 @@ SfxPrinter* SmViewShell::GetPrinter(bool bCreate)
|
|||||||
return nullptr;
|
return nullptr;
|
||||||
}
|
}
|
||||||
|
|
||||||
sal_uInt16 SmViewShell::SetPrinter(SfxPrinter *pNewPrinter, SfxPrinterChangeFlags nDiffFlags, bool )
|
sal_uInt16 SmViewShell::SetPrinter(SfxPrinter *pNewPrinter, SfxPrinterChangeFlags nDiffFlags )
|
||||||
{
|
{
|
||||||
SfxPrinter *pOld = GetDoc()->GetPrinter();
|
SfxPrinter *pOld = GetDoc()->GetPrinter();
|
||||||
if ( pOld && pOld->IsPrinting() )
|
if ( pOld && pOld->IsPrinting() )
|
||||||
|
@ -384,7 +384,7 @@ public:
|
|||||||
virtual ErrCode DoVerb( long nVerb ) override;
|
virtual ErrCode DoVerb( long nVerb ) override;
|
||||||
|
|
||||||
virtual sal_uInt16 SetPrinter( SfxPrinter* pNew,
|
virtual sal_uInt16 SetPrinter( SfxPrinter* pNew,
|
||||||
SfxPrinterChangeFlags nDiff = SFX_PRINTER_ALL, bool bIsAPI=false) override;
|
SfxPrinterChangeFlags nDiff = SFX_PRINTER_ALL) override;
|
||||||
ShellModes GetShellMode();
|
ShellModes GetShellMode();
|
||||||
|
|
||||||
css::view::XSelectionSupplier* GetUNOObject();
|
css::view::XSelectionSupplier* GetUNOObject();
|
||||||
@ -575,7 +575,7 @@ public:
|
|||||||
|
|
||||||
virtual void WriteUserData(OUString &, bool bBrowse = false) override;
|
virtual void WriteUserData(OUString &, bool bBrowse = false) override;
|
||||||
virtual void ReadUserData(const OUString &, bool bBrowse = false) override;
|
virtual void ReadUserData(const OUString &, bool bBrowse = false) override;
|
||||||
virtual void ReadUserDataSequence ( const css::uno::Sequence < css::beans::PropertyValue >&, bool bBrowse ) override;
|
virtual void ReadUserDataSequence ( const css::uno::Sequence < css::beans::PropertyValue >& ) override;
|
||||||
virtual void WriteUserDataSequence ( css::uno::Sequence < css::beans::PropertyValue >& ) override;
|
virtual void WriteUserDataSequence ( css::uno::Sequence < css::beans::PropertyValue >& ) override;
|
||||||
|
|
||||||
void SetCursorAtTop( bool bFlag, bool bCenter = false )
|
void SetCursorAtTop( bool bFlag, bool bCenter = false )
|
||||||
|
@ -1316,7 +1316,7 @@ void SwSidebarWin::ExecuteCommand(sal_uInt16 nSlot)
|
|||||||
case FN_DELETE_ALL_NOTES:
|
case FN_DELETE_ALL_NOTES:
|
||||||
case FN_HIDE_ALL_NOTES:
|
case FN_HIDE_ALL_NOTES:
|
||||||
// not possible as slot as this would require that "this" is the active postit
|
// not possible as slot as this would require that "this" is the active postit
|
||||||
mrView.GetViewFrame()->GetBindings().Execute( nSlot, nullptr, 0, SfxCallMode::ASYNCHRON );
|
mrView.GetViewFrame()->GetBindings().Execute( nSlot, nullptr, SfxCallMode::ASYNCHRON );
|
||||||
break;
|
break;
|
||||||
case FN_DELETE_NOTE_AUTHOR:
|
case FN_DELETE_NOTE_AUTHOR:
|
||||||
case FN_HIDE_NOTE_AUTHOR:
|
case FN_HIDE_NOTE_AUTHOR:
|
||||||
@ -1326,7 +1326,7 @@ void SwSidebarWin::ExecuteCommand(sal_uInt16 nSlot)
|
|||||||
const SfxPoolItem* aItems[2];
|
const SfxPoolItem* aItems[2];
|
||||||
aItems[0] = &aItem;
|
aItems[0] = &aItem;
|
||||||
aItems[1] = nullptr;
|
aItems[1] = nullptr;
|
||||||
mrView.GetViewFrame()->GetBindings().Execute( nSlot, aItems, 0, SfxCallMode::ASYNCHRON );
|
mrView.GetViewFrame()->GetBindings().Execute( nSlot, aItems, SfxCallMode::ASYNCHRON );
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
@ -3318,7 +3318,7 @@ void SwEditWin::MouseButtonDown(const MouseEvent& _rMEvt)
|
|||||||
if (!comphelper::LibreOfficeKit::isActive())
|
if (!comphelper::LibreOfficeKit::isActive())
|
||||||
{
|
{
|
||||||
GetView().GetViewFrame()->GetBindings().Execute(
|
GetView().GetViewFrame()->GetBindings().Execute(
|
||||||
FN_FORMAT_GRAFIC_DLG, nullptr, 0,
|
FN_FORMAT_GRAFIC_DLG, nullptr,
|
||||||
SfxCallMode::RECORD|SfxCallMode::SLOT);
|
SfxCallMode::RECORD|SfxCallMode::SLOT);
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
@ -3337,7 +3337,7 @@ void SwEditWin::MouseButtonDown(const MouseEvent& _rMEvt)
|
|||||||
if (!comphelper::LibreOfficeKit::isActive())
|
if (!comphelper::LibreOfficeKit::isActive())
|
||||||
{
|
{
|
||||||
GetView().GetViewFrame()->GetBindings().Execute(
|
GetView().GetViewFrame()->GetBindings().Execute(
|
||||||
FN_FORMAT_FRAME_DLG, nullptr, 0,
|
FN_FORMAT_FRAME_DLG, nullptr,
|
||||||
SfxCallMode::RECORD|SfxCallMode::SLOT);
|
SfxCallMode::RECORD|SfxCallMode::SLOT);
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
|
@ -199,7 +199,7 @@ class SW_DLLPUBLIC SwPagePreview: public SfxViewShell
|
|||||||
SAL_DLLPRIVATE bool ChgPage( int eMvMode, bool bUpdateScrollbar = true );
|
SAL_DLLPRIVATE bool ChgPage( int eMvMode, bool bUpdateScrollbar = true );
|
||||||
|
|
||||||
SAL_DLLPRIVATE virtual SfxPrinter* GetPrinter( bool bCreate = false ) override;
|
SAL_DLLPRIVATE virtual SfxPrinter* GetPrinter( bool bCreate = false ) override;
|
||||||
SAL_DLLPRIVATE virtual sal_uInt16 SetPrinter( SfxPrinter *pNewPrinter, SfxPrinterChangeFlags nDiffFlags = SFX_PRINTER_ALL, bool bIsAPI=false ) override;
|
SAL_DLLPRIVATE virtual sal_uInt16 SetPrinter( SfxPrinter *pNewPrinter, SfxPrinterChangeFlags nDiffFlags = SFX_PRINTER_ALL ) override;
|
||||||
SAL_DLLPRIVATE virtual bool HasPrintOptionsPage() const override;
|
SAL_DLLPRIVATE virtual bool HasPrintOptionsPage() const override;
|
||||||
SAL_DLLPRIVATE virtual VclPtr<SfxTabPage> CreatePrintOptionsPage(vcl::Window *pParent, const SfxItemSet &rOptions ) override;
|
SAL_DLLPRIVATE virtual VclPtr<SfxTabPage> CreatePrintOptionsPage(vcl::Window *pParent, const SfxItemSet &rOptions ) override;
|
||||||
|
|
||||||
|
@ -76,7 +76,7 @@ public:
|
|||||||
|
|
||||||
void Load(SwDocShell* pDocShell);
|
void Load(SwDocShell* pDocShell);
|
||||||
|
|
||||||
virtual sal_uInt16 SetPrinter( SfxPrinter* pNew, SfxPrinterChangeFlags nDiff = SFX_PRINTER_ALL, bool bIsAPI=false ) override;
|
virtual sal_uInt16 SetPrinter( SfxPrinter* pNew, SfxPrinterChangeFlags nDiff = SFX_PRINTER_ALL ) override;
|
||||||
virtual SfxPrinter* GetPrinter( bool bCreate = false ) override;
|
virtual SfxPrinter* GetPrinter( bool bCreate = false ) override;
|
||||||
|
|
||||||
sal_Int32 PrintSource( OutputDevice *pOutDev, sal_Int32 nPage, bool bCalcNumPagesOnly );
|
sal_Int32 PrintSource( OutputDevice *pOutDev, sal_Int32 nPage, bool bCalcNumPagesOnly );
|
||||||
|
@ -392,7 +392,7 @@ void SwInputWindow::ApplyFormula()
|
|||||||
const SfxPoolItem* aArgs[2];
|
const SfxPoolItem* aArgs[2];
|
||||||
aArgs[0] = &aParam;
|
aArgs[0] = &aParam;
|
||||||
aArgs[1] = nullptr;
|
aArgs[1] = nullptr;
|
||||||
pView->GetViewFrame()->GetBindings().Execute( FN_EDIT_FORMULA, aArgs, 0, SfxCallMode::ASYNCHRON );
|
pView->GetViewFrame()->GetBindings().Execute( FN_EDIT_FORMULA, aArgs, SfxCallMode::ASYNCHRON );
|
||||||
}
|
}
|
||||||
|
|
||||||
void SwInputWindow::CancelFormula()
|
void SwInputWindow::CancelFormula()
|
||||||
|
@ -509,7 +509,7 @@ void SwPagePreviewWin::MouseButtonDown( const MouseEvent& rMEvt )
|
|||||||
mrView.SetNewCursorPos( sNewCursorPos );
|
mrView.SetNewCursorPos( sNewCursorPos );
|
||||||
|
|
||||||
SfxViewFrame *pTmpFrame = mrView.GetViewFrame();
|
SfxViewFrame *pTmpFrame = mrView.GetViewFrame();
|
||||||
pTmpFrame->GetBindings().Execute( SID_VIEWSHELL0, nullptr, 0,
|
pTmpFrame->GetBindings().Execute( SID_VIEWSHELL0, nullptr,
|
||||||
SfxCallMode::ASYNCHRON );
|
SfxCallMode::ASYNCHRON );
|
||||||
}
|
}
|
||||||
else if ( bIsDocPos || bPosInEmptyPage )
|
else if ( bIsDocPos || bPosInEmptyPage )
|
||||||
@ -957,7 +957,7 @@ MOVEPAGE:
|
|||||||
nSelPage +=2;
|
nSelPage +=2;
|
||||||
SetNewPage( nSelPage );
|
SetNewPage( nSelPage );
|
||||||
SfxViewFrame *pTmpFrame = GetViewFrame();
|
SfxViewFrame *pTmpFrame = GetViewFrame();
|
||||||
pTmpFrame->GetBindings().Execute( SID_VIEWSHELL0, nullptr, 0,
|
pTmpFrame->GetBindings().Execute( SID_VIEWSHELL0, nullptr,
|
||||||
SfxCallMode::ASYNCHRON );
|
SfxCallMode::ASYNCHRON );
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@ -1668,7 +1668,7 @@ SfxPrinter* SwPagePreview::GetPrinter( bool bCreate )
|
|||||||
return pViewWin->GetViewShell()->getIDocumentDeviceAccess().getPrinter( bCreate );
|
return pViewWin->GetViewShell()->getIDocumentDeviceAccess().getPrinter( bCreate );
|
||||||
}
|
}
|
||||||
|
|
||||||
sal_uInt16 SwPagePreview::SetPrinter( SfxPrinter *pNew, SfxPrinterChangeFlags nDiffFlags, bool )
|
sal_uInt16 SwPagePreview::SetPrinter( SfxPrinter *pNew, SfxPrinterChangeFlags nDiffFlags )
|
||||||
{
|
{
|
||||||
SwViewShell &rSh = *GetViewShell();
|
SwViewShell &rSh = *GetViewShell();
|
||||||
SfxPrinter* pOld = rSh.getIDocumentDeviceAccess().getPrinter( false );
|
SfxPrinter* pOld = rSh.getIDocumentDeviceAccess().getPrinter( false );
|
||||||
|
@ -660,7 +660,7 @@ void SwSrcView::StartSearchAndReplace(const SvxSearchItem& rSearchItem,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
sal_uInt16 SwSrcView::SetPrinter(SfxPrinter* pNew, SfxPrinterChangeFlags nDiffFlags, bool )
|
sal_uInt16 SwSrcView::SetPrinter(SfxPrinter* pNew, SfxPrinterChangeFlags nDiffFlags )
|
||||||
{
|
{
|
||||||
SwDocShell* pDocSh = GetDocShell();
|
SwDocShell* pDocSh = GetDocShell();
|
||||||
if ( (SfxPrinterChangeFlags::JOBSETUP | SfxPrinterChangeFlags::PRINTER) & nDiffFlags )
|
if ( (SfxPrinterChangeFlags::JOBSETUP | SfxPrinterChangeFlags::PRINTER) & nDiffFlags )
|
||||||
|
@ -1236,13 +1236,13 @@ void SwView::ReadUserData( const OUString &rUserData, bool bBrowse )
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void SwView::ReadUserDataSequence ( const uno::Sequence < beans::PropertyValue >& rSequence, bool bBrowse )
|
void SwView::ReadUserDataSequence ( const uno::Sequence < beans::PropertyValue >& rSequence )
|
||||||
{
|
{
|
||||||
if(GetDocShell()->IsPreview()||m_bIsPreviewDoubleClick)
|
if(GetDocShell()->IsPreview()||m_bIsPreviewDoubleClick)
|
||||||
return;
|
return;
|
||||||
bool bIsOwnDocument = lcl_IsOwnDocument( *this );
|
bool bIsOwnDocument = lcl_IsOwnDocument( *this );
|
||||||
sal_Int32 nLength = rSequence.getLength();
|
sal_Int32 nLength = rSequence.getLength();
|
||||||
if (nLength && (!m_pWrtShell->IsNewLayout() || m_pWrtShell->GetViewOptions()->getBrowseMode() || bBrowse) )
|
if (nLength)
|
||||||
{
|
{
|
||||||
SET_CURR_SHELL(m_pWrtShell);
|
SET_CURR_SHELL(m_pWrtShell);
|
||||||
const beans::PropertyValue *pValue = rSequence.getConstArray();
|
const beans::PropertyValue *pValue = rSequence.getConstArray();
|
||||||
@ -1251,7 +1251,8 @@ void SwView::ReadUserDataSequence ( const uno::Sequence < beans::PropertyValue >
|
|||||||
const SwViewOption* pVOpt = m_pWrtShell->GetViewOptions();
|
const SwViewOption* pVOpt = m_pWrtShell->GetViewOptions();
|
||||||
|
|
||||||
sal_Int64 nX = rRect.Left(), nY = rRect.Top(), nLeft = rVis.Left(), nTop = rVis.Top();
|
sal_Int64 nX = rRect.Left(), nY = rRect.Top(), nLeft = rVis.Left(), nTop = rVis.Top();
|
||||||
sal_Int64 nRight = bBrowse ? LONG_MIN : rVis.Right(), nBottom = bBrowse ? LONG_MIN : rVis.Bottom();
|
sal_Int64 nRight = LONG_MIN;
|
||||||
|
sal_Int64 nBottom = LONG_MIN;
|
||||||
sal_Int16 nZoomType = static_cast< sal_Int16 >(pVOpt->GetZoomType());
|
sal_Int16 nZoomType = static_cast< sal_Int16 >(pVOpt->GetZoomType());
|
||||||
sal_Int16 nZoomFactor = static_cast < sal_Int16 > (pVOpt->GetZoom());
|
sal_Int16 nZoomFactor = static_cast < sal_Int16 > (pVOpt->GetZoom());
|
||||||
bool bViewLayoutBookMode = pVOpt->IsViewLayoutBookMode();
|
bool bViewLayoutBookMode = pVOpt->IsViewLayoutBookMode();
|
||||||
@ -1422,7 +1423,7 @@ void SwView::ReadUserDataSequence ( const uno::Sequence < beans::PropertyValue >
|
|||||||
// go to the last editing position when opening own files
|
// go to the last editing position when opening own files
|
||||||
if(m_bOldShellWasPagePreview||bIsOwnDocument)
|
if(m_bOldShellWasPagePreview||bIsOwnDocument)
|
||||||
{
|
{
|
||||||
if ( bBrowse && bGotVisibleLeft && bGotVisibleTop )
|
if ( bGotVisibleLeft && bGotVisibleTop )
|
||||||
{
|
{
|
||||||
Point aTopLeft(aVis.TopLeft());
|
Point aTopLeft(aVis.TopLeft());
|
||||||
// make sure the document is still centered
|
// make sure the document is still centered
|
||||||
|
@ -104,7 +104,7 @@ void SetPrinter( IDocumentDeviceAccess* pIDDA, SfxPrinter* pNew, bool bWeb )
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
sal_uInt16 SwView::SetPrinter(SfxPrinter* pNew, SfxPrinterChangeFlags nDiffFlags, bool )
|
sal_uInt16 SwView::SetPrinter(SfxPrinter* pNew, SfxPrinterChangeFlags nDiffFlags )
|
||||||
{
|
{
|
||||||
SwWrtShell &rSh = GetWrtShell();
|
SwWrtShell &rSh = GetWrtShell();
|
||||||
SfxPrinter* pOld = rSh.getIDocumentDeviceAccess().getPrinter( false );
|
SfxPrinter* pOld = rSh.getIDocumentDeviceAccess().getPrinter( false );
|
||||||
|
@ -519,7 +519,7 @@ void LoadURL( SwViewShell& rVSh, const OUString& rURL, sal_uInt16 nFilter,
|
|||||||
nullptr
|
nullptr
|
||||||
};
|
};
|
||||||
|
|
||||||
pViewFrame->GetDispatcher()->GetBindings()->Execute( SID_OPENDOC, aArr, 0,
|
pViewFrame->GetDispatcher()->GetBindings()->Execute( SID_OPENDOC, aArr,
|
||||||
SfxCallMode::ASYNCHRON|SfxCallMode::RECORD );
|
SfxCallMode::ASYNCHRON|SfxCallMode::RECORD );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user