summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--basctl/source/basicide/basdoc.cxx2
-rw-r--r--basctl/source/basicide/basidesh.cxx2
-rw-r--r--basctl/source/basicide/basobj3.cxx4
-rw-r--r--basctl/source/basicide/macrodlg.cxx14
-rw-r--r--basctl/source/basicide/moduldl2.cxx4
-rw-r--r--basctl/source/basicide/moduldlg.cxx4
-rw-r--r--basctl/source/basicide/scriptdocument.cxx8
-rw-r--r--cui/source/dialogs/SpellDialog.cxx2
-rw-r--r--cui/source/dialogs/cuicharmap.cxx2
-rw-r--r--cui/source/dialogs/cuifmsearch.cxx2
-rw-r--r--cui/source/dialogs/cuihyperdlg.cxx6
-rw-r--r--cui/source/dialogs/hltpbase.cxx2
-rw-r--r--cui/source/factory/dlgfact.cxx2
-rw-r--r--cui/source/options/optpath.cxx2
-rw-r--r--cui/source/options/treeopt.cxx26
-rw-r--r--desktop/source/app/app.cxx4
-rw-r--r--desktop/source/app/dispatchwatcher.cxx2
-rw-r--r--extensions/source/propctrlr/formcomponenthandler.cxx2
-rw-r--r--include/sfx2/app.hxx2
-rw-r--r--sc/source/core/data/validat.cxx2
-rw-r--r--sc/source/core/tool/compiler.cxx2
-rw-r--r--sc/source/core/tool/interpr4.cxx2
-rw-r--r--sc/source/core/tool/progress.cxx2
-rw-r--r--sc/source/ui/app/inputhdl.cxx10
-rw-r--r--sc/source/ui/app/inputwin.cxx4
-rw-r--r--sc/source/ui/app/scmod.cxx12
-rw-r--r--sc/source/ui/dbgui/validate.cxx2
-rw-r--r--sc/source/ui/docshell/dbdocfun.cxx6
-rw-r--r--sc/source/ui/docshell/docfunc.cxx28
-rw-r--r--sc/source/ui/docshell/docsh.cxx6
-rw-r--r--sc/source/ui/docshell/docsh3.cxx2
-rw-r--r--sc/source/ui/docshell/docsh4.cxx2
-rw-r--r--sc/source/ui/docshell/docsh5.cxx8
-rw-r--r--sc/source/ui/docshell/externalrefmgr.cxx2
-rw-r--r--sc/source/ui/docshell/servobj.cxx8
-rw-r--r--sc/source/ui/docshell/tablink.cxx4
-rw-r--r--sc/source/ui/drawfunc/drawsh.cxx4
-rw-r--r--sc/source/ui/miscdlgs/anyrefdg.cxx2
-rw-r--r--sc/source/ui/namedlg/namedefdlg.cxx2
-rw-r--r--sc/source/ui/navipi/navipi.cxx4
-rw-r--r--sc/source/ui/undo/undoblk.cxx16
-rw-r--r--sc/source/ui/undo/undoblk3.cxx8
-rw-r--r--sc/source/ui/undo/undocell.cxx2
-rw-r--r--sc/source/ui/undo/undodat.cxx8
-rw-r--r--sc/source/ui/undo/undorangename.cxx6
-rw-r--r--sc/source/ui/undo/undotab.cxx20
-rw-r--r--sc/source/ui/unoobj/appluno.cxx2
-rw-r--r--sc/source/ui/unoobj/funcuno.cxx2
-rw-r--r--sc/source/ui/unoobj/servuno.cxx2
-rw-r--r--sc/source/ui/unoobj/viewuno.cxx2
-rw-r--r--sc/source/ui/vba/vbaapplication.cxx8
-rw-r--r--sc/source/ui/vba/vbahelper.cxx4
-rw-r--r--sc/source/ui/vba/vbarange.cxx2
-rw-r--r--sc/source/ui/view/dbfunc.cxx2
-rw-r--r--sc/source/ui/view/dbfunc3.cxx2
-rw-r--r--sc/source/ui/view/prevwsh.cxx4
-rw-r--r--sc/source/ui/view/tabvwsh4.cxx6
-rw-r--r--sc/source/ui/view/tabvwshb.cxx2
-rw-r--r--sc/source/ui/view/viewfun2.cxx16
-rw-r--r--sc/source/ui/view/viewfunc.cxx4
-rw-r--r--scripting/source/basprov/basprov.cxx4
-rw-r--r--scripting/source/dlgprov/dlgevtatt.cxx2
-rw-r--r--scripting/source/dlgprov/dlgprov.cxx2
-rw-r--r--sd/source/core/drawdoc3.cxx2
-rw-r--r--sd/source/ui/app/sdmod.cxx2
-rw-r--r--sd/source/ui/app/sdmod1.cxx16
-rw-r--r--sd/source/ui/dlg/dlgass.cxx6
-rw-r--r--sd/source/ui/func/fuinsfil.cxx6
-rw-r--r--sd/source/ui/sidebar/MasterPageContainerProviders.cxx2
-rw-r--r--sd/source/ui/table/TableDesignPane.cxx4
-rw-r--r--sd/source/ui/view/drviewsg.cxx2
-rw-r--r--sd/source/ui/view/sdview4.cxx2
-rw-r--r--sfx2/source/appl/appbaslib.cxx8
-rw-r--r--sfx2/source/appl/appcfg.cxx2
-rw-r--r--sfx2/source/appl/appdde.cxx8
-rw-r--r--sfx2/source/appl/appdispatchprovider.cxx6
-rw-r--r--sfx2/source/appl/appinit.cxx4
-rw-r--r--sfx2/source/appl/appopen.cxx6
-rw-r--r--sfx2/source/appl/childwin.cxx8
-rw-r--r--sfx2/source/appl/linkmgr2.cxx2
-rw-r--r--sfx2/source/appl/macroloader.cxx2
-rw-r--r--sfx2/source/appl/module.cxx4
-rw-r--r--sfx2/source/appl/sfxpicklist.cxx6
-rw-r--r--sfx2/source/appl/shutdownicon.cxx2
-rw-r--r--sfx2/source/appl/workwin.cxx4
-rw-r--r--sfx2/source/bastyp/progress.cxx16
-rw-r--r--sfx2/source/control/bindings.cxx16
-rw-r--r--sfx2/source/control/dispatch.cxx22
-rw-r--r--sfx2/source/control/msgpool.cxx2
-rw-r--r--sfx2/source/control/objface.cxx4
-rw-r--r--sfx2/source/control/statcach.cxx2
-rw-r--r--sfx2/source/control/unoctitm.cxx8
-rw-r--r--sfx2/source/dialog/filedlghelper.cxx8
-rw-r--r--sfx2/source/dialog/mgetempl.cxx2
-rw-r--r--sfx2/source/dialog/tabdlg.cxx8
-rw-r--r--sfx2/source/dialog/templdlg.cxx6
-rw-r--r--sfx2/source/doc/docfile.cxx10
-rw-r--r--sfx2/source/doc/docinsert.cxx10
-rw-r--r--sfx2/source/doc/frmdescr.cxx4
-rw-r--r--sfx2/source/doc/guisaveas.cxx2
-rw-r--r--sfx2/source/doc/new.cxx2
-rw-r--r--sfx2/source/doc/objcont.cxx2
-rw-r--r--sfx2/source/doc/objembed.cxx2
-rw-r--r--sfx2/source/doc/objmisc.cxx14
-rw-r--r--sfx2/source/doc/objserv.cxx2
-rw-r--r--sfx2/source/doc/objstor.cxx10
-rw-r--r--sfx2/source/doc/objxtor.cxx8
-rw-r--r--sfx2/source/doc/sfxbasemodel.cxx26
-rw-r--r--sfx2/source/doc/templatedlg.cxx2
-rw-r--r--sfx2/source/menu/mnuitem.cxx4
-rw-r--r--sfx2/source/menu/virtmenu.cxx2
-rw-r--r--sfx2/source/notify/eventsupplier.cxx6
-rw-r--r--sfx2/source/notify/globalevents.cxx2
-rw-r--r--sfx2/source/sidebar/Theme.cxx2
-rw-r--r--sfx2/source/statbar/stbitem.cxx4
-rw-r--r--sfx2/source/toolbox/tbxitem.cxx8
-rw-r--r--sfx2/source/view/frame.cxx8
-rw-r--r--sfx2/source/view/frmload.cxx10
-rw-r--r--sfx2/source/view/sfxbasecontroller.cxx6
-rw-r--r--sfx2/source/view/viewfrm.cxx38
-rw-r--r--sfx2/source/view/viewfrm2.cxx2
-rw-r--r--sfx2/source/view/viewprn.cxx2
-rw-r--r--sfx2/source/view/viewsh.cxx20
-rw-r--r--starmath/source/document.cxx6
-rw-r--r--svx/source/dialog/databaseregistrationui.cxx2
-rw-r--r--svx/source/dialog/hyperdlg.cxx2
-rw-r--r--svx/source/dialog/srchdlg.cxx6
-rw-r--r--svx/source/form/fmscriptingenv.cxx2
-rw-r--r--svx/source/form/fmshell.cxx2
-rw-r--r--svx/source/form/fmtextcontrolshell.cxx8
-rw-r--r--svx/source/gallery2/galbrws1.cxx2
-rw-r--r--svx/source/unodraw/unoshap2.cxx2
-rw-r--r--sw/qa/core/filters-test.cxx2
-rw-r--r--sw/source/filter/html/htmlbas.cxx2
-rw-r--r--sw/source/ui/dbui/mmoutputpage.cxx4
-rw-r--r--sw/source/ui/index/cnttab.cxx2
-rw-r--r--sw/source/uibase/app/appopt.cxx4
-rw-r--r--sw/source/uibase/app/docsh2.cxx4
-rw-r--r--sw/source/uibase/app/docst.cxx2
-rw-r--r--sw/source/uibase/app/swmodule.cxx4
-rw-r--r--sw/source/uibase/dbui/dbmgr.cxx12
-rw-r--r--sw/source/uibase/shells/textsh1.cxx2
-rw-r--r--sw/source/uibase/uiview/view2.cxx4
-rw-r--r--sw/source/uibase/uno/unomailmerge.cxx4
-rw-r--r--sw/source/uibase/utlui/navipi.cxx4
-rw-r--r--uui/source/iahndl.cxx2
-rw-r--r--vbahelper/source/vbahelper/vbahelper.cxx4
147 files changed, 412 insertions, 414 deletions
diff --git a/basctl/source/basicide/basdoc.cxx b/basctl/source/basicide/basdoc.cxx
index c1dddbaa99c5..aa78bea3b8f6 100644
--- a/basctl/source/basicide/basdoc.cxx
+++ b/basctl/source/basicide/basdoc.cxx
@@ -49,7 +49,7 @@ void basctl_DocShell::InitInterface_Impl()
DocShell::DocShell()
:SfxObjectShell( SFXMODEL_DISABLE_EMBEDDED_SCRIPTS | SFXMODEL_DISABLE_DOCUMENT_RECOVERY )
{
- SetPool( &SFX_APP()->GetPool() );
+ SetPool( &SfxGetpApp()->GetPool() );
SetBaseModel( new SIDEModel(this) );
}
diff --git a/basctl/source/basicide/basidesh.cxx b/basctl/source/basicide/basidesh.cxx
index f66f8ca44613..18be9999cbf8 100644
--- a/basctl/source/basicide/basidesh.cxx
+++ b/basctl/source/basicide/basidesh.cxx
@@ -370,7 +370,7 @@ void Shell::StoreAllWindowData( bool bPersistent )
if ( bPersistent )
{
- SFX_APP()->SaveBasicAndDialogContainer();
+ SfxGetpApp()->SaveBasicAndDialogContainer();
SetAppBasicModified(false);
if (SfxBindings* pBindings = GetBindingsPtr())
diff --git a/basctl/source/basicide/basobj3.cxx b/basctl/source/basicide/basobj3.cxx
index ccc1e23cfb6a..6a3f5998a6b5 100644
--- a/basctl/source/basicide/basobj3.cxx
+++ b/basctl/source/basicide/basobj3.cxx
@@ -422,9 +422,9 @@ long HandleBasicError( StarBASIC* pBasic )
pShell = GetShell();
if ( !pShell )
{
- SfxAllItemSet aArgs( SFX_APP()->GetPool() );
+ SfxAllItemSet aArgs( SfxGetpApp()->GetPool() );
SfxRequest aRequest( SID_BASICIDE_APPEAR, SFX_CALLMODE_SYNCHRON, aArgs );
- SFX_APP()->ExecuteSlot( aRequest );
+ SfxGetpApp()->ExecuteSlot( aRequest );
pShell = GetShell();
}
}
diff --git a/basctl/source/basicide/macrodlg.cxx b/basctl/source/basicide/macrodlg.cxx
index d5969d18becf..55f4f8010dbd 100644
--- a/basctl/source/basicide/macrodlg.cxx
+++ b/basctl/source/basicide/macrodlg.cxx
@@ -125,7 +125,7 @@ MacroChooser::MacroChooser( Window* pParnt, bool bCreateEntries )
MacroChooser::~MacroChooser()
{
if ( bForceStoreBasic )
- SFX_APP()->SaveBasicAndDialogContainer();
+ SfxGetpApp()->SaveBasicAndDialogContainer();
}
void MacroChooser::StoreMacroDescription()
@@ -674,9 +674,9 @@ IMPL_LINK( MacroChooser, ButtonHdl, Button *, pButton )
if ( pEntry )
aInfoItem.SetMethod( m_pMacroBox->GetEntryText( pEntry ) );
StoreMacroDescription();
- SfxAllItemSet aArgs( SFX_APP()->GetPool() );
+ SfxAllItemSet aArgs( SfxGetpApp()->GetPool() );
SfxRequest aRequest( SID_BASICIDE_APPEAR, SFX_CALLMODE_SYNCHRON, aArgs );
- SFX_APP()->ExecuteSlot( aRequest );
+ SfxGetpApp()->ExecuteSlot( aRequest );
if (SfxDispatcher* pDispatcher = GetDispatcher())
pDispatcher->Execute( SID_BASICIDE_EDITMACRO, SFX_CALLMODE_ASYNCHRON, &aInfoItem, 0L );
@@ -710,9 +710,9 @@ IMPL_LINK( MacroChooser, ButtonHdl, Button *, pButton )
aInfoItem.SetMethod( pMethod->GetName() );
aInfoItem.SetModule( pMethod->GetModule()->GetName() );
aInfoItem.SetLib( pMethod->GetModule()->GetParent()->GetName() );
- SfxAllItemSet aArgs( SFX_APP()->GetPool() );
+ SfxAllItemSet aArgs( SfxGetpApp()->GetPool() );
SfxRequest aRequest( SID_BASICIDE_APPEAR, SFX_CALLMODE_SYNCHRON, aArgs );
- SFX_APP()->ExecuteSlot( aRequest );
+ SfxGetpApp()->ExecuteSlot( aRequest );
if (SfxDispatcher* pDispatcher = GetDispatcher())
pDispatcher->Execute( SID_BASICIDE_EDITMACRO, SFX_CALLMODE_ASYNCHRON, &aInfoItem, 0L );
@@ -739,10 +739,10 @@ IMPL_LINK( MacroChooser, ButtonHdl, Button *, pButton )
DBG_ASSERT( pMethod, "Method?" );
OUString aComment( GetInfo( pMethod ) );
SfxMacroInfoItem aItem( SID_MACROINFO, pBasMgr, aLib, aMod, aSub, aComment );
- SfxAllItemSet Args( SFX_APP()->GetPool() );
+ SfxAllItemSet Args( SfxGetpApp()->GetPool() );
SfxRequest aRequest( SID_CONFIG, SFX_CALLMODE_SYNCHRON, Args );
aRequest.AppendItem( aItem );
- SFX_APP()->ExecuteSlot( aRequest );
+ SfxGetpApp()->ExecuteSlot( aRequest );
}
else if (pButton == m_pNewLibButton)
{
diff --git a/basctl/source/basicide/moduldl2.cxx b/basctl/source/basicide/moduldl2.cxx
index 3a22d5714c16..199c5d4986c9 100644
--- a/basctl/source/basicide/moduldl2.cxx
+++ b/basctl/source/basicide/moduldl2.cxx
@@ -576,9 +576,9 @@ IMPL_LINK( LibPage, ButtonHdl, Button *, pButton )
{
if (pButton == m_pEditButton)
{
- SfxAllItemSet aArgs( SFX_APP()->GetPool() );
+ SfxAllItemSet aArgs( SfxGetpApp()->GetPool() );
SfxRequest aRequest( SID_BASICIDE_APPEAR, SFX_CALLMODE_SYNCHRON, aArgs );
- SFX_APP()->ExecuteSlot( aRequest );
+ SfxGetpApp()->ExecuteSlot( aRequest );
SfxUsrAnyItem aDocItem( SID_BASICIDE_ARG_DOCUMENT_MODEL, makeAny( m_aCurDocument.getDocumentOrNull() ) );
SvTreeListEntry* pCurEntry = m_pLibBox->GetCurEntry();
diff --git a/basctl/source/basicide/moduldlg.cxx b/basctl/source/basicide/moduldlg.cxx
index 35f631659f23..dbae1502e23d 100644
--- a/basctl/source/basicide/moduldlg.cxx
+++ b/basctl/source/basicide/moduldlg.cxx
@@ -679,9 +679,9 @@ IMPL_LINK( ObjectPage, ButtonHdl, Button *, pButton )
{
if (pButton == m_pEditButton)
{
- SfxAllItemSet aArgs( SFX_APP()->GetPool() );
+ SfxAllItemSet aArgs( SfxGetpApp()->GetPool() );
SfxRequest aRequest( SID_BASICIDE_APPEAR, SFX_CALLMODE_SYNCHRON, aArgs );
- SFX_APP()->ExecuteSlot( aRequest );
+ SfxGetpApp()->ExecuteSlot( aRequest );
SfxDispatcher* pDispatcher = GetDispatcher();
SvTreeListEntry* pCurEntry = m_pBasicBox->GetCurEntry();
diff --git a/basctl/source/basicide/scriptdocument.cxx b/basctl/source/basicide/scriptdocument.cxx
index 4847ad098d92..c4f54e350118 100644
--- a/basctl/source/basicide/scriptdocument.cxx
+++ b/basctl/source/basicide/scriptdocument.cxx
@@ -372,7 +372,7 @@ namespace basctl
try
{
if ( isApplication() )
- xContainer.set( _eType == E_SCRIPTS ? SFX_APP()->GetBasicContainer() : SFX_APP()->GetDialogContainer(), UNO_QUERY_THROW );
+ xContainer.set( _eType == E_SCRIPTS ? SfxGetpApp()->GetBasicContainer() : SfxGetpApp()->GetDialogContainer(), UNO_QUERY_THROW );
else
{
xContainer.set(
@@ -430,7 +430,7 @@ namespace basctl
return NULL;
if ( isApplication() )
- return SFX_APP()->GetBasicManager();
+ return SfxGetpApp()->GetBasicManager();
return ::basic::BasicManagerRepository::getDocumentBasicManager( m_xDocument );
}
@@ -1088,7 +1088,7 @@ namespace basctl
ScriptDocument ScriptDocument::getDocumentForBasicManager( const BasicManager* _pManager )
{
- if ( _pManager == SFX_APP()->GetBasicManager() )
+ if ( _pManager == SfxGetpApp()->GetBasicManager() )
return getApplicationScriptDocument();
docs::Documents aDocuments;
@@ -1100,7 +1100,7 @@ namespace basctl
)
{
const BasicManager* pDocBasicManager = ::basic::BasicManagerRepository::getDocumentBasicManager( doc->xModel );
- if ( ( pDocBasicManager != SFX_APP()->GetBasicManager() )
+ if ( ( pDocBasicManager != SfxGetpApp()->GetBasicManager() )
&& ( pDocBasicManager == _pManager )
)
{
diff --git a/cui/source/dialogs/SpellDialog.cxx b/cui/source/dialogs/SpellDialog.cxx
index 38bb11671f40..ffb147e382f3 100644
--- a/cui/source/dialogs/SpellDialog.cxx
+++ b/cui/source/dialogs/SpellDialog.cxx
@@ -495,7 +495,7 @@ void SpellDialog::StartSpellOptDlg_Impl()
SID_AUTOSPELL_CHECK, SID_AUTOSPELL_CHECK,
0
};
- SfxItemSet aSet( SFX_APP()->GetPool(), aSpellInfos);
+ SfxItemSet aSet( SfxGetpApp()->GetPool(), aSpellInfos);
aSet.Put(SfxSpellCheckItem( xSpell, SID_ATTR_SPELL ));
SfxSingleTabDialog* pDlg =
new SfxSingleTabDialog(this, aSet, "SpellOptionsDialog", "cui/ui/spelloptionsdialog.ui");
diff --git a/cui/source/dialogs/cuicharmap.cxx b/cui/source/dialogs/cuicharmap.cxx
index f23c8e1082dc..5ea074da9999 100644
--- a/cui/source/dialogs/cuicharmap.cxx
+++ b/cui/source/dialogs/cuicharmap.cxx
@@ -101,7 +101,7 @@ SvxCharacterMap::SvxCharacterMap( Window* pParent, bool bOne_, const SfxItemSet*
SetCharFont( aTmpFont );
}
- CreateOutputItemSet( pSet ? *pSet->GetPool() : SFX_APP()->GetPool() );
+ CreateOutputItemSet( pSet ? *pSet->GetPool() : SfxGetpApp()->GetPool() );
}
diff --git a/cui/source/dialogs/cuifmsearch.cxx b/cui/source/dialogs/cuifmsearch.cxx
index ecbf3ffd4029..a63fba041fb5 100644
--- a/cui/source/dialogs/cuifmsearch.cxx
+++ b/cui/source/dialogs/cuifmsearch.cxx
@@ -345,7 +345,7 @@ IMPL_LINK(FmSearchDialog, OnClickedSpecialSettings, Button*, pButton )
}
else if (m_pSoundsLikeCJKSettings == pButton)
{
- SfxItemSet aSet( SFX_APP()->GetPool() );
+ SfxItemSet aSet( SfxGetpApp()->GetPool() );
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
if(pFact)
{
diff --git a/cui/source/dialogs/cuihyperdlg.cxx b/cui/source/dialogs/cuihyperdlg.cxx
index 33081c158a07..5bf73b9415d8 100644
--- a/cui/source/dialogs/cuihyperdlg.cxx
+++ b/cui/source/dialogs/cuihyperdlg.cxx
@@ -117,7 +117,7 @@ SvxHpLinkDlg::SvxHpLinkDlg (Window* pParent, SfxBindings* pBindings)
GetCancelButton().SetText ( CUI_RESSTR(RID_SVXSTR_HYPDLG_CLOSEBUT) );
// create itemset for tabpages
- mpItemSet = new SfxItemSet( SFX_APP()->GetPool(), SID_HYPERLINK_GETLINK,
+ mpItemSet = new SfxItemSet( SfxGetpApp()->GetPool(), SID_HYPERLINK_GETLINK,
SID_HYPERLINK_SETLINK );
SvxHyperlinkItem aItem;
@@ -197,7 +197,7 @@ void SvxHpLinkDlg::Move()
Size aDlgSize ( GetSizePixel () );
// Size of Office-Main-Window
- Size aWindowSize( SFX_APP()->GetTopWindow()->GetSizePixel() );
+ Size aWindowSize( SfxGetpApp()->GetTopWindow()->GetSizePixel() );
// Size of Extrawindow
Size aExtraWndSize( pCurrentPage->GetSizeExtraWnd() );
@@ -239,7 +239,7 @@ void SvxHpLinkDlg::Move()
IMPL_LINK_NOARG(SvxHpLinkDlg, ClickApplyHdl_Impl)
{
- SfxItemSet aItemSet( SFX_APP()->GetPool(), SID_HYPERLINK_GETLINK,
+ SfxItemSet aItemSet( SfxGetpApp()->GetPool(), SID_HYPERLINK_GETLINK,
SID_HYPERLINK_SETLINK );
SvxHyperlinkTabPageBase* pCurrentPage = (SvxHyperlinkTabPageBase*)
diff --git a/cui/source/dialogs/hltpbase.cxx b/cui/source/dialogs/hltpbase.cxx
index b019bebde343..3b3cd201783b 100644
--- a/cui/source/dialogs/hltpbase.cxx
+++ b/cui/source/dialogs/hltpbase.cxx
@@ -307,7 +307,7 @@ IMPL_LINK_NOARG(SvxHyperlinkTabPageBase, ClickScriptHdl_Impl)
aItem.SetMacroTable( *pMacroTbl );
// create empty itemset for macro-dlg
- SfxItemSet* pItemSet = new SfxItemSet(SFX_APP()->GetPool(),
+ SfxItemSet* pItemSet = new SfxItemSet(SfxGetpApp()->GetPool(),
SID_ATTR_MACROITEM,
SID_ATTR_MACROITEM );
pItemSet->Put ( aItem, SID_ATTR_MACROITEM );
diff --git a/cui/source/factory/dlgfact.cxx b/cui/source/factory/dlgfact.cxx
index 01490ba0fc82..55d20b3ccc17 100644
--- a/cui/source/factory/dlgfact.cxx
+++ b/cui/source/factory/dlgfact.cxx
@@ -1596,7 +1596,7 @@ class SvxMacroAssignDialog : public VclAbstractDialog
public:
SvxMacroAssignDialog( Window* _pParent, const Reference< XFrame >& _rxDocumentFrame, const bool _bUnoDialogMode,
const Reference< XNameReplace >& _rxEvents, const sal_uInt16 _nInitiallySelectedEvent )
- :m_aItems( SFX_APP()->GetPool(), SID_ATTR_MACROITEM, SID_ATTR_MACROITEM )
+ :m_aItems( SfxGetpApp()->GetPool(), SID_ATTR_MACROITEM, SID_ATTR_MACROITEM )
{
m_aItems.Put( SfxBoolItem( SID_ATTR_MACROITEM, _bUnoDialogMode ) );
m_pDialog.reset( new SvxMacroAssignDlg( _pParent, _rxDocumentFrame, m_aItems, _rxEvents, _nInitiallySelectedEvent ) );
diff --git a/cui/source/options/optpath.cxx b/cui/source/options/optpath.cxx
index b39286939c8a..fad0d74bd32f 100644
--- a/cui/source/options/optpath.cxx
+++ b/cui/source/options/optpath.cxx
@@ -513,7 +513,7 @@ void SvxPathTabPage::ChangeCurrentEntry( const OUString& _rFolder )
SvtViewOptions aDlgOpt( E_DIALOG, IODLG_CONFIGNAME );
aDlgOpt.Delete();
// Reset also last used dir in the sfx application instance
- SfxApplication *pSfxApp = SFX_APP();
+ SfxApplication *pSfxApp = SfxGetpApp();
pSfxApp->ResetLastDir();
// Set configuration flag to notify file picker that it's necessary
diff --git a/cui/source/options/treeopt.cxx b/cui/source/options/treeopt.cxx
index 1420c3ae2811..ed363cce9f2a 100644
--- a/cui/source/options/treeopt.cxx
+++ b/cui/source/options/treeopt.cxx
@@ -1230,7 +1230,7 @@ SfxItemSet* OfaTreeOptionsDialog::CreateItemSet( sal_uInt16 nId )
case SID_GENERAL_OPTIONS:
{
pRet = new SfxItemSet(
- SFX_APP()->GetPool(),
+ SfxGetpApp()->GetPool(),
SID_ATTR_METRIC, SID_ATTR_SPELL,
SID_AUTOSPELL_CHECK, SID_AUTOSPELL_CHECK,
SID_ATTR_QUICKLAUNCHER, SID_ATTR_QUICKLAUNCHER,
@@ -1238,8 +1238,8 @@ SfxItemSet* OfaTreeOptionsDialog::CreateItemSet( sal_uInt16 nId )
SID_HTML_MODE, SID_HTML_MODE,
0 );
- SfxItemSet aOptSet( SFX_APP()->GetPool(), SID_ATTR_QUICKLAUNCHER, SID_ATTR_QUICKLAUNCHER );
- SFX_APP()->GetOptions(aOptSet);
+ SfxItemSet aOptSet( SfxGetpApp()->GetPool(), SID_ATTR_QUICKLAUNCHER, SID_ATTR_QUICKLAUNCHER );
+ SfxGetpApp()->GetOptions(aOptSet);
pRet->Put(aOptSet);
utl::MiscCfg aMisc;
@@ -1270,7 +1270,7 @@ SfxItemSet* OfaTreeOptionsDialog::CreateItemSet( sal_uInt16 nId )
break;
case SID_LANGUAGE_OPTIONS :
{
- pRet = new SfxItemSet(SFX_APP()->GetPool(),
+ pRet = new SfxItemSet(SfxGetpApp()->GetPool(),
SID_ATTR_LANGUAGE, SID_AUTOSPELL_CHECK,
SID_ATTR_CHAR_CJK_LANGUAGE, SID_ATTR_CHAR_CTL_LANGUAGE,
SID_OPT_LOCALE_CHANGED, SID_OPT_LOCALE_CHANGED,
@@ -1328,7 +1328,7 @@ SfxItemSet* OfaTreeOptionsDialog::CreateItemSet( sal_uInt16 nId )
}
break;
case SID_INET_DLG :
- pRet = new SfxItemSet( SFX_APP()->GetPool(),
+ pRet = new SfxItemSet( SfxGetpApp()->GetPool(),
SID_BASIC_ENABLED, SID_BASIC_ENABLED,
//SID_OPTIONS_START - ..END
SID_INET_PROXY_TYPE, SID_INET_PROXY_PORT,
@@ -1338,20 +1338,20 @@ SfxItemSet* OfaTreeOptionsDialog::CreateItemSet( sal_uInt16 nId )
SID_INET_DNS_AUTO, SID_INET_DNS_SERVER,
SID_SECURE_URL, SID_SECURE_URL,
0L );
- SFX_APP()->GetOptions(*pRet);
+ SfxGetpApp()->GetOptions(*pRet);
break;
case SID_FILTER_DLG:
- pRet = new SfxItemSet( SFX_APP()->GetPool(),
+ pRet = new SfxItemSet( SfxGetpApp()->GetPool(),
SID_ATTR_DOCINFO, SID_ATTR_AUTOSAVEMINUTE,
SID_SAVEREL_INET, SID_SAVEREL_FSYS,
SID_ATTR_PRETTYPRINTING, SID_ATTR_PRETTYPRINTING,
SID_ATTR_WARNALIENFORMAT, SID_ATTR_WARNALIENFORMAT,
0 );
- SFX_APP()->GetOptions(*pRet);
+ SfxGetpApp()->GetOptions(*pRet);
break;
case SID_SB_STARBASEOPTIONS:
- pRet = new SfxItemSet( SFX_APP()->GetPool(),
+ pRet = new SfxItemSet( SfxGetpApp()->GetPool(),
SID_SB_POOLING_ENABLED, SID_SB_DB_REGISTER,
0 );
::offapp::ConnectionPoolConfig::GetOptions(*pRet);
@@ -1361,7 +1361,7 @@ SfxItemSet* OfaTreeOptionsDialog::CreateItemSet( sal_uInt16 nId )
case SID_SCH_EDITOPTIONS:
{
SvxChartOptions aChartOpt;
- pRet = new SfxItemSet( SFX_APP()->GetPool(), SID_SCH_EDITOPTIONS, SID_SCH_EDITOPTIONS );
+ pRet = new SfxItemSet( SfxGetpApp()->GetPool(), SID_SCH_EDITOPTIONS, SID_SCH_EDITOPTIONS );
pRet->Put( SvxChartColorTableItem( SID_SCH_EDITOPTIONS, aChartOpt.GetDefaultColors() ) );
break;
}
@@ -1377,10 +1377,10 @@ void OfaTreeOptionsDialog::ApplyItemSet( sal_uInt16 nId, const SfxItemSet& rSet
{
utl::MiscCfg aMisc;
const SfxPoolItem* pItem;
- SfxItemSet aOptSet(SFX_APP()->GetPool(), SID_ATTR_QUICKLAUNCHER, SID_ATTR_QUICKLAUNCHER );
+ SfxItemSet aOptSet(SfxGetpApp()->GetPool(), SID_ATTR_QUICKLAUNCHER, SID_ATTR_QUICKLAUNCHER );
aOptSet.Put(rSet);
if(aOptSet.Count())
- SFX_APP()->SetOptions( aOptSet );
+ SfxGetpApp()->SetOptions( aOptSet );
// get dispatcher anew, because SetOptions() might have destroyed the dispatcher
SfxViewFrame *pViewFrame = SfxViewFrame::Current();
@@ -1427,7 +1427,7 @@ void OfaTreeOptionsDialog::ApplyItemSet( sal_uInt16 nId, const SfxItemSet& rSet
break;
case SID_INET_DLG :
case SID_FILTER_DLG:
- SFX_APP()->SetOptions( rSet );
+ SfxGetpApp()->SetOptions( rSet );
break;
case SID_SB_STARBASEOPTIONS:
diff --git a/desktop/source/app/app.cxx b/desktop/source/app/app.cxx
index fb11a189f32a..3704bbdd9aa8 100644
--- a/desktop/source/app/app.cxx
+++ b/desktop/source/app/app.cxx
@@ -326,8 +326,8 @@ bool shouldLaunchQuickstart()
if (!bQuickstart)
{
const SfxPoolItem* pItem=0;
- SfxItemSet aQLSet(SFX_APP()->GetPool(), SID_ATTR_QUICKLAUNCHER, SID_ATTR_QUICKLAUNCHER);
- SFX_APP()->GetOptions(aQLSet);
+ SfxItemSet aQLSet(SfxGetpApp()->GetPool(), SID_ATTR_QUICKLAUNCHER, SID_ATTR_QUICKLAUNCHER);
+ SfxGetpApp()->GetOptions(aQLSet);
SfxItemState eState = aQLSet.GetItemState(SID_ATTR_QUICKLAUNCHER, false, &pItem);
if (SFX_ITEM_SET == eState)
bQuickstart = ((SfxBoolItem*)pItem)->GetValue();
diff --git a/desktop/source/app/dispatchwatcher.cxx b/desktop/source/app/dispatchwatcher.cxx
index 41f7fdd05fde..294d54382f2a 100644
--- a/desktop/source/app/dispatchwatcher.cxx
+++ b/desktop/source/app/dispatchwatcher.cxx
@@ -92,7 +92,7 @@ static OUString impl_GetFilterFromExt( const OUString& aUrl, SfxFilterFlags nFla
}
else
{
- SFX_APP()->GetFilterMatcher().GuessFilter( *pMedium, &pSfxFilter, nFlags, 0 );
+ SfxGetpApp()->GetFilterMatcher().GuessFilter( *pMedium, &pSfxFilter, nFlags, 0 );
}
if( pSfxFilter )
diff --git a/extensions/source/propctrlr/formcomponenthandler.cxx b/extensions/source/propctrlr/formcomponenthandler.cxx
index b35fa382ef71..256317f33b3f 100644
--- a/extensions/source/propctrlr/formcomponenthandler.cxx
+++ b/extensions/source/propctrlr/formcomponenthandler.cxx
@@ -2694,7 +2694,7 @@ namespace pcr
try
{
// create the itemset for the dialog
- SfxItemSet aCoreSet(SFX_APP()->GetPool(),
+ SfxItemSet aCoreSet(SfxGetpApp()->GetPool(),
SID_ATTR_NUMBERFORMAT_VALUE, SID_ATTR_NUMBERFORMAT_VALUE,
SID_ATTR_NUMBERFORMAT_INFO, SID_ATTR_NUMBERFORMAT_INFO,
0); // ripped this somewhere ... don't understand it :(
diff --git a/include/sfx2/app.hxx b/include/sfx2/app.hxx
index 3f81077d5b43..1c677566ea6c 100644
--- a/include/sfx2/app.hxx
+++ b/include/sfx2/app.hxx
@@ -264,8 +264,6 @@ public:
sfx2::sidebar::Theme & GetSidebarTheme();
};
-#define SFX_APP() SfxGetpApp()
-
inline SfxApplication* SfxGetpApp()
{
return SfxApplication::GetOrCreate();
diff --git a/sc/source/core/data/validat.cxx b/sc/source/core/data/validat.cxx
index bcd66e053a14..f1bd6bdb4c37 100644
--- a/sc/source/core/data/validat.cxx
+++ b/sc/source/core/data/validat.cxx
@@ -305,7 +305,7 @@ bool ScValidationData::DoMacro( const ScAddress& rPos, const OUString& rInput,
if ( pObject->GetParent() )
aBasicStr = pObject->GetParent()->GetName(); // Dokumentenbasic
else
- aBasicStr = SFX_APP()->GetName(); // Applikationsbasic
+ aBasicStr = SfxGetpApp()->GetName(); // Applikationsbasic
// Parameter fuer Makro
SbxArrayRef refPar = new SbxArray;
diff --git a/sc/source/core/tool/compiler.cxx b/sc/source/core/tool/compiler.cxx
index 2af538343666..cec91da3c58c 100644
--- a/sc/source/core/tool/compiler.cxx
+++ b/sc/source/core/tool/compiler.cxx
@@ -2771,7 +2771,7 @@ bool ScCompiler::IsMacro( const OUString& rName )
StarBASIC* pObj = 0;
SfxObjectShell* pDocSh = pDoc->GetDocumentShell();
- SfxApplication* pSfxApp = SFX_APP();
+ SfxApplication* pSfxApp = SfxGetpApp();
try
{
diff --git a/sc/source/core/tool/interpr4.cxx b/sc/source/core/tool/interpr4.cxx
index 3238d066f9d6..3406027b7885 100644
--- a/sc/source/core/tool/interpr4.cxx
+++ b/sc/source/core/tool/interpr4.cxx
@@ -3156,7 +3156,7 @@ void ScInterpreter::ScMacro()
}
else
{
- aBasicStr = SFX_APP()->GetName(); // Applikationsbasic
+ aBasicStr = SfxGetpApp()->GetName(); // Applikationsbasic
}
// Parameter-Array zusammenbauen
diff --git a/sc/source/core/tool/progress.cxx b/sc/source/core/tool/progress.cxx
index c1d2991b1fdb..2877a131849c 100644
--- a/sc/source/core/tool/progress.cxx
+++ b/sc/source/core/tool/progress.cxx
@@ -87,7 +87,7 @@ ScProgress::ScProgress( SfxObjectShell* pObjSh, const OUString& rText,
pProgress = NULL;
}
}
- else if ( SFX_APP()->IsDowning() )
+ else if ( SfxGetpApp()->IsDowning() )
{
// This happens. E.g. when saving the clipboard-content as OLE when closing the app.
// In this case a SfxProgress would produce dirt in memory.
diff --git a/sc/source/ui/app/inputhdl.cxx b/sc/source/ui/app/inputhdl.cxx
index a28ddc76ebb9..2b7020251f85 100644
--- a/sc/source/ui/app/inputhdl.cxx
+++ b/sc/source/ui/app/inputhdl.cxx
@@ -1627,7 +1627,7 @@ void ScInputHandler::ViewShellGone(ScTabViewShell* pViewSh) // Executed synchron
EnterHandler();
bFormulaMode = false;
pRefViewSh = NULL;
- SFX_APP()->Broadcast( SfxSimpleHint( FID_REFMODECHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( FID_REFMODECHANGED ) );
SC_MOD()->SetRefInputHdl(NULL);
if (pInputWin)
pInputWin->SetFormulaMode(false);
@@ -2118,7 +2118,7 @@ void ScInputHandler::DataChanged( bool bFromTopNotify, bool bSetModified )
void ScInputHandler::UpdateFormulaMode()
{
- SfxApplication* pSfxApp = SFX_APP();
+ SfxApplication* pSfxApp = SfxGetpApp();
bool bIsFormula = !bProtected && pEngine->GetParagraphCount() == 1;
if (bIsFormula)
@@ -2362,7 +2362,7 @@ void ScInputHandler::EnterHandler( sal_uInt8 nBlockMode )
bool bMatrix = ( nBlockMode == SC_ENTER_MATRIX );
- SfxApplication* pSfxApp = SFX_APP();
+ SfxApplication* pSfxApp = SfxGetpApp();
EditTextObject* pObject = NULL;
ScPatternAttr* pCellAttrs = NULL;
bool bForget = false; // Remove due to validity?
@@ -2712,7 +2712,7 @@ void ScInputHandler::CancelHandler()
pExecuteSh->ActiveGrabFocus();
}
bFormulaMode = false;
- SFX_APP()->Broadcast( SfxSimpleHint( FID_REFMODECHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( FID_REFMODECHANGED ) );
SC_MOD()->SetRefInputHdl(NULL);
if (pInputWin)
pInputWin->SetFormulaMode(false);
@@ -3436,7 +3436,7 @@ void ScInputHandler::NotifyChange( const ScInputHdlState* pState,
}
if (bStopEditing)
- SFX_APP()->Broadcast( SfxSimpleHint( FID_KILLEDITVIEW ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( FID_KILLEDITVIEW ) );
// As long as the content is not edited, turn off online spelling.
// Online spelling is turned back on in StartTable, after setting
diff --git a/sc/source/ui/app/inputwin.cxx b/sc/source/ui/app/inputwin.cxx
index 57e5bec06e35..a2e557ee272a 100644
--- a/sc/source/ui/app/inputwin.cxx
+++ b/sc/source/ui/app/inputwin.cxx
@@ -2063,12 +2063,12 @@ ScPosWnd::ScPosWnd( Window* pParent ) :
FillRangeNames();
- StartListening( *SFX_APP() ); // For Navigator rangename updates
+ StartListening( *SfxGetpApp() ); // For Navigator rangename updates
}
ScPosWnd::~ScPosWnd()
{
- EndListening( *SFX_APP() );
+ EndListening( *SfxGetpApp() );
HideTip();
diff --git a/sc/source/ui/app/scmod.cxx b/sc/source/ui/app/scmod.cxx
index 5cd585106fc0..d534592df90d 100644
--- a/sc/source/ui/app/scmod.cxx
+++ b/sc/source/ui/app/scmod.cxx
@@ -185,7 +185,7 @@ ScModule::ScModule( SfxObjectFactory* pFact ) :
SetPool( pMessagePool );
ScGlobal::InitTextHeight( pMessagePool );
- StartListening( *SFX_APP() ); // for SFX_HINT_DEINITIALIZING
+ StartListening( *SfxGetpApp() ); // for SFX_HINT_DEINITIALIZING
}
ScModule::~ScModule()
@@ -972,7 +972,7 @@ void ScModule::ModifyOptions( const SfxItemSet& rOptSet )
bool bSaveInputOptions = false;
bool bCompileErrorCells = false;
- // SFX_APP()->SetOptions( rOptSet );
+ // SfxGetpApp()->SetOptions( rOptSet );
// No more linguistics
if (rOptSet.HasItem(SID_ATTR_METRIC, &pItem))
@@ -1253,7 +1253,7 @@ void ScModule::ModifyOptions( const SfxItemSet& rOptSet )
SetPrintOptions( rNewOpt );
// broadcast causes all previews to recalc page numbers
- SFX_APP()->Broadcast( SfxSimpleHint( SID_SCPRINTOPTIONS ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SID_SCPRINTOPTIONS ) );
}
if ( bSaveAppOptions )
@@ -1408,7 +1408,7 @@ bool ScModule::InputKeyEvent( const KeyEvent& rKEvt, bool bStartEdit )
void ScModule::InputEnterHandler( sal_uInt8 nBlockMode )
{
- if ( !SFX_APP()->IsDowning() ) // Not when quitting the program
+ if ( !SfxGetpApp()->IsDowning() ) // Not when quitting the program
{
ScInputHandler* pHdl = GetInputHdl();
if (pHdl)
@@ -1555,7 +1555,7 @@ void ScModule::SetRefDialog( sal_uInt16 nId, bool bVis, SfxViewFrame* pViewFrm )
pViewFrm->SetChildWindow( nId, bVis );
}
- SfxApplication* pSfxApp = SFX_APP();
+ SfxApplication* pSfxApp = SfxGetpApp();
pSfxApp->Broadcast( SfxSimpleHint( FID_REFMODECHANGED ) );
}
}
@@ -2003,7 +2003,7 @@ SfxItemSet* ScModule::CreateItemSet( sal_uInt16 nId )
ScUserListItem aULItem( SCITEM_USERLIST );
ScUserList* pUL = ScGlobal::GetUserList();
- // SFX_APP()->GetOptions( aSet );
+ // SfxGetpApp()->GetOptions( aSet );
pRet->Put( SfxUInt16Item( SID_ATTR_METRIC,
sal::static_int_cast<sal_uInt16>(rAppOpt.GetAppMetric()) ) );
diff --git a/sc/source/ui/dbgui/validate.cxx b/sc/source/ui/dbgui/validate.cxx
index 92e8f6848cfb..6cfaafa88fbd 100644
--- a/sc/source/ui/dbgui/validate.cxx
+++ b/sc/source/ui/dbgui/validate.cxx
@@ -80,7 +80,7 @@ static const sal_uInt16 pValueRanges[] =
ScValidationDlg::ScValidationDlg(Window* pParent, const SfxItemSet* pArgSet,
ScTabViewShell *pTabViewSh, SfxBindings *pB /*= NULL*/)
- : ScValidationDlgBase(pParent ? pParent : SFX_APP()->GetTopWindow(),
+ : ScValidationDlgBase(pParent ? pParent : SfxGetpApp()->GetTopWindow(),
"ValidationDialog", "modules/scalc/ui/validationdialog.ui", pArgSet, pB)
, m_pTabVwSh(pTabViewSh)
, m_nValuePageId(0)
diff --git a/sc/source/ui/docshell/dbdocfun.cxx b/sc/source/ui/docshell/dbdocfun.cxx
index 0c8e5d1dc63c..1c7ad537da3f 100644
--- a/sc/source/ui/docshell/dbdocfun.cxx
+++ b/sc/source/ui/docshell/dbdocfun.cxx
@@ -104,7 +104,7 @@ bool ScDBDocFunc::AddDBRange( const OUString& rName, const ScRange& rRange, bool
}
aModificator.SetDocumentModified();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_DBAREAS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_DBAREAS_CHANGED ) );
return true;
}
@@ -137,7 +137,7 @@ bool ScDBDocFunc::DeleteDBRange(const OUString& rName)
}
aModificator.SetDocumentModified();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_DBAREAS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_DBAREAS_CHANGED ) );
bDone = true;
}
@@ -184,7 +184,7 @@ bool ScDBDocFunc::RenameDBRange( const OUString& rOld, const OUString& rNew )
delete pUndoColl;
aModificator.SetDocumentModified();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_DBAREAS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_DBAREAS_CHANGED ) );
bDone = true;
}
}
diff --git a/sc/source/ui/docshell/docfunc.cxx b/sc/source/ui/docshell/docfunc.cxx
index f45db67ef0b9..fd1d5ce6bfdf 100644
--- a/sc/source/ui/docshell/docfunc.cxx
+++ b/sc/source/ui/docshell/docfunc.cxx
@@ -2016,7 +2016,7 @@ bool ScDocFunc::InsertCells( const ScRange& rRange, const ScMarkData* pTabMark,
aModificator.SetDocumentModified();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
return bSuccess;
}
@@ -2493,7 +2493,7 @@ bool ScDocFunc::DeleteCells( const ScRange& rRange, const ScMarkData* pTabMark,
aModificator.SetDocumentModified();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
return true;
}
@@ -2840,7 +2840,7 @@ bool ScDocFunc::MoveBlock( const ScRange& rSource, const ScAddress& rDestPos,
aModificator.SetDocumentModified();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
delete pClipDoc;
return true;
@@ -2988,7 +2988,7 @@ bool ScDocFunc::InsertTable( SCTAB nTab, const OUString& rName, bool bRecord, bo
rDocShell.PostPaintExtras();
aModificator.SetDocumentModified();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
bSuccess = true;
}
else if (!bApi)
@@ -3083,7 +3083,7 @@ bool ScDocFunc::DeleteTable( SCTAB nTab, bool bRecord, bool /* bApi */ )
rDocShell.PostPaintExtras();
aModificator.SetDocumentModified();
- SfxApplication* pSfxApp = SFX_APP(); // Navigator
+ SfxApplication* pSfxApp = SfxGetpApp(); // Navigator
pSfxApp->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
pSfxApp->Broadcast( SfxSimpleHint( SC_HINT_DBAREAS_CHANGED ) );
pSfxApp->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
@@ -3144,7 +3144,7 @@ bool ScDocFunc::SetTableVisible( SCTAB nTab, bool bVisible, bool bApi )
if (!bVisible)
rDocShell.Broadcast( ScTablesHint( SC_TAB_HIDDEN, nTab ) );
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
rDocShell.PostPaint(0,0,0,MAXCOL,MAXROW,MAXTAB, PAINT_EXTRAS);
aModificator.SetDocumentModified();
@@ -3208,7 +3208,7 @@ bool ScDocFunc::RenameTable( SCTAB nTab, const OUString& rName, bool bRecord, bo
}
rDocShell.PostPaintExtras();
aModificator.SetDocumentModified();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
bSuccess = true;
}
@@ -3245,7 +3245,7 @@ bool ScDocFunc::SetTabBgColor( SCTAB nTab, const Color& rColor, bool bRecord, bo
rDocShell.PostPaintExtras();
ScDocShellModificator aModificator( rDocShell );
aModificator.SetDocumentModified();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
bSuccess = true;
}
@@ -4843,7 +4843,7 @@ bool ScDocFunc::SetNewRangeNames( ScRangeName* pNewRanges, bool bModifyDoc, SCTA
if (bModifyDoc)
{
aModificator.SetDocumentModified();
- SFX_APP()->Broadcast( SfxSimpleHint(SC_HINT_AREAS_CHANGED) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint(SC_HINT_AREAS_CHANGED) );
}
return true;
@@ -4867,7 +4867,7 @@ void ScDocFunc::ModifyAllRangeNames( const boost::ptr_map<OUString, ScRangeName>
rDoc.PostprocessRangeNameUpdate();
aModificator.SetDocumentModified();
- SFX_APP()->Broadcast(SfxSimpleHint(SC_HINT_AREAS_CHANGED));
+ SfxGetpApp()->Broadcast(SfxSimpleHint(SC_HINT_AREAS_CHANGED));
}
void ScDocFunc::CreateOneName( ScRangeName& rList,
@@ -5018,7 +5018,7 @@ bool ScDocFunc::CreateNames( const ScRange& rRange, sal_uInt16 nFlags, bool bApi
bDone = ModifyRangeNames( aNewRanges, aTab );
aModificator.SetDocumentModified();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREAS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREAS_CHANGED ) );
}
return bDone;
@@ -5261,7 +5261,7 @@ bool ScDocFunc::InsertAreaLink( const OUString& rFile, const OUString& rFilter,
if (pBindings)
pBindings->Invalidate( SID_LINKS );
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) ); // Navigator
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) ); // Navigator
return true;
}
@@ -5354,7 +5354,7 @@ void ScDocFunc::ReplaceConditionalFormat( sal_uLong nOldFormat, ScConditionalFor
rDocShell.PostPaint(*pRepaintRange, PAINT_GRID);
aModificator.SetDocumentModified();
- SFX_APP()->Broadcast(SfxSimpleHint(SC_HINT_AREAS_CHANGED));
+ SfxGetpApp()->Broadcast(SfxSimpleHint(SC_HINT_AREAS_CHANGED));
}
void ScDocFunc::SetConditionalFormatList( ScConditionalFormatList* pList, SCTAB nTab )
@@ -5384,7 +5384,7 @@ void ScDocFunc::SetConditionalFormatList( ScConditionalFormatList* pList, SCTAB
rDoc.SetStreamValid(nTab, false);
aModificator.SetDocumentModified();
- SFX_APP()->Broadcast(SfxSimpleHint(SC_HINT_AREAS_CHANGED));
+ SfxGetpApp()->Broadcast(SfxSimpleHint(SC_HINT_AREAS_CHANGED));
}
void ScDocFunc::EnterListAction( sal_uInt16 nNameResId )
diff --git a/sc/source/ui/docshell/docsh.cxx b/sc/source/ui/docshell/docsh.cxx
index 1e5e4486c6c2..92cc36ca2b14 100644
--- a/sc/source/ui/docshell/docsh.cxx
+++ b/sc/source/ui/docshell/docsh.cxx
@@ -623,7 +623,7 @@ void ScDocShell::Notify( SfxBroadcaster&, const SfxHint& rHint )
case SFX_HINT_TITLECHANGED:
aDocument.SetName( SfxShell::GetName() );
// RegisterNewTargetNames gibts nicht mehr
- SFX_APP()->Broadcast(SfxSimpleHint( SC_HINT_DOCNAME_CHANGED )); // Navigator
+ SfxGetpApp()->Broadcast(SfxSimpleHint( SC_HINT_DOCNAME_CHANGED )); // Navigator
break;
}
}
@@ -2725,7 +2725,7 @@ ScDocShell::~ScDocShell()
delete pAutoStyleList;
- SfxApplication *pSfxApp = SFX_APP();
+ SfxApplication *pSfxApp = SfxGetpApp();
if ( pSfxApp->GetDdeService() ) // Delete DDE for Document
pSfxApp->RemoveDdeTopic( this );
@@ -2855,7 +2855,7 @@ void ScDocShell::SetDrawModified( bool bIsModified /* = true */ )
if ( aDocument.IsChartListenerCollectionNeedsUpdate() )
{
aDocument.UpdateChartListenerCollection();
- SFX_APP()->Broadcast(SfxSimpleHint( SC_HINT_DRAW_CHANGED )); // Navigator
+ SfxGetpApp()->Broadcast(SfxSimpleHint( SC_HINT_DRAW_CHANGED )); // Navigator
}
SC_MOD()->AnythingChanged();
}
diff --git a/sc/source/ui/docshell/docsh3.cxx b/sc/source/ui/docshell/docsh3.cxx
index e3eb97b3ecf5..8544435181f5 100644
--- a/sc/source/ui/docshell/docsh3.cxx
+++ b/sc/source/ui/docshell/docsh3.cxx
@@ -82,7 +82,7 @@ void ScDocShell::PostEditView( ScEditEngineDefaulter* pEditEngine, const ScAddre
void ScDocShell::PostDataChanged()
{
Broadcast( SfxSimpleHint( FID_DATACHANGED ) );
- SFX_APP()->Broadcast(SfxSimpleHint( FID_ANYDATACHANGED )); // Navigator
+ SfxGetpApp()->Broadcast(SfxSimpleHint( FID_ANYDATACHANGED )); // Navigator
aDocument.ClearFormulaContext();
//! Navigator direkt benachrichtigen!
}
diff --git a/sc/source/ui/docshell/docsh4.cxx b/sc/source/ui/docshell/docsh4.cxx
index 0f5a9cffdab5..2aa636ae3f4e 100644
--- a/sc/source/ui/docshell/docsh4.cxx
+++ b/sc/source/ui/docshell/docsh4.cxx
@@ -660,7 +660,7 @@ void ScDocShell::Execute( SfxRequest& rReq )
rReq.Ignore();
break;
}
- SfxApplication* pApp = SFX_APP();
+ SfxApplication* pApp = SfxGetpApp();
const SfxPoolItem* pItem;
SfxMedium* pMed = NULL;
if ( pReqArgs &&
diff --git a/sc/source/ui/docshell/docsh5.cxx b/sc/source/ui/docshell/docsh5.cxx
index d9ba6d37c5e8..7d0698119dda 100644
--- a/sc/source/ui/docshell/docsh5.cxx
+++ b/sc/source/ui/docshell/docsh5.cxx
@@ -299,7 +299,7 @@ ScDBData* ScDocShell::GetDBData( const ScRange& rMarked, ScGetDBMode eMode, ScGe
// "Import1" etc am Navigator bekanntmachen
if (eMode==SC_DB_IMPORT)
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_DBAREAS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_DBAREAS_CHANGED ) );
}
pData = pNoNameData;
}
@@ -741,7 +741,7 @@ void ScDocShell::ModifyScenario( SCTAB nTab, const OUString& rName, const OUStri
aModificator.SetDocumentModified();
if (!aOldName.equals(rName))
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
SfxBindings* pBindings = GetViewBindings();
if (pBindings)
@@ -807,7 +807,7 @@ SCTAB ScDocShell::MakeScenario( SCTAB nTab, const OUString& rName, const OUStrin
PostPaintExtras(); // Tabellenreiter
aModificator.SetDocumentModified();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
return nNewTab;
}
@@ -978,7 +978,7 @@ bool ScDocShell::MoveTable( SCTAB nSrcTab, SCTAB nDestTab, bool bCopy, bool bRec
PostPaintGridAll();
PostPaintExtras();
aModificator.SetDocumentModified();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
return true;
}
diff --git a/sc/source/ui/docshell/externalrefmgr.cxx b/sc/source/ui/docshell/externalrefmgr.cxx
index f251164af674..6757d36291e8 100644
--- a/sc/source/ui/docshell/externalrefmgr.cxx
+++ b/sc/source/ui/docshell/externalrefmgr.cxx
@@ -2352,7 +2352,7 @@ SfxObjectShellRef ScExternalRefManager::loadSrcDocument(sal_uInt16 nFileId, OUSt
setRelativeFileName(nFileId, aStr);
}
- SfxItemSet* pSet = new SfxAllItemSet(SFX_APP()->GetPool());
+ SfxItemSet* pSet = new SfxAllItemSet(SfxGetpApp()->GetPool());
if (!aOptions.isEmpty())
pSet->Put(SfxStringItem(SID_FILE_FILTEROPTIONS, aOptions));
diff --git a/sc/source/ui/docshell/servobj.cxx b/sc/source/ui/docshell/servobj.cxx
index b23f9c751930..39d3ee1494df 100644
--- a/sc/source/ui/docshell/servobj.cxx
+++ b/sc/source/ui/docshell/servobj.cxx
@@ -103,7 +103,7 @@ ScServerObject::ScServerObject( ScDocShell* pShell, const OUString& rItem ) :
pDocSh->GetDocument().StartListeningArea( aRange, &aForwarder );
StartListening(*pDocSh); // um mitzubekommen, wenn die DocShell geloescht wird
- StartListening(*SFX_APP()); // for SC_HINT_AREAS_CHANGED
+ StartListening(*SfxGetpApp()); // for SC_HINT_AREAS_CHANGED
}
ScServerObject::~ScServerObject()
@@ -121,7 +121,7 @@ void ScServerObject::Clear()
pTemp->GetDocument().EndListeningArea( aRange, &aForwarder );
pTemp->GetDocument().GetLinkManager()->RemoveServer( this );
EndListening(*pTemp);
- EndListening(*SFX_APP());
+ EndListening(*SfxGetpApp());
}
}
@@ -156,7 +156,7 @@ bool ScServerObject::GetData(
EndListeningAll();
pDocSh->GetDocument().StartListeningArea( aRange, &aForwarder );
StartListening(*pDocSh);
- StartListening(*SFX_APP());
+ StartListening(*SfxGetpApp());
bRefreshListener = false;
}
@@ -206,7 +206,7 @@ void ScServerObject::Notify( SfxBroadcaster& rBC, const SfxHint& rHint )
if ( rHint.ISA(SfxSimpleHint) && ((const SfxSimpleHint&)rHint).GetId() == SFX_HINT_DYING )
{
pDocSh = NULL;
- EndListening(*SFX_APP());
+ EndListening(*SfxGetpApp());
// don't access DocShell anymore for EndListening etc.
}
}
diff --git a/sc/source/ui/docshell/tablink.cxx b/sc/source/ui/docshell/tablink.cxx
index 9059a27a67f1..8ece986b7a10 100644
--- a/sc/source/ui/docshell/tablink.cxx
+++ b/sc/source/ui/docshell/tablink.cxx
@@ -190,7 +190,7 @@ bool ScTableLink::Refresh(const OUString& rNewFile, const OUString& rNewFilter,
aOptions = *pNewOptions;
// ItemSet immer anlegen, damit die DocShell die Optionen setzen kann
- SfxItemSet* pSet = new SfxAllItemSet( SFX_APP()->GetPool() );
+ SfxItemSet* pSet = new SfxAllItemSet( SfxGetpApp()->GetPool() );
if (!aOptions.isEmpty())
pSet->Put( SfxStringItem( SID_FILE_FILTEROPTIONS, aOptions ) );
@@ -507,7 +507,7 @@ SfxMedium* ScDocumentLoader::CreateMedium( const OUString& rFileName, const SfxF
const OUString& rOptions )
{
// Always create SfxItemSet so ScDocShell can set options.
- SfxItemSet* pSet = new SfxAllItemSet( SFX_APP()->GetPool() );
+ SfxItemSet* pSet = new SfxAllItemSet( SfxGetpApp()->GetPool() );
if ( !rOptions.isEmpty() )
pSet->Put( SfxStringItem( SID_FILE_FILTEROPTIONS, rOptions ) );
diff --git a/sc/source/ui/drawfunc/drawsh.cxx b/sc/source/ui/drawfunc/drawsh.cxx
index aec10e8b2905..ec6d47f18aba 100644
--- a/sc/source/ui/drawfunc/drawsh.cxx
+++ b/sc/source/ui/drawfunc/drawsh.cxx
@@ -316,7 +316,7 @@ void ScDrawShell::ExecDrawAttr( SfxRequest& rReq )
void ScDrawShell::ExecuteMacroAssign( SdrObject* pObj, Window* pWin )
{
- SvxMacroItem aItem ( SFX_APP()->GetPool().GetWhich( SID_ATTR_MACROITEM ) );
+ SvxMacroItem aItem ( SfxGetpApp()->GetPool().GetWhich( SID_ATTR_MACROITEM ) );
ScMacroInfo* pInfo = ScDrawLayer::GetMacroInfo( pObj, true );
if ( !pInfo->GetMacro().isEmpty() )
{
@@ -327,7 +327,7 @@ void ScDrawShell::ExecuteMacroAssign( SdrObject* pObj, Window* pWin )
}
// create empty itemset for macro-dlg
- boost::scoped_ptr<SfxItemSet> pItemSet(new SfxItemSet(SFX_APP()->GetPool(), SID_ATTR_MACROITEM, SID_ATTR_MACROITEM, SID_EVENTCONFIG, SID_EVENTCONFIG, 0 ));
+ boost::scoped_ptr<SfxItemSet> pItemSet(new SfxItemSet(SfxGetpApp()->GetPool(), SID_ATTR_MACROITEM, SID_ATTR_MACROITEM, SID_EVENTCONFIG, SID_EVENTCONFIG, 0 ));
pItemSet->Put ( aItem, SID_ATTR_MACROITEM );
SfxEventNamesItem aNamesItem(SID_EVENTCONFIG);
diff --git a/sc/source/ui/miscdlgs/anyrefdg.cxx b/sc/source/ui/miscdlgs/anyrefdg.cxx
index 4d284152d3ec..37db74e89197 100644
--- a/sc/source/ui/miscdlgs/anyrefdg.cxx
+++ b/sc/source/ui/miscdlgs/anyrefdg.cxx
@@ -611,7 +611,7 @@ void ScFormulaReferenceHelper::ToggleCollapsed( formula::RefEdit* pEdit, formula
bool ScFormulaReferenceHelper::DoClose( sal_uInt16 nId )
{
- SfxApplication* pSfxApp = SFX_APP();
+ SfxApplication* pSfxApp = SfxGetpApp();
SetDispatcherLock( false ); //! here and in dtor ?
diff --git a/sc/source/ui/namedlg/namedefdlg.cxx b/sc/source/ui/namedlg/namedefdlg.cxx
index b05d69b66352..36a36d01feb6 100644
--- a/sc/source/ui/namedlg/namedefdlg.cxx
+++ b/sc/source/ui/namedlg/namedefdlg.cxx
@@ -244,7 +244,7 @@ void ScNameDefDlg::AddPushed()
// call invalidates the stream
if (nTab != -1)
mpDoc->SetStreamValid(nTab, false);
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREAS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREAS_CHANGED ) );
mpDocShell->SetDocumentModified();
Close();
}
diff --git a/sc/source/ui/navipi/navipi.cxx b/sc/source/ui/navipi/navipi.cxx
index 9da736c2c130..70624af0cfb5 100644
--- a/sc/source/ui/navipi/navipi.cxx
+++ b/sc/source/ui/navipi/navipi.cxx
@@ -628,7 +628,7 @@ ScNavigatorDlg::ScNavigatorDlg( SfxBindings* pB, SfxChildWindowContext* pCW, Win
rBindings.LEAVEREGISTRATIONS();
- StartListening( *(SFX_APP()) );
+ StartListening( *(SfxGetpApp()) );
StartListening( rBindings );
aLbDocuments.Hide(); // bei NAV_LMODE_NONE gibts die nicht
@@ -690,7 +690,7 @@ ScNavigatorDlg::~ScNavigatorDlg()
delete [] ppBoundItems;
delete pMarkArea;
- EndListening( *(SFX_APP()) );
+ EndListening( *(SfxGetpApp()) );
EndListening( rBindings );
}
diff --git a/sc/source/ui/undo/undoblk.cxx b/sc/source/ui/undo/undoblk.cxx
index 71281465b35a..982925d8c3ab 100644
--- a/sc/source/ui/undo/undoblk.cxx
+++ b/sc/source/ui/undo/undoblk.cxx
@@ -513,7 +513,7 @@ void ScUndoDeleteCells::Undo()
BeginUndo();
DoChange( true );
EndUndo();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
// Selection not until EndUndo
ScTabViewShell* pViewShell = ScTabViewShell::GetActiveViewShell();
@@ -536,7 +536,7 @@ void ScUndoDeleteCells::Redo()
BeginRedo();
DoChange( false);
EndRedo();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
ScTabViewShell* pViewShell = ScTabViewShell::GetActiveViewShell();
if (pViewShell)
@@ -695,7 +695,7 @@ void ScUndoDeleteMulti::Undo()
//! since no data for selection exist
EndUndo();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
}
void ScUndoDeleteMulti::Redo()
@@ -722,7 +722,7 @@ void ScUndoDeleteMulti::Redo()
DoChange();
EndRedo();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
}
void ScUndoDeleteMulti::Repeat(SfxRepeatTarget& rTarget)
@@ -1073,7 +1073,7 @@ void ScUndoPaste::Undo()
if (!maBlockRanges.empty())
ShowTable(*maBlockRanges.front());
EndUndo();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
}
void ScUndoPaste::Redo()
@@ -1084,7 +1084,7 @@ void ScUndoPaste::Redo()
DoChange( false );
EnableDrawAdjust( &rDoc, true ); //! include in ScBlockUndo?
EndRedo();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
}
void ScUndoPaste::Repeat(SfxRepeatTarget& rTarget)
@@ -1291,7 +1291,7 @@ void ScUndoDragDrop::Undo()
}
EndUndo();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
}
void ScUndoDragDrop::Redo()
@@ -1375,7 +1375,7 @@ void ScUndoDragDrop::Redo()
EnableDrawAdjust( &rDoc, true ); //! include in ScBlockUndo?
EndRedo();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
}
void ScUndoDragDrop::Repeat(SfxRepeatTarget& /* rTarget */)
diff --git a/sc/source/ui/undo/undoblk3.cxx b/sc/source/ui/undo/undoblk3.cxx
index e80c5265969b..661f3e95c460 100644
--- a/sc/source/ui/undo/undoblk3.cxx
+++ b/sc/source/ui/undo/undoblk3.cxx
@@ -1526,7 +1526,7 @@ void ScUndoInsertAreaLink::Undo()
if (pLink)
pLinkManager->Remove( pLink );
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) ); // Navigator
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) ); // Navigator
}
void ScUndoInsertAreaLink::Redo()
@@ -1542,7 +1542,7 @@ void ScUndoInsertAreaLink::Redo()
pLink->Update();
pLink->SetInCreate( false );
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) ); // Navigator
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) ); // Navigator
}
void ScUndoInsertAreaLink::Repeat(SfxRepeatTarget& /* rTarget */)
@@ -1591,7 +1591,7 @@ void ScUndoRemoveAreaLink::Undo()
pLink->Update();
pLink->SetInCreate( false );
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) ); // Navigator
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) ); // Navigator
}
void ScUndoRemoveAreaLink::Redo()
@@ -1604,7 +1604,7 @@ void ScUndoRemoveAreaLink::Redo()
if (pLink)
pLinkManager->Remove( pLink );
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) ); // Navigator
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) ); // Navigator
}
void ScUndoRemoveAreaLink::Repeat(SfxRepeatTarget& /* rTarget */)
diff --git a/sc/source/ui/undo/undocell.cxx b/sc/source/ui/undo/undocell.cxx
index 8e6c7cfb391a..5ece768fa2e0 100644
--- a/sc/source/ui/undo/undocell.cxx
+++ b/sc/source/ui/undo/undocell.cxx
@@ -1010,7 +1010,7 @@ void ScUndoRangeNames::DoChange( bool bUndo )
rDoc.PostprocessRangeNameUpdate();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREAS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREAS_CHANGED ) );
}
void ScUndoRangeNames::Undo()
diff --git a/sc/source/ui/undo/undodat.cxx b/sc/source/ui/undo/undodat.cxx
index 4d6111befdae..b6bc5d614a33 100644
--- a/sc/source/ui/undo/undodat.cxx
+++ b/sc/source/ui/undo/undodat.cxx
@@ -1135,7 +1135,7 @@ void ScUndoDBData::Undo()
rDoc.CompileDBFormula( false ); // CompileFormulaString
rDoc.SetAutoCalc( bOldAutoCalc );
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_DBAREAS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_DBAREAS_CHANGED ) );
EndUndo();
}
@@ -1153,7 +1153,7 @@ void ScUndoDBData::Redo()
rDoc.CompileDBFormula( false ); // CompileFormulaString
rDoc.SetAutoCalc( bOldAutoCalc );
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_DBAREAS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_DBAREAS_CHANGED ) );
EndRedo();
}
@@ -1974,7 +1974,7 @@ void ScUndoDataForm::Undo()
DoChange( true );
ShowTable( aBlockRange );
EndUndo();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
}
void ScUndoDataForm::Redo()
@@ -1985,7 +1985,7 @@ void ScUndoDataForm::Redo()
DoChange( false );
EnableDrawAdjust( &rDoc, true ); //! include in ScBlockUndo?
EndRedo();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
}
void ScUndoDataForm::Repeat(SfxRepeatTarget& /*rTarget*/)
diff --git a/sc/source/ui/undo/undorangename.cxx b/sc/source/ui/undo/undorangename.cxx
index 4c06b2948b4c..8eafa6bf8dde 100644
--- a/sc/source/ui/undo/undorangename.cxx
+++ b/sc/source/ui/undo/undorangename.cxx
@@ -80,7 +80,7 @@ void ScUndoAllRangeNames::DoChange(const boost::ptr_map<OUString, ScRangeName>&
rDoc.SetAllRangeNames(rNames);
rDoc.PostprocessRangeNameUpdate();
- SFX_APP()->Broadcast(SfxSimpleHint(SC_HINT_AREAS_CHANGED));
+ SfxGetpApp()->Broadcast(SfxSimpleHint(SC_HINT_AREAS_CHANGED));
}
ScUndoAddRangeData::ScUndoAddRangeData(ScDocShell* pDocSh, ScRangeData* pRangeData, SCTAB nTab) :
@@ -109,7 +109,7 @@ void ScUndoAddRangeData::Undo()
pRangeName = rDoc.GetRangeName( mnTab );
}
pRangeName->erase(*mpRangeData);
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREAS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREAS_CHANGED ) );
}
@@ -126,7 +126,7 @@ void ScUndoAddRangeData::Redo()
pRangeName = rDoc.GetRangeName( mnTab );
}
pRangeName->insert(new ScRangeData(*mpRangeData));
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREAS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREAS_CHANGED ) );
}
void ScUndoAddRangeData::Repeat(SfxRepeatTarget& /*rTarget*/)
diff --git a/sc/source/ui/undo/undotab.cxx b/sc/source/ui/undo/undotab.cxx
index 67772dc5d1a0..b5091d5954f0 100644
--- a/sc/source/ui/undo/undotab.cxx
+++ b/sc/source/ui/undo/undotab.cxx
@@ -377,7 +377,7 @@ void ScUndoDeleteTab::Undo()
{
pDocShell->Broadcast( ScTablesHint( SC_TAB_INSERTED, theTabs[i]) );
}
- SfxApplication* pSfxApp = SFX_APP(); // Navigator
+ SfxApplication* pSfxApp = SfxGetpApp(); // Navigator
pSfxApp->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
pSfxApp->Broadcast( SfxSimpleHint( SC_HINT_DBAREAS_CHANGED ) );
pSfxApp->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
@@ -448,7 +448,7 @@ void ScUndoRenameTab::DoChange( SCTAB nTabP, const OUString& rName ) const
ScDocument& rDoc = pDocShell->GetDocument();
rDoc.RenameTab( nTabP, rName );
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) ); // Navigator
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) ); // Navigator
pDocShell->PostPaintGridAll();
pDocShell->PostPaintExtras();
@@ -556,7 +556,7 @@ void ScUndoMoveTab::DoChange( bool bUndo ) const
}
}
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) ); // Navigator
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) ); // Navigator
pDocShell->PostPaintGridAll();
pDocShell->PostPaintExtras();
@@ -617,7 +617,7 @@ void ScUndoCopyTab::DoChange() const
if (pViewShell)
pViewShell->SetTabNo((*mpOldTabs)[0],true);
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) ); // Navigator
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) ); // Navigator
pDocShell->PostPaintGridAll();
pDocShell->PostPaintExtras();
@@ -836,7 +836,7 @@ void ScUndoMakeScenario::Undo()
if (pViewShell)
pViewShell->SetTabNo( nSrcTab, true );
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
// SetTabNo(...,sal_True) for all views to sync with drawing layer pages
pDocShell->Broadcast( SfxSimpleHint( SC_HINT_FORCESETTAB ) );
@@ -860,7 +860,7 @@ void ScUndoMakeScenario::Redo()
if (pViewShell)
pViewShell->SetTabNo( nDestTab, true );
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
}
void ScUndoMakeScenario::Repeat(SfxRepeatTarget& rTarget)
@@ -915,7 +915,7 @@ void ScUndoImportTab::DoChange() const
}
}
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) ); // Navigator
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) ); // Navigator
pDocShell->PostPaint( 0,0,0, MAXCOL,MAXROW,MAXTAB,
PAINT_GRID | PAINT_TOP | PAINT_LEFT | PAINT_EXTRAS );
}
@@ -1140,7 +1140,7 @@ void ScUndoShowHideTab::DoChange( bool bShowP ) const
pViewShell->SetTabNo(nTab,true);
}
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
pDocShell->SetDocumentModified();
}
@@ -1425,7 +1425,7 @@ void ScUndoScenarioFlags::Undo()
pViewShell->UpdateInputHandler();
if ( aOldName != aNewName )
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
}
void ScUndoScenarioFlags::Redo()
@@ -1442,7 +1442,7 @@ void ScUndoScenarioFlags::Redo()
pViewShell->UpdateInputHandler();
if ( aOldName != aNewName )
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
}
void ScUndoScenarioFlags::Repeat(SfxRepeatTarget& /* rTarget */)
diff --git a/sc/source/ui/unoobj/appluno.cxx b/sc/source/ui/unoobj/appluno.cxx
index 4d165df38136..e10ec30807e2 100644
--- a/sc/source/ui/unoobj/appluno.cxx
+++ b/sc/source/ui/unoobj/appluno.cxx
@@ -496,7 +496,7 @@ void SAL_CALL ScSpreadsheetSettings::setPropertyValue(
ScPrintOptions aPrintOpt(pScMod->GetPrintOptions());
aPrintOpt.SetSkipEmpty( !ScUnoHelpFunctions::GetBoolFromAny( aValue ) ); // reversed
pScMod->SetPrintOptions( aPrintOpt );
- SFX_APP()->Broadcast( SfxSimpleHint( SID_SCPRINTOPTIONS ) ); // update previews
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SID_SCPRINTOPTIONS ) ); // update previews
}
if ( bSaveApp )
diff --git a/sc/source/ui/unoobj/funcuno.cxx b/sc/source/ui/unoobj/funcuno.cxx
index b171bf69a637..4d4a9b723c50 100644
--- a/sc/source/ui/unoobj/funcuno.cxx
+++ b/sc/source/ui/unoobj/funcuno.cxx
@@ -179,7 +179,7 @@ ScFunctionAccess::ScFunctionAccess() :
mbArray( true ), // default according to behaviour of older Office versions
mbValid( true )
{
- StartListening( *SFX_APP() ); // for SFX_HINT_DEINITIALIZING
+ StartListening( *SfxGetpApp() ); // for SFX_HINT_DEINITIALIZING
}
ScFunctionAccess::~ScFunctionAccess()
diff --git a/sc/source/ui/unoobj/servuno.cxx b/sc/source/ui/unoobj/servuno.cxx
index d4836851eefa..859117a4b4bb 100644
--- a/sc/source/ui/unoobj/servuno.cxx
+++ b/sc/source/ui/unoobj/servuno.cxx
@@ -614,7 +614,7 @@ uno::Reference<uno::XInterface> ScServiceProvider::MakeInstance(
aArgs[ 0 ] <<= pDocShell->GetModel();
xRet = ::comphelper::getProcessServiceFactory()->createInstanceWithArguments( OUString( "ooo.vba.excel.Globals" ), aArgs );
pDocShell->GetBasicManager()->SetGlobalUNOConstant( "VBAGlobals", uno::Any( xRet ) );
- BasicManager* pAppMgr = SFX_APP()->GetBasicManager();
+ BasicManager* pAppMgr = SfxGetpApp()->GetBasicManager();
if ( pAppMgr )
pAppMgr->SetGlobalUNOConstant( "ThisExcelDoc", aArgs[ 0 ] );
diff --git a/sc/source/ui/unoobj/viewuno.cxx b/sc/source/ui/unoobj/viewuno.cxx
index b2c825786e76..604a714b30a4 100644
--- a/sc/source/ui/unoobj/viewuno.cxx
+++ b/sc/source/ui/unoobj/viewuno.cxx
@@ -1741,7 +1741,7 @@ void ScTabViewObj::SelectionChanged()
// will cause the style dialog to be raised so we go
// direct here
ScFormatShell aShell( &GetViewShell()->GetViewData() );
- SfxAllItemSet reqList( SFX_APP()->GetPool() );
+ SfxAllItemSet reqList( SfxGetpApp()->GetPool() );
SfxRequest aReq( SID_STYLE_END_PREVIEW, 0, reqList );
aShell.ExecuteStyle( aReq );
lang::EventObject aEvent;
diff --git a/sc/source/ui/vba/vbaapplication.cxx b/sc/source/ui/vba/vbaapplication.cxx
index 81aafa2bc0a7..6426232641be 100644
--- a/sc/source/ui/vba/vbaapplication.cxx
+++ b/sc/source/ui/vba/vbaapplication.cxx
@@ -463,7 +463,7 @@ ScVbaApplication::Windows( const uno::Any& aIndex ) throw (uno::RuntimeExceptio
void SAL_CALL
ScVbaApplication::wait( double time ) throw (uno::RuntimeException, std::exception)
{
- StarBASIC* pBasic = SFX_APP()->GetBasic();
+ StarBASIC* pBasic = SfxGetpApp()->GetBasic();
SbxArrayRef aArgs = new SbxArray;
SbxVariableRef aRef = new SbxVariable;
aRef->PutDouble( time );
@@ -1238,7 +1238,7 @@ ScVbaApplication::getDisplayFormulaBar()
if ( pViewShell )
{
SfxBoolItem sfxFormBar( FID_TOGGLEINPUTLINE);
- SfxAllItemSet reqList( SFX_APP()->GetPool() );
+ SfxAllItemSet reqList( SfxGetpApp()->GetPool() );
reqList.Put( sfxFormBar );
pViewShell->GetState( reqList );
@@ -1257,7 +1257,7 @@ ScVbaApplication::setDisplayFormulaBar( sal_Bool _displayformulabar )
if ( pViewShell && ( _displayformulabar != getDisplayFormulaBar() ) )
{
SfxBoolItem sfxFormBar( FID_TOGGLEINPUTLINE, _displayformulabar);
- SfxAllItemSet reqList( SFX_APP()->GetPool() );
+ SfxAllItemSet reqList( SfxGetpApp()->GetPool() );
SfxRequest aReq( FID_TOGGLEINPUTLINE, 0, reqList );
pViewShell->Execute( aReq );
}
@@ -1266,7 +1266,7 @@ ScVbaApplication::setDisplayFormulaBar( sal_Bool _displayformulabar )
uno::Any SAL_CALL
ScVbaApplication::Caller( const uno::Any& /*aIndex*/ ) throw ( uno::RuntimeException, std::exception )
{
- StarBASIC* pBasic = SFX_APP()->GetBasic();
+ StarBASIC* pBasic = SfxGetpApp()->GetBasic();
SbMethod* pMeth = (SbMethod*)pBasic->GetRtl()->Find( OUString("FuncCaller"), SbxCLASS_METHOD );
uno::Any aRet;
if ( pMeth )
diff --git a/sc/source/ui/vba/vbahelper.cxx b/sc/source/ui/vba/vbahelper.cxx
index 662ffec00358..a29ae357f88f 100644
--- a/sc/source/ui/vba/vbahelper.cxx
+++ b/sc/source/ui/vba/vbahelper.cxx
@@ -232,7 +232,7 @@ void implnPasteSpecial(sal_uInt16 nFlags,sal_uInt16 nFunction,sal_Bool bSkipEmpt
getCurrentDocument() throw (uno::RuntimeException)
{
uno::Reference< frame::XModel > xModel;
- SbxObject* pBasic = dynamic_cast< SbxObject* > ( SFX_APP()->GetBasic() );
+ SbxObject* pBasic = dynamic_cast< SbxObject* > ( SfxGetpApp()->GetBasic() );
SbxObject* basicChosen = pBasic ;
if ( basicChosen == NULL)
{
@@ -405,7 +405,7 @@ void PrintOutHelper( const uno::Any& From, const uno::Any& To, const uno::Any& C
pViewFrame = pViewShell->GetViewFrame();
if ( pViewFrame )
{
- SfxAllItemSet aArgs( SFX_APP()->GetPool() );
+ SfxAllItemSet aArgs( SfxGetpApp()->GetPool() );
SfxBoolItem sfxCollate( SID_PRINT_COLLATE, bCollate );
aArgs.Put( sfxCollate, sfxCollate.Which() );
diff --git a/sc/source/ui/vba/vbarange.cxx b/sc/source/ui/vba/vbarange.cxx
index 521f224e8d40..a14bb3129903 100644
--- a/sc/source/ui/vba/vbarange.cxx
+++ b/sc/source/ui/vba/vbarange.cxx
@@ -3574,7 +3574,7 @@ ScVbaRange::End( ::sal_Int32 Direction ) throw (uno::RuntimeException, std::exc
SfxViewFrame* pViewFrame = excel::getViewFrame( xModel );
if ( pViewFrame )
{
- SfxAllItemSet aArgs( SFX_APP()->GetPool() );
+ SfxAllItemSet aArgs( SfxGetpApp()->GetPool() );
// Hoping this will make sure this slot is called
// synchronously
SfxBoolItem sfxAsync( SID_ASYNCHRON, false );
diff --git a/sc/source/ui/view/dbfunc.cxx b/sc/source/ui/view/dbfunc.cxx
index 3472140c0cb3..a1a5fc215a5b 100644
--- a/sc/source/ui/view/dbfunc.cxx
+++ b/sc/source/ui/view/dbfunc.cxx
@@ -226,7 +226,7 @@ void ScDBFunc::NotifyCloseDbNameDlg( const ScDBCollection& rNewColl, const std::
pOldColl = NULL;
pDocShell->PostPaint(ScRange(0, 0, 0, MAXCOL, MAXROW, MAXTAB), PAINT_GRID);
aModificator.SetDocumentModified();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_DBAREAS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_DBAREAS_CHANGED ) );
if (bRecord)
{
diff --git a/sc/source/ui/view/dbfunc3.cxx b/sc/source/ui/view/dbfunc3.cxx
index 09293c01589e..ba0d50d20f17 100644
--- a/sc/source/ui/view/dbfunc3.cxx
+++ b/sc/source/ui/view/dbfunc3.cxx
@@ -626,7 +626,7 @@ bool ScDBFunc::MakePivotTable(
if ( bNewTable )
{
pDocSh->PostPaintExtras();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
}
return bSuccess;
diff --git a/sc/source/ui/view/prevwsh.cxx b/sc/source/ui/view/prevwsh.cxx
index 691d2b0b17a6..121a9cc2509e 100644
--- a/sc/source/ui/view/prevwsh.cxx
+++ b/sc/source/ui/view/prevwsh.cxx
@@ -135,7 +135,7 @@ void ScPreviewShell::Construct( Window* pParent )
SetPool( &SC_MOD()->GetPool() );
SetWindow( pPreview );
StartListening(*pDocShell,true);
- StartListening(*SFX_APP(),true); // #i62045# #i62046# application is needed for Calc's own hints
+ StartListening(*SfxGetpApp(),true); // #i62045# #i62046# application is needed for Calc's own hints
SfxBroadcaster* pDrawBC = pDocShell->GetDocument().GetDrawBroadcaster();
if (pDrawBC)
StartListening(*pDrawBC);
@@ -192,7 +192,7 @@ ScPreviewShell::~ScPreviewShell()
SfxBroadcaster* pDrawBC = pDocShell->GetDocument().GetDrawBroadcaster();
if (pDrawBC)
EndListening(*pDrawBC);
- EndListening(*SFX_APP());
+ EndListening(*SfxGetpApp());
EndListening(*pDocShell);
SetWindow(0);
diff --git a/sc/source/ui/view/tabvwsh4.cxx b/sc/source/ui/view/tabvwsh4.cxx
index ed254f05b2d6..f46b5bf22683 100644
--- a/sc/source/ui/view/tabvwsh4.cxx
+++ b/sc/source/ui/view/tabvwsh4.cxx
@@ -165,7 +165,7 @@ void ScTabViewShell::Activate(bool bMDI)
if ( bFirstActivate )
{
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_NAVIGATOR_UPDATEALL ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_NAVIGATOR_UPDATEALL ) );
bFirstActivate = false;
// ReadExtOptions (view settings from Excel import) must also be done
@@ -1566,7 +1566,7 @@ bool ScTabViewShell::KeyInput( const KeyEvent &rKeyEvent )
void ScTabViewShell::Construct( sal_uInt8 nForceDesignMode )
{
- SfxApplication* pSfxApp = SFX_APP();
+ SfxApplication* pSfxApp = SfxGetpApp();
ScDocShell* pDocSh = GetViewData().GetDocShell();
ScDocument& rDoc = pDocSh->GetDocument();
bReadOnly = pDocSh->IsReadOnly();
@@ -1819,7 +1819,7 @@ ScTabViewShell::~ScTabViewShell()
ScDocShell* pDocSh = GetViewData().GetDocShell();
EndListening(*pDocSh);
EndListening(*GetViewFrame());
- EndListening(*SFX_APP()); // #i62045# #i62046# needed now - SfxViewShell no longer does it
+ EndListening(*SfxGetpApp()); // #i62045# #i62046# needed now - SfxViewShell no longer does it
SC_MOD()->ViewShellGone(this);
diff --git a/sc/source/ui/view/tabvwshb.cxx b/sc/source/ui/view/tabvwshb.cxx
index b3fb6a345b34..858bfa773ee7 100644
--- a/sc/source/ui/view/tabvwshb.cxx
+++ b/sc/source/ui/view/tabvwshb.cxx
@@ -367,7 +367,7 @@ void ScTabViewShell::ExecDrawIns(SfxRequest& rReq)
{
pDlg->Execute();
rBindings.Invalidate( nSlot );
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) ); // Navigator
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) ); // Navigator
rReq.Done();
}
}
diff --git a/sc/source/ui/view/viewfun2.cxx b/sc/source/ui/view/viewfun2.cxx
index 5cdb61095d98..84044529dee2 100644
--- a/sc/source/ui/view/viewfun2.cxx
+++ b/sc/source/ui/view/viewfun2.cxx
@@ -1892,7 +1892,7 @@ bool ScViewFunc::InsertTables(std::vector<OUString>& aNames, SCTAB nTab,
SetTabNo( nTab, true );
pDocSh->PostPaintExtras();
pDocSh->SetDocumentModified();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
return true;
}
else
@@ -1923,7 +1923,7 @@ bool ScViewFunc::AppendTable( const OUString& rName, bool bRecord )
SetTabNo( nTab, true );
pDocSh->PostPaintExtras();
pDocSh->SetDocumentModified();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
return true;
}
else
@@ -1982,7 +1982,7 @@ bool ScViewFunc::DeleteTables( const SCTAB nTab, SCTAB nSheets )
pDocSh->PostPaintExtras();
pDocSh->SetDocumentModified();
- SfxApplication* pSfxApp = SFX_APP(); // Navigator
+ SfxApplication* pSfxApp = SfxGetpApp(); // Navigator
pSfxApp->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
pSfxApp->Broadcast( SfxSimpleHint( SC_HINT_DBAREAS_CHANGED ) );
pSfxApp->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
@@ -2106,7 +2106,7 @@ bool ScViewFunc::DeleteTables(const vector<SCTAB> &TheTabs, bool bRecord )
pDocSh->PostPaintExtras();
pDocSh->SetDocumentModified();
- SfxApplication* pSfxApp = SFX_APP(); // Navigator
+ SfxApplication* pSfxApp = SfxGetpApp(); // Navigator
pSfxApp->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
pSfxApp->Broadcast( SfxSimpleHint( SC_HINT_DBAREAS_CHANGED ) );
pSfxApp->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
@@ -2305,7 +2305,7 @@ void ScViewFunc::ImportTables( ScDocShell* pSrcShell,
pDocSh->PostPaint( 0,0,0, MAXCOL,MAXROW,MAXTAB,
PAINT_GRID | PAINT_TOP | PAINT_LEFT | PAINT_EXTRAS );
- SfxApplication* pSfxApp = SFX_APP();
+ SfxApplication* pSfxApp = SfxGetpApp();
pSfxApp->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
pSfxApp->Broadcast( SfxSimpleHint( SC_HINT_AREAS_CHANGED ) );
@@ -2535,7 +2535,7 @@ void ScViewFunc::MoveTable(
TheTabs.clear();
pDestShell->SetDocumentModified();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
}
else
{
@@ -2692,7 +2692,7 @@ void ScViewFunc::ShowTable( const std::vector<OUString>& rNames )
{
rDoc.SetVisible( nPos, true );
SetTabNo( nPos, true );
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
if (!bFound)
bFound = true;
if (bUndo)
@@ -2752,7 +2752,7 @@ void ScViewFunc::HideTable( const ScMarkData& rMark )
}
// Update views
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_TABLES_CHANGED ) );
pDocSh->PostPaint(0,0,0,MAXCOL,MAXROW,MAXTAB, PAINT_EXTRAS);
pDocSh->SetDocumentModified();
}
diff --git a/sc/source/ui/view/viewfunc.cxx b/sc/source/ui/view/viewfunc.cxx
index ed0d0f5e91e0..b139987730f5 100644
--- a/sc/source/ui/view/viewfunc.cxx
+++ b/sc/source/ui/view/viewfunc.cxx
@@ -1727,7 +1727,7 @@ void ScViewFunc::DeleteMulti( bool bRows, bool bRecord )
nCurX = static_cast<SCCOL>(aSpans[0].mnStart);
SetCursor( nCurX, nCurY );
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREALINKS_CHANGED ) );
}
// delete contents
@@ -2784,7 +2784,7 @@ bool ScViewFunc::InsertName( const OUString& rName, const OUString& rSymbol,
rDoc.PostprocessRangeNameUpdate();
aModificator.SetDocumentModified();
- SFX_APP()->Broadcast( SfxSimpleHint( SC_HINT_AREAS_CHANGED ) );
+ SfxGetpApp()->Broadcast( SfxSimpleHint( SC_HINT_AREAS_CHANGED ) );
}
delete pNewEntry; // if it wasn't inserted
diff --git a/scripting/source/basprov/basprov.cxx b/scripting/source/basprov/basprov.cxx
index 6e8d5b3a0411..0f27e92cc28e 100644
--- a/scripting/source/basprov/basprov.cxx
+++ b/scripting/source/basprov/basprov.cxx
@@ -271,10 +271,10 @@ namespace basprov
// TODO
if ( !m_pAppBasicManager )
- m_pAppBasicManager = SFX_APP()->GetBasicManager();
+ m_pAppBasicManager = SfxGetpApp()->GetBasicManager();
if ( !m_xLibContainerApp.is() )
- m_xLibContainerApp = Reference< script::XLibraryContainer >( SFX_APP()->GetBasicContainer(), UNO_QUERY );
+ m_xLibContainerApp = Reference< script::XLibraryContainer >( SfxGetpApp()->GetBasicContainer(), UNO_QUERY );
}
diff --git a/scripting/source/dlgprov/dlgevtatt.cxx b/scripting/source/dlgprov/dlgevtatt.cxx
index bf66765389a7..d77ec5cb09d4 100644
--- a/scripting/source/dlgprov/dlgevtatt.cxx
+++ b/scripting/source/dlgprov/dlgevtatt.cxx
@@ -630,7 +630,7 @@ namespace dlgprov
}
else
{
- ResMgr* pResMgr = SFX_APP()->GetSfxResManager();
+ ResMgr* pResMgr = SfxGetpApp()->GetSfxResManager();
if( pResMgr )
{
OUString aRes( ResId(STR_ERRUNOEVENTBINDUNG, *pResMgr) );
diff --git a/scripting/source/dlgprov/dlgprov.cxx b/scripting/source/dlgprov/dlgprov.cxx
index 6367e2cbfd9c..bebd3ae0ba39 100644
--- a/scripting/source/dlgprov/dlgprov.cxx
+++ b/scripting/source/dlgprov/dlgprov.cxx
@@ -354,7 +354,7 @@ static OUString aResourceResolverPropName("ResourceResolver");
if ( sLocation == "application" )
{
- xLibContainer = Reference< XLibraryContainer >( SFX_APP()->GetDialogContainer(), UNO_QUERY );
+ xLibContainer = Reference< XLibraryContainer >( SfxGetpApp()->GetDialogContainer(), UNO_QUERY );
}
else if ( sLocation == "document" )
{
diff --git a/sd/source/core/drawdoc3.cxx b/sd/source/core/drawdoc3.cxx
index 65b6ff7d5a01..72fab2ccb2e9 100644
--- a/sd/source/core/drawdoc3.cxx
+++ b/sd/source/core/drawdoc3.cxx
@@ -201,7 +201,7 @@ SdDrawDocument* SdDrawDocument::OpenBookmarkDoc(SfxMedium& rMedium)
if ( !pFilter )
{
rMedium.UseInteractionHandler( true );
- SFX_APP()->GetFilterMatcher().GuessFilter( rMedium, &pFilter );
+ SfxGetpApp()->GetFilterMatcher().GuessFilter( rMedium, &pFilter );
}
if ( !pFilter )
diff --git a/sd/source/ui/app/sdmod.cxx b/sd/source/ui/app/sdmod.cxx
index 871bbc06b6ad..9bd820d35c6d 100644
--- a/sd/source/ui/app/sdmod.cxx
+++ b/sd/source/ui/app/sdmod.cxx
@@ -83,7 +83,7 @@ SdModule::SdModule(SfxObjectFactory* pFact1, SfxObjectFactory* pFact2 )
SetName( OUString( "StarDraw" ) ); // Do not translate!
pSearchItem = new SvxSearchItem(SID_SEARCH_ITEM);
pSearchItem->SetAppFlag(SVX_SEARCHAPP_DRAW);
- StartListening( *SFX_APP() );
+ StartListening( *SfxGetpApp() );
SvxErrorHandler::ensure();
mpErrorHdl = new SfxErrorHandler( RID_SD_ERRHDL,
ERRCODE_AREA_SD,
diff --git a/sd/source/ui/app/sdmod1.cxx b/sd/source/ui/app/sdmod1.cxx
index a10cbf31a868..b4d725649604 100644
--- a/sd/source/ui/app/sdmod1.cxx
+++ b/sd/source/ui/app/sdmod1.cxx
@@ -99,7 +99,7 @@ void SdModule::Execute(SfxRequest& rReq)
{
case SID_NEWDOC:
{
- SFX_APP()->ExecuteSlot(rReq, SFX_APP()->GetInterface());
+ SfxGetpApp()->ExecuteSlot(rReq, SfxGetpApp()->GetInterface());
}
break;
@@ -230,7 +230,7 @@ void SdModule::Execute(SfxRequest& rReq)
if (!bIntercept)
{
- SFX_APP()->ExecuteSlot(rReq, SFX_APP()->GetInterface());
+ SfxGetpApp()->ExecuteSlot(rReq, SfxGetpApp()->GetInterface());
}
else
{
@@ -358,7 +358,7 @@ void SdModule::GetState(SfxItemSet& rItemSet)
// state of SID_OPENDOC is determined by the base class
if (rItemSet.GetItemState(SID_OPENDOC) != SFX_ITEM_UNKNOWN)
{
- const SfxPoolItem* pItem = SFX_APP()->GetSlotState(SID_OPENDOC, SFX_APP()->GetInterface());
+ const SfxPoolItem* pItem = SfxGetpApp()->GetSlotState(SID_OPENDOC, SfxGetpApp()->GetInterface());
if (pItem)
rItemSet.Put(*pItem);
}
@@ -366,7 +366,7 @@ void SdModule::GetState(SfxItemSet& rItemSet)
// state of SID_OPENHYPERLINK is determined by the base class
if (rItemSet.GetItemState(SID_OPENHYPERLINK) != SFX_ITEM_UNKNOWN)
{
- const SfxPoolItem* pItem = SFX_APP()->GetSlotState(SID_OPENHYPERLINK, SFX_APP()->GetInterface());
+ const SfxPoolItem* pItem = SfxGetpApp()->GetSlotState(SID_OPENHYPERLINK, SfxGetpApp()->GetInterface());
if (pItem)
rItemSet.Put(*pItem);
}
@@ -498,10 +498,10 @@ SfxFrame* SdModule::CreateFromTemplate( const OUString& rTemplatePath, const Ref
SfxObjectShellLock xDocShell;
- SfxItemSet* pSet = new SfxAllItemSet( SFX_APP()->GetPool() );
+ SfxItemSet* pSet = new SfxAllItemSet( SfxGetpApp()->GetPool() );
pSet->Put( SfxBoolItem( SID_TEMPLATE, true ) );
- sal_uLong lErr = SFX_APP()->LoadTemplate( xDocShell, rTemplatePath, true, pSet );
+ sal_uLong lErr = SfxGetpApp()->LoadTemplate( xDocShell, rTemplatePath, true, pSet );
SfxObjectShell* pDocShell = xDocShell;
@@ -601,7 +601,7 @@ SfxFrame* SdModule::ExecuteNewDocument( SfxRequest& rReq )
}
else
{
- SfxRequest aRequest (SID_OPENDOC, SFX_CALLMODE_SYNCHRON, SFX_APP()->GetPool());
+ SfxRequest aRequest (SID_OPENDOC, SFX_CALLMODE_SYNCHRON, SfxGetpApp()->GetPool());
aRequest.AppendItem (aFile);
aRequest.AppendItem (aReferer);
// Put the password into the request
@@ -613,7 +613,7 @@ SfxFrame* SdModule::ExecuteNewDocument( SfxRequest& rReq )
OUString("_default")));
try
{
- const SfxPoolItem* pRet = SFX_APP()->ExecuteSlot (aRequest);
+ const SfxPoolItem* pRet = SfxGetpApp()->ExecuteSlot (aRequest);
const SfxViewFrameItem* pFrameItem = PTR_CAST( SfxViewFrameItem, pRet );
if ( pFrameItem )
pFrame = &pFrameItem->GetFrame()->GetFrame();
diff --git a/sd/source/ui/dlg/dlgass.cxx b/sd/source/ui/dlg/dlgass.cxx
index b434666c28a8..0e7f4d39263b 100644
--- a/sd/source/ui/dlg/dlgass.cxx
+++ b/sd/source/ui/dlg/dlgass.cxx
@@ -1406,7 +1406,7 @@ void AssistentDlgImpl::UpdatePreview( bool bDocPreview )
OUString aDocFile = GetDocFileName();
OUString aLayoutFile = GetLayoutFileName();
- SfxApplication *pSfxApp = SFX_APP();
+ SfxApplication *pSfxApp = SfxGetpApp();
sal_uLong lErr;
bool bChangeMaster = !aLayoutFile.isEmpty();
@@ -1468,14 +1468,14 @@ void AssistentDlgImpl::UpdatePreview( bool bDocPreview )
}
else
{
- SfxRequest aReq( SID_OPENDOC, SFX_CALLMODE_SYNCHRON, SFX_APP()->GetPool() );
+ SfxRequest aReq( SID_OPENDOC, SFX_CALLMODE_SYNCHRON, SfxGetpApp()->GetPool() );
aReq.AppendItem( SfxStringItem( SID_FILE_NAME, aDocFile ));
aReq.AppendItem( SfxStringItem( SID_REFERER, OUString() ) );
aReq.AppendItem( SfxStringItem( SID_TARGETNAME, OUString("_default") ) );
aReq.AppendItem( SfxBoolItem( SID_HIDDEN, true ) );
aReq.AppendItem( SfxBoolItem( SID_PREVIEW, bDocPreview ) );
- const SfxViewFrameItem* pRet = PTR_CAST( SfxViewFrameItem, SFX_APP()->ExecuteSlot( aReq ) );
+ const SfxViewFrameItem* pRet = PTR_CAST( SfxViewFrameItem, SfxGetpApp()->ExecuteSlot( aReq ) );
if ( pRet && pRet->GetFrame() && pRet->GetFrame()->GetObjectShell() )
xDocShell = pRet->GetFrame()->GetObjectShell();
diff --git a/sd/source/ui/func/fuinsfil.cxx b/sd/source/ui/func/fuinsfil.cxx
index 99a240760e27..4d172e02f431 100644
--- a/sd/source/ui/func/fuinsfil.cxx
+++ b/sd/source/ui/func/fuinsfil.cxx
@@ -92,7 +92,7 @@ rtl::Reference<FuPoor> FuInsertFile::Create( ViewShell* pViewSh, ::sd::Window* p
void FuInsertFile::DoExecute( SfxRequest& rReq )
{
- SfxFilterMatcher& rMatcher = SFX_APP()->GetFilterMatcher();
+ SfxFilterMatcher& rMatcher = SfxGetpApp()->GetFilterMatcher();
::std::vector< OUString > aFilterVector;
const SfxItemSet* pArgs = rReq.GetArgs ();
@@ -251,7 +251,7 @@ void FuInsertFile::DoExecute( SfxRequest& rReq )
SfxMedium* pMedium = new SfxMedium( aFile, STREAM_READ | STREAM_NOCREATE );
const SfxFilter* pFilter = NULL;
- SFX_APP()->GetFilterMatcher().GuessFilter( *pMedium, &pFilter, SFX_FILTER_IMPORT, SFX_FILTER_NOTINSTALLED | SFX_FILTER_EXECUTABLE );
+ SfxGetpApp()->GetFilterMatcher().GuessFilter( *pMedium, &pFilter, SFX_FILTER_IMPORT, SFX_FILTER_NOTINSTALLED | SFX_FILTER_EXECUTABLE );
bool bDrawMode = mpViewShell && mpViewShell->ISA(DrawViewShell);
bool bInserted = false;
@@ -718,7 +718,7 @@ bool FuInsertFile::InsSDDinOlMode(SfxMedium* pMedium)
void FuInsertFile::GetSupportedFilterVector( ::std::vector< OUString >& rFilterVector )
{
- SfxFilterMatcher& rMatcher = SFX_APP()->GetFilterMatcher();
+ SfxFilterMatcher& rMatcher = SfxGetpApp()->GetFilterMatcher();
const SfxFilter* pSearchFilter = NULL;
rFilterVector.clear();
diff --git a/sd/source/ui/sidebar/MasterPageContainerProviders.cxx b/sd/source/ui/sidebar/MasterPageContainerProviders.cxx
index c81f74aaeca7..c197615666e3 100644
--- a/sd/source/ui/sidebar/MasterPageContainerProviders.cxx
+++ b/sd/source/ui/sidebar/MasterPageContainerProviders.cxx
@@ -151,7 +151,7 @@ SdPage* TemplatePageObjectProvider::operator() (SdDrawDocument* pContainerDocume
::sd::DrawDocShell* TemplatePageObjectProvider::LoadDocument (const OUString& sFileName)
{
- SfxApplication* pSfxApp = SFX_APP();
+ SfxApplication* pSfxApp = SfxGetpApp();
SfxItemSet* pSet = new SfxAllItemSet (pSfxApp->GetPool());
pSet->Put (SfxBoolItem (SID_TEMPLATE, true));
pSet->Put (SfxBoolItem (SID_PREVIEW, true));
diff --git a/sd/source/ui/table/TableDesignPane.cxx b/sd/source/ui/table/TableDesignPane.cxx
index 01219e549e07..ef06796497a2 100644
--- a/sd/source/ui/table/TableDesignPane.cxx
+++ b/sd/source/ui/table/TableDesignPane.cxx
@@ -189,7 +189,7 @@ void TableDesignWidget::ApplyStyle()
{
if( pView )
{
- SfxRequest aReq( SID_TABLE_STYLE, SFX_CALLMODE_SYNCHRON, SFX_APP()->GetPool() );
+ SfxRequest aReq( SID_TABLE_STYLE, SFX_CALLMODE_SYNCHRON, SfxGetpApp()->GetPool() );
aReq.AppendItem( SfxStringItem( SID_TABLE_STYLE, sStyleName ) );
rtl::Reference< sdr::SelectionController > xController( pView->getSelectionController() );
@@ -238,7 +238,7 @@ void TableDesignWidget::ApplyOptions()
if( mxSelectedTable.is() )
{
- SfxRequest aReq( SID_TABLE_STYLE_SETTINGS, SFX_CALLMODE_SYNCHRON, SFX_APP()->GetPool() );
+ SfxRequest aReq( SID_TABLE_STYLE_SETTINGS, SFX_CALLMODE_SYNCHRON, SfxGetpApp()->GetPool() );
for( sal_uInt16 i = CB_HEADER_ROW; i <= CB_BANDED_COLUMNS; ++i )
{
diff --git a/sd/source/ui/view/drviewsg.cxx b/sd/source/ui/view/drviewsg.cxx
index cbb919c2ac1d..2ada0a9cbad7 100644
--- a/sd/source/ui/view/drviewsg.cxx
+++ b/sd/source/ui/view/drviewsg.cxx
@@ -199,7 +199,7 @@ void DrawViewShell::ExecOptionsBar( SfxRequest& rReq )
pOptions->StoreConfig();
// Saves the configuration IMMEDIATELY
- // SFX_APP()->SaveConfiguration();
+ // SfxGetpApp()->SaveConfiguration();
WriteFrameViewData();
mpFrameView->Update( pOptions );
diff --git a/sd/source/ui/view/sdview4.cxx b/sd/source/ui/view/sdview4.cxx
index 70adc9d90864..a437669a0ca8 100644
--- a/sd/source/ui/view/sdview4.cxx
+++ b/sd/source/ui/view/sdview4.cxx
@@ -447,7 +447,7 @@ IMPL_LINK_NOARG(View, DropInsertFileHdl)
{
const SfxFilter* pFoundFilter = NULL;
SfxMedium aSfxMedium( aCurrentDropFile, STREAM_READ | STREAM_SHARE_DENYNONE );
- ErrCode nErr = SFX_APP()->GetFilterMatcher().GuessFilter( aSfxMedium, &pFoundFilter, SFX_FILTER_IMPORT, SFX_FILTER_NOTINSTALLED | SFX_FILTER_EXECUTABLE );
+ ErrCode nErr = SfxGetpApp()->GetFilterMatcher().GuessFilter( aSfxMedium, &pFoundFilter, SFX_FILTER_IMPORT, SFX_FILTER_NOTINSTALLED | SFX_FILTER_EXECUTABLE );
if( pFoundFilter && !nErr )
{
diff --git a/sfx2/source/appl/appbaslib.cxx b/sfx2/source/appl/appbaslib.cxx
index d22dc48030d4..3eee7e575b68 100644
--- a/sfx2/source/appl/appbaslib.cxx
+++ b/sfx2/source/appl/appbaslib.cxx
@@ -160,8 +160,8 @@ com_sun_star_comp_sfx2_ApplicationDialogLibraryContainer_get_implementation(
css::uno::XComponentContext *,
css::uno::Sequence<css::uno::Any> const &)
{
- SFX_APP()->GetBasicManager();
- return SFX_APP()->GetDialogContainer();
+ SfxGetpApp()->GetBasicManager();
+ return SfxGetpApp()->GetDialogContainer();
}
@@ -172,8 +172,8 @@ com_sun_star_comp_sfx2_ApplicationScriptLibraryContainer_get_implementation(
css::uno::XComponentContext *,
css::uno::Sequence<css::uno::Any> const &)
{
- SFX_APP()->GetBasicManager();
- return SFX_APP()->GetBasicContainer();
+ SfxGetpApp()->GetBasicManager();
+ return SfxGetpApp()->GetBasicContainer();
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sfx2/source/appl/appcfg.cxx b/sfx2/source/appl/appcfg.cxx
index 225fc4cb2c75..23d464219295 100644
--- a/sfx2/source/appl/appcfg.cxx
+++ b/sfx2/source/appl/appcfg.cxx
@@ -140,7 +140,7 @@ IMPL_LINK(SfxEventAsyncer_Impl, TimerHdl, Timer*, pAsyncTimer)
OSL_TRACE( "%s", aTmp.getStr() );
}
#endif
- SFX_APP()->Broadcast( aHint );
+ SfxGetpApp()->Broadcast( aHint );
if ( xRef.Is() )
xRef->Broadcast( aHint );
delete this;
diff --git a/sfx2/source/appl/appdde.cxx b/sfx2/source/appl/appdde.cxx
index c034467d832e..9d3d63429e32 100644
--- a/sfx2/source/appl/appdde.cxx
+++ b/sfx2/source/appl/appdde.cxx
@@ -129,7 +129,7 @@ bool ImplDdeService::MakeTopic( const OUString& rNm )
OUString sTmp( pShell->GetTitle(SFX_TITLE_FULLNAME) );
if( sNm == sTmp.toAsciiLowerCase() )
{
- SFX_APP()->AddDdeTopic( pShell );
+ SfxGetpApp()->AddDdeTopic( pShell );
bRet = true;
break;
}
@@ -148,7 +148,7 @@ bool ImplDdeService::MakeTopic( const OUString& rNm )
SfxBoolItem aNewView(SID_OPEN_NEW_VIEW, sal_True);
SfxBoolItem aSilent(SID_SILENT, sal_True);
- SfxDispatcher* pDispatcher = SFX_APP()->GetDispatcher_Impl();
+ SfxDispatcher* pDispatcher = SfxGetpApp()->GetDispatcher_Impl();
const SfxPoolItem* pRet = pDispatcher->Execute( SID_OPENDOC,
SFX_CALLMODE_SYNCHRON,
&aName, &aNewView,
@@ -159,7 +159,7 @@ bool ImplDdeService::MakeTopic( const OUString& rNm )
0 != ( pShell = ((SfxViewFrameItem*)pRet)
->GetFrame()->GetObjectShell() ) )
{
- SFX_APP()->AddDdeTopic( pShell );
+ SfxGetpApp()->AddDdeTopic( pShell );
bRet = true;
}
}
@@ -192,7 +192,7 @@ OUString ImplDdeService::Topics()
bool ImplDdeService::SysTopicExecute( const OUString* pStr )
{
- return SFX_APP()->DdeExecute( *pStr );
+ return SfxGetpApp()->DdeExecute( *pStr );
}
#endif
diff --git a/sfx2/source/appl/appdispatchprovider.cxx b/sfx2/source/appl/appdispatchprovider.cxx
index 740b052206b8..53c33651aa39 100644
--- a/sfx2/source/appl/appdispatchprovider.cxx
+++ b/sfx2/source/appl/appdispatchprovider.cxx
@@ -136,7 +136,7 @@ Reference < XDispatch > SAL_CALL SfxAppDispatchProvider::queryDispatch(
bool bMasterCommand( false );
Reference < XDispatch > xDisp;
const SfxSlot* pSlot = 0;
- SfxDispatcher* pAppDisp = SFX_APP()->GetAppDispatcher_Impl();
+ SfxDispatcher* pAppDisp = SfxGetpApp()->GetAppDispatcher_Impl();
if ( aURL.Protocol == "slot:" || aURL.Protocol == "commandId:" )
{
nId = (sal_uInt16) aURL.Path.toInt32();
@@ -182,7 +182,7 @@ throw (uno::RuntimeException, std::exception)
SolarMutexGuard aGuard;
std::list< sal_Int16 > aGroupList;
- SfxSlotPool* pAppSlotPool = &SFX_APP()->GetAppSlotPool_Impl();
+ SfxSlotPool* pAppSlotPool = &SfxGetpApp()->GetAppSlotPool_Impl();
const sal_uIntPtr nMode( SFX_SLOT_TOOLBOXCONFIG|SFX_SLOT_ACCELCONFIG|SFX_SLOT_MENUCONFIG );
@@ -215,7 +215,7 @@ throw (uno::RuntimeException, std::exception)
std::list< frame::DispatchInformation > aCmdList;
SolarMutexGuard aGuard;
- SfxSlotPool* pAppSlotPool = &SFX_APP()->GetAppSlotPool_Impl();
+ SfxSlotPool* pAppSlotPool = &SfxGetpApp()->GetAppSlotPool_Impl();
if ( pAppSlotPool )
{
diff --git a/sfx2/source/appl/appinit.cxx b/sfx2/source/appl/appinit.cxx
index 04bb2db70ee6..9f2c54868c34 100644
--- a/sfx2/source/appl/appinit.cxx
+++ b/sfx2/source/appl/appinit.cxx
@@ -94,7 +94,7 @@ void SAL_CALL SfxTerminateListener_Impl::disposing( const EventObject& ) throw(
void SAL_CALL SfxTerminateListener_Impl::queryTermination( const EventObject& ) throw(TerminationVetoException, RuntimeException, std::exception )
{
SolarMutexGuard aGuard;
- if ( !SFX_APP()->QueryExit_Impl() )
+ if ( !SfxGetpApp()->QueryExit_Impl() )
throw TerminationVetoException();
}
@@ -111,7 +111,7 @@ void SAL_CALL SfxTerminateListener_Impl::notifyTermination( const EventObject& a
// Application::Quit(), which is asynchronous (PostUserEvent) - disable!
Timer::ImplDeInitTimer();
- SfxApplication* pApp = SFX_APP();
+ SfxApplication* pApp = SfxGetpApp();
pApp->Broadcast( SfxSimpleHint( SFX_HINT_DEINITIALIZING ) );
pApp->Get_Impl()->pAppDispatch->ReleaseAll();
pApp->Get_Impl()->pAppDispatch->release();
diff --git a/sfx2/source/appl/appopen.cxx b/sfx2/source/appl/appopen.cxx
index 9c1362074d59..8cb4630a5f5b 100644
--- a/sfx2/source/appl/appopen.cxx
+++ b/sfx2/source/appl/appopen.cxx
@@ -439,7 +439,7 @@ void SfxApplication::NewDocDirectExec_Impl( SfxRequest& rReq )
if ( pDefaultNameItem )
aReq.AppendItem( *pDefaultNameItem );
- SFX_APP()->ExecuteSlot( aReq );
+ SfxGetpApp()->ExecuteSlot( aReq );
const SfxViewFrameItem* pItem = PTR_CAST( SfxViewFrameItem, aReq.GetReturnValue() );
if ( pItem )
rReq.SetReturnValue( SfxFrameItem( 0, pItem->GetFrame() ) );
@@ -831,7 +831,7 @@ void SfxApplication::OpenDocExec_Impl( SfxRequest& rReq )
if ( eMode == SvtExtendedSecurityOptions::OPEN_NEVER && aINetProtocol != INET_PROT_VND_SUN_STAR_HELP )
{
SolarMutexGuard aGuard;
- Window *pWindow = SFX_APP()->GetTopWindow();
+ Window *pWindow = SfxGetpApp()->GetTopWindow();
WarningBox aSecurityWarningBox( pWindow, SfxResId( RID_SECURITY_WARNING_NO_HYPERLINKS ));
aSecurityWarningBox.SetText( SfxResId(RID_SECURITY_WARNING_TITLE).toString() );
@@ -840,7 +840,7 @@ void SfxApplication::OpenDocExec_Impl( SfxRequest& rReq )
}
aTypeName = xTypeDetection->queryTypeByURL( aURL.Main );
- SfxFilterMatcher& rMatcher = SFX_APP()->GetFilterMatcher();
+ SfxFilterMatcher& rMatcher = SfxGetpApp()->GetFilterMatcher();
const SfxFilter* pFilter = rMatcher.GetFilter4EA( aTypeName );
if (!pFilter || !lcl_isFilterNativelySupported(*pFilter))
{
diff --git a/sfx2/source/appl/childwin.cxx b/sfx2/source/appl/childwin.cxx
index 85d4d68f39d4..1397e3403b2a 100644
--- a/sfx2/source/appl/childwin.cxx
+++ b/sfx2/source/appl/childwin.cxx
@@ -200,7 +200,7 @@ SfxChildWindow* SfxChildWindow::CreateChildWindow( sal_uInt16 nId,
// First search for ChildWindow in SDT; "Overloading has to be realized
// by using ChildWindowContext
- SfxApplication *pApp = SFX_APP();
+ SfxApplication *pApp = SfxGetpApp();
{
SfxChildWinFactArr_Impl &rFactories = pApp->GetChildWinFactories_Impl();
for ( sal_uInt16 nFactory = 0; nFactory < rFactories.size(); ++nFactory )
@@ -418,7 +418,7 @@ void SfxChildWindow::CreateContext( sal_uInt16 nContextId, SfxBindings& rBinding
{
SfxChildWindowContext *pCon = NULL;
SfxChildWinFactory* pFact=0;
- SfxApplication *pApp = SFX_APP();
+ SfxApplication *pApp = SfxGetpApp();
SfxDispatcher *pDisp = rBindings.GetDispatcher_Impl();
SfxModule *pMod = pDisp ? SfxModule::GetActiveModule( pDisp->GetFrame() ) :0;
if ( pMod )
@@ -748,12 +748,12 @@ bool SfxChildWindow::CanGetFocus() const
void SfxChildWindowContext::RegisterChildWindowContext(SfxModule* pMod, sal_uInt16 nId, SfxChildWinContextFactory* pFact)
{
- SFX_APP()->RegisterChildWindowContext_Impl( pMod, nId, pFact );
+ SfxGetpApp()->RegisterChildWindowContext_Impl( pMod, nId, pFact );
}
void SfxChildWindow::RegisterChildWindow(SfxModule* pMod, SfxChildWinFactory* pFact)
{
- SFX_APP()->RegisterChildWindow_Impl( pMod, pFact );
+ SfxGetpApp()->RegisterChildWindow_Impl( pMod, pFact );
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sfx2/source/appl/linkmgr2.cxx b/sfx2/source/appl/linkmgr2.cxx
index 291671305a44..501ec5457d00 100644
--- a/sfx2/source/appl/linkmgr2.cxx
+++ b/sfx2/source/appl/linkmgr2.cxx
@@ -662,7 +662,7 @@ bool SvxInternalLink::Connect( sfx2::SvBaseLink* pLink )
SfxBoolItem aDdeConnect(SID_DDE_RECONNECT_ONLOAD, false);
// #i14200# (DDE-link crashes wordprocessor)
- SfxAllItemSet aArgs( SFX_APP()->GetPool() );
+ SfxAllItemSet aArgs( SfxGetpApp()->GetPool() );
aArgs.Put(aReferer);
aArgs.Put(aTarget);
aArgs.Put(aHidden);
diff --git a/sfx2/source/appl/macroloader.cxx b/sfx2/source/appl/macroloader.cxx
index f51b7a0781e1..0505c3885b09 100644
--- a/sfx2/source/appl/macroloader.cxx
+++ b/sfx2/source/appl/macroloader.cxx
@@ -207,7 +207,7 @@ ErrCode SfxMacroLoader::loadMacro( const OUString& rURL, com::sun::star::uno::An
OUString aMacro( rURL );
sal_Int32 nHashPos = aMacro.indexOf( '/', 8 );
sal_Int32 nArgsPos = aMacro.indexOf( '(' );
- BasicManager *pAppMgr = SFX_APP()->GetBasicManager();
+ BasicManager *pAppMgr = SfxGetpApp()->GetBasicManager();
BasicManager *pBasMgr = 0;
ErrCode nErr = ERRCODE_NONE;
diff --git a/sfx2/source/appl/module.cxx b/sfx2/source/appl/module.cxx
index 32508b602dca..fe416c37431d 100644
--- a/sfx2/source/appl/module.cxx
+++ b/sfx2/source/appl/module.cxx
@@ -127,7 +127,7 @@ void SfxModule::Construct_Impl()
{
if( !bDummy )
{
- SfxApplication *pApp = SFX_APP();
+ SfxApplication *pApp = SfxGetpApp();
SfxModuleArr_Impl& rArr = GetModules_Impl();
SfxModule* pPtr = (SfxModule*)this;
rArr.push_back( pPtr );
@@ -151,7 +151,7 @@ SfxModule::~SfxModule()
{
if( !bDummy )
{
- if ( SFX_APP()->Get_Impl() )
+ if ( SfxGetpApp()->Get_Impl() )
{
// The module will be destroyed before the Deinitialize,
// so remove from the array
diff --git a/sfx2/source/appl/sfxpicklist.cxx b/sfx2/source/appl/sfxpicklist.cxx
index 19c1c313fbbd..c405a7ef1e9a 100644
--- a/sfx2/source/appl/sfxpicklist.cxx
+++ b/sfx2/source/appl/sfxpicklist.cxx
@@ -240,7 +240,7 @@ SfxPickList::SfxPickList( sal_uInt32 nAllowedMenuSize ) :
{
m_xStringLength = new StringLength;
m_nAllowedMenuSize = ::std::min( m_nAllowedMenuSize, (sal_uInt32)PICKLIST_MAXSIZE );
- StartListening( *SFX_APP() );
+ StartListening( *SfxGetpApp() );
}
SfxPickList::~SfxPickList()
@@ -335,7 +335,7 @@ void SfxPickList::ExecuteEntry( sal_uInt32 nIndex )
if ( pPick )
{
- SfxRequest aReq( SID_OPENDOC, SFX_CALLMODE_ASYNCHRON, SFX_APP()->GetPool() );
+ SfxRequest aReq( SID_OPENDOC, SFX_CALLMODE_ASYNCHRON, SfxGetpApp()->GetPool() );
aReq.AppendItem( SfxStringItem( SID_FILE_NAME, pPick->aName ));
aReq.AppendItem( SfxStringItem( SID_REFERER, "private:user" ) );
aReq.AppendItem( SfxStringItem( SID_TARGETNAME, "_default" ) );
@@ -352,7 +352,7 @@ void SfxPickList::ExecuteEntry( sal_uInt32 nIndex )
aReq.AppendItem(SfxStringItem( SID_FILTER_NAME, aFilter ));
aReq.AppendItem( SfxBoolItem( SID_TEMPLATE, false ) );
- SFX_APP()->ExecuteSlot( aReq );
+ SfxGetpApp()->ExecuteSlot( aReq );
}
}
diff --git a/sfx2/source/appl/shutdownicon.cxx b/sfx2/source/appl/shutdownicon.cxx
index 9a5c9e4247fc..05c8c62e9bde 100644
--- a/sfx2/source/appl/shutdownicon.cxx
+++ b/sfx2/source/appl/shutdownicon.cxx
@@ -520,7 +520,7 @@ IMPL_STATIC_LINK( ShutdownIcon, DialogClosedHdl_Impl, FileDialogHelper*, EMPTYAR
if ( !aFilterName.isEmpty() )
{
- const SfxFilter* pFilter = SFX_APP()->GetFilterMatcher().GetFilter4UIName( aFilterName, 0, SFX_FILTER_NOTINFILEDLG );
+ const SfxFilter* pFilter = SfxGetpApp()->GetFilterMatcher().GetFilter4UIName( aFilterName, 0, SFX_FILTER_NOTINFILEDLG );
if ( pFilter )
{
diff --git a/sfx2/source/appl/workwin.cxx b/sfx2/source/appl/workwin.cxx
index 392ba876a134..b2ba60f85a23 100644
--- a/sfx2/source/appl/workwin.cxx
+++ b/sfx2/source/appl/workwin.cxx
@@ -1325,7 +1325,7 @@ void SfxWorkWindow::UpdateObjectBars_Impl()
}
// you realize what is needed often (saves Code and execution time)
- SFX_APP();
+ SfxGetpApp();
Reference< com::sun::star::beans::XPropertySet > xPropSet( GetFrameInterface(), UNO_QUERY );
Reference< ::com::sun::star::frame::XLayoutManager > xLayoutManager;
@@ -2431,7 +2431,7 @@ void SfxWorkWindow::InitializeChild_Impl(SfxChildWin_Impl *pCW)
}
SfxChildWinFactory* pFact=0;
- SfxApplication *pApp = SFX_APP();
+ SfxApplication *pApp = SfxGetpApp();
{
SfxChildWinFactArr_Impl &rFactories = pApp->GetChildWinFactories_Impl();
for ( sal_uInt16 nFactory = 0; nFactory < rFactories.size(); ++nFactory )
diff --git a/sfx2/source/bastyp/progress.cxx b/sfx2/source/bastyp/progress.cxx
index 2b4a51a83d90..83410b689f1b 100644
--- a/sfx2/source/bastyp/progress.cxx
+++ b/sfx2/source/bastyp/progress.cxx
@@ -97,7 +97,7 @@ void SfxProgress_Impl::Enable_Impl( bool bEnable )
}
if ( !pDoc )
- SFX_APP()->GetAppDispatcher_Impl()->Lock( !bEnable );
+ SfxGetpApp()->GetAppDispatcher_Impl()->Lock( !bEnable );
}
@@ -170,7 +170,7 @@ SfxProgress::SfxProgress
if ( pObjSh )
pObjSh->SetProgress_Impl(this);
else if( !pImp->pActiveProgress )
- SFX_APP()->SetProgress_Impl(this);
+ SfxGetpApp()->SetProgress_Impl(this);
Resume();
}
@@ -218,7 +218,7 @@ void SfxProgress::Stop()
if ( pImp->xObjSh.Is() )
pImp->xObjSh->SetProgress_Impl(0);
else
- SFX_APP()->SetProgress_Impl(0);
+ SfxGetpApp()->SetProgress_Impl(0);
if ( pImp->bLocked )
pImp->Enable_Impl(true);
}
@@ -320,7 +320,7 @@ bool SfxProgress::SetState
}
else if ( pImp->pView )
{
- pImp->pWorkWin = SFX_APP()->GetWorkWindow_Impl( pImp->pView );
+ pImp->pWorkWin = SfxGetpApp()->GetWorkWindow_Impl( pImp->pView );
if ( pImp->pWorkWin )
pImp->xStatusInd = pImp->pWorkWin->GetStatusIndicator();
}
@@ -454,7 +454,7 @@ void SfxProgress::Reschedule()
SFX_STACK(SfxProgress::Reschedule);
if( pImp->pActiveProgress ) return;
- SfxApplication* pApp = SFX_APP();
+ SfxApplication* pApp = SfxGetpApp();
if ( pImp->bLocked && 0 == pApp->Get_Impl()->nRescheduleLocks )
{
SfxAppData_Impl *pAppData = pApp->Get_Impl();
@@ -509,7 +509,7 @@ SfxProgress* SfxProgress::GetActiveProgress
if ( pDocSh )
pProgress = pDocSh->GetProgress();
if ( !pProgress )
- pProgress = SFX_APP()->GetProgress();
+ pProgress = SfxGetpApp()->GetProgress();
return pProgress;
}
@@ -517,14 +517,14 @@ SfxProgress* SfxProgress::GetActiveProgress
void SfxProgress::EnterLock()
{
- SFX_APP()->Get_Impl()->nRescheduleLocks++;
+ SfxGetpApp()->Get_Impl()->nRescheduleLocks++;
}
void SfxProgress::LeaveLock()
{
- SfxAppData_Impl *pImp = SFX_APP()->Get_Impl();
+ SfxAppData_Impl *pImp = SfxGetpApp()->Get_Impl();
DBG_ASSERT( 0 != pImp->nRescheduleLocks, "SFxProgress::LeaveLock but no locks" );
pImp->nRescheduleLocks--;
}
diff --git a/sfx2/source/control/bindings.cxx b/sfx2/source/control/bindings.cxx
index b83ef08d9e44..8b1175375a4f 100644
--- a/sfx2/source/control/bindings.cxx
+++ b/sfx2/source/control/bindings.cxx
@@ -649,7 +649,7 @@ void SfxBindings::InvalidateAll
// everything is already set dirty or downing => nothing to do
if ( !pDispatcher ||
( pImp->bAllDirty && ( !bWithMsg || pImp->bAllMsgDirty ) ) ||
- SFX_APP()->IsDowning() )
+ SfxGetpApp()->IsDowning() )
{
return;
}
@@ -693,7 +693,7 @@ void SfxBindings::Invalidate
pImp->pSubBindings->Invalidate( pIds );
// everything is already set dirty or downing => nothing to do
- if ( !pDispatcher || pImp->bAllDirty || SFX_APP()->IsDowning() )
+ if ( !pDispatcher || pImp->bAllDirty || SfxGetpApp()->IsDowning() )
return;
// Search binary in always smaller areas
@@ -742,7 +742,7 @@ void SfxBindings::InvalidateShell
if ( pImp->pSubBindings )
pImp->pSubBindings->InvalidateShell( rSh, bDeep );
- if ( !pDispatcher || pImp->bAllDirty || SFX_APP()->IsDowning() )
+ if ( !pDispatcher || pImp->bAllDirty || SfxGetpApp()->IsDowning() )
return;
// flush now already, it is done in GetShellLevel (rsh) anyway,
@@ -751,7 +751,7 @@ void SfxBindings::InvalidateShell
if ( !pDispatcher ||
( pImp->bAllDirty && pImp->bAllMsgDirty ) ||
- SFX_APP()->IsDowning() )
+ SfxGetpApp()->IsDowning() )
{
// if the next one is anyway, then all the servers are collected
return;
@@ -799,7 +799,7 @@ void SfxBindings::Invalidate
if ( pImp->pSubBindings )
pImp->pSubBindings->Invalidate( nId );
- if ( !pDispatcher || pImp->bAllDirty || SFX_APP()->IsDowning() )
+ if ( !pDispatcher || pImp->bAllDirty || SfxGetpApp()->IsDowning() )
return;
SfxStateCache* pCache = GetStateCache(nId);
@@ -830,7 +830,7 @@ void SfxBindings::Invalidate
if ( pImp->pSubBindings )
pImp->pSubBindings->Invalidate( nId, bWithItem, bWithMsg );
- if ( SFX_APP()->IsDowning() )
+ if ( SfxGetpApp()->IsDowning() )
return;
SfxStateCache* pCache = GetStateCache(nId);
@@ -1535,7 +1535,7 @@ IMPL_LINK( SfxBindings, NextJob_Impl, Timer *, pTimer )
return sal_True;
}
- SfxApplication *pSfxApp = SFX_APP();
+ SfxApplication *pSfxApp = SfxGetpApp();
if( pDispatcher )
pDispatcher->Update_Impl();
@@ -1705,7 +1705,7 @@ void SfxBindings::LeaveRegistrations( sal_uInt16 nLevel, const char *pFile, int
pImp->nOwnRegLevel--;
// check if this is the outer most level
- if ( --nRegLevel == 0 && !SFX_APP()->IsDowning() )
+ if ( --nRegLevel == 0 && !SfxGetpApp()->IsDowning() )
{
if ( pImp->bContextChanged )
{
diff --git a/sfx2/source/control/dispatch.cxx b/sfx2/source/control/dispatch.cxx
index 4f8bccae90dc..f7a83c1649f9 100644
--- a/sfx2/source/control/dispatch.cxx
+++ b/sfx2/source/control/dispatch.cxx
@@ -422,7 +422,7 @@ SfxDispatcher::~SfxDispatcher()
*pImp->pInCallAliveFlag = false;
// Get bindings and application
- SfxApplication *pSfxApp = SFX_APP();
+ SfxApplication *pSfxApp = SfxGetpApp();
SfxBindings* pBindings = GetBindings();
// When not flushed, revive the bindings
@@ -472,7 +472,7 @@ void SfxDispatcher::Pop
bool bUntil = (nMode & SFX_SHELL_POP_UNTIL) == SFX_SHELL_POP_UNTIL;
bool bPush = (nMode & SFX_SHELL_PUSH) == SFX_SHELL_PUSH;
- SfxApplication *pSfxApp = SFX_APP();
+ SfxApplication *pSfxApp = SfxGetpApp();
SAL_INFO(
"sfx.control",
@@ -792,7 +792,7 @@ void SfxDispatcher::DoDeactivate_Impl( bool bMDI, SfxViewFrame* pNew )
{
SFX_STACK(SfxDispatcher::DoDeactivate);
- SfxApplication *pSfxApp = SFX_APP();
+ SfxApplication *pSfxApp = SfxGetpApp();
if ( bMDI )
{
@@ -1092,7 +1092,7 @@ const SfxPoolItem* SfxDispatcher::Execute
pReq->SetModifier( nModi );
if( pInternalArgs && *pInternalArgs)
{
- SfxAllItemSet aSet( SFX_APP()->GetPool() );
+ SfxAllItemSet aSet( SfxGetpApp()->GetPool() );
for ( const SfxPoolItem **pArg = pInternalArgs; *pArg; ++pArg )
aSet.Put( **pArg );
pReq->SetInternalArgs_Impl( aSet );
@@ -1249,7 +1249,7 @@ IMPL_LINK( SfxDispatcher, PostMsgHandler, SfxRequest*, pReq )
const SfxSlot *pSlot = aSvr.GetSlot();
SfxShell *pSh = GetShell(aSvr.GetShellLevel());
- DBG( SfxApplication *pSfxApp = SFX_APP() );
+ DBG( SfxApplication *pSfxApp = SfxGetpApp() );
DBG( pSfxApp->EnterAsynchronCall_Impl() );
// When the pSlot is a "Pseudoslot" for macros or Verbs, it can
@@ -1312,7 +1312,7 @@ void SfxDispatcher::Update_Impl( bool bForce )
if ( !pImp->pFrame )
return;
- SFX_APP(); // -Wall is this required???
+ SfxGetpApp(); // -Wall is this required???
SfxDispatcher *pDisp = this;
bool bUpdate = bForce;
while ( pDisp && pDisp->pImp->pFrame )
@@ -1413,7 +1413,7 @@ void SfxDispatcher::Update_Impl( bool bForce )
void SfxDispatcher::_Update_Impl( bool bUIActive, bool bIsMDIApp, bool bIsIPOwner, SfxWorkWindow *pTaskWin )
{
- SFX_APP();
+ SfxGetpApp();
SfxWorkWindow *pWorkWin = pImp->pFrame->GetFrame().GetWorkWindow_Impl();
bool bIsActive = false;
bool bIsTaskActive = false;
@@ -1604,7 +1604,7 @@ void SfxDispatcher::FlushImpl()
return;
}
- SfxApplication *pSfxApp = SFX_APP();
+ SfxApplication *pSfxApp = SfxGetpApp();
// Re-build the true stack in the first round
std::deque<SfxToDo_Impl> aToDoCopy;
@@ -2112,7 +2112,7 @@ bool SfxDispatcher::_FillState
SfxPopupMenuManager* SfxDispatcher::Popup( sal_uInt16 nConfigId,Window *pWin, const Point *pPos )
{
- SfxDispatcher &rDisp = *SFX_APP()->GetDispatcher_Impl();
+ SfxDispatcher &rDisp = *SfxGetpApp()->GetDispatcher_Impl();
sal_uInt16 nShLevel = 0;
SfxShell *pSh;
@@ -2138,7 +2138,7 @@ SfxPopupMenuManager* SfxDispatcher::Popup( sal_uInt16 nConfigId,Window *pWin, co
void SfxDispatcher::ExecutePopup( sal_uInt16 nConfigId, Window *pWin, const Point *pPos )
{
- SfxDispatcher &rDisp = *SFX_APP()->GetDispatcher_Impl();
+ SfxDispatcher &rDisp = *SfxGetpApp()->GetDispatcher_Impl();
sal_uInt16 nShLevel = 0;
SfxShell *pSh;
@@ -2337,7 +2337,7 @@ void SfxDispatcher::RemoveShell_Impl( SfxShell& rShell )
}
}
- if ( !SFX_APP()->IsDowning() )
+ if ( !SfxGetpApp()->IsDowning() )
{
pImp->bUpdated = false;
pImp->pCachedServ1 = 0;
diff --git a/sfx2/source/control/msgpool.cxx b/sfx2/source/control/msgpool.cxx
index 352de2c113cd..f059dada9385 100644
--- a/sfx2/source/control/msgpool.cxx
+++ b/sfx2/source/control/msgpool.cxx
@@ -322,7 +322,7 @@ SfxSlotPool& SfxSlotPool::GetSlotPool( SfxViewFrame *pFrame )
if ( pMod && pMod->GetSlotPool() )
return *pMod->GetSlotPool();
else
- return *SFX_APP()->Get_Impl()->pSlotPool;
+ return *SfxGetpApp()->Get_Impl()->pSlotPool;
}
diff --git a/sfx2/source/control/objface.cxx b/sfx2/source/control/objface.cxx
index 59347e6c5428..fe5248375bb3 100644
--- a/sfx2/source/control/objface.cxx
+++ b/sfx2/source/control/objface.cxx
@@ -134,7 +134,7 @@ void SfxInterface::Register( SfxModule* pMod )
if ( pMod )
pMod->GetSlotPool()->RegisterInterface(*this);
else
- SFX_APP()->GetAppSlotPool_Impl().RegisterInterface(*this);
+ SfxGetpApp()->GetAppSlotPool_Impl().RegisterInterface(*this);
}
void SfxInterface::SetSlotMap( SfxSlot& rSlotMap, sal_uInt16 nSlotCount )
@@ -295,7 +295,7 @@ SfxInterface::~SfxInterface()
if ( pMod )
pMod->GetSlotPool()->ReleaseInterface(*this);
else
- SFX_APP()->GetAppSlotPool_Impl().ReleaseInterface(*this);
+ SfxGetpApp()->GetAppSlotPool_Impl().ReleaseInterface(*this);
}
}
diff --git a/sfx2/source/control/statcach.cxx b/sfx2/source/control/statcach.cxx
index 940be5f191c4..8ee8d72a6699 100644
--- a/sfx2/source/control/statcach.cxx
+++ b/sfx2/source/control/statcach.cxx
@@ -280,7 +280,7 @@ const SfxSlotServer* SfxStateCache::GetSlotServer( SfxDispatcher &rDispat , cons
// If this dispatch object does not use the wanted dispatcher or the AppDispatcher, it's treated like any other UNO component
// (intercepting by internal dispatches)
SfxDispatcher *pDispatcher = pDisp->GetDispatcher_Impl();
- if ( pDispatcher == &rDispat || pDispatcher == SFX_APP()->GetAppDispatcher_Impl() )
+ if ( pDispatcher == &rDispat || pDispatcher == SfxGetpApp()->GetAppDispatcher_Impl() )
{
// so we can use it directly
bSlotDirty = false;
diff --git a/sfx2/source/control/unoctitm.cxx b/sfx2/source/control/unoctitm.cxx
index 400063f815e6..1c44eb6f115b 100644
--- a/sfx2/source/control/unoctitm.cxx
+++ b/sfx2/source/control/unoctitm.cxx
@@ -686,7 +686,7 @@ void SAL_CALL SfxDispatchController_Impl::dispatch( const ::com::sun::star::util
// ~CntItemPool:
if (pDispatcher)
{
- SfxAllItemSet aInternalSet( SFX_APP()->GetPool() );
+ SfxAllItemSet aInternalSet( SfxGetpApp()->GetPool() );
if (xFrameRef.is()) // an empty set is no problem ... but an empty frame reference can be a problem !
aInternalSet.Put( SfxUnoFrameItem( SID_FILLFRAME, xFrameRef ) );
@@ -742,9 +742,9 @@ void SAL_CALL SfxDispatchController_Impl::dispatch( const ::com::sun::star::util
}
else
{
- eMapUnit = GetCoreMetric( SFX_APP()->GetPool(), GetId() );
+ eMapUnit = GetCoreMetric( SfxGetpApp()->GetPool(), GetId() );
// AppDispatcher
- SfxAllItemSet aSet( SFX_APP()->GetPool() );
+ SfxAllItemSet aSet( SfxGetpApp()->GetPool() );
TransformParameters( GetId(), lNewArgs, aSet );
if ( aSet.Count() )
@@ -756,7 +756,7 @@ void SAL_CALL SfxDispatchController_Impl::dispatch( const ::com::sun::star::util
// no bindings, no invalidate ( usually done in SfxDispatcher::Call_Impl()! )
if ( SfxApplication::Get() )
{
- SfxDispatcher* pAppDispat = SFX_APP()->GetAppDispatcher_Impl();
+ SfxDispatcher* pAppDispat = SfxGetpApp()->GetAppDispatcher_Impl();
if ( pAppDispat )
{
const SfxPoolItem* pState=0;
diff --git a/sfx2/source/dialog/filedlghelper.cxx b/sfx2/source/dialog/filedlghelper.cxx
index ecda3b483cc2..78015cd9c94f 100644
--- a/sfx2/source/dialog/filedlghelper.cxx
+++ b/sfx2/source/dialog/filedlghelper.cxx
@@ -1414,7 +1414,7 @@ ErrCode FileDialogHelper_Impl::execute( std::vector<OUString>& rpURLList,
{
// create an itemset if there is no
if( !rpSet )
- rpSet = new SfxAllItemSet( SFX_APP()->GetPool() );
+ rpSet = new SfxAllItemSet( SfxGetpApp()->GetPool() );
// the item should remain only if it was set by the dialog
rpSet->ClearItem( SID_SELECTION );
@@ -1707,7 +1707,7 @@ void FileDialogHelper_Impl::addFilters( const OUString& rFactory,
// we still need a matcher to convert UI names to filter names
if ( rFactory.isEmpty() )
{
- SfxApplication *pSfxApp = SFX_APP();
+ SfxApplication *pSfxApp = SfxGetpApp();
mpMatcher = &pSfxApp->GetFilterMatcher();
mbDeleteMatcher = false;
}
@@ -1994,7 +1994,7 @@ void FileDialogHelper_Impl::saveConfig()
aDlgOpt.SetUserItem( USERITEM_NAME, makeAny( OUString( aUserData ) ) );
}
- SfxApplication *pSfxApp = SFX_APP();
+ SfxApplication *pSfxApp = SfxGetpApp();
pSfxApp->SetLastDir_Impl( getPath() );
}
@@ -2002,7 +2002,7 @@ namespace
{
static OUString getInitPath( const OUString& _rFallback, const sal_Int32 _nFallbackToken )
{
- SfxApplication *pSfxApp = SFX_APP();
+ SfxApplication *pSfxApp = SfxGetpApp();
OUString sPath = pSfxApp->GetLastDir_Impl();
if ( sPath.isEmpty() )
diff --git a/sfx2/source/dialog/mgetempl.cxx b/sfx2/source/dialog/mgetempl.cxx
index 14934e683fc0..41830a187fc6 100644
--- a/sfx2/source/dialog/mgetempl.cxx
+++ b/sfx2/source/dialog/mgetempl.cxx
@@ -74,7 +74,7 @@ SfxManageStyleSheetPage::SfxManageStyleSheetPage(Window* pParent, const SfxItemS
// this Page needs ExchangeSupport
SetExchangeSupport();
- ResMgr* pResMgr = SFX_APP()->GetModule_Impl()->GetResMgr();
+ ResMgr* pResMgr = SfxGetpApp()->GetModule_Impl()->GetResMgr();
OSL_ENSURE( pResMgr, "No ResMgr in Module" );
pFamilies = new SfxStyleFamilies( ResId( DLG_STYLE_DESIGNER, *pResMgr ) );
diff --git a/sfx2/source/dialog/tabdlg.cxx b/sfx2/source/dialog/tabdlg.cxx
index 3bc6a7f828d5..debeb01b59f9 100644
--- a/sfx2/source/dialog/tabdlg.cxx
+++ b/sfx2/source/dialog/tabdlg.cxx
@@ -642,7 +642,7 @@ void SfxTabDialog::Start_Impl()
nActPage = nAppPageId;
else
{
- sal_uInt16 nAutoTabPageId = SFX_APP()->Get_Impl()->nAutoTabPageId;
+ sal_uInt16 nAutoTabPageId = SfxGetpApp()->Get_Impl()->nAutoTabPageId;
if ( nAutoTabPageId )
nActPage = nAutoTabPageId;
}
@@ -925,7 +925,7 @@ SfxItemSet* SfxTabDialog::CreateInputItemSet( sal_uInt16 )
{
SAL_WARN( "sfx.dialog", "CreateInputItemSet not implemented" );
- return new SfxAllItemSet( SFX_APP()->GetPool() );
+ return new SfxAllItemSet( SfxGetpApp()->GetPool() );
}
@@ -1162,7 +1162,7 @@ IMPL_LINK( SfxTabDialog, ActivatePageHdl, TabControl *, pTabCtrl )
sal_uInt16 nId = pTabCtrl->GetCurPageId();
DBG_ASSERT( pImpl->aData.size(), "no Pages registered" );
- SFX_APP();
+ SfxGetpApp();
// Tab Page schon da?
SfxTabPage* pTabPage = dynamic_cast<SfxTabPage*> (pTabCtrl->GetTabPage( nId ));
@@ -1260,7 +1260,7 @@ IMPL_LINK( SfxTabDialog, DeactivatePageHdl, TabControl *, pTabCtrl )
{
sal_uInt16 nId = pTabCtrl->GetCurPageId();
- SFX_APP();
+ SfxGetpApp();
SfxTabPage *pPage = dynamic_cast<SfxTabPage*> (pTabCtrl->GetTabPage( nId ));
DBG_ASSERT( pPage, "no active Page" );
if (!pPage)
diff --git a/sfx2/source/dialog/templdlg.cxx b/sfx2/source/dialog/templdlg.cxx
index 56396a7ded49..a2912eae8f29 100644
--- a/sfx2/source/dialog/templdlg.cxx
+++ b/sfx2/source/dialog/templdlg.cxx
@@ -1715,7 +1715,7 @@ bool SfxCommonTemplateDialog_Impl::Execute_Impl(
sal_uInt16 nId, const OUString &rStr, const OUString& rRefStr, sal_uInt16 nFamily,
sal_uInt16 nMask, sal_uInt16 *pIdx, const sal_uInt16* pModifier)
{
- SfxDispatcher &rDispatcher = *SFX_APP()->GetDispatcher_Impl();
+ SfxDispatcher &rDispatcher = *SfxGetpApp()->GetDispatcher_Impl();
SfxStringItem aItem(nId, rStr);
SfxUInt16Item aFamily(SID_STYLE_FAMILY, nFamily);
SfxUInt16Item aMask( SID_STYLE_MASK, nMask );
@@ -1927,7 +1927,7 @@ void SfxCommonTemplateDialog_Impl::ActionSelect(sal_uInt16 nEntry)
break;
}
case SID_TEMPLATE_LOAD:
- SFX_APP()->GetDispatcher_Impl()->Execute(nEntry);
+ SfxGetpApp()->GetDispatcher_Impl()->Execute(nEntry);
break;
default: OSL_FAIL("not implemented"); break;
}
@@ -2117,7 +2117,7 @@ void SfxCommonTemplateDialog_Impl::DeleteHdl(void *)
if ( bUsedStyle )
{
#if defined UNX
- QueryBox aBox( SFX_APP()->GetTopWindow(), WB_YES_NO | WB_DEF_NO, aMsg );
+ QueryBox aBox( SfxGetpApp()->GetTopWindow(), WB_YES_NO | WB_DEF_NO, aMsg );
#else
QueryBox aBox( GetWindow(), WB_YES_NO | WB_DEF_NO , aMsg );
#endif
diff --git a/sfx2/source/doc/docfile.cxx b/sfx2/source/doc/docfile.cxx
index b70421e04b84..4cb807d7d821 100644
--- a/sfx2/source/doc/docfile.cxx
+++ b/sfx2/source/doc/docfile.cxx
@@ -2822,7 +2822,7 @@ SfxMedium::SfxMedium(const OUString &rName, const OUString &rReferer, StreamMode
SfxMedium::SfxMedium( const uno::Sequence<beans::PropertyValue>& aArgs ) :
pImp(new SfxMedium_Impl(this))
{
- SfxAllItemSet *pParams = new SfxAllItemSet( SFX_APP()->GetPool() );
+ SfxAllItemSet *pParams = new SfxAllItemSet( SfxGetpApp()->GetPool() );
pImp->m_pSet = pParams;
TransformParameters( SID_OPENDOC, aArgs, *pParams );
@@ -2839,7 +2839,7 @@ SfxMedium::SfxMedium( const uno::Sequence<beans::PropertyValue>& aArgs ) :
if (aFilterProvider.isEmpty())
{
// This is a conventional filter type.
- pImp->m_pFilter = SFX_APP()->GetFilterMatcher().GetFilter4FilterName( aFilterName );
+ pImp->m_pFilter = SfxGetpApp()->GetFilterMatcher().GetFilter4FilterName( aFilterName );
}
else
{
@@ -2892,7 +2892,7 @@ SfxMedium::SfxMedium( const uno::Reference < embed::XStorage >& rStor, const OUS
pImp(new SfxMedium_Impl(this))
{
OUString aType = SfxFilter::GetTypeFromStorage(rStor);
- pImp->m_pFilter = SFX_APP()->GetFilterMatcher().GetFilter4EA( aType );
+ pImp->m_pFilter = SfxGetpApp()->GetFilterMatcher().GetFilter4EA( aType );
DBG_ASSERT( pImp->m_pFilter, "No Filter for storage found!" );
Init_Impl();
@@ -2910,7 +2910,7 @@ SfxMedium::SfxMedium( const uno::Reference < embed::XStorage >& rStor, const OUS
SfxMedium::SfxMedium( const uno::Reference < embed::XStorage >& rStor, const OUString& rBaseURL, const OUString &rTypeName, const SfxItemSet* p ) :
pImp(new SfxMedium_Impl(this))
{
- pImp->m_pFilter = SFX_APP()->GetFilterMatcher().GetFilter4EA( rTypeName );
+ pImp->m_pFilter = SfxGetpApp()->GetFilterMatcher().GetFilter4EA( rTypeName );
DBG_ASSERT( pImp->m_pFilter, "No Filter for storage found!" );
Init_Impl();
@@ -3015,7 +3015,7 @@ SfxItemSet* SfxMedium::GetItemSet() const
{
// this method *must* return an ItemSet, returning NULL can cause crashes
if (!pImp->m_pSet)
- pImp->m_pSet = new SfxAllItemSet( SFX_APP()->GetPool() );
+ pImp->m_pSet = new SfxAllItemSet( SfxGetpApp()->GetPool() );
return pImp->m_pSet;
}
diff --git a/sfx2/source/doc/docinsert.cxx b/sfx2/source/doc/docinsert.cxx
index ce2b0c22ebba..e51854ebe18e 100644
--- a/sfx2/source/doc/docinsert.cxx
+++ b/sfx2/source/doc/docinsert.cxx
@@ -87,7 +87,7 @@ SfxMedium* DocumentInserter::CreateMedium()
OUString sURL(m_pURLList[0]);
pMedium = new SfxMedium(
sURL, SFX_STREAM_READONLY,
- SFX_APP()->GetFilterMatcher().GetFilter4FilterName( m_sFilter ), m_pItemSet );
+ SfxGetpApp()->GetFilterMatcher().GetFilter4FilterName( m_sFilter ), m_pItemSet );
pMedium->UseInteractionHandler( true );
SfxFilterMatcher* pMatcher = NULL;
if ( !m_sDocFactory.isEmpty() )
@@ -102,7 +102,7 @@ SfxMedium* DocumentInserter::CreateMedium()
else
DELETEZ( pMedium );
- if ( pMedium && CheckPasswd_Impl( 0, SFX_APP()->GetPool(), pMedium ) == ERRCODE_ABORT )
+ if ( pMedium && CheckPasswd_Impl( 0, SfxGetpApp()->GetPool(), pMedium ) == ERRCODE_ABORT )
pMedium = NULL;
DELETEZ( pMatcher );
@@ -120,7 +120,7 @@ SfxMediumList* DocumentInserter::CreateMediumList()
{
SfxMedium* pMedium = new SfxMedium(
*i, SFX_STREAM_READONLY,
- SFX_APP()->GetFilterMatcher().GetFilter4FilterName( m_sFilter ), m_pItemSet );
+ SfxGetpApp()->GetFilterMatcher().GetFilter4FilterName( m_sFilter ), m_pItemSet );
pMedium->UseInteractionHandler( true );
@@ -132,7 +132,7 @@ SfxMediumList* DocumentInserter::CreateMediumList()
else
DELETEZ( pMedium );
- if( pMedium && CheckPasswd_Impl( 0, SFX_APP()->GetPool(), pMedium ) != ERRCODE_ABORT )
+ if( pMedium && CheckPasswd_Impl( 0, SfxGetpApp()->GetPool(), pMedium ) != ERRCODE_ABORT )
pMediumList->push_back( pMedium );
else
delete pMedium;
@@ -173,7 +173,7 @@ IMPL_LINK_NOARG(DocumentInserter, DialogClosedHdl)
if ( xCtrlAccess.is() )
{
// always create a new itemset
- m_pItemSet = new SfxAllItemSet( SFX_APP()->GetPool() );
+ m_pItemSet = new SfxAllItemSet( SfxGetpApp()->GetPool() );
short nDlgType = m_pFileDlg->GetDialogType();
bool bHasPassword = (
diff --git a/sfx2/source/doc/frmdescr.cxx b/sfx2/source/doc/frmdescr.cxx
index e1fc9b4721b2..6b9e23663f67 100644
--- a/sfx2/source/doc/frmdescr.cxx
+++ b/sfx2/source/doc/frmdescr.cxx
@@ -64,7 +64,7 @@ SfxFrameDescriptor::~SfxFrameDescriptor()
SfxItemSet* SfxFrameDescriptor::GetArgs()
{
if( !pImp->pArgs )
- pImp->pArgs = new SfxAllItemSet( SFX_APP()->GetPool() );
+ pImp->pArgs = new SfxAllItemSet( SfxGetpApp()->GetPool() );
return pImp->pArgs;
}
@@ -118,7 +118,7 @@ SfxFrameDescriptor* SfxFrameDescriptor::Clone( bool bWithIds ) const
if( pImp->pArgs )
{
// Currently in the clone of SfxAllItemSets there is still a bug ...
- pFrame->pImp->pArgs = new SfxAllItemSet( SFX_APP()->GetPool() );
+ pFrame->pImp->pArgs = new SfxAllItemSet( SfxGetpApp()->GetPool() );
pFrame->pImp->pArgs->Put(*pImp->pArgs);
}
diff --git a/sfx2/source/doc/guisaveas.cxx b/sfx2/source/doc/guisaveas.cxx
index 85a9947c267a..b6efad193fbc 100644
--- a/sfx2/source/doc/guisaveas.cxx
+++ b/sfx2/source/doc/guisaveas.cxx
@@ -1048,7 +1048,7 @@ bool ModelData_Impl::OutputFileDialog( sal_Int8 nStoreMode,
// generate SidSet from MediaDescriptor and provide it into FileDialog
// than merge changed SidSet back
- SfxAllItemSet aDialogParams( SFX_APP()->GetPool() );
+ SfxAllItemSet aDialogParams( SfxGetpApp()->GetPool() );
SfxItemSet* pDialogParams = &aDialogParams;
TransformParameters( nSlotID,
GetMediaDescr().getAsConstPropertyValueList(),
diff --git a/sfx2/source/doc/new.cxx b/sfx2/source/doc/new.cxx
index 77680ff2c5f6..9997782dc649 100644
--- a/sfx2/source/doc/new.cxx
+++ b/sfx2/source/doc/new.cxx
@@ -219,7 +219,7 @@ IMPL_LINK_NOARG(SfxNewFileDialog_Impl, Update)
Window *pParent = Application::GetDefDialogParent();
Application::SetDefDialogParent( pAntiImpl );
SfxErrorContext eEC(ERRCTX_SFX_LOADTEMPLATE,pAntiImpl);
- SfxApplication *pSfxApp = SFX_APP();
+ SfxApplication *pSfxApp = SfxGetpApp();
sal_uIntPtr lErr;
SfxItemSet* pSet = new SfxAllItemSet( pSfxApp->GetPool() );
pSet->Put( SfxBoolItem( SID_TEMPLATE, true ) );
diff --git a/sfx2/source/doc/objcont.cxx b/sfx2/source/doc/objcont.cxx
index 7bba8d6b791c..33700ffc22f7 100644
--- a/sfx2/source/doc/objcont.cxx
+++ b/sfx2/source/doc/objcont.cxx
@@ -527,7 +527,7 @@ void SfxObjectShell::ResetFromTemplate( const OUString& rTemplateName, const OUS
if( ::utl::LocalFileHelper::IsLocalFile( rFileName ) )
{
OUString aFoundName;
- if( SFX_APP()->Get_Impl()->GetDocumentTemplates()->GetFull( OUString(), rTemplateName, aFoundName ) )
+ if( SfxGetpApp()->Get_Impl()->GetDocumentTemplates()->GetFull( OUString(), rTemplateName, aFoundName ) )
{
INetURLObject aObj( rFileName );
xDocProps->setTemplateURL( aObj.GetMainURL(INetURLObject::DECODE_TO_IURI) );
diff --git a/sfx2/source/doc/objembed.cxx b/sfx2/source/doc/objembed.cxx
index c4c95e3c351b..7c69dc8a6238 100644
--- a/sfx2/source/doc/objembed.cxx
+++ b/sfx2/source/doc/objembed.cxx
@@ -123,7 +123,7 @@ void SfxObjectShell::SetVisArea( const Rectangle & rVisArea )
if ( IsEnableSetModified() )
SetModified( true );
- SFX_APP()->NotifyEvent(SfxEventHint( SFX_EVENT_VISAREACHANGED, GlobalEventConfig::GetEventName(STR_EVENT_VISAREACHANGED), this));
+ SfxGetpApp()->NotifyEvent(SfxEventHint( SFX_EVENT_VISAREACHANGED, GlobalEventConfig::GetEventName(STR_EVENT_VISAREACHANGED), this));
}
}
}
diff --git a/sfx2/source/doc/objmisc.cxx b/sfx2/source/doc/objmisc.cxx
index f296e98df93f..34fe8656a537 100644
--- a/sfx2/source/doc/objmisc.cxx
+++ b/sfx2/source/doc/objmisc.cxx
@@ -366,7 +366,7 @@ void SfxObjectShell::ModifyChanged()
Invalidate( SID_MACRO_SIGNATURE );
Broadcast( SfxSimpleHint( SFX_HINT_TITLECHANGED ) ); // xmlsec05, signed state might change in title...
- SFX_APP()->NotifyEvent( SfxEventHint( SFX_EVENT_MODIFYCHANGED, GlobalEventConfig::GetEventName(STR_EVENT_MODIFYCHANGED), this ) );
+ SfxGetpApp()->NotifyEvent( SfxEventHint( SFX_EVENT_MODIFYCHANGED, GlobalEventConfig::GetEventName(STR_EVENT_MODIFYCHANGED), this ) );
}
@@ -486,7 +486,7 @@ void SfxObjectShell::SetModalMode_Impl( bool bModal )
if ( !pImp->bModalMode != !bModal )
{
// Central count
- sal_uInt16 &rDocModalCount = SFX_APP()->Get_Impl()->nDocModalMode;
+ sal_uInt16 &rDocModalCount = SfxGetpApp()->Get_Impl()->nDocModalMode;
if ( bModal )
++rDocModalCount;
else
@@ -728,7 +728,7 @@ void SfxObjectShell::SetTitle
&& !IsDocShared() )
return;
- SfxApplication *pSfxApp = SFX_APP();
+ SfxApplication *pSfxApp = SfxGetpApp();
// If possible relase the unnamed number.
if ( pImp->bIsNamedVisible && USHRT_MAX != pImp->nVisualDocumentNumber )
@@ -972,7 +972,7 @@ void SfxObjectShell::SetNamedVisibility_Impl()
pImp->bIsNamedVisible = true;
if ( !HasName() && USHRT_MAX == pImp->nVisualDocumentNumber && pImp->aTitle.isEmpty() )
{
- pImp->nVisualDocumentNumber = SFX_APP()->GetFreeIndex();
+ pImp->nVisualDocumentNumber = SfxGetpApp()->GetFreeIndex();
Broadcast( SfxSimpleHint(SFX_HINT_TITLECHANGED) );
}
}
@@ -1018,7 +1018,7 @@ void SfxObjectShell::SetProgress_Impl
void SfxObjectShell::PostActivateEvent_Impl( SfxViewFrame* pFrame )
{
- SfxApplication* pSfxApp = SFX_APP();
+ SfxApplication* pSfxApp = SfxGetpApp();
if ( !pSfxApp->IsDowning() && !IsLoading() && pFrame && !pFrame->GetFrame().IsClosing_Impl() )
{
SFX_ITEMSET_ARG( pMedium->GetItemSet(), pHiddenItem, SfxBoolItem, SID_HIDDEN, false );
@@ -1447,7 +1447,7 @@ void AutoReloadTimer_Impl::Timeout()
return;
}
- SfxAllItemSet aSet( SFX_APP()->GetPool() );
+ SfxAllItemSet aSet( SfxGetpApp()->GetPool() );
aSet.Put( SfxBoolItem( SID_AUTOLOAD, true ) );
if ( !aUrl.isEmpty() )
aSet.Put( SfxStringItem( SID_FILE_NAME, aUrl ) );
@@ -1475,7 +1475,7 @@ ErrCode SfxObjectShell::CallBasic( const OUString& rMacro,
const OUString& rBasic, SbxArray* pArgs,
SbxValue* pRet )
{
- SfxApplication* pApp = SFX_APP();
+ SfxApplication* pApp = SfxGetpApp();
if( pApp->GetName() != rBasic )
{
if ( !AdjustMacroMode( OUString() ) )
diff --git a/sfx2/source/doc/objserv.cxx b/sfx2/source/doc/objserv.cxx
index 707fd3c57eeb..f389232cd63f 100644
--- a/sfx2/source/doc/objserv.cxx
+++ b/sfx2/source/doc/objserv.cxx
@@ -1272,7 +1272,7 @@ void SfxObjectShell::ExecView_Impl(SfxRequest &rReq)
{
SfxStringItem aName( SID_FILE_NAME, aFileName );
SfxBoolItem aCreateView( SID_OPEN_NEW_VIEW, true );
- SFX_APP()->GetAppDispatcher_Impl()->Execute(
+ SfxGetpApp()->GetAppDispatcher_Impl()->Execute(
SID_OPENDOC, SFX_CALLMODE_ASYNCHRON, &aName,
&aCreateView, 0L);
}
diff --git a/sfx2/source/doc/objstor.cxx b/sfx2/source/doc/objstor.cxx
index 1e37373efdd7..3f789e004f5b 100644
--- a/sfx2/source/doc/objstor.cxx
+++ b/sfx2/source/doc/objstor.cxx
@@ -572,7 +572,7 @@ bool SfxObjectShell::ImportFromGeneratedStream_Impl(
else
pMedium->SetStorage_Impl( xStorage );
- SfxAllItemSet aSet( SFX_APP()->GetPool() );
+ SfxAllItemSet aSet( SfxGetpApp()->GetPool() );
TransformParameters( SID_OPENDOC, rMediaDescr, aSet );
pMedium->GetItemSet()->Put( aSet );
pMedium->CanDisposeStorage_Impl( false );
@@ -1349,7 +1349,7 @@ bool SfxObjectShell::SaveTo_Impl
// a draw document ), the ClassId of the destination storage is different from the ClassId of this
// document. It can be retrieved from the default filter for the desired target format
long nFormat = rMedium.GetFilter()->GetFormat();
- SfxFilterMatcher& rMatcher = SFX_APP()->GetFilterMatcher();
+ SfxFilterMatcher& rMatcher = SfxGetpApp()->GetFilterMatcher();
const SfxFilter *pFilt = rMatcher.GetFilter4ClipBoardId( nFormat );
if ( pFilt )
{
@@ -3050,7 +3050,7 @@ bool SfxObjectShell::LoadOwnFormat( SfxMedium& rMedium )
{
// Password
SFX_ITEMSET_ARG( rMedium.GetItemSet(), pPasswdItem, SfxStringItem, SID_PASSWORD, false );
- if ( pPasswdItem || ERRCODE_IO_ABORT != CheckPasswd_Impl( this, SFX_APP()->GetPool(), pMedium ) )
+ if ( pPasswdItem || ERRCODE_IO_ABORT != CheckPasswd_Impl( this, SfxGetpApp()->GetPool(), pMedium ) )
{
uno::Sequence< beans::NamedValue > aEncryptionData;
if ( GetEncryptionData_Impl(pMedium->GetItemSet(), aEncryptionData) )
@@ -3119,7 +3119,7 @@ uno::Reference< embed::XStorage > SfxObjectShell::GetStorage()
SetupStorage( pImp->m_xDocStorage, SOFFICE_FILEFORMAT_CURRENT, false, false );
pImp->m_bCreateTempStor = false;
- SFX_APP()->NotifyEvent( SfxEventHint( SFX_EVENT_STORAGECHANGED, GlobalEventConfig::GetEventName(STR_EVENT_STORAGECHANGED), this ) );
+ SfxGetpApp()->NotifyEvent( SfxEventHint( SFX_EVENT_STORAGECHANGED, GlobalEventConfig::GetEventName(STR_EVENT_STORAGECHANGED), this ) );
}
catch( uno::Exception& )
{
@@ -3271,7 +3271,7 @@ bool SfxObjectShell::SaveCompleted( const uno::Reference< embed::XStorage >& xSt
if ( bSendNotification )
{
- SFX_APP()->NotifyEvent( SfxEventHint( SFX_EVENT_STORAGECHANGED, GlobalEventConfig::GetEventName(STR_EVENT_STORAGECHANGED), this ) );
+ SfxGetpApp()->NotifyEvent( SfxEventHint( SFX_EVENT_STORAGECHANGED, GlobalEventConfig::GetEventName(STR_EVENT_STORAGECHANGED), this ) );
}
return bResult;
diff --git a/sfx2/source/doc/objxtor.cxx b/sfx2/source/doc/objxtor.cxx
index e3eff9571c23..9ce512b21582 100644
--- a/sfx2/source/doc/objxtor.cxx
+++ b/sfx2/source/doc/objxtor.cxx
@@ -188,7 +188,7 @@ void SAL_CALL SfxModelListener_Impl::disposing( const com::sun::star::lang::Even
VBAConstantNameMap::iterator aIt = s_aRegisteredVBAConstants.find( _rEvent.Source.get() );
if ( aIt != s_aRegisteredVBAConstants.end() )
{
- if ( BasicManager* pAppMgr = SFX_APP()->GetBasicManager() )
+ if ( BasicManager* pAppMgr = SfxGetpApp()->GetBasicManager() )
pAppMgr->SetGlobalUNOConstant( aIt->second.getStr(), Any( Reference< XInterface >() ) );
s_aRegisteredVBAConstants.erase( aIt );
}
@@ -267,7 +267,7 @@ SfxObjectShell_Impl::SfxObjectShell_Impl( SfxObjectShell& _rDocShell )
,m_bModifyPasswordEntered( false )
{
SfxObjectShell* pDoc = &_rDocShell;
- SfxObjectShellArr_Impl &rArr = SFX_APP()->GetObjectShells_Impl();
+ SfxObjectShellArr_Impl &rArr = SfxGetpApp()->GetObjectShells_Impl();
rArr.push_back( pDoc );
bInList = true;
}
@@ -359,7 +359,7 @@ SfxObjectShell::~SfxObjectShell()
DELETEX(AutoReloadTimer_Impl, pImp->pReloadTimer );
- SfxApplication *pSfxApp = SFX_APP();
+ SfxApplication *pSfxApp = SfxGetpApp();
if ( USHRT_MAX != pImp->nVisualDocumentNumber )
pSfxApp->ReleaseIndex(pImp->nVisualDocumentNumber);
@@ -462,7 +462,7 @@ bool SfxObjectShell::Close()
if ( pImp->bClosing )
{
// remove from Document list
- SfxApplication *pSfxApp = SFX_APP();
+ SfxApplication *pSfxApp = SfxGetpApp();
SfxObjectShellArr_Impl &rDocs = pSfxApp->GetObjectShells_Impl();
SfxObjectShellArr_Impl::iterator it = std::find( rDocs.begin(), rDocs.end(), this );
if ( it != rDocs.end() )
diff --git a/sfx2/source/doc/sfxbasemodel.cxx b/sfx2/source/doc/sfxbasemodel.cxx
index 64b2fb2d47a0..eb5088541155 100644
--- a/sfx2/source/doc/sfxbasemodel.cxx
+++ b/sfx2/source/doc/sfxbasemodel.cxx
@@ -1091,7 +1091,7 @@ void SAL_CALL SfxBaseModel::connectController( const Reference< frame::XControll
pViewFrame->UpdateDocument_Impl();
const OUString sDocumentURL = GetObjectShell()->GetMedium()->GetName();
if ( !sDocumentURL.isEmpty() )
- SFX_APP()->Broadcast( SfxStringHint( SID_OPENURL, sDocumentURL ) );
+ SfxGetpApp()->Broadcast( SfxStringHint( SID_OPENURL, sDocumentURL ) );
}
}
@@ -1572,10 +1572,10 @@ void SAL_CALL SfxBaseModel::storeSelf( const Sequence< beans::PropertyValue >
}
}
- SfxAllItemSet *pParams = new SfxAllItemSet( SFX_APP()->GetPool() );
+ SfxAllItemSet *pParams = new SfxAllItemSet( SfxGetpApp()->GetPool() );
TransformParameters( nSlotId, aArgs, *pParams );
- SFX_APP()->NotifyEvent( SfxEventHint( SFX_EVENT_SAVEDOC, GlobalEventConfig::GetEventName(STR_EVENT_SAVEDOC), m_pData->m_pObjectShell ) );
+ SfxGetpApp()->NotifyEvent( SfxEventHint( SFX_EVENT_SAVEDOC, GlobalEventConfig::GetEventName(STR_EVENT_SAVEDOC), m_pData->m_pObjectShell ) );
bool bRet = false;
@@ -1616,7 +1616,7 @@ void SAL_CALL SfxBaseModel::storeSelf( const Sequence< beans::PropertyValue >
m_pData->m_pObjectShell->AddLog( OUString( OSL_LOG_PREFIX "successful saving." ) );
m_pData->m_aPreusedFilterName = GetMediumFilterName_Impl();
- SFX_APP()->NotifyEvent( SfxEventHint( SFX_EVENT_SAVEDOCDONE, GlobalEventConfig::GetEventName(STR_EVENT_SAVEDOCDONE), m_pData->m_pObjectShell ) );
+ SfxGetpApp()->NotifyEvent( SfxEventHint( SFX_EVENT_SAVEDOCDONE, GlobalEventConfig::GetEventName(STR_EVENT_SAVEDOCDONE), m_pData->m_pObjectShell ) );
}
else
{
@@ -1624,7 +1624,7 @@ void SAL_CALL SfxBaseModel::storeSelf( const Sequence< beans::PropertyValue >
m_pData->m_pObjectShell->StoreLog();
// write the contents of the logger to the file
- SFX_APP()->NotifyEvent( SfxEventHint( SFX_EVENT_SAVEDOCFAILED, GlobalEventConfig::GetEventName(STR_EVENT_SAVEDOCFAILED), m_pData->m_pObjectShell ) );
+ SfxGetpApp()->NotifyEvent( SfxEventHint( SFX_EVENT_SAVEDOCFAILED, GlobalEventConfig::GetEventName(STR_EVENT_SAVEDOCFAILED), m_pData->m_pObjectShell ) );
throw task::ErrorCodeIOException(
"SfxBaseModel::storeSelf: 0x" + OUString::number(nErrCode, 16),
@@ -1904,7 +1904,7 @@ void SAL_CALL SfxBaseModel::load( const Sequence< beans::PropertyValue >& seqA
{
// file recovery: restore original filter
SFX_ITEMSET_ARG( pMedium->GetItemSet(), pFilterItem, SfxStringItem, SID_FILTER_NAME, false );
- SfxFilterMatcher& rMatcher = SFX_APP()->GetFilterMatcher();
+ SfxFilterMatcher& rMatcher = SfxGetpApp()->GetFilterMatcher();
const SfxFilter* pSetFilter = rMatcher.GetFilter4FilterName( pFilterItem->GetValue() );
pMedium->SetFilter( pSetFilter );
m_pData->m_pObjectShell->SetModified(true);
@@ -3006,10 +3006,10 @@ void SfxBaseModel::impl_store( const OUString& sURL
if ( !bSaved && m_pData->m_pObjectShell )
{
- SFX_APP()->NotifyEvent( SfxEventHint( bSaveTo ? SFX_EVENT_SAVETODOC : SFX_EVENT_SAVEASDOC, GlobalEventConfig::GetEventName( bSaveTo ? STR_EVENT_SAVETODOC : STR_EVENT_SAVEASDOC ),
+ SfxGetpApp()->NotifyEvent( SfxEventHint( bSaveTo ? SFX_EVENT_SAVETODOC : SFX_EVENT_SAVEASDOC, GlobalEventConfig::GetEventName( bSaveTo ? STR_EVENT_SAVETODOC : STR_EVENT_SAVEASDOC ),
m_pData->m_pObjectShell ) );
- SfxAllItemSet *aParams = new SfxAllItemSet( SFX_APP()->GetPool() );
+ SfxAllItemSet *aParams = new SfxAllItemSet( SfxGetpApp()->GetPool() );
aParams->Put( SfxStringItem( SID_FILE_NAME, sURL ) );
if ( bSaveTo )
aParams->Put( SfxBoolItem( SID_SAVETO, true ) );
@@ -3106,14 +3106,14 @@ void SfxBaseModel::impl_store( const OUString& sURL
m_pData->m_aPreusedFilterName = GetMediumFilterName_Impl();
m_pData->m_pObjectShell->SetModifyPasswordEntered();
- SFX_APP()->NotifyEvent( SfxEventHint( SFX_EVENT_SAVEASDOCDONE, GlobalEventConfig::GetEventName(STR_EVENT_SAVEASDOCDONE), m_pData->m_pObjectShell ) );
+ SfxGetpApp()->NotifyEvent( SfxEventHint( SFX_EVENT_SAVEASDOCDONE, GlobalEventConfig::GetEventName(STR_EVENT_SAVEASDOCDONE), m_pData->m_pObjectShell ) );
}
else
{
m_pData->m_pObjectShell->SetModifyPasswordHash( nOldModifyPasswordHash );
m_pData->m_pObjectShell->SetModifyPasswordInfo( aOldModifyPasswordInfo );
- SFX_APP()->NotifyEvent( SfxEventHint( SFX_EVENT_SAVETODOCDONE, GlobalEventConfig::GetEventName(STR_EVENT_SAVETODOCDONE), m_pData->m_pObjectShell ) );
+ SfxGetpApp()->NotifyEvent( SfxEventHint( SFX_EVENT_SAVETODOCDONE, GlobalEventConfig::GetEventName(STR_EVENT_SAVETODOCDONE), m_pData->m_pObjectShell ) );
}
}
else
@@ -3126,7 +3126,7 @@ void SfxBaseModel::impl_store( const OUString& sURL
m_pData->m_pObjectShell->SetModifyPasswordInfo( aOldModifyPasswordInfo );
- SFX_APP()->NotifyEvent( SfxEventHint( bSaveTo ? SFX_EVENT_SAVETODOCFAILED : SFX_EVENT_SAVEASDOCFAILED, GlobalEventConfig::GetEventName( bSaveTo ? STR_EVENT_SAVETODOCFAILED : STR_EVENT_SAVEASDOCFAILED),
+ SfxGetpApp()->NotifyEvent( SfxEventHint( bSaveTo ? SFX_EVENT_SAVETODOCFAILED : SFX_EVENT_SAVEASDOCFAILED, GlobalEventConfig::GetEventName( bSaveTo ? STR_EVENT_SAVETODOCFAILED : STR_EVENT_SAVEASDOCFAILED),
m_pData->m_pObjectShell ) );
throw task::ErrorCodeIOException(
@@ -3735,7 +3735,7 @@ void SAL_CALL SfxBaseModel::loadFromStorage( const Reference< embed::XStorage >&
// after i36090 is fixed the pool from object shell can be used
// SfxAllItemSet aSet( m_pData->m_pObjectShell->GetPool() );
- SfxAllItemSet aSet( SFX_APP()->GetPool() );
+ SfxAllItemSet aSet( SfxGetpApp()->GetPool() );
// the BaseURL is part of the ItemSet
SfxMedium* pMedium = new SfxMedium( xStorage, OUString() );
@@ -3784,7 +3784,7 @@ void SAL_CALL SfxBaseModel::storeToStorage( const Reference< embed::XStorage >&
if( pItem )
{
OUString aFilterName = pItem->GetValue();
- const SfxFilter* pFilter = SFX_APP()->GetFilterMatcher().GetFilter4FilterName( aFilterName );
+ const SfxFilter* pFilter = SfxGetpApp()->GetFilterMatcher().GetFilter4FilterName( aFilterName );
if ( pFilter && pFilter->UsesStorage() )
nVersion = pFilter->GetVersion();
}
diff --git a/sfx2/source/doc/templatedlg.cxx b/sfx2/source/doc/templatedlg.cxx
index 2f917961b1f5..019fa7e9a81d 100644
--- a/sfx2/source/doc/templatedlg.cxx
+++ b/sfx2/source/doc/templatedlg.cxx
@@ -1690,7 +1690,7 @@ static bool lcl_getServiceName ( const OUString &rFileURL, OUString &rName )
sal_uIntPtr nFormat = SotStorage::GetFormatID( xStorage );
- const SfxFilter* pFilter = SFX_APP()->GetFilterMatcher().GetFilter4ClipBoardId( nFormat );
+ const SfxFilter* pFilter = SfxGetpApp()->GetFilterMatcher().GetFilter4ClipBoardId( nFormat );
if ( pFilter )
{
diff --git a/sfx2/source/menu/mnuitem.cxx b/sfx2/source/menu/mnuitem.cxx
index a4da1786b269..3ce93a96a785 100644
--- a/sfx2/source/menu/mnuitem.cxx
+++ b/sfx2/source/menu/mnuitem.cxx
@@ -252,7 +252,7 @@ void SfxMenuControl::RegisterControl( sal_uInt16 nSlotId, SfxModule *pMod )
void SfxMenuControl::RegisterMenuControl(SfxModule* pMod, SfxMenuCtrlFactory* pFact)
{
- SFX_APP()->RegisterMenuControl_Impl( pMod, pFact );
+ SfxGetpApp()->RegisterMenuControl_Impl( pMod, pFact );
}
SfxMenuControl* SfxMenuControl::CreateControl( sal_uInt16 nId, Menu &rMenu, SfxBindings &rBindings )
@@ -260,7 +260,7 @@ SfxMenuControl* SfxMenuControl::CreateControl( sal_uInt16 nId, Menu &rMenu, SfxB
TypeId aSlotType = SFX_SLOTPOOL().GetSlotType(nId);
if ( aSlotType )
{
- SfxApplication *pApp = SFX_APP();
+ SfxApplication *pApp = SfxGetpApp();
SfxDispatcher *pDisp = rBindings.GetDispatcher_Impl();
SfxModule *pMod = pDisp ? SfxModule::GetActiveModule( pDisp->GetFrame() ) :0;
if ( pMod )
diff --git a/sfx2/source/menu/virtmenu.cxx b/sfx2/source/menu/virtmenu.cxx
index b4861cb14bd9..434198de89f9 100644
--- a/sfx2/source/menu/virtmenu.cxx
+++ b/sfx2/source/menu/virtmenu.cxx
@@ -327,7 +327,7 @@ void SfxVirtualMenu::CreateFromSVMenu()
pItems = new SfxMenuControl[nCount];
// remember some values
- SFX_APP();
+ SfxGetpApp();
const int bOleServer = sal_False;
const int bMac = sal_False;
SvtMenuOptions aOptions;
diff --git a/sfx2/source/notify/eventsupplier.cxx b/sfx2/source/notify/eventsupplier.cxx
index 9832c47e3492..311faf5fb795 100644
--- a/sfx2/source/notify/eventsupplier.cxx
+++ b/sfx2/source/notify/eventsupplier.cxx
@@ -395,7 +395,7 @@ SvxMacro* SfxEvents_Impl::ConvertToMacro( const uno::Any& rElement, SfxObjectShe
if ( !aMacroName.isEmpty() )
{
if ( aLibrary == "application" )
- aLibrary = SFX_APP()->GetName();
+ aLibrary = SfxGetpApp()->GetName();
else
aLibrary = "";
pMacro = new SvxMacro( aMacroName, aLibrary, eType );
@@ -448,7 +448,7 @@ void SfxEvents_Impl::NormalizeMacro( const ::comphelper::NamedValueCollection& i
if ( aBasMgrName == "." )
aLibrary = pDoc->GetTitle();
else
- aLibrary = SFX_APP()->GetName();
+ aLibrary = SfxGetpApp()->GetName();
// Get the macro name
aMacroName = aScript.copy( nHashPos+1, nArgsPos - nHashPos - 1 );
@@ -462,7 +462,7 @@ void SfxEvents_Impl::NormalizeMacro( const ::comphelper::NamedValueCollection& i
else if ( !aMacroName.isEmpty() )
{
aScript = OUString( MACRO_PRFIX );
- if ( aLibrary != SFX_APP()->GetName() && aLibrary != "StarDesktop" && aLibrary != "application" )
+ if ( aLibrary != SfxGetpApp()->GetName() && aLibrary != "StarDesktop" && aLibrary != "application" )
aScript += OUString('.');
aScript += OUString('/');
diff --git a/sfx2/source/notify/globalevents.cxx b/sfx2/source/notify/globalevents.cxx
index fa0949382212..04aef56c3c3f 100644
--- a/sfx2/source/notify/globalevents.cxx
+++ b/sfx2/source/notify/globalevents.cxx
@@ -236,7 +236,7 @@ SfxGlobalEvents_Impl::SfxGlobalEvents_Impl( const uno::Reference < uno::XCompone
, pImp (0 )
{
m_refCount++;
- SFX_APP();
+ SfxGetpApp();
pImp = new GlobalEventConfig();
m_xEvents = pImp;
m_refCount--;
diff --git a/sfx2/source/sidebar/Theme.cxx b/sfx2/source/sidebar/Theme.cxx
index e38d3bd082c6..2f5d228236f4 100644
--- a/sfx2/source/sidebar/Theme.cxx
+++ b/sfx2/source/sidebar/Theme.cxx
@@ -36,7 +36,7 @@ namespace sfx2 { namespace sidebar {
Theme& Theme::GetCurrentTheme()
{
- return SFX_APP()->GetSidebarTheme();
+ return SfxGetpApp()->GetSidebarTheme();
}
Theme::Theme()
diff --git a/sfx2/source/statbar/stbitem.cxx b/sfx2/source/statbar/stbitem.cxx
index df13974eb563..882c4ea5d398 100644
--- a/sfx2/source/statbar/stbitem.cxx
+++ b/sfx2/source/statbar/stbitem.cxx
@@ -626,7 +626,7 @@ SfxStatusBarControl* SfxStatusBarControl::CreateControl
)
{
SolarMutexGuard aGuard;
- SfxApplication *pApp = SFX_APP();
+ SfxApplication *pApp = SfxGetpApp();
SfxSlotPool *pSlotPool;
if ( pMod )
@@ -665,7 +665,7 @@ SfxStatusBarControl* SfxStatusBarControl::CreateControl
void SfxStatusBarControl::RegisterStatusBarControl(SfxModule* pMod, SfxStbCtrlFactory* pFact)
{
- SFX_APP()->RegisterStatusBarControl_Impl( pMod, pFact );
+ SfxGetpApp()->RegisterStatusBarControl_Impl( pMod, pFact );
}
diff --git a/sfx2/source/toolbox/tbxitem.cxx b/sfx2/source/toolbox/tbxitem.cxx
index 73380fde79fb..8c443f11c605 100644
--- a/sfx2/source/toolbox/tbxitem.cxx
+++ b/sfx2/source/toolbox/tbxitem.cxx
@@ -302,14 +302,14 @@ void SAL_CALL SfxToolBoxControl::dispose() throw (::com::sun::star::uno::Runtime
void SfxToolBoxControl::RegisterToolBoxControl( SfxModule* pMod, SfxTbxCtrlFactory* pFact)
{
- SFX_APP()->RegisterToolBoxControl_Impl( pMod, pFact );
+ SfxGetpApp()->RegisterToolBoxControl_Impl( pMod, pFact );
}
SfxToolBoxControl* SfxToolBoxControl::CreateControl( sal_uInt16 nSlotId, sal_uInt16 nTbxId, ToolBox *pBox, SfxModule* pMod )
{
SolarMutexGuard aGuard;
- SfxApplication *pApp = SFX_APP();
+ SfxApplication *pApp = SfxGetpApp();
SfxSlotPool *pSlotPool;
if ( pMod )
@@ -1130,7 +1130,7 @@ SfxPopupWindow::SfxPopupWindow(
sal_uInt16 nId,
const Reference< XFrame >& rFrame,
WinBits nBits ) :
- FloatingWindow( SFX_APP()->GetTopWindow(), nBits )
+ FloatingWindow( SfxGetpApp()->GetTopWindow(), nBits )
, m_bFloating( false )
, m_bCascading( false )
, m_nId( nId )
@@ -1148,7 +1148,7 @@ SfxPopupWindow::SfxPopupWindow(
sal_uInt16 nId,
const Reference< XFrame >& rFrame,
const ResId &rId ) :
- FloatingWindow( SFX_APP()->GetTopWindow(), rId )
+ FloatingWindow( SfxGetpApp()->GetTopWindow(), rId )
, m_bFloating( false )
, m_bCascading( false )
, m_nId( nId )
diff --git a/sfx2/source/view/frame.cxx b/sfx2/source/view/frame.cxx
index 416f08502350..26c6b5fe539d 100644
--- a/sfx2/source/view/frame.cxx
+++ b/sfx2/source/view/frame.cxx
@@ -213,7 +213,7 @@ bool SfxFrame::PrepareClose_Impl( bool bUI )
bOther = ( &pFrame->GetFrame() != this );
}
- SFX_APP()->NotifyEvent( SfxViewEventHint(SFX_EVENT_PREPARECLOSEVIEW, GlobalEventConfig::GetEventName( STR_EVENT_PREPARECLOSEVIEW ), pCur, GetController() ) );
+ SfxGetpApp()->NotifyEvent( SfxViewEventHint(SFX_EVENT_PREPARECLOSEVIEW, GlobalEventConfig::GetEventName( STR_EVENT_PREPARECLOSEVIEW ), pCur, GetController() ) );
if ( bOther )
// if there are other views only the current view of this frame must be asked
@@ -518,13 +518,13 @@ bool SfxFrame::IsParent( SfxFrame *pFrame ) const
void SfxFrame::InsertTopFrame_Impl( SfxFrame* pFrame )
{
- SfxFrameArr_Impl& rArr = *SFX_APP()->Get_Impl()->pTopFrames;
+ SfxFrameArr_Impl& rArr = *SfxGetpApp()->Get_Impl()->pTopFrames;
rArr.push_back( pFrame );
}
void SfxFrame::RemoveTopFrame_Impl( SfxFrame* pFrame )
{
- SfxFrameArr_Impl& rArr = *SFX_APP()->Get_Impl()->pTopFrames;
+ SfxFrameArr_Impl& rArr = *SfxGetpApp()->Get_Impl()->pTopFrames;
SfxFrameArr_Impl::iterator it = std::find( rArr.begin(), rArr.end(), pFrame );
if ( it != rArr.end() )
rArr.erase( it );
@@ -955,7 +955,7 @@ const SfxPoolItem* SfxFrame::OpenDocumentSynchron( SfxItemSet& i_rSet, const Ref
{
i_rSet.Put( SfxUnoFrameItem( SID_FILLFRAME, i_rTargetFrame ) );
i_rSet.ClearItem( SID_TARGETNAME );
- return SFX_APP()->GetDispatcher_Impl()->Execute( SID_OPENDOC, SFX_CALLMODE_SYNCHRON, i_rSet );
+ return SfxGetpApp()->GetDispatcher_Impl()->Execute( SID_OPENDOC, SFX_CALLMODE_SYNCHRON, i_rSet );
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/sfx2/source/view/frmload.cxx b/sfx2/source/view/frmload.cxx
index afbf092142f6..4dec0d6470d7 100644
--- a/sfx2/source/view/frmload.cxx
+++ b/sfx2/source/view/frmload.cxx
@@ -262,7 +262,7 @@ const SfxFilter* SfxFrameLoader_Impl::impl_getFilterFromServiceName_nothrow( con
m_aContext->getServiceManager()->createInstanceWithContext("com.sun.star.document.FilterFactory", m_aContext),
UNO_QUERY_THROW );
- const SfxFilterMatcher& rMatcher = SFX_APP()->GetFilterMatcher();
+ const SfxFilterMatcher& rMatcher = SfxGetpApp()->GetFilterMatcher();
const SfxFilterFlags nMust = SFX_FILTER_IMPORT;
const SfxFilterFlags nDont = SFX_FILTER_NOTINSTALLED;
@@ -343,11 +343,11 @@ namespace
bool SfxFrameLoader_Impl::impl_createNewDocWithSlotParam( const sal_uInt16 _nSlotID, const Reference< XFrame >& i_rxFrame,
const bool i_bHidden )
{
- SfxRequest aRequest( _nSlotID, SFX_CALLMODE_SYNCHRON, SFX_APP()->GetPool() );
+ SfxRequest aRequest( _nSlotID, SFX_CALLMODE_SYNCHRON, SfxGetpApp()->GetPool() );
aRequest.AppendItem( SfxUnoFrameItem( SID_FILLFRAME, i_rxFrame ) );
if ( i_bHidden )
aRequest.AppendItem( SfxBoolItem( SID_HIDDEN, true ) );
- return lcl_getDispatchResult( SFX_APP()->ExecuteSlot( aRequest ) );
+ return lcl_getDispatchResult( SfxGetpApp()->ExecuteSlot( aRequest ) );
}
@@ -360,7 +360,7 @@ void SfxFrameLoader_Impl::impl_determineFilter( ::comphelper::NamedValueCollecti
const Reference< XInteractionHandler >
xInteraction = io_rDescriptor.getOrDefault( "InteractionHandler", Reference< XInteractionHandler >() );
- const SfxFilterMatcher& rMatcher = SFX_APP()->GetFilterMatcher();
+ const SfxFilterMatcher& rMatcher = SfxGetpApp()->GetFilterMatcher();
const SfxFilter* pFilter = NULL;
// get filter by its name directly ...
@@ -443,7 +443,7 @@ bool SfxFrameLoader_Impl::impl_determineTemplateDocument( ::comphelper::NamedVal
{
// detect the filter for the template. Might still be NULL (if the template is broken, or does not
// exist, or some such), but this is handled by our caller the same way as if no template/URL was present.
- const SfxFilter* pTemplateFilter = impl_detectFilterForURL( sTemplateURL, io_rDescriptor, SFX_APP()->GetFilterMatcher() );
+ const SfxFilter* pTemplateFilter = impl_detectFilterForURL( sTemplateURL, io_rDescriptor, SfxGetpApp()->GetFilterMatcher() );
if ( pTemplateFilter )
{
// load the template document, but, well, "as template"
diff --git a/sfx2/source/view/sfxbasecontroller.cxx b/sfx2/source/view/sfxbasecontroller.cxx
index 51c73c1a8c9c..fb06fe630225 100644
--- a/sfx2/source/view/sfxbasecontroller.cxx
+++ b/sfx2/source/view/sfxbasecontroller.cxx
@@ -572,7 +572,7 @@ void SAL_CALL SfxBaseController::attachFrame( const Reference< frame::XFrame >&
// attaching the frame to the controller is the last step in the creation of a new view, so notify this
SfxViewEventHint aHint( SFX_EVENT_VIEWCREATED, GlobalEventConfig::GetEventName( STR_EVENT_VIEWCREATED ), m_pData->m_pViewShell->GetObjectShell(), Reference< frame::XController2 >( this ) );
- SFX_APP()->NotifyEvent( aHint );
+ SfxGetpApp()->NotifyEvent( aHint );
}
}
}
@@ -1000,9 +1000,9 @@ void SAL_CALL SfxBaseController::dispose() throw( RuntimeException, std::excepti
pView = SfxViewFrame::GetNext( *pView, pDoc );
}
- SFX_APP()->NotifyEvent( SfxViewEventHint(SFX_EVENT_CLOSEVIEW, GlobalEventConfig::GetEventName( STR_EVENT_CLOSEVIEW ), pDoc, Reference< frame::XController2 >( this ) ) );
+ SfxGetpApp()->NotifyEvent( SfxViewEventHint(SFX_EVENT_CLOSEVIEW, GlobalEventConfig::GetEventName( STR_EVENT_CLOSEVIEW ), pDoc, Reference< frame::XController2 >( this ) ) );
if ( !pView )
- SFX_APP()->NotifyEvent( SfxEventHint(SFX_EVENT_CLOSEDOC, GlobalEventConfig::GetEventName( STR_EVENT_CLOSEDOC ), pDoc) );
+ SfxGetpApp()->NotifyEvent( SfxEventHint(SFX_EVENT_CLOSEDOC, GlobalEventConfig::GetEventName( STR_EVENT_CLOSEDOC ), pDoc) );
Reference< frame::XModel > xModel = pDoc->GetModel();
Reference < util::XCloseable > xCloseable( xModel, uno::UNO_QUERY );
diff --git a/sfx2/source/view/viewfrm.cxx b/sfx2/source/view/viewfrm.cxx
index 84d0a711c2e7..6a6db38de0d3 100644
--- a/sfx2/source/view/viewfrm.cxx
+++ b/sfx2/source/view/viewfrm.cxx
@@ -339,7 +339,7 @@ void SfxViewFrame::ExecReload_Impl( SfxRequest& rReq )
SFX_ITEMSET_ARG( pSh->GetMedium()->GetItemSet(), pItem, SfxBoolItem, SID_VIEWONLY, false );
if ( pItem && pItem->GetValue() )
{
- SfxApplication* pApp = SFX_APP();
+ SfxApplication* pApp = SfxGetpApp();
SfxAllItemSet aSet( pApp->GetPool() );
aSet.Put( SfxStringItem( SID_FILE_NAME, pMed->GetURLObject().GetMainURL(INetURLObject::NO_DECODE) ) );
aSet.Put( SfxBoolItem( SID_TEMPLATE, true ) );
@@ -494,7 +494,7 @@ void SfxViewFrame::ExecReload_Impl( SfxRequest& rReq )
QueryBox aBox( &GetWindow(), SfxResId(MSG_QUERY_OPENASTEMPLATE) );
if ( RET_YES == aBox.Execute() )
{
- SfxApplication* pApp = SFX_APP();
+ SfxApplication* pApp = SfxGetpApp();
SfxAllItemSet aSet( pApp->GetPool() );
aSet.Put( SfxStringItem( SID_FILE_NAME, pMed->GetName() ) );
SFX_ITEMSET_ARG( pMed->GetItemSet(), pReferer, SfxStringItem, SID_REFERER, false );
@@ -546,7 +546,7 @@ void SfxViewFrame::ExecReload_Impl( SfxRequest& rReq )
// despite this is not!
if ( !pSh || !pSh->CanReload_Impl() )
break;
- SfxApplication* pApp = SFX_APP();
+ SfxApplication* pApp = SfxGetpApp();
SFX_REQUEST_ARG(rReq, pForceReloadItem, SfxBoolItem,
SID_FORCERELOAD, false);
if( pForceReloadItem && !pForceReloadItem->GetValue() &&
@@ -815,7 +815,7 @@ void SfxViewFrame::ExecReload_Impl( SfxRequest& rReq )
}
// Propagate document closure.
- SFX_APP()->NotifyEvent( SfxEventHint( SFX_EVENT_CLOSEDOC, GlobalEventConfig::GetEventName( STR_EVENT_CLOSEDOC ), xOldObj ) );
+ SfxGetpApp()->NotifyEvent( SfxEventHint( SFX_EVENT_CLOSEDOC, GlobalEventConfig::GetEventName( STR_EVENT_CLOSEDOC ), xOldObj ) );
}
// Record as done
@@ -1131,7 +1131,7 @@ bool SfxViewFrame::Close()
void SfxViewFrame::DoActivate( bool bUI, SfxViewFrame* pOldFrame )
{
- SFX_APP();
+ SfxGetpApp();
pDispatcher->DoActivate_Impl( bUI, pOldFrame );
@@ -1152,7 +1152,7 @@ void SfxViewFrame::DoActivate( bool bUI, SfxViewFrame* pOldFrame )
void SfxViewFrame::DoDeactivate(bool bUI, SfxViewFrame* pNewFrame )
{
- SFX_APP();
+ SfxGetpApp();
pDispatcher->DoDeactivate_Impl( bUI, pNewFrame );
// If this ViewFrame has got a parent and this is not a parent of the
@@ -1384,7 +1384,7 @@ void SfxViewFrame::Construct_Impl( SfxObjectShell *pObjSh )
pImp->aMargin = Size( -1, -1 );
pImp->pWindow = 0;
- SetPool( &SFX_APP()->GetPool() );
+ SetPool( &SfxGetpApp()->GetPool() );
pDispatcher = new SfxDispatcher(this);
if ( !GetBindings().GetDispatcher() )
GetBindings().SetDispatcher( pDispatcher );
@@ -1395,7 +1395,7 @@ void SfxViewFrame::Construct_Impl( SfxObjectShell *pObjSh )
if ( pObjSh )
{
- pDispatcher->Push( *SFX_APP() );
+ pDispatcher->Push( *SfxGetpApp() );
SfxModule* pModule = xObjSh->GetModule();
if( pModule )
pDispatcher->Push( *pModule );
@@ -1410,12 +1410,12 @@ void SfxViewFrame::Construct_Impl( SfxObjectShell *pObjSh )
}
else
{
- pDispatcher->Push( *SFX_APP() );
+ pDispatcher->Push( *SfxGetpApp() );
pDispatcher->Push( *this );
pDispatcher->Flush();
}
- SfxViewFrameArr_Impl &rViewArr = SFX_APP()->GetViewFrames_Impl();
+ SfxViewFrameArr_Impl &rViewArr = SfxGetpApp()->GetViewFrames_Impl();
rViewArr.push_back( this );
}
@@ -1469,7 +1469,7 @@ SfxViewFrame::~SfxViewFrame()
GetFrame().SetCurrentViewFrame_Impl( NULL );
// Unregister from the Frame List.
- SfxApplication *pSfxApp = SFX_APP();
+ SfxApplication *pSfxApp = SfxGetpApp();
SfxViewFrameArr_Impl &rFrames = pSfxApp->GetViewFrames_Impl();
SfxViewFrameArr_Impl::iterator it = std::find( rFrames.begin(), rFrames.end(), this );
rFrames.erase( it );
@@ -1503,7 +1503,7 @@ void SfxViewFrame::KillDispatcher_Impl()
SfxViewFrame* SfxViewFrame::Current()
{
- return SfxApplication::Get() ? SFX_APP()->Get_Impl()->pViewFrame : NULL;
+ return SfxApplication::Get() ? SfxGetpApp()->Get_Impl()->pViewFrame : NULL;
}
@@ -1514,7 +1514,7 @@ SfxViewFrame* SfxViewFrame::GetFirst
bool bOnlyIfVisible
)
{
- SfxApplication *pSfxApp = SFX_APP();
+ SfxApplication *pSfxApp = SfxGetpApp();
SfxViewFrameArr_Impl &rFrames = pSfxApp->GetViewFrames_Impl();
// search for a SfxDocument of the specified type
@@ -1539,7 +1539,7 @@ SfxViewFrame* SfxViewFrame::GetNext
bool bOnlyIfVisible
)
{
- SfxApplication *pSfxApp = SFX_APP();
+ SfxApplication *pSfxApp = SfxGetpApp();
SfxViewFrameArr_Impl &rFrames = pSfxApp->GetViewFrames_Impl();
// refind the specified predecessor
@@ -2175,7 +2175,7 @@ bool SfxViewFrame::SwitchToViewShell_Impl
return false;
}
- DBG_ASSERT( SFX_APP()->GetViewFrames_Impl().size() == SFX_APP()->GetViewShells_Impl().size(), "Inconsistent view arrays!" );
+ DBG_ASSERT( SfxGetpApp()->GetViewFrames_Impl().size() == SfxGetpApp()->GetViewShells_Impl().size(), "Inconsistent view arrays!" );
return true;
}
@@ -2566,10 +2566,10 @@ void SfxViewFrame::AddDispatchMacroToBasic_Impl( const OUString& sMacro )
if ( sMacro.isEmpty() )
return;
- SfxApplication* pSfxApp = SFX_APP();
+ SfxApplication* pSfxApp = SfxGetpApp();
SfxRequest aReq( SID_BASICCHOOSER, SFX_CALLMODE_SYNCHRON, pSfxApp->GetPool() );
aReq.AppendItem( SfxBoolItem(SID_RECORDMACRO,true) );
- const SfxPoolItem* pRet = SFX_APP()->ExecuteSlot( aReq );
+ const SfxPoolItem* pRet = SfxGetpApp()->ExecuteSlot( aReq );
OUString aScriptURL;
if ( pRet )
aScriptURL = ((SfxStringItem*)pRet)->GetValue();
@@ -2637,7 +2637,7 @@ void SfxViewFrame::AddDispatchMacroToBasic_Impl( const OUString& sMacro )
com::sun::star::uno::Reference< com::sun::star::script::XLibraryContainer > xLibCont;
if ( aLocation.equalsIgnoreAsciiCase( "application" ) )
{
- xLibCont = SFX_APP()->GetBasicContainer();
+ xLibCont = SfxGetpApp()->GetBasicContainer();
}
else if ( aLocation.equalsIgnoreAsciiCase( "document" ) )
{
@@ -3275,7 +3275,7 @@ void SfxViewFrame::UpdateDocument_Impl()
void SfxViewFrame::SetViewFrame( SfxViewFrame* pFrame )
{
- SFX_APP()->SetViewFrame_Impl( pFrame );
+ SfxGetpApp()->SetViewFrame_Impl( pFrame );
}
diff --git a/sfx2/source/view/viewfrm2.cxx b/sfx2/source/view/viewfrm2.cxx
index 9a7f23667c0d..9590acc75922 100644
--- a/sfx2/source/view/viewfrm2.cxx
+++ b/sfx2/source/view/viewfrm2.cxx
@@ -224,7 +224,7 @@ void SfxViewFrame::Exec_Impl(SfxRequest &rReq )
aReq.AppendItem( SfxStringItem( SID_FILE_NAME, aFact ) );
aReq.AppendItem( SfxFrameItem( SID_DOCFRAME, &GetFrame() ) );
aReq.AppendItem( SfxStringItem( SID_TARGETNAME, OUString( "_blank" ) ) );
- SFX_APP()->ExecuteSlot( aReq );
+ SfxGetpApp()->ExecuteSlot( aReq );
const SfxViewFrameItem* pItem = PTR_CAST( SfxViewFrameItem, aReq.GetReturnValue() );
if ( pItem )
rReq.SetReturnValue( SfxFrameItem( 0, pItem->GetFrame() ) );
diff --git a/sfx2/source/view/viewprn.cxx b/sfx2/source/view/viewprn.cxx
index 8007221e9230..267ab28c4e1f 100644
--- a/sfx2/source/view/viewprn.cxx
+++ b/sfx2/source/view/viewprn.cxx
@@ -318,7 +318,7 @@ void SfxPrinterController::jobStarted()
now.GetNanoSec(), now.GetSec(), now.GetMin(), now.GetHour(),
now.GetDay(), now.GetMonth(), now.GetYear(), false) );
- SFX_APP()->NotifyEvent( SfxEventHint(SFX_EVENT_PRINTDOC, GlobalEventConfig::GetEventName( STR_EVENT_PRINTDOC ), mpObjectShell ) );
+ SfxGetpApp()->NotifyEvent( SfxEventHint(SFX_EVENT_PRINTDOC, GlobalEventConfig::GetEventName( STR_EVENT_PRINTDOC ), mpObjectShell ) );
uno::Sequence < beans::PropertyValue > aOpts;
aOpts = getJobProperties( aOpts );
diff --git a/sfx2/source/view/viewsh.cxx b/sfx2/source/view/viewsh.cxx
index c8b8eb7e26fe..c4cd7c2ae588 100644
--- a/sfx2/source/view/viewsh.cxx
+++ b/sfx2/source/view/viewsh.cxx
@@ -556,7 +556,7 @@ void SfxViewShell::ExecMisc_Impl( SfxRequest &rReq )
if ( eResult == SfxMailModel::SEND_MAIL_ERROR )
{
- InfoBox aBox( SFX_APP()->GetTopWindow(), SfxResId( MSG_ERROR_SEND_MAIL ));
+ InfoBox aBox( SfxGetpApp()->GetTopWindow(), SfxResId( MSG_ERROR_SEND_MAIL ));
aBox.Execute();
rReq.Ignore();
}
@@ -576,7 +576,7 @@ void SfxViewShell::ExecMisc_Impl( SfxRequest &rReq )
SfxMailModel::SendMailResult eResult = aModel.SaveAndSend( xFrame, OUString() );
if( eResult == SfxMailModel::SEND_MAIL_ERROR )
{
- InfoBox aBox( SFX_APP()->GetTopWindow(), SfxResId( MSG_ERROR_SEND_MAIL ));
+ InfoBox aBox( SfxGetpApp()->GetTopWindow(), SfxResId( MSG_ERROR_SEND_MAIL ));
aBox.Execute();
rReq.Ignore();
}
@@ -1206,7 +1206,7 @@ void SfxViewShell::SetWindow
pWindow->GrabFocus();
//TODO/CLEANUP
//Do we still need this Method?!
- //SFX_APP()->GrabFocus( pWindow );
+ //SfxGetpApp()->GrabFocus( pWindow );
}
@@ -1238,7 +1238,7 @@ SfxViewShell::SfxViewShell
StartListening(*pViewFrame->GetObjectShell());
// Insert into list
- SfxViewShellArr_Impl &rViewArr = SFX_APP()->GetViewShells_Impl();
+ SfxViewShellArr_Impl &rViewArr = SfxGetpApp()->GetViewShells_Impl();
rViewArr.push_back(this);
}
@@ -1249,7 +1249,7 @@ SfxViewShell::~SfxViewShell()
// Remove from list
const SfxViewShell *pThis = this;
- SfxViewShellArr_Impl &rViewArr = SFX_APP()->GetViewShells_Impl();
+ SfxViewShellArr_Impl &rViewArr = SfxGetpApp()->GetViewShells_Impl();
SfxViewShellArr_Impl::iterator it = std::find( rViewArr.begin(), rViewArr.end(), pThis );
rViewArr.erase( it );
@@ -1484,8 +1484,8 @@ SfxViewShell* SfxViewShell::GetFirst
)
{
// search for a SfxViewShell of the specified type
- SfxViewShellArr_Impl &rShells = SFX_APP()->GetViewShells_Impl();
- SfxViewFrameArr_Impl &rFrames = SFX_APP()->GetViewFrames_Impl();
+ SfxViewShellArr_Impl &rShells = SfxGetpApp()->GetViewShells_Impl();
+ SfxViewFrameArr_Impl &rFrames = SfxGetpApp()->GetViewFrames_Impl();
for ( sal_uInt16 nPos = 0; nPos < rShells.size(); ++nPos )
{
SfxViewShell *pShell = rShells[nPos];
@@ -1521,8 +1521,8 @@ SfxViewShell* SfxViewShell::GetNext
bool bOnlyVisible
)
{
- SfxViewShellArr_Impl &rShells = SFX_APP()->GetViewShells_Impl();
- SfxViewFrameArr_Impl &rFrames = SFX_APP()->GetViewFrames_Impl();
+ SfxViewShellArr_Impl &rShells = SfxGetpApp()->GetViewShells_Impl();
+ SfxViewFrameArr_Impl &rFrames = SfxGetpApp()->GetViewFrames_Impl();
sal_uInt16 nPos;
for ( nPos = 0; nPos < rShells.size(); ++nPos )
if ( rShells[nPos] == &rPrev )
@@ -1567,7 +1567,7 @@ void SfxViewShell::Notify( SfxBroadcaster& rBC,
if ( GetController().is() )
{
// avoid access to dangling ViewShells
- SfxViewFrameArr_Impl &rFrames = SFX_APP()->GetViewFrames_Impl();
+ SfxViewFrameArr_Impl &rFrames = SfxGetpApp()->GetViewFrames_Impl();
for ( sal_uInt16 n=0; n<rFrames.size(); ++n )
{
SfxViewFrame *frame = rFrames[n];
diff --git a/starmath/source/document.cxx b/starmath/source/document.cxx
index 51dfe5f5f308..4009d6a8d5fd 100644
--- a/starmath/source/document.cxx
+++ b/starmath/source/document.cxx
@@ -170,7 +170,7 @@ void SmDocShell::SetText(const OUString& rBuffer)
// have SwOleClient::FormatChanged() to align the modified formula properly
// even if the vis area does not change (e.g. when formula text changes from
// "{a over b + c} over d" to "d over {a over b + c}"
- SFX_APP()->NotifyEvent(SfxEventHint( SFX_EVENT_VISAREACHANGED, GlobalEventConfig::GetEventName(STR_EVENT_VISAREACHANGED), this));
+ SfxGetpApp()->NotifyEvent(SfxEventHint( SFX_EVENT_VISAREACHANGED, GlobalEventConfig::GetEventName(STR_EVENT_VISAREACHANGED), this));
Repaint();
}
@@ -664,7 +664,7 @@ SmDocShell::SmDocShell( const sal_uInt64 i_nSfxCreationFlags ) :
{
pCursor = NULL;
- SetPool(&SFX_APP()->GetPool());
+ SetPool(&SfxGetpApp()->GetPool());
SmModule *pp = SM_MOD();
aFormat = pp->GetConfig()->GetStandardFormat();
@@ -1280,7 +1280,7 @@ void SmDocShell::Draw(OutputDevice *pDevice,
SfxItemPool& SmDocShell::GetPool() const
{
- return SFX_APP()->GetPool();
+ return SfxGetpApp()->GetPool();
}
void SmDocShell::SetVisArea(const Rectangle & rVisArea)
diff --git a/svx/source/dialog/databaseregistrationui.cxx b/svx/source/dialog/databaseregistrationui.cxx
index 1b1f40d0f226..b4e2316b7085 100644
--- a/svx/source/dialog/databaseregistrationui.cxx
+++ b/svx/source/dialog/databaseregistrationui.cxx
@@ -37,7 +37,7 @@ namespace svx
{
sal_uInt16 nResult = RET_CANCEL;
- SfxItemSet aRegistrationItems( SFX_APP()->GetPool(), SID_SB_DB_REGISTER, SID_SB_DB_REGISTER, 0 );
+ SfxItemSet aRegistrationItems( SfxGetpApp()->GetPool(), SID_SB_DB_REGISTER, SID_SB_DB_REGISTER, 0 );
SvxAbstractDialogFactory* pDialogFactory = SvxAbstractDialogFactory::Create();
boost::scoped_ptr< SfxAbstractDialog > pDialog;
diff --git a/svx/source/dialog/hyperdlg.cxx b/svx/source/dialog/hyperdlg.cxx
index 95a2800c9b62..621e95c16ac9 100644
--- a/svx/source/dialog/hyperdlg.cxx
+++ b/svx/source/dialog/hyperdlg.cxx
@@ -62,7 +62,7 @@ SvxHlinkDlgWrapper::SvxHlinkDlgWrapper( Window* _pParent, sal_uInt16 nId,
Window* pTopWindow = 0;
if ( pInfo->aSize.Width() != 0 && pInfo->aSize.Height() != 0 &&
- (0 != (pTopWindow = SFX_APP()->GetTopWindow())))
+ (0 != (pTopWindow = SfxGetpApp()->GetTopWindow())))
{
Size aParentSize( pTopWindow->GetSizePixel() );
Size aDlgSize ( GetSizePixel () );
diff --git a/svx/source/dialog/srchdlg.cxx b/svx/source/dialog/srchdlg.cxx
index 6a6cb82eea9c..c3c39120a278 100644
--- a/svx/source/dialog/srchdlg.cxx
+++ b/svx/source/dialog/srchdlg.cxx
@@ -135,7 +135,7 @@ struct SearchDlg_Impl
void ListToStrArr_Impl( sal_uInt16 nId, std::vector<OUString>& rStrLst, ComboBox& rCBox )
{
SfxStringListItem* pSrchItem =
- (SfxStringListItem*)SFX_APP()->GetItem( nId );
+ (SfxStringListItem*)SfxGetpApp()->GetItem( nId );
if (pSrchItem)
{
@@ -152,7 +152,7 @@ void ListToStrArr_Impl( sal_uInt16 nId, std::vector<OUString>& rStrLst, ComboBox
void StrArrToList_Impl( sal_uInt16 nId, const std::vector<OUString>& rStrLst )
{
DBG_ASSERT( !rStrLst.empty(), "check in advance");
- SFX_APP()->PutItem( SfxStringListItem( nId, &rStrLst ) );
+ SfxGetpApp()->PutItem( SfxStringListItem( nId, &rStrLst ) );
}
// class SearchAttrItemList ----------------------------------------------
@@ -1305,7 +1305,7 @@ IMPL_LINK( SvxSearchDialog, CommandHdl_Impl, Button *, pBtn )
}
else if (pBtn == m_pJapOptionsBtn)
{
- SfxItemSet aSet( SFX_APP()->GetPool() );
+ SfxItemSet aSet( SfxGetpApp()->GetPool() );
pSearchItem->SetTransliterationFlags( GetTransliterationFlags() );
SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
if(pFact)
diff --git a/svx/source/form/fmscriptingenv.cxx b/svx/source/form/fmscriptingenv.cxx
index 58dc19de9fb6..5c9b5b9abb54 100644
--- a/svx/source/form/fmscriptingenv.cxx
+++ b/svx/source/form/fmscriptingenv.cxx
@@ -982,7 +982,7 @@ namespace svxform
if ( sMacroLocation.isEmpty() )
{
// legacy format: use the app-wide Basic, if it has a respective method, otherwise fall back to the doc's Basic
- if ( SFX_APP()->GetBasicManager()->HasMacro( sScriptCode ) )
+ if ( SfxGetpApp()->GetBasicManager()->HasMacro( sScriptCode ) )
sMacroLocation = "application";
else
sMacroLocation = "document";
diff --git a/svx/source/form/fmshell.cxx b/svx/source/form/fmshell.cxx
index a87fae4cbdb5..23a65c85646d 100644
--- a/svx/source/form/fmshell.cxx
+++ b/svx/source/form/fmshell.cxx
@@ -221,7 +221,7 @@ FmFormShell::FmFormShell( SfxViewShell* _pParent, FmFormView* pView )
,m_bHasForms(false)
{
m_pImpl->acquire();
- SetPool( &SFX_APP()->GetPool() );
+ SetPool( &SfxGetpApp()->GetPool() );
SetName( OUString("Form") );
SetView(m_pFormView);
diff --git a/svx/source/form/fmtextcontrolshell.cxx b/svx/source/form/fmtextcontrolshell.cxx
index 594afb09fa6d..4682df6244ab 100644
--- a/svx/source/form/fmtextcontrolshell.cxx
+++ b/svx/source/form/fmtextcontrolshell.cxx
@@ -585,8 +585,8 @@ namespace svx
SfxSlotId nSlotId( aFeature->first );
#if OSL_DEBUG_LEVEL > 0
OUString sUnoSlotName;
- if ( SFX_APP() )
- sUnoSlotName = lcl_getUnoSlotName( *SFX_APP(), nSlotId );
+ if ( SfxGetpApp() )
+ sUnoSlotName = lcl_getUnoSlotName( *SfxGetpApp(), nSlotId );
else
sUnoSlotName = "<unknown>";
OString sUnoSlotNameAscii( "\"" );
@@ -739,7 +739,7 @@ namespace svx
sError += "\n WhichID: "; sError += OString::number( nWhich );
sError += "\n UNO name: ";
- OUString sUnoSlotName = lcl_getUnoSlotName( *SFX_APP(), nSlotForItemSet );
+ OUString sUnoSlotName = lcl_getUnoSlotName( *SfxGetpApp(), nSlotForItemSet );
if ( !sUnoSlotName.isEmpty() )
sError += OString( sUnoSlotName.getStr(), sUnoSlotName.getLength(), RTL_TEXTENCODING_ASCII_US );
else
@@ -1275,7 +1275,7 @@ namespace svx
ControlFeatures& _rDispatchers )
{
Reference< XDispatchProvider > xProvider( _rxControl, UNO_QUERY );
- SfxApplication* pApplication = SFX_APP();
+ SfxApplication* pApplication = SfxGetpApp();
DBG_ASSERT( pApplication, "FmTextControlShell::fillFeatureDispatchers: no SfxApplication!" );
if ( xProvider.is() && pApplication )
{
diff --git a/svx/source/gallery2/galbrws1.cxx b/svx/source/gallery2/galbrws1.cxx
index 0cc404ef81f2..ddb6bfa9d7be 100644
--- a/svx/source/gallery2/galbrws1.cxx
+++ b/svx/source/gallery2/galbrws1.cxx
@@ -266,7 +266,7 @@ void GalleryBrowser1::ImplGetExecuteVector(::std::vector< sal_uInt16 >& o_aExec)
void GalleryBrowser1::ImplGalleryThemeProperties( const OUString & rThemeName, bool bCreateNew )
{
DBG_ASSERT(!mpThemePropsDlgItemSet, "mpThemePropsDlgItemSet already set!");
- mpThemePropsDlgItemSet = new SfxItemSet( SFX_APP()->GetPool() );
+ mpThemePropsDlgItemSet = new SfxItemSet( SfxGetpApp()->GetPool() );
GalleryTheme* pTheme = mpGallery->AcquireTheme( rThemeName, *this );
ImplFillExchangeData( pTheme, *mpExchangeData );
diff --git a/svx/source/unodraw/unoshap2.cxx b/svx/source/unodraw/unoshap2.cxx
index acbb614fc74d..0c52dd972ad7 100644
--- a/svx/source/unodraw/unoshap2.cxx
+++ b/svx/source/unodraw/unoshap2.cxx
@@ -1526,7 +1526,7 @@ bool SvxGraphicObject::setPropertyValueImpl( const OUString& rName, const SfxIte
const SfxFilter* pSfxFilter = NULL;
SfxMedium aSfxMedium( aURL, referer_, STREAM_READ | STREAM_SHARE_DENYNONE );
- SFX_APP()->GetFilterMatcher().GuessFilter( aSfxMedium, &pSfxFilter, SFX_FILTER_IMPORT, SFX_FILTER_NOTINSTALLED | SFX_FILTER_EXECUTABLE );
+ SfxGetpApp()->GetFilterMatcher().GuessFilter( aSfxMedium, &pSfxFilter, SFX_FILTER_IMPORT, SFX_FILTER_NOTINSTALLED | SFX_FILTER_EXECUTABLE );
if( !pSfxFilter )
{
diff --git a/sw/qa/core/filters-test.cxx b/sw/qa/core/filters-test.cxx
index 85486162da69..2a80f3efb242 100644
--- a/sw/qa/core/filters-test.cxx
+++ b/sw/qa/core/filters-test.cxx
@@ -95,7 +95,7 @@ bool SwFiltersTest::filter(const OUString &rFilter, const OUString &rURL,
SfxFilter* pExportFilter = 0;
if (bExport)
{
- SFX_APP()->GetFilterMatcher().GuessFilter(*pSrcMed, &pImportFilter, SFX_FILTER_IMPORT, 0);
+ SfxGetpApp()->GetFilterMatcher().GuessFilter(*pSrcMed, &pImportFilter, SFX_FILTER_IMPORT, 0);
pExportFilter = pFilter;
}
else
diff --git a/sw/source/filter/html/htmlbas.cxx b/sw/source/filter/html/htmlbas.cxx
index 63467afbe4e8..5662e20580bc 100644
--- a/sw/source/filter/html/htmlbas.cxx
+++ b/sw/source/filter/html/htmlbas.cxx
@@ -260,7 +260,7 @@ void SwHTMLWriter::OutBasic()
BasicManager *pBasicMan = pDoc->GetDocShell()->GetBasicManager();
OSL_ENSURE( pBasicMan, "Wo ist der Basic-Manager?" );
// nur das DocumentBasic schreiben
- if( !pBasicMan || pBasicMan == SFX_APP()->GetBasicManager() )
+ if( !pBasicMan || pBasicMan == SfxGetpApp()->GetBasicManager() )
{
return;
}
diff --git a/sw/source/ui/dbui/mmoutputpage.cxx b/sw/source/ui/dbui/mmoutputpage.cxx
index ec881424da09..0d8ca5c395cf 100644
--- a/sw/source/ui/dbui/mmoutputpage.cxx
+++ b/sw/source/ui/dbui/mmoutputpage.cxx
@@ -814,7 +814,7 @@ IMPL_LINK_NOARG(SwMailMergeOutputPage, PrintHdl_Impl)
}
SfxObjectShell* pObjSh = pTargetView->GetViewFrame()->GetObjectShell();
- SFX_APP()->NotifyEvent(SfxEventHint(SW_EVENT_MAIL_MERGE, SwDocShell::GetEventName(STR_SW_EVENT_MAIL_MERGE), pObjSh));
+ SfxGetpApp()->NotifyEvent(SfxEventHint(SW_EVENT_MAIL_MERGE, SwDocShell::GetEventName(STR_SW_EVENT_MAIL_MERGE), pObjSh));
SfxBoolItem aMergeSilent(SID_SILENT, false);
m_pWizard->enableButtons(WZB_CANCEL, false);
@@ -825,7 +825,7 @@ IMPL_LINK_NOARG(SwMailMergeOutputPage, PrintHdl_Impl)
aProps[1]. Value <<= sPages;
pTargetView->ExecPrint( aProps, false, true );
- SFX_APP()->NotifyEvent(SfxEventHint(SW_EVENT_MAIL_MERGE_END, SwDocShell::GetEventName(STR_SW_EVENT_MAIL_MERGE_END), pObjSh));
+ SfxGetpApp()->NotifyEvent(SfxEventHint(SW_EVENT_MAIL_MERGE_END, SwDocShell::GetEventName(STR_SW_EVENT_MAIL_MERGE_END), pObjSh));
pTargetView->SetMailMergeConfigItem(0, 0, false);
m_pWizard->enableButtons(WZB_CANCEL, true);
diff --git a/sw/source/ui/index/cnttab.cxx b/sw/source/ui/index/cnttab.cxx
index 7f537e01e9b8..b0831e782a35 100644
--- a/sw/source/ui/index/cnttab.cxx
+++ b/sw/source/ui/index/cnttab.cxx
@@ -101,7 +101,7 @@ static OUString lcl_CreateAutoMarkFileDlg( const OUString& rURL,
xFltMgr->appendFilter( rFileString, "*.sdi" );
xFltMgr->setCurrentFilter( rFileString ) ;
- OUString& rLastSaveDir = (OUString&)SFX_APP()->GetLastSaveDirectory();
+ OUString& rLastSaveDir = (OUString&)SfxGetpApp()->GetLastSaveDirectory();
OUString sSaveDir = rLastSaveDir;
if( !rURL.isEmpty() )
diff --git a/sw/source/uibase/app/appopt.cxx b/sw/source/uibase/app/appopt.cxx
index 24d4d3ddfced..c78c16389aff 100644
--- a/sw/source/uibase/app/appopt.cxx
+++ b/sw/source/uibase/app/appopt.cxx
@@ -293,7 +293,7 @@ void SwModule::ApplyItemSet( sal_uInt16 nId, const SfxItemSet& rSet )
if( SFX_ITEM_SET == rSet.GetItemState(SID_ATTR_METRIC, false, &pItem ) )
{
- SFX_APP()->SetOptions(rSet);
+ SfxGetpApp()->SetOptions(rSet);
PutItem(*pItem);
const SfxUInt16Item* pMetricItem = (const SfxUInt16Item*)pItem;
::SetDfltMetric((FieldUnit)pMetricItem->GetValue(), !bTextDialog);
@@ -301,7 +301,7 @@ void SwModule::ApplyItemSet( sal_uInt16 nId, const SfxItemSet& rSet )
if( SFX_ITEM_SET == rSet.GetItemState(SID_ATTR_APPLYCHARUNIT,
false, &pItem ) )
{
- SFX_APP()->SetOptions(rSet);
+ SfxGetpApp()->SetOptions(rSet);
const SfxBoolItem* pCharItem = (const SfxBoolItem*)pItem;
::SetApplyCharUnit(pCharItem->GetValue(), !bTextDialog);
}
diff --git a/sw/source/uibase/app/docsh2.cxx b/sw/source/uibase/app/docsh2.cxx
index e68a0d951db9..ad0aed99cdc2 100644
--- a/sw/source/uibase/app/docsh2.cxx
+++ b/sw/source/uibase/app/docsh2.cxx
@@ -346,7 +346,7 @@ void SwDocShell::Execute(SfxRequest& rReq)
editeng::SortedAutoCompleteStrings aTmpLst( rACW.GetWordList() );
pAFlags->m_pAutoCompleteList = &aTmpLst;
- SfxApplication* pApp = SFX_APP();
+ SfxApplication* pApp = SfxGetpApp();
SfxRequest aAppReq(SID_AUTO_CORRECT_DLG, SFX_CALLMODE_SYNCHRON, pApp->GetPool());
SfxBoolItem aSwOptions( SID_AUTO_CORRECT_DLG, true );
aAppReq.AppendItem(aSwOptions);
@@ -1295,7 +1295,7 @@ void SwDocShell::ReloadFromHtml( const OUString& rStreamName, SwSrcView* pSrcVie
if( rHtmlOptions.IsStarBasic() && HasBasic())
{
BasicManager *pBasicMan = GetBasicManager();
- if( pBasicMan && (pBasicMan != SFX_APP()->GetBasicManager()) )
+ if( pBasicMan && (pBasicMan != SfxGetpApp()->GetBasicManager()) )
{
sal_uInt16 nLibCount = pBasicMan->GetLibCount();
while( nLibCount )
diff --git a/sw/source/uibase/app/docst.cxx b/sw/source/uibase/app/docst.cxx
index da3aab0265a1..8b7f77fe4406 100644
--- a/sw/source/uibase/app/docst.cxx
+++ b/sw/source/uibase/app/docst.cxx
@@ -470,7 +470,7 @@ void SwDocShell::ExecStyleSheet( SfxRequest& rReq )
case SID_STYLE_NEW_BY_EXAMPLE:
{
nRet = MakeByExample(aParam, nFamily, nMask, pActShell );
- SfxTemplateDialog* pDlg = SFX_APP()->GetTemplateDialog();
+ SfxTemplateDialog* pDlg = SfxGetpApp()->GetTemplateDialog();
if(pDlg && pDlg->IsVisible())
pDlg->Update();
diff --git a/sw/source/uibase/app/swmodule.cxx b/sw/source/uibase/app/swmodule.cxx
index f2f33eed0209..8a48251289e2 100644
--- a/sw/source/uibase/app/swmodule.cxx
+++ b/sw/source/uibase/app/swmodule.cxx
@@ -197,7 +197,7 @@ SwModule::SwModule( SfxObjectFactory* pWebFact,
const SvxAutoCorrect* pOld = rACfg.GetAutoCorrect();
rACfg.SetAutoCorrect(new SwAutoCorrect( *pOld ));
- StartListening( *SFX_APP() );
+ StartListening( *SfxGetpApp() );
// OD 14.02.2003 #107424# - init color configuration
// member <pColorConfig> is created and the color configuration is applied
@@ -226,7 +226,7 @@ uno::Reference< linguistic2::XLanguageGuessing > SwModule::GetLanguageGuesser()
SwModule::~SwModule()
{
delete pErrorHdl;
- EndListening( *SFX_APP() );
+ EndListening( *SfxGetpApp() );
}
void SwModule::CreateLngSvcEvtListener()
diff --git a/sw/source/uibase/dbui/dbmgr.cxx b/sw/source/uibase/dbui/dbmgr.cxx
index 3bd6a15d6729..0ed706fddfbf 100644
--- a/sw/source/uibase/dbui/dbmgr.cxx
+++ b/sw/source/uibase/dbui/dbmgr.cxx
@@ -1025,9 +1025,9 @@ bool SwDBManager::MergeMailFiles(SwWrtShell* pSourceShell,
SwDoc* pWorkDoc = ((SwDocShell*)(&xWorkDocSh))->GetDoc();
SwDBManager* pOldDBManager = pWorkDoc->GetDBManager();
pWorkDoc->SetDBManager( this );
- SFX_APP()->NotifyEvent(SfxEventHint(SW_EVENT_FIELD_MERGE, SwDocShell::GetEventName(STR_SW_EVENT_FIELD_MERGE), xWorkDocSh));
+ SfxGetpApp()->NotifyEvent(SfxEventHint(SW_EVENT_FIELD_MERGE, SwDocShell::GetEventName(STR_SW_EVENT_FIELD_MERGE), xWorkDocSh));
pWorkDoc->UpdateFlds(NULL, false);
- SFX_APP()->NotifyEvent(SfxEventHint(SW_EVENT_FIELD_MERGE_FINISHED, SwDocShell::GetEventName(STR_SW_EVENT_FIELD_MERGE_FINISHED), xWorkDocSh));
+ SfxGetpApp()->NotifyEvent(SfxEventHint(SW_EVENT_FIELD_MERGE_FINISHED, SwDocShell::GetEventName(STR_SW_EVENT_FIELD_MERGE_FINISHED), xWorkDocSh));
pWorkDoc->RemoveInvisibleContent();
@@ -2411,7 +2411,7 @@ void SwDBManager::ExecuteFormLetter( SwWrtShell& rSh,
// SfxObjectShellRef is ok, since there should be no control over the document lifetime here
SfxObjectShellRef xDocShell = rSh.GetView().GetViewFrame()->GetObjectShell();
- SFX_APP()->NotifyEvent(SfxEventHint(SW_EVENT_MAIL_MERGE, SwDocShell::GetEventName(STR_SW_EVENT_MAIL_MERGE), xDocShell));
+ SfxGetpApp()->NotifyEvent(SfxEventHint(SW_EVENT_MAIL_MERGE, SwDocShell::GetEventName(STR_SW_EVENT_MAIL_MERGE), xDocShell));
{
//copy rSh to aTempFile
OUString sTempURL;
@@ -2485,7 +2485,7 @@ void SwDBManager::ExecuteFormLetter( SwWrtShell& rSh,
//remove the temporary file
SWUnoHelper::UCB_DeleteFile( sTempURL );
}
- SFX_APP()->NotifyEvent(SfxEventHint(SW_EVENT_MAIL_MERGE_END, SwDocShell::GetEventName(STR_SW_EVENT_MAIL_MERGE_END), rSh.GetView().GetViewFrame()->GetObjectShell()));
+ SfxGetpApp()->NotifyEvent(SfxEventHint(SW_EVENT_MAIL_MERGE_END, SwDocShell::GetEventName(STR_SW_EVENT_MAIL_MERGE_END), rSh.GetView().GetViewFrame()->GetObjectShell()));
// reset the cursor inside
xResSet = NULL;
@@ -2839,9 +2839,9 @@ sal_Int32 SwDBManager::MergeDocuments( SwMailMergeConfigItem& rMMConfig,
// create a layout
rWorkShell.CalcLayout();
rWorkShell.UnlockExpFlds();
- SFX_APP()->NotifyEvent(SfxEventHint(SW_EVENT_FIELD_MERGE, SwDocShell::GetEventName(STR_SW_EVENT_FIELD_MERGE), rWorkShell.GetView().GetViewFrame()->GetObjectShell()));
+ SfxGetpApp()->NotifyEvent(SfxEventHint(SW_EVENT_FIELD_MERGE, SwDocShell::GetEventName(STR_SW_EVENT_FIELD_MERGE), rWorkShell.GetView().GetViewFrame()->GetObjectShell()));
rWorkShell.SwViewShell::UpdateFlds();
- SFX_APP()->NotifyEvent(SfxEventHint(SW_EVENT_FIELD_MERGE_FINISHED, SwDocShell::GetEventName(STR_SW_EVENT_FIELD_MERGE_FINISHED), rWorkShell.GetView().GetViewFrame()->GetObjectShell()));
+ SfxGetpApp()->NotifyEvent(SfxEventHint(SW_EVENT_FIELD_MERGE_FINISHED, SwDocShell::GetEventName(STR_SW_EVENT_FIELD_MERGE_FINISHED), rWorkShell.GetView().GetViewFrame()->GetObjectShell()));
// strip invisible content and convert fields to text
rWorkShell.RemoveInvisibleContent();
diff --git a/sw/source/uibase/shells/textsh1.cxx b/sw/source/uibase/shells/textsh1.cxx
index c9d6244bdb1b..90fcfb083525 100644
--- a/sw/source/uibase/shells/textsh1.cxx
+++ b/sw/source/uibase/shells/textsh1.cxx
@@ -1227,7 +1227,7 @@ void SwTextShell::Execute(SfxRequest &rReq)
case SID_RUBY_DIALOG:
case SID_HYPERLINK_DIALOG:
{
- SfxRequest aReq(nSlot, SFX_CALLMODE_SLOT, SFX_APP()->GetPool());
+ SfxRequest aReq(nSlot, SFX_CALLMODE_SLOT, SfxGetpApp()->GetPool());
GetView().GetViewFrame()->ExecuteSlot( aReq);
rReq.Ignore();
}
diff --git a/sw/source/uibase/uiview/view2.cxx b/sw/source/uibase/uiview/view2.cxx
index 372187827496..1baf8fe0ef5d 100644
--- a/sw/source/uibase/uiview/view2.cxx
+++ b/sw/source/uibase/uiview/view2.cxx
@@ -1335,7 +1335,7 @@ void SwView::StateStatusLine(SfxItemSet &rSet)
if (m_nPageCnt != nCnt) // notify Basic
{
m_nPageCnt = nCnt;
- SFX_APP()->NotifyEvent(SfxEventHint(SW_EVENT_PAGE_COUNT, SwDocShell::GetEventName(STR_SW_EVENT_PAGE_COUNT), GetViewFrame()->GetObjectShell()), false);
+ SfxGetpApp()->NotifyEvent(SfxEventHint(SW_EVENT_PAGE_COUNT, SwDocShell::GetEventName(STR_SW_EVENT_PAGE_COUNT), GetViewFrame()->GetObjectShell()), false);
}
}
break;
@@ -2418,7 +2418,7 @@ void SwView::GenerateFormLetter(bool bUseCurrentDocument)
else
{
// call documents and template dialog
- SfxApplication* pSfxApp = SFX_APP();
+ SfxApplication* pSfxApp = SfxGetpApp();
Window* pTopWin = pSfxApp->GetTopWindow();
boost::scoped_ptr<SvtDocumentTemplateDialog> pDocTemplDlg(new SvtDocumentTemplateDialog( pTopWin ));
pDocTemplDlg->SelectTemplateFolder();
diff --git a/sw/source/uibase/uno/unomailmerge.cxx b/sw/source/uibase/uno/unomailmerge.cxx
index 4d670c7c8b93..5f5410269598 100644
--- a/sw/source/uibase/uno/unomailmerge.cxx
+++ b/sw/source/uibase/uno/unomailmerge.cxx
@@ -791,9 +791,9 @@ uno::Any SAL_CALL SwXMailMerge::execute(
OSL_ENSURE( !pOldSrc || pOldSrc == this, "Ooops... different event source already set." );
pMgr->SetMailMergeEvtSrc( this ); // launch events for listeners
- SFX_APP()->NotifyEvent(SfxEventHint(SW_EVENT_MAIL_MERGE, SwDocShell::GetEventName(STR_SW_EVENT_MAIL_MERGE), xCurDocSh));
+ SfxGetpApp()->NotifyEvent(SfxEventHint(SW_EVENT_MAIL_MERGE, SwDocShell::GetEventName(STR_SW_EVENT_MAIL_MERGE), xCurDocSh));
bool bSucc = pMgr->MergeNew( aMergeDesc );
- SFX_APP()->NotifyEvent(SfxEventHint(SW_EVENT_MAIL_MERGE_END, SwDocShell::GetEventName(STR_SW_EVENT_MAIL_MERGE_END), xCurDocSh));
+ SfxGetpApp()->NotifyEvent(SfxEventHint(SW_EVENT_MAIL_MERGE_END, SwDocShell::GetEventName(STR_SW_EVENT_MAIL_MERGE_END), xCurDocSh));
pMgr->SetMailMergeEvtSrc( pOldSrc );
diff --git a/sw/source/uibase/utlui/navipi.cxx b/sw/source/uibase/utlui/navipi.cxx
index b9e50d72c2d0..f20fc03205ab 100644
--- a/sw/source/uibase/utlui/navipi.cxx
+++ b/sw/source/uibase/utlui/navipi.cxx
@@ -811,7 +811,7 @@ SwNavigationPI::SwNavigationPI( SfxBindings* _pBindings,
aContentTree.SetFont(aFont);
aGlobalTree.SetFont(aFont);
- StartListening(*SFX_APP());
+ StartListening(*SfxGetpApp());
if ( pCreateView )
StartListening(*pCreateView);
SfxImageManager* pImgMan = SfxImageManager::GetImageManager( SW_MOD() );
@@ -861,7 +861,7 @@ SwNavigationPI::~SwNavigationPI()
pView->GetDocShell()->SetReadOnlyUI(false);
}
- EndListening(*SFX_APP());
+ EndListening(*SfxGetpApp());
SfxImageManager* pImgMan = SfxImageManager::GetImageManager( SW_MOD() );
pImgMan->ReleaseToolBox(&aContentToolBox);
diff --git a/uui/source/iahndl.cxx b/uui/source/iahndl.cxx
index de4e70c74563..89a45d2d6a07 100644
--- a/uui/source/iahndl.cxx
+++ b/uui/source/iahndl.cxx
@@ -1275,7 +1275,7 @@ UUIInteractionHelper::handleFutureDocumentVersionUpdateRequest(
static bool s_bDeferredToNextSession = false;
// TODO: this static variable is somewhat hacky. Formerly (before the dialog was moved from SFX2 to the
- // interaction handler implementation), this was stored in SFX_APP()'s impl structure, in member
+ // interaction handler implementation), this was stored in SfxGetpApp()'s impl structure, in member
// bODFVersionWarningLater. Of course, we do not have access to it here.
// A proper solution which I would envision would be:
diff --git a/vbahelper/source/vbahelper/vbahelper.cxx b/vbahelper/source/vbahelper/vbahelper.cxx
index 6ab7dba455ac..828bd6c45f65 100644
--- a/vbahelper/source/vbahelper/vbahelper.cxx
+++ b/vbahelper/source/vbahelper/vbahelper.cxx
@@ -188,7 +188,7 @@ uno::Reference< frame::XModel >
getCurrentDoc( const OUString& sKey ) throw (uno::RuntimeException)
{
uno::Reference< frame::XModel > xModel;
- SbxObject* pBasic = dynamic_cast< SbxObject* > ( SFX_APP()->GetBasic() );
+ SbxObject* pBasic = dynamic_cast< SbxObject* > ( SfxGetpApp()->GetBasic() );
SbxObject* basicChosen = pBasic ;
if ( basicChosen == NULL)
{
@@ -372,7 +372,7 @@ void PrintOutHelper( SfxViewShell* pViewShell, const uno::Any& From, const uno::
pViewFrame = pViewShell->GetViewFrame();
if ( pViewFrame )
{
- SfxAllItemSet aArgs( SFX_APP()->GetPool() );
+ SfxAllItemSet aArgs( SfxGetpApp()->GetPool() );
SfxBoolItem sfxCollate( SID_PRINT_COLLATE, bCollate );
aArgs.Put( sfxCollate, sfxCollate.Which() );