summaryrefslogtreecommitdiff
path: root/sfx2/source/appl
diff options
context:
space:
mode:
authorAndreas Schlüns <as@openoffice.org>2000-11-08 13:25:58 +0000
committerAndreas Schlüns <as@openoffice.org>2000-11-08 13:25:58 +0000
commit6e2bbea30437535ccbce34286f6ecfb11d1c3b44 (patch)
tree4cd92a84f93aa47f9bb8b73b0baa5e288285d463 /sfx2/source/appl
parent969bf33314f8c35f1d12b8ac727e0fc7a8e7352e (diff)
MUST obsolete soffice.ini / SfxIniManager ...
Diffstat (limited to 'sfx2/source/appl')
-rw-r--r--sfx2/source/appl/app.cxx121
-rw-r--r--sfx2/source/appl/appbas.cxx68
-rw-r--r--sfx2/source/appl/appcfg.cxx719
-rw-r--r--sfx2/source/appl/appdata.cxx8
-rw-r--r--sfx2/source/appl/appdde.cxx15
-rw-r--r--sfx2/source/appl/appinit.cxx49
-rw-r--r--sfx2/source/appl/appmain.cxx31
-rw-r--r--sfx2/source/appl/appmisc.cxx93
-rw-r--r--sfx2/source/appl/appopen.cxx39
-rw-r--r--sfx2/source/appl/appquit.cxx8
-rw-r--r--sfx2/source/appl/appreg.cxx8
-rw-r--r--sfx2/source/appl/appserv.cxx25
-rw-r--r--sfx2/source/appl/appuno.cxx20
-rw-r--r--sfx2/source/appl/childwin.cxx28
-rw-r--r--sfx2/source/appl/sfxhelp.cxx25
15 files changed, 1198 insertions, 59 deletions
diff --git a/sfx2/source/appl/app.cxx b/sfx2/source/appl/app.cxx
index 870282a5ba..d4476f51f2 100644
--- a/sfx2/source/appl/app.cxx
+++ b/sfx2/source/appl/app.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: app.cxx,v $
*
- * $Revision: 1.11 $
+ * $Revision: 1.12 $
*
- * last change: $Author: mba $ $Date: 2000-10-26 16:01:05 $
+ * last change: $Author: as $ $Date: 2000-11-08 14:25:41 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -213,6 +213,9 @@
#include <svtools/saveopt.hxx>
#include <svtools/undoopt.hxx>
#include <svtools/helpopt.hxx>
+#include <svtools/menuoptions.hxx>
+#include <svtools/pathoptions.hxx>
+#include <svtools/workingsetoptions.hxx>
// Static member
SfxApplication* SfxApplication::pApp = NULL;
@@ -257,7 +260,9 @@ SfxApplication::SfxApplication()
, pAppDispat( 0 )
, bDispatcherLocked( sal_False )
, pResMgr( 0 )
+#ifdef ENABLE_INIMANAGER//MUSTINI
, pAppIniMgr( 0 )
+#endif
, pCfgMgr( 0 )
, pSlotPool( 0 )
, pInterfaces( 0 )
@@ -287,10 +292,15 @@ SfxApplication::SfxApplication()
pImp->pSimpleResManager = 0;
pImp->nWarnLevel = 0;
pImp->pAutoSaveTimer = 0;
+#ifdef ENABLE_INIMANAGER//MUSTINI
pAppIniMgr = CreateIniManager();
pAppData_Impl = new SfxAppData_Impl( this );
pAppData_Impl->StartListening( *pAppIniMgr );
pAppData_Impl->UpdateApplicationSettings( pAppIniMgr->IsDontHideDisabledEntries() );
+#else
+ pAppData_Impl = new SfxAppData_Impl( this );
+ pAppData_Impl->UpdateApplicationSettings( SvtMenuOptions().IsEntryHidingEnabled() );
+#endif
pApp->PreInit();
pAppData_Impl->pSaveOptions = new SvtSaveOptions;
@@ -324,7 +334,9 @@ SfxApplication::~SfxApplication()
Broadcast( SfxSimpleHint(SFX_HINT_DYING) );
delete pImp;
delete pAppData_Impl;
+#ifdef ENABLE_INIMANAGER//MUSTINI
SfxIniManager::Close();
+#endif
utl::ConfigManager::RemoveConfigManager();
pApp = 0;
}
@@ -822,7 +834,11 @@ void SfxApplication::SetViewFrame( SfxViewFrame *pFrame )
if ( !pSh )
{
// Wenn es ein Dokument gibt, wird die BaseURL im Activate gesetzt
+#if SUPD<613//MUSTINI
INetURLObject aObject( GetIniManager()->Get( SFX_KEY_WORK_PATH ), INET_PROT_FILE );
+#else
+ INetURLObject aObject( SvtPathOptions().GetWorkPath(), INET_PROT_FILE );
+#endif
aObject.setFinalSlash();
INetURLObject::SetBaseURL( aObject.GetMainURL() );
}
@@ -1212,10 +1228,10 @@ sal_uInt16 SfxApplication::Exception( sal_uInt16 nError )
CntSystem::Flush();
#endif
+#if SUPD<613//MUSTINI
INetURLObject aSaveObj( pAppIniMgr->Get( SFX_KEY_BACKUP_PATH ), INET_PROT_FILE );
if ( Application::IsInExecute() )
{
- // save all modified documents and close all documents
SfxObjectShell *pIter, *pNext;
sal_uInt16 n = 0;
for(pIter = SfxObjectShell::GetFirst(); pIter; pIter = pNext)
@@ -1276,7 +1292,6 @@ sal_uInt16 SfxApplication::Exception( sal_uInt16 nError )
aEntry += DEFINE_CONST_UNICODE("title;"),
aEntry += aOldName;
}
-
pAppIniMgr->Set( aEntry, SFX_GROUP_WORKINGSET_IMPL, DEFINE_CONST_UNICODE("Recover"), n++ );
}
/*catch ( ::Exception & )
@@ -1284,7 +1299,6 @@ sal_uInt16 SfxApplication::Exception( sal_uInt16 nError )
}*/
}
}
-
pAppIniMgr->Flush();
if ( ( nError & EXC_MAJORTYPE ) != EXC_DISPLAY && ( nError & EXC_MAJORTYPE ) != EXC_REMOTE )
@@ -1295,7 +1309,100 @@ sal_uInt16 SfxApplication::Exception( sal_uInt16 nError )
}
else
pAppIniMgr->Flush();
+#else//MUSTINI
+ INetURLObject aSaveObj( SvtPathOptions().GetBackupPath(), INET_PROT_FILE );
+ // save all modified documents and close all documents
+ // Do it only, if it's allowed! Ask configuration for right flag.
+ if(
+ ( Application::IsInExecute() ) &&
+ ( pAppData_Impl->pSaveOptions->IsSaveWorkingSet() == sal_True )
+ )
+ {
+ SfxObjectShell *pIter, *pNext;
+ sal_uInt16 n = 0;
+ ::com::sun::star::uno::Sequence< ::rtl::OUString > seqWindowList;
+ for(pIter = SfxObjectShell::GetFirst(); pIter; pIter = pNext)
+ {
+ pNext = SfxObjectShell::GetNext(*pIter);
+ if( pIter->IsModified() && pIter->GetName().CompareToAscii("BasicIDE") != COMPARE_EQUAL && !pIter->IsLoading() )
+ {
+ //try
+ {
+ // backup unsaved document
+ SFX_ITEMSET_ARG( pIter->GetMedium()->GetItemSet(), pPassItem, SfxStringItem, SID_PASSWORD, sal_False );
+ SfxRequest aReq(SID_SAVEASDOC, SFX_CALLMODE_SYNCHRON, pIter->GetPool());
+
+ sal_Bool bHadName = pIter->HasName();
+ INetURLObject aOldURL = pIter->GetMedium()->GetURLObject();
+ String aOldName = pIter->GetTitle();
+
+ const SfxFilter *pFilter = pIter->GetMedium()->GetFilter();
+ const SfxFilter *pOrigFilter = pFilter;
+ if ( !pFilter || ( pFilter->GetFilterFlags() & SFX_FILTER_PACKED ) || !( pFilter->GetFilterFlags() & SFX_FILTER_EXPORT ) )
+ // packed files must be saved with default format, but remember original filter !
+ pFilter = pIter->GetFactory().GetFilter(0);
+ String aSaveName, aSavePath = aSaveObj.GetMainURL();
+ String aFilterName;
+ if ( pFilter )
+ {
+ aFilterName = pFilter->GetName();
+ TempFile aTempFile( &aSavePath );
+ aSaveName = aTempFile.GetName();
+ }
+ else
+ {
+ String aExt( DEFINE_CONST_UNICODE( ".sav" ) );
+ TempFile aTempFile( DEFINE_CONST_UNICODE( "exc" ), &aExt, &aSavePath );
+ aSaveName = aTempFile.GetName();
+ }
+
+ aReq.AppendItem( SfxStringItem( SID_FILE_NAME, aSaveName ) );
+ aReq.AppendItem( SfxStringItem( SID_FILTER_NAME, aFilterName ) );
+ if ( pPassItem )
+ aReq.AppendItem( *pPassItem );
+
+ pIter->ExecuteSlot(aReq);
+
+ String aEntry( n );
+ aEntry += aSaveName;
+ aEntry += DEFINE_CONST_UNICODE(";");
+ aEntry += pOrigFilter ? pOrigFilter->GetName() : aFilterName;
+ aEntry += DEFINE_CONST_UNICODE(";");
+
+ if ( bHadName && INET_PROT_FILE == aOldURL.GetProtocol() )
+ {
+ aEntry += DEFINE_CONST_UNICODE("url;"),
+ aEntry += aOldURL.GetMainURL();
+ }
+ else
+ {
+ aEntry += DEFINE_CONST_UNICODE("title;"),
+ aEntry += aOldName;
+ }
+
+ seqWindowList.realloc(n+1);
+ seqWindowList[n] = aEntry;
+ ++n;
+ }
+ /*catch ( ::Exception & )
+ {
+ }*/
+ }
+ }
+
+ SvtWorkingSetOptions().SetWindowList( seqWindowList );
+
+ if ( ( nError & EXC_MAJORTYPE ) != EXC_DISPLAY && ( nError & EXC_MAJORTYPE ) != EXC_REMOTE )
+ {
+ Window *pTopWindow = GetTopWindow(); // GCC needs temporary
+ WarningBox( pTopWindow, SfxResId(STR_RECOVER_PREPARED) ).Execute();
+ }
+ }
+#endif//MUSTINI
+
+#if SUPD<613//MUSTINI
+/*TODO: We need a new key to save informations for SenCrashMail feature.*/
sal_Bool bSendMail = (sal_uInt16) pAppIniMgr->ReadKey( DEFINE_CONST_UNICODE("Common"), DEFINE_CONST_UNICODE("SendCrashMail") ).ToInt32();
if ( !pAppData_Impl->bBean && bSendMail )
{
@@ -1351,7 +1458,7 @@ sal_uInt16 SfxApplication::Exception( sal_uInt16 nError )
pAppIniMgr->Flush();
}
}
-
+#endif//MUSTINI
switch( nError & EXC_MAJORTYPE )
{
case EXC_USER:
@@ -1376,8 +1483,6 @@ sal_uInt16 SfxApplication::Exception( sal_uInt16 nError )
ResMgr* SfxApplication::CreateResManager( const char *pPrefix )
{
- DBG_ASSERT( pAppIniMgr, "call CreateIniManger() before!" )
-
String aMgrName = String::CreateFromAscii( pPrefix );
aMgrName += String::CreateFromInt32(SOLARUPD); // aktuelle Versionsnummer
return ResMgr::CreateResMgr(U2S(aMgrName));
diff --git a/sfx2/source/appl/appbas.cxx b/sfx2/source/appl/appbas.cxx
index b2c3bba6df..6f52a23821 100644
--- a/sfx2/source/appl/appbas.cxx
+++ b/sfx2/source/appl/appbas.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: appbas.cxx,v $
*
- * $Revision: 1.5 $
+ * $Revision: 1.6 $
*
- * last change: $Author: mba $ $Date: 2000-10-23 12:23:17 $
+ * last change: $Author: as $ $Date: 2000-11-08 14:25:41 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -108,9 +108,11 @@
#ifndef _SB_SBSTAR_HXX //autogen
#include <basic/sbstar.hxx>
#endif
+#if SUPD<613//MUSTINI
#ifndef _SFXINIMGR_HXX //autogen
#include <svtools/iniman.hxx>
#endif
+#endif
#ifndef _SVSTOR_HXX //autogen
#include <so3/svstor.hxx>
#endif
@@ -137,6 +139,8 @@
#endif
#include <svtools/undoopt.hxx>
+#include <svtools/pathoptions.hxx>
+#include <svtools/useroptions.hxx>
#pragma hdrstop
@@ -528,7 +532,11 @@ sal_uInt16 SfxApplication::SaveBasicManager() const
// Ncht den vom BasicManager, falls inzwischen der Pfad geaendert wurde !?
// So wird natuerlich auch das erste Dir genommen, wenn der BasicManager
// vorher im zweiten gefunden wurde...
+/*MUSTINI-----------------------------------------------------------------------------
String aBasicPath( GetIniManager()->Get( SFX_KEY_BASIC_PATH ) );
+*/
+ String aBasicPath( SvtPathOptions().GetBasicPath() );
+/*MUSTINI-----------------------------------------------------------------------------*/
INetURLObject aAppBasicObj( aBasicPath.GetToken(0), INET_PROT_FILE );
aAppBasicObj.insertName( Application::GetAppName() );
aAppBasicObj.setExtension( DEFINE_CONST_UNICODE( "sbl" ) );
@@ -617,13 +625,22 @@ BasicManager* SfxApplication::GetBasicManager()
if ( !pImp->pBasicMgr )
{
// Directory bestimmen
- SfxIniManager* pIniMgr = GetIniManager();
+#if SUPD<613//MUSTINI
+ SfxIniManager* pIniMgr = GetIniManager();
String aAppBasicDir( pIniMgr->Get( SFX_KEY_BASIC_PATH ) );
if ( !aAppBasicDir.Len() )
{
aAppBasicDir = pIniMgr->GetProgramPath();
pIniMgr->Set( aAppBasicDir, SFX_KEY_BASIC_PATH );
}
+#else
+ SvtPathOptions aPathCFG;
+ String aAppBasicDir( aPathCFG.GetBasicPath() );
+ if ( !aAppBasicDir.Len() )
+ {
+ aPathCFG.SetBasicPath( aPathCFG.SubstituteVariable( String::CreateFromAscii("$(insturl)") ) );
+ }
+#endif
// #58293# soffice.new nur im ::com::sun::star::sdbcx::User-Dir suchen => erstes Verzeichnis
String aAppFirstBasicDir = aAppBasicDir.GetToken(0);
@@ -896,8 +913,9 @@ void SfxApplication::EventState_Impl
//-------------------------------------------------------------------------
void SfxApplication::PropExec_Impl( SfxRequest &rReq )
{
+#if SUPD<613//MUSTINI
SfxIniManager *pIniMgr = GetIniManager();
-
+#endif
const SfxItemSet *pArgs = rReq.GetArgs();
sal_uInt16 nSID = rReq.GetSlot();
switch ( nSID )
@@ -934,7 +952,11 @@ void SfxApplication::PropExec_Impl( SfxRequest &rReq )
case SID_DEFAULTFILEPATH:
{
SFX_REQUEST_ARG(rReq, pPathItem, SfxStringItem, nSID, sal_False);
+#if SUPD<613//MUSTINI
pIniMgr->Set(pPathItem->GetValue(), SFX_KEY_WORK_PATH );
+#else
+ SvtPathOptions().SetWorkPath( pPathItem->GetValue() );
+#endif
break;
}
@@ -1016,6 +1038,7 @@ void SfxApplication::PropExec_Impl( SfxRequest &rReq )
break;
}
+#if SUPD<613//MUSTINI
case SID_OFFICE_PRIVATE_USE:
case SID_OFFICE_COMMERCIAL_USE:
{
@@ -1035,14 +1058,25 @@ void SfxApplication::PropExec_Impl( SfxRequest &rReq )
}
break;
}
-
+#else
+ case SID_OFFICE_PRIVATE_USE:
+ case SID_OFFICE_COMMERCIAL_USE:
+ {
+ DBG_ASSERT( sal_False, "SfxApplication::PropExec_Impl()\nSID_OFFICE_PRIVATE_USE & SID_OFFICE_COMMERCIAL_USE are obsolete!\n" );
+ break;
+ }
+#endif
case SID_OFFICE_CUSTOMERNUMBER:
{
SFX_REQUEST_ARG(rReq, pStringItem, SfxStringItem, nSID, sal_False);
if ( pStringItem )
+#if SUPD<613//MUSTINI
pIniMgr->Set( pStringItem->GetValue(),
SFX_KEY_CUSTOMERNUMBER );
+#else
+ SvtUserOptions().SetCustomerNumber( pStringItem->GetValue() );
+#endif
break;
}
}
@@ -1052,8 +1086,9 @@ void SfxApplication::PropExec_Impl( SfxRequest &rReq )
void SfxApplication::PropState_Impl( SfxItemSet &rSet )
{
SfxViewFrame *pFrame = SfxViewFrame::Current();
+#if SUPD<613//MUSTINI
SfxIniManager *pIniMgr = GetIniManager();
-
+#endif
SfxWhichIter aIter(rSet);
for ( sal_uInt16 nSID = aIter.FirstWhich(); nSID; nSID = aIter.NextWhich() )
{
@@ -1134,7 +1169,11 @@ void SfxApplication::PropState_Impl( SfxItemSet &rSet )
break;
case SID_DEFAULTFILEPATH:
+#if SUPD<613//MUSTINI
rSet.Put( SfxStringItem( SID_DEFAULTFILEPATH, pIniMgr->Get(SFX_KEY_WORK_PATH) ) );
+#else
+ rSet.Put( SfxStringItem( SID_DEFAULTFILEPATH, SvtPathOptions().GetWorkPath() ) );
+#endif
break;
case SID_PROGFILENAME:
@@ -1142,7 +1181,11 @@ void SfxApplication::PropState_Impl( SfxItemSet &rSet )
break;
case SID_PROGPATH:
+#if SUPD<613//MUSTINI
rSet.Put( SfxStringItem( SID_PROGPATH, pIniMgr->GetProgramPath() ) );
+#else
+ rSet.Put( SfxStringItem( SID_PROGPATH, SvtPathOptions().SubstituteVariable( String::CreateFromAscii("$(prog)") ) ) );
+#endif
break;
case SID_INTERACTIVEMODE:
@@ -1262,6 +1305,7 @@ void SfxApplication::PropState_Impl( SfxItemSet &rSet )
}
break;
+#if SUPD<613//MUSTINI
case SID_OFFICE_PRIVATE_USE:
case SID_OFFICE_COMMERCIAL_USE:
{
@@ -1275,11 +1319,23 @@ void SfxApplication::PropState_Impl( SfxItemSet &rSet )
rSet.Put( SfxStringItem( nSID, aRet ) );
break;
}
+#else
+ case SID_OFFICE_PRIVATE_USE:
+ case SID_OFFICE_COMMERCIAL_USE:
+ {
+ DBG_ASSERT( sal_False, "SfxApplication::PropState_Impl()\nSID_OFFICE_PRIVATE_USE & SID_OFFICE_COMMERCIAL_USE are obsolete!\n" );
+ break;
+ }
+#endif
case SID_OFFICE_CUSTOMERNUMBER:
{
+#if SUPD<613//MUSTINI
String aCustomerNumber = pIniMgr->Get(SFX_KEY_CUSTOMERNUMBER);
rSet.Put( SfxStringItem( nSID, aCustomerNumber ) );
+#else
+ rSet.Put( SfxStringItem( nSID, SvtUserOptions().GetCustomerNumber() ) );
+#endif
break;
}
}
diff --git a/sfx2/source/appl/appcfg.cxx b/sfx2/source/appl/appcfg.cxx
index 417e80e999..72d97adf7f 100644
--- a/sfx2/source/appl/appcfg.cxx
+++ b/sfx2/source/appl/appcfg.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: appcfg.cxx,v $
*
- * $Revision: 1.4 $
+ * $Revision: 1.5 $
*
- * last change: $Author: pb $ $Date: 2000-11-03 05:08:36 $
+ * last change: $Author: as $ $Date: 2000-11-08 14:25:41 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -76,9 +76,11 @@
#ifndef _SFXITEMPOOL_HXX //autogen
#include <svtools/itempool.hxx>
#endif
+#if SUPD<613//MUSTINI
#ifndef _SFXINIMGR_HXX //autogen
#include <svtools/iniman.hxx>
#endif
+#endif
#ifndef _AEITEM_HXX //autogen
#include <svtools/aeitem.hxx>
#endif
@@ -100,10 +102,11 @@
#ifndef _UNDO_HXX //autogen
#include <svtools/undo.hxx>
#endif
+#if SUPD<613//MUSTINI
#ifndef _SFXINIPROP_HXX
#include <svtools/iniprop.hxx>
#endif
-
+#endif
#ifndef _INET_WRAPPER_HXX
#include <inet/wrapper.hxx>
#endif
@@ -138,6 +141,9 @@
#include <svtools/saveopt.hxx>
#include <svtools/helpopt.hxx>
#include <svtools/undoopt.hxx>
+#include <svtools/securityoptions.hxx>
+#include <svtools/pathoptions.hxx>
+#include <svtools/inetoptions.hxx>
#include "viewfrm.hxx"
#include "sfxhelp.hxx"
@@ -194,6 +200,7 @@ const USHORT* SfxApplication::GetOptionsRanges() const
}
// -----------------------------------------------------------------------
+#if SUPD<613//MUSTINI
String GetJavaIniEntry_Impl( SfxIniKey eKey, SfxIniManager* pIniMgr )
{
@@ -238,12 +245,59 @@ BOOL SetJavaIniEntry_Impl( SfxIniKey eKey, const String& rValue, SfxIniManager*
return TRUE;
}
+#else
+
+// -----------------------------------------------------------------------
+
+String GetJavaIniEntry_Impl( const String& sKeyName )
+{
+ INetURLObject aObj;
+ aObj.SetSmartProtocol( INET_PROT_FILE );
+ aObj.SetSmartURL( Config::GetConfigName( SvtPathOptions().GetUserConfigPath(), DEFINE_CONST_UNICODE("java") ) );
+ String aIniEntry;
+ String aIniPath = aObj.getName();
+
+ Config aJavaCfg( aIniPath );
+ aJavaCfg.SetGroup( "Java" );
+ aIniEntry = (String)S2U(aJavaCfg.ReadKey( U2S(sKeyName) ));
+
+ return aIniEntry;
+}
+
+// -----------------------------------------------------------------------
+
+BOOL SetJavaIniEntry_Impl( const String& sKeyName, const String& sValue )
+{
+ SvtPathOptions aPathOptions;
+ String aIniFile = Config::GetConfigName( aPathOptions.GetUserConfigPath(), DEFINE_CONST_UNICODE("java") );
+ if ( !SfxContentHelper::Exists( aIniFile ) )
+ {
+ INetURLObject aObj( aIniFile, INET_PROT_FILE );
+ String aIniFileName = aObj.getName();
+ aObj.SetSmartURL( aPathOptions.GetConfigPath() );
+ aObj.insertName( aIniFileName );
+ String aShareFile = aObj.PathToFileName();
+
+ if ( !SfxContentHelper::Exists( aShareFile ) ||
+ !SfxContentHelper::CopyTo( aShareFile, aIniFile ) )
+ return FALSE;
+ }
+ Config aJavaCfg( aIniFile );
+ aJavaCfg.SetGroup( "Java" );
+ aJavaCfg.WriteKey( U2S(sKeyName), U2S(sValue) );
+ return TRUE;
+}
+
+#endif
+
//--------------------------------------------------------------------
BOOL SfxApplication::GetOptions( SfxItemSet& rSet )
{
BOOL bRet = FALSE;
+#if SUPD<613//MUSTINI
SfxIniManager *pIni = GetIniManager();
+#endif
SfxItemPool &rPool = GetPool();
SfxToolBoxConfig *pTbxCfg = SfxToolBoxConfig::GetOrCreate();
String aTRUEStr = 0x0031; // ^= '1'
@@ -252,6 +306,8 @@ BOOL SfxApplication::GetOptions( SfxItemSet& rSet )
SvtSaveOptions aSaveOptions;
SvtUndoOptions aUndoOptions;
SvtHelpOptions aHelpOptions;
+ SvtInetOptions aInetOptions;
+ SvtSecurityOptions aSecurityOptions;
while ( *pRanges )
{
for(USHORT nWhich = *pRanges++; nWhich <= *pRanges; ++nWhich)
@@ -358,6 +414,7 @@ BOOL SfxApplication::GetOptions( SfxItemSet& rSet )
aUndoOptions.GetUndoCount() ) ) )
bRet = TRUE;
break;
+#if SUPD<613//MUSTINI
case SID_INET_HOMEPAGE :
if(rSet.Put( SfxStringItem ( rPool.GetWhich( SID_INET_HOMEPAGE ),
pIni->Get(SFX_KEY_INET_HOME) ) ) )
@@ -393,9 +450,26 @@ BOOL SfxApplication::GetOptions( SfxItemSet& rSet )
pIni->Get(SFX_KEY_INET_CACHEABORTED).ToInt32() ) ) )
bRet = TRUE;
break;
+#else
+ case SID_INET_HOMEPAGE :
+ case SID_INET_MEMCACHE :
+ case SID_INET_DISKCACHE :
+ case SID_INET_EXPIRATION :
+ case SID_INET_CACHEJS :
+ case SID_INET_CACHEEXPIRED :
+ case SID_INET_CACHEABORTED :
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ DBG_ASSERT( sal_False, "SfxApplication::GetOptions()\nSome INET values not no longer supported!\n" );
+#endif
+ break;
+#endif
case SID_INET_REVEAL_MAILADDR :
if(rSet.Put( SfxBoolItem ( rPool.GetWhich( SID_INET_REVEAL_MAILADDR),
+#if SUPD<613//MUSTINI
(BOOL)(USHORT)pIni->Get(SFX_KEY_INET_REVEAL_MAILADDR).ToInt32() ) ) )
+#else
+ aInetOptions.GetProtocolRevealMailAddress() ) ) )
+#endif
bRet = TRUE;
break;
case SID_SAVEREL_INET :
@@ -410,9 +484,14 @@ BOOL SfxApplication::GetOptions( SfxItemSet& rSet )
break;
case SID_INET_SMTPSERVER :
if(rSet.Put( SfxStringItem ( rPool.GetWhich( SID_INET_SMTPSERVER),
+#if SUPD<613//MUSTINI
pIni->Get(SFX_KEY_INET_SMTPSERVER) ) ) )
+#else
+ aInetOptions.GetSmtpServerName() )))
+#endif
bRet = TRUE;
break;
+#if SUPD<613//MUSTINI
case SID_INET_POPSERVER :
if(rSet.Put( SfxStringItem ( rPool.GetWhich( SID_INET_POPSERVER),
pIni->Get(SFX_KEY_INET_POPSERVER) ) ) )
@@ -448,11 +527,31 @@ BOOL SfxApplication::GetOptions( SfxItemSet& rSet )
pIni->Get(SFX_KEY_INET_MAILUSERNAME) ) ) )
bRet = TRUE;
break;
+#else
+ case SID_INET_POPSERVER :
+ case SID_INET_NNTPSERVER :
+ case SID_INET_MAXNEWS :
+ case SID_INET_MAXHTTPCONS :
+ case SID_INET_MAXFTPCONS :
+ case SID_INET_SMTPGATEWAY :
+ case SID_INET_MAILUSERNAME :
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ DBG_ASSERT( sal_False, "SfxApplication::GetOptions()\nSome INET values not longer supported!\n" );
+#endif
+ break;
+#endif
case SID_ATTR_ALLOWFOLDERWEBVIEW :
+#if SUPD<613//MUSTINI
if(rSet.Put( SfxStringItem( rPool.GetWhich(SID_ATTR_ALLOWFOLDERWEBVIEW),
pIni->Get(SFX_KEY_ALLOWFOLDERWEBVIEW) ) ) )
bRet = TRUE;
+#else
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ DBG_ASSERT(sal_False,"SfxApplication::GetOptions()\nINI-Key \"Common\\AllowFolderWebView\" is obsolete ... SID_ATTR_ALLOWFOLDERWEBVIEW isn't supported any longer!\n");
+#endif
+#endif
break;
+#if SUPD<613//MUSTINI
case SID_INET_MAILPASSWORD :
if(rSet.Put( SfxStringItem ( rPool.GetWhich( SID_INET_MAILPASSWORD),
SfxStringDecode( pIni->Get(SFX_KEY_INET_MAILPASSWORD) ) ) ) )
@@ -467,15 +566,30 @@ BOOL SfxApplication::GetOptions( SfxItemSet& rSet )
bRet = TRUE;
break;
}
+#else
+ case SID_INET_MAILPASSWORD :
+ case SID_INET_MAILTEXTFORMAT :
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ DBG_ASSERT( sal_False, "SfxApplication::GetOptions()\nConfig item for INET values not implemented yet!\n" );
+#endif
+ break;
+#endif
case SID_BASIC_ENABLED :
if ( rSet.Put( SfxUInt16Item( rPool.GetWhich( SID_BASIC_ENABLED ),
+#if SUPD<613//MUSTINI
pIni->Get(SFX_KEY_BASIC_ENABLE).ToInt32()) ) )
+#else
+ aSecurityOptions.GetBasicMode())))
+#endif
bRet = TRUE;
break;
-
case SID_INET_JAVA_ENABLE:
{
+#if SUPD<613//MUSTINI
String aIniEntry = GetJavaIniEntry_Impl( SFX_KEY_JAVA_ENABLE, pIni );
+#else
+ String aIniEntry = GetJavaIniEntry_Impl( DEFINE_CONST_UNICODE("Java") );
+#endif
if ( rSet.Put( SfxBoolItem(
rPool.GetWhich( SID_INET_JAVA_ENABLE ), ( aIniEntry == aTRUEStr ) ) ) )
bRet = TRUE;
@@ -484,7 +598,11 @@ BOOL SfxApplication::GetOptions( SfxItemSet& rSet )
case SID_INET_EXE_APPLETS :
{
+#if SUPD<613//MUSTINI
String aIniEntry = GetJavaIniEntry_Impl( SFX_KEY_INET_EXE_APPLETS, pIni );
+#else
+ String aIniEntry = GetJavaIniEntry_Impl( DEFINE_CONST_UNICODE("Applets") );
+#endif
if ( rSet.Put( SfxBoolItem(
rPool.GetWhich( SID_INET_EXE_APPLETS ), ( aIniEntry == aTRUEStr ) ) ) )
bRet = TRUE;
@@ -493,7 +611,11 @@ BOOL SfxApplication::GetOptions( SfxItemSet& rSet )
case SID_INET_JAVA_ACCESSTYPE:
{
SjNetAccess eAccess = NET_HOST;
+#if SUPD<613//MUSTINI
String aNetAccess = GetJavaIniEntry_Impl( SFX_KEY_JAVA_NETACCESS, pIni );
+#else
+ String aNetAccess = GetJavaIniEntry_Impl( DEFINE_CONST_UNICODE("NetAccess") );
+#endif
if ( aNetAccess.Len() )
{
if ( aNetAccess.CompareIgnoreCaseToAscii( "UNRESTRICTED" ) == COMPARE_EQUAL )
@@ -508,7 +630,11 @@ BOOL SfxApplication::GetOptions( SfxItemSet& rSet )
}
case SID_INET_JAVA_SECURITY:
{
+#if SUPD<613//MUSTINI
String aIniEntry = GetJavaIniEntry_Impl( SFX_KEY_JAVA_SECURITY, pIni );
+#else
+ String aIniEntry = GetJavaIniEntry_Impl( DEFINE_CONST_UNICODE("Security") );
+#endif
if ( rSet.Put( SfxBoolItem(
rPool.GetWhich( SID_INET_JAVA_SECURITY ), ( aIniEntry.CompareToAscii("0") != COMPARE_EQUAL ) ) ) )
bRet = TRUE;
@@ -516,12 +642,17 @@ BOOL SfxApplication::GetOptions( SfxItemSet& rSet )
}
case SID_INET_JAVA_CLASSPATH :
{
+#if SUPD<613//MUSTINI
String aIniEntry = GetJavaIniEntry_Impl( SFX_KEY_JAVA_USERCLASSPATH, pIni );
+#else
+ String aIniEntry = GetJavaIniEntry_Impl( DEFINE_CONST_UNICODE("UserClassPath") );
+#endif
if ( rSet.Put( SfxStringItem( rPool.GetWhich( SID_INET_JAVA_CLASSPATH ), aIniEntry ) ) )
bRet = TRUE;
break;
}
+#if SUPD<613//MUSTINI
case SID_INET_EXE_PLUGIN :
if ( rSet.Put( SfxBoolItem( rPool.GetWhich( SID_INET_EXE_PLUGIN ),
( pIni->Get( SFX_KEY_INET_EXE_PLUGIN ) == aTRUEStr ) ) ) )
@@ -537,16 +668,34 @@ BOOL SfxApplication::GetOptions( SfxItemSet& rSet )
pIni->Get( SFX_KEY_INET_NONCACHED_SERVER ) ) ) )
bRet = TRUE;
break;
+#else
+ case SID_INET_EXE_PLUGIN :
+ case SID_INET_USERAGENT :
+ case SID_INET_NONCACHED_SERVER :
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ DBG_ASSERT( sal_False, "SfxApplication::GetOptions()\nSome INET values no longer supported!\n" );
+#endif
+ break;
+#endif
case SID_INET_DNS_SERVER :
if ( rSet.Put( SfxStringItem( rPool.GetWhich(SID_INET_DNS_SERVER),
+#if SUPD<613//MUSTINI
pIni->Get(SFX_KEY_INET_DNS ) ) ) )
+#else
+ aInetOptions.GetDnsIpAddress() ) ) )
+#endif
bRet = TRUE;
break;
case SID_INET_DNS_AUTO :
if ( rSet.Put( SfxBoolItem( rPool.GetWhich( SID_INET_DNS_AUTO ),
+#if SUPD<613//MUSTINI
!pIni->Get(SFX_KEY_INET_DNS).Len() ) ) )
+#else
+ !aInetOptions.GetDnsIpAddress().getLength() ) ) )
+#endif
bRet = TRUE;
break;
+#if SUPD<613//MUSTINI
case SID_INET_CHANNELS_ONOFF :
if ( rSet.Put( SfxBoolItem( rPool.GetWhich( SID_INET_CHANNELS_ONOFF ),
( pIni->Get( SFX_KEY_INET_CHANNELS ) == aTRUEStr ) ) ) )
@@ -557,8 +706,17 @@ BOOL SfxApplication::GetOptions( SfxItemSet& rSet )
pIni->Get(SFX_KEY_INET_COOKIES).ToInt32() ) ) )
bRet = TRUE;
break;
+#else
+ case SID_INET_CHANNELS_ONOFF :
+ case SID_INET_COOKIESHANDLE :
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ DBG_ASSERT( sal_False, "SfxApplication::GetOptions()\nSome INET values no longer supported!\n" );
+#endif
+ break;
+#endif
case SID_SECURE_URL :
{
+#if SUPD<613//MUSTINI
List aList;
USHORT nCount = pIni->Get( SFX_KEY_SECURE_URL ).ToInt32();
USHORT n;
@@ -570,8 +728,29 @@ BOOL SfxApplication::GetOptions( SfxItemSet& rSet )
for ( n = 0; n < nCount; ++n )
delete (String*)aList.GetObject(n);
aList.Clear();
+#else
+ ::com::sun::star::uno::Sequence< ::rtl::OUString > seqURLs = aSecurityOptions.GetSecureURLs();
+ List aList;
+ sal_uInt32 nCount = seqURLs.getLength();
+ sal_uInt32 nURL;
+ for( nURL=0; nURL<nCount; ++nURL )
+ {
+ aList.Insert( new String( seqURLs[nURL] ), LIST_APPEND );
+ }
+ if( rSet.Put( SfxStringListItem( rPool.GetWhich(SID_SECURE_URL),
+ &aList ) ) )
+ {
+ bRet = TRUE;
+ }
+ for( nURL=0; nURL<nCount; ++nURL )
+ {
+ delete (String*)aList.GetObject(nURL);
+ }
+ aList.Clear();
+#endif
break;
}
+#if SUPD<613//MUSTINI
case SID_ICONGRID :
{
String aIconGrid( pIni->Get(SFX_KEY_ICONGRID) );
@@ -589,8 +768,17 @@ BOOL SfxApplication::GetOptions( SfxItemSet& rSet )
bRet = TRUE;
break;
}
+#else
+ case SID_ICONGRID :
+ case SID_AUTO_ADJUSTICONS :
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ DBG_ASSERT(sal_False, "SfxApplication::GetOptions()\nSoffice.ini key \"View\\IconGrid\" is obsolete! .. How I can support SID_ICONGRID & SID_AUTO_ADJUSTICONS any longer?\n");
+#endif
+ break;
+#endif
case SID_RESTORE_EXPAND_STATE :
{
+#if SUPD<613//MUSTINI
String aRestoreExpand( pIni->Get( SFX_KEY_AUTOOPEN ));
BOOL bRestoreExpand = TRUE;
if( aRestoreExpand.Len() )
@@ -598,48 +786,88 @@ BOOL SfxApplication::GetOptions( SfxItemSet& rSet )
if( rSet.Put( SfxBoolItem( rPool.GetWhich( SID_RESTORE_EXPAND_STATE ),
bRestoreExpand )))
bRet = TRUE;
+#else
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ DBG_ASSERT(sal_False, "SfxApplication::GetOptions()\nSoffice.ini key \"View\\AutoOpen\" is obsolete! .. How I can support SID_RESTORE_EXPAND_STATE any longer?\n");
+#endif
+#endif
break;
}
case SID_ENABLE_METAFILEPRINT :
+#if SUPD<613//MUSTINI
if( rSet.Put( SfxBoolItem( rPool.GetWhich( SID_ENABLE_METAFILEPRINT ),
(BOOL)(USHORT)pIni->Get(SFX_KEY_METAFILEPRINT ).ToInt32() ) ) )
bRet = TRUE;
+#else
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ DBG_ASSERT(sal_False, "SfxApplication::GetOptions()\nSoffice.ini key \"Common\\MetafilePrint\" is obsolete! .. How I can support SID_ENABLE_METAFILEPRINT any longer?\n");
+#endif
+#endif
break;
case SID_INET_PROXY_TYPE :
if(rSet.Put( SfxUInt16Item ( rPool.GetWhich( SID_INET_PROXY_TYPE ),
+#if SUPD<613//MUSTINI
pIni->Get(SFX_KEY_INET_PROXYTYPE).ToInt32() ) ) )
+#else
+ aInetOptions.GetProxyType() )))
+#endif
bRet = TRUE;
break;
case SID_INET_FTP_PROXY_NAME :
if ( rSet.Put( SfxStringItem ( rPool.GetWhich(SID_INET_FTP_PROXY_NAME ),
+#if SUPD<613//MUSTINI
pIni->Get(SFX_KEY_INET_FTPPROXYNAME) ) ) )
+#else
+ aInetOptions.GetProxyFtpName() )))
+#endif
bRet = TRUE;
break;
case SID_INET_FTP_PROXY_PORT :
if ( rSet.Put( SfxInt32Item ( rPool.GetWhich(SID_INET_FTP_PROXY_PORT ),
+#if SUPD<613//MUSTINI
pIni->Get(SFX_KEY_INET_FTPPROXYPORT).ToInt32() ) ) )
+#else
+ aInetOptions.GetProxyFtpPort() )))
+#endif
bRet = TRUE;
break;
case SID_INET_HTTP_PROXY_NAME :
if ( rSet.Put( SfxStringItem ( rPool.GetWhich(SID_INET_HTTP_PROXY_NAME ),
+#if SUPD<613//MUSTINI
pIni->Get(SFX_KEY_INET_HTTPPROXYNAME) ) ) )
+#else
+ aInetOptions.GetProxyHttpName() )))
+#endif
bRet = TRUE;
break;
case SID_INET_HTTP_PROXY_PORT :
if ( rSet.Put( SfxInt32Item( rPool.GetWhich(SID_INET_HTTP_PROXY_PORT ),
+#if SUPD<613//MUSTINI
pIni->Get(SFX_KEY_INET_HTTPPROXYPORT).ToInt32() ) ) )
+#else
+ aInetOptions.GetProxyHttpPort() )))
+#endif
bRet = TRUE;
break;
case SID_INET_SOCKS_PROXY_NAME :
if ( rSet.Put( SfxStringItem ( rPool.GetWhich(SID_INET_SOCKS_PROXY_NAME ),
+#if SUPD<613//MUSTINI
pIni->Get(SFX_KEY_INET_SOCKSPROXYNAME) ) ) )
+#else
+ aInetOptions.GetProxySocksName() )))
+#endif
bRet = TRUE;
break;
case SID_INET_SOCKS_PROXY_PORT :
if ( rSet.Put( SfxInt32Item( rPool.GetWhich(SID_INET_SOCKS_PROXY_PORT ),
+#if SUPD<613//MUSTINI
pIni->Get(SFX_KEY_INET_SOCKSPROXYPORT).ToInt32() ) ) )
+#else
+ aInetOptions.GetProxySocksPort() )))
+#endif
bRet = TRUE;
break;
+#if SUPD<613//MUSTINI
case SID_INET_SECURITY_PROXY_NAME :
if ( rSet.Put( SfxStringItem ( rPool.GetWhich(SID_INET_SECURITY_PROXY_NAME ),
pIni->Get(SFX_KEY_INET_SECURITYPROXYNAME) ) ) )
@@ -650,9 +878,21 @@ BOOL SfxApplication::GetOptions( SfxItemSet& rSet )
pIni->Get(SFX_KEY_INET_SECURITYPROXYPORT).ToInt32() ) ) )
bRet = TRUE;
break;
+#else
+ case SID_INET_SECURITY_PROXY_NAME :
+ case SID_INET_SECURITY_PROXY_PORT :
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ DBG_ASSERT( sal_False, "SfxApplication::GetOptions()\nSome INET values no longer supported!\n" );
+#endif
+ break;
+#endif
case SID_INET_NOPROXY :
if(rSet.Put( SfxStringItem ( rPool.GetWhich( SID_INET_NOPROXY),
+#if SUPD<613//MUSTINI
pIni->Get(SFX_KEY_INET_NOPROXY) ) ) )
+#else
+ aInetOptions.GetProxyNoProxy() )))
+#endif
bRet = TRUE;
break;
case SID_ATTR_PATHNAME :
@@ -660,7 +900,164 @@ BOOL SfxApplication::GetOptions( SfxItemSet& rSet )
{
SfxAllEnumItem aNames(rPool.GetWhich(SID_ATTR_PATHGROUP));
SfxAllEnumItem aValues(rPool.GetWhich(SID_ATTR_PATHNAME));
+#if SUPD<613//MUSTINI
pIni->Fill(SFX_GROUP_DIR, aNames, aValues);
+#else
+ SvtPathOptions aPathCFG;
+ sal_uInt32 nCount = aNames.GetValueCount();
+ sal_uInt32 nPosition= 0;
+ for( nPosition=0; nPosition<nCount; ++nPosition )
+ {
+ String sPathType = aNames.GetValueTextByPos(nPosition);
+ String sValue;
+ if( sPathType.CompareToAscii("Addin") )
+ {
+ sValue = aPathCFG.GetAddinPath();
+ }
+ else
+ if( sPathType.CompareToAscii("AutoCorrect") )
+ {
+ sValue = aPathCFG.GetAutoCorrectPath();
+ }
+ else
+ if( sPathType.CompareToAscii("AutoPilot") )
+ {
+ sValue = aPathCFG.GetAutoPilotPath();
+ }
+ else
+ if( sPathType.CompareToAscii("Backup") )
+ {
+ sValue = aPathCFG.GetBackupPath();
+ }
+ else
+ if( sPathType.CompareToAscii("Basic") )
+ {
+ sValue = aPathCFG.GetBasicPath();
+ }
+ else
+ if( sPathType.CompareToAscii("Bitmap") )
+ {
+ sValue = aPathCFG.GetBitmapPath();
+ }
+ else
+ if( sPathType.CompareToAscii("Config") )
+ {
+ sValue = aPathCFG.GetConfigPath();
+ }
+ else
+ if( sPathType.CompareToAscii("Database") )
+ {
+ sValue = aPathCFG.GetDatabasePath();
+ }
+ else
+ if( sPathType.CompareToAscii("Dictionary") )
+ {
+ sValue = aPathCFG.GetDictionaryPath();
+ }
+ else
+ if( sPathType.CompareToAscii("Favorites") )
+ {
+ sValue = aPathCFG.GetFavoritesPath();
+ }
+ else
+ if( sPathType.CompareToAscii("Filter") )
+ {
+ sValue = aPathCFG.GetFilterPath();
+ }
+ else
+ if( sPathType.CompareToAscii("Gallery") )
+ {
+ sValue = aPathCFG.GetGalleryPath();
+ }
+ else
+ if( sPathType.CompareToAscii("AutoText") )
+ {
+ sValue = aPathCFG.GetAutoTextPath();
+ }
+ else
+ if( sPathType.CompareToAscii("Graphic") )
+ {
+ sValue = aPathCFG.GetGraphicPath();
+ }
+ else
+ if( sPathType.CompareToAscii("Help") )
+ {
+ sValue = aPathCFG.GetHelpPath();
+ }
+ else
+ if( sPathType.CompareToAscii("Linguistic") )
+ {
+ sValue = aPathCFG.GetLinguisticPath();
+ }
+ else
+ if( sPathType.CompareToAscii("Module") )
+ {
+ sValue = aPathCFG.GetModulePath();
+ }
+ else
+ if( sPathType.CompareToAscii("NewMenu") )
+ {
+ sValue = aPathCFG.GetNewMenuPath();
+ }
+ else
+ if( sPathType.CompareToAscii("Palette") )
+ {
+ sValue = aPathCFG.GetPalettePath();
+ }
+ else
+ if( sPathType.CompareToAscii("Plugin") )
+ {
+ sValue = aPathCFG.GetPluginPath();
+ }
+ else
+ if( sPathType.CompareToAscii("Storage") )
+ {
+ sValue = aPathCFG.GetStoragePath();
+ }
+ else
+ if( sPathType.CompareToAscii("SubIni") )
+ {
+ sValue = aPathCFG.GetSubIniPath();
+ }
+ else
+ if( sPathType.CompareToAscii("Temp") )
+ {
+ sValue = aPathCFG.GetTempPath();
+ }
+ else
+ if( sPathType.CompareToAscii("Template") )
+ {
+ sValue = aPathCFG.GetTemplatePath();
+ }
+ else
+ if( sPathType.CompareToAscii("Trash") )
+ {
+ sValue = aPathCFG.GetTrashPath();
+ }
+ else
+ if( sPathType.CompareToAscii("UserConfig") )
+ {
+ sValue = aPathCFG.GetUserConfigPath();
+ }
+ else
+ if( sPathType.CompareToAscii("UserDictionary") )
+ {
+ sValue = aPathCFG.GetUserDictionaryPath();
+ }
+ else
+ if( sPathType.CompareToAscii("Work") )
+ {
+ sValue = aPathCFG.GetWorkPath();
+ }
+ else
+ {
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ DBG_ASSERT(sal_False,"SfxApplication::GetOptions()\nUnsupported path name detected!\n");
+#endif
+ }
+ aValues.InsertValue(nPosition,sValue);
+ }
+#endif
if ( rSet.Put(aNames) || rSet.Put(aValues) )
bRet = TRUE;
break;
@@ -680,9 +1077,9 @@ BOOL SfxApplication::GetOptions( SfxItemSet& rSet )
}
//--------------------------------------------------------------------
-
BOOL SfxApplication::IsSecureURL( const INetURLObject& rURL, const String* pReferer ) const
{
+#if SUPD<613//MUSTINI
// unkritisches Protokoll?
INetProtocol eProt = rURL.GetProtocol();
if ( INET_PROT_MACRO != eProt && INET_PROT_SLOT != eProt )
@@ -735,14 +1132,18 @@ BOOL SfxApplication::IsSecureURL( const INetURLObject& rURL, const String* pRefe
// gemaess Liste
return bTrusted;
+#else
+ return SvtSecurityOptions().IsSecureURL( rURL.GetMainURL(), *pReferer );
+#endif
}
-
//--------------------------------------------------------------------
void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
{
+#if SUPD<613//MUSTINI
SfxIniManager *pIni = GetIniManager();
pIni->EnterLock();
+#endif
const SfxPoolItem *pItem = 0;
SfxItemPool &rPool = GetPool();
BOOL bResetSession = FALSE;
@@ -752,6 +1153,9 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
SvtSaveOptions aSaveOptions;
SvtUndoOptions aUndoOptions;
SvtHelpOptions aHelpOptions;
+ SvtSecurityOptions aSecurityOptions;
+ SvtPathOptions aPathOptions;
+ SvtInetOptions aInetOptions;
if ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_ATTR_BUTTON_OUTSTYLE3D), TRUE, &pItem) )
{
DBG_ASSERT(pItem->ISA(SfxBoolItem), "BoolItem expected");
@@ -949,6 +1353,7 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
}
}
}
+#if SUPD<613//MUSTINI
if ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_INET_HOMEPAGE), TRUE, &pItem))
{
DBG_ASSERT(pItem->ISA(SfxStringItem), "StringItem expected");
@@ -995,11 +1400,31 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
INT32 nFlag = (USHORT)( (const SfxBoolItem*)pItem )->GetValue();
pIni->Set( String::CreateFromInt32( nFlag ), SFX_KEY_INET_CACHEABORTED );
}
+#else
+ if(
+ ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_INET_HOMEPAGE), TRUE, &pItem)) ||
+ ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_INET_MEMCACHE), TRUE, &pItem)) ||
+ ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_INET_DISKCACHE), TRUE, &pItem)) ||
+ ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_INET_EXPIRATION), TRUE, &pItem)) ||
+ ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_INET_CACHEJS), TRUE, &pItem)) ||
+ ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_INET_CACHEEXPIRED), TRUE, &pItem)) ||
+ ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_INET_CACHEABORTED), TRUE, &pItem))
+ )
+ {
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ DBG_ASSERT(sal_False, "SfxApplication::SetOptions_Impl()\nSome INET keys no longer supported!\n");
+#endif
+ }
+#endif
if ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_INET_REVEAL_MAILADDR), TRUE, &pItem))
{
DBG_ASSERT( pItem->ISA(SfxBoolItem), "BoolItem expected" );
+#if SUPD<613//MUSTINI
INT32 nFlag = (USHORT)( (const SfxBoolItem*)pItem )->GetValue();
pIni->Set( String::CreateFromInt32( nFlag ), SFX_KEY_INET_REVEAL_MAILADDR );
+#else
+ aInetOptions.SetProtocolRevealMailAddress( ((const SfxBoolItem*)pItem)->GetValue() );
+#endif
bResetSession = TRUE;
}
@@ -1007,10 +1432,14 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
if ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_INET_SMTPSERVER), TRUE, &pItem))
{
DBG_ASSERT(pItem->ISA(SfxStringItem), "StringItem expected");
+#if SUPD<613//MUSTINI
pIni->Set(((const SfxStringItem *)pItem)->GetValue(), SFX_KEY_INET_SMTPSERVER);
+#else
+ aInetOptions.SetSmtpServerName(((const SfxStringItem *)pItem)->GetValue());
+#endif
bResetSession = TRUE;
}
-
+#if SUPD<613//MUSTINI
// POP-Server
if ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_INET_POPSERVER), TRUE, &pItem))
{
@@ -1083,13 +1512,35 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
INT32 nFlag = (USHORT)( (const SfxByteItem*)pItem )->GetValue();
pIni->Set( String::CreateFromInt32( nFlag ), SFX_KEY_INET_MAILTEXTFORMAT );
}
+#else
+ if(
+ ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_INET_POPSERVER), TRUE, &pItem)) ||
+ ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_INET_NNTPSERVER), TRUE, &pItem)) ||
+ ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_INET_MAXNEWS), TRUE, &pItem)) ||
+ ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_INET_MAXHTTPCONS), TRUE, &pItem)) ||
+ ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_INET_MAXFTPCONS), TRUE, &pItem)) ||
+ ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_INET_SMTPGATEWAY), TRUE, &pItem)) ||
+ ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_INET_MAILUSERNAME), TRUE, &pItem)) ||
+ ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_INET_MAILPASSWORD), TRUE, &pItem)) ||
+ ( SFX_ITEM_SET == rSet.GetItemState( rPool.GetWhich( SID_INET_MAILTEXTFORMAT ), TRUE, &pItem ) )
+ )
+ {
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ DBG_ASSERT(sal_False, "SfxApplication::SetOptions_Impl()\nSome INET keys no longer supported!\n");
+#endif
+ }
+#endif
// Proxy-Type
if ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_INET_PROXY_TYPE), TRUE, &pItem))
{
DBG_ASSERT( pItem->ISA(SfxUInt16Item), "UInt16Item expected" );
+#if SUPD<613//MUSTINI
String aValue = String::CreateFromInt32( ( (const SfxUInt16Item*)pItem )->GetValue() );
pIni->Set( aValue, SFX_KEY_INET_PROXYTYPE );
+#else
+ aInetOptions.SetProxyType((SvtInetOptions::ProxyType)( (const SfxUInt16Item*)pItem )->GetValue());
+#endif
bResetSession = TRUE;
bProxiesModified = TRUE;
}
@@ -1098,7 +1549,11 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
if ( SFX_ITEM_SET == rSet.GetItemState(SID_INET_NOPROXY, TRUE, &pItem))
{
DBG_ASSERT(pItem->ISA(SfxStringItem), "StringItem expected");
+#if SUPD<613//MUSTINI
pIni->Set(((const SfxStringItem *)pItem)->GetValue(), SFX_KEY_INET_NOPROXY);
+#else
+ aInetOptions.SetProxyNoProxy(((const SfxStringItem *)pItem)->GetValue());
+#endif
bResetSession = TRUE;
bProxiesModified = TRUE;
}
@@ -1107,8 +1562,12 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
if ( SFX_ITEM_SET == rSet.GetItemState(SID_BASIC_ENABLED, TRUE, &pItem))
{
DBG_ASSERT(pItem->ISA(SfxUInt16Item), "SfxInt16Item expected");
+#if SUPD<613//MUSTINI
String aValue = String::CreateFromInt32( ( (const SfxUInt16Item*)pItem )->GetValue() );
pIni->Set( aValue, SFX_KEY_BASIC_ENABLE );
+#else
+ aSecurityOptions.SetBasicMode( (EBasicSecurityMode)( (const SfxUInt16Item*)pItem )->GetValue() );
+#endif
}
// Java Enable
@@ -1117,7 +1576,11 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
DBG_ASSERT(pItem->ISA(SfxBoolItem), "SfxBoolItem expected");
BOOL bJava = ( (const SfxBoolItem*)pItem )->GetValue();
String aVal = bJava ? 0x0031 : 0x0030; // ^= '1' or '0'
+#if SUPD<613//MUSTINI
BOOL bSet = SetJavaIniEntry_Impl( SFX_KEY_JAVA_ENABLE, aVal, pIni );
+#else
+ BOOL bSet = SetJavaIniEntry_Impl( DEFINE_CONST_UNICODE("Java"), aVal );
+#endif
bResetSession = TRUE;
}
// Applets Enable
@@ -1126,7 +1589,11 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
DBG_ASSERT(pItem->ISA(SfxBoolItem), "SfxBoolItem expected");
BOOL bApplets = ( (const SfxBoolItem*)pItem )->GetValue();
String aVal = bApplets ? 0x0031 : 0x0030; // ^= '1' or '0'
+#if SUPD<613//MUSTINI
BOOL bSet = SetJavaIniEntry_Impl( SFX_KEY_INET_EXE_APPLETS, aVal, pIni );
+#else
+ BOOL bSet = SetJavaIniEntry_Impl( DEFINE_CONST_UNICODE("Applets"), aVal );
+#endif
bResetSession = TRUE;
}
@@ -1142,7 +1609,11 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
aVal = DEFINE_CONST_UNICODE("UNRESTRICTED");
else
aVal = DEFINE_CONST_UNICODE("NONE");
+#if SUPD<613//MUSTINI
BOOL bSet = SetJavaIniEntry_Impl( SFX_KEY_JAVA_NETACCESS, aVal, pIni );
+#else
+ BOOL bSet = SetJavaIniEntry_Impl( DEFINE_CONST_UNICODE("NetAccess"), aVal );
+#endif
bResetSession = TRUE;
}
@@ -1152,7 +1623,11 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
DBG_ASSERT(pItem->ISA(SfxBoolItem), "SfxBoolItem expected");
BOOL bSecurity = ((const SfxBoolItem *)pItem)->GetValue();
String aVal = bSecurity ? 0x0031 : 0x0030; // ^= '1' or '0'
+#if SUPD<613//MUSTINI
BOOL bSet = SetJavaIniEntry_Impl( SFX_KEY_JAVA_SECURITY, aVal, pIni );
+#else
+ BOOL bSet = SetJavaIniEntry_Impl( DEFINE_CONST_UNICODE("Security"), aVal );
+#endif
bResetSession = TRUE;
}
@@ -1161,7 +1636,11 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
{
DBG_ASSERT( pItem->ISA(SfxStringItem), "SfxStringItem expected" );
String aVal = ( (const SfxStringItem *)pItem )->GetValue();
+#if SUPD<613//MUSTINI
BOOL bSet = SetJavaIniEntry_Impl( SFX_KEY_JAVA_USERCLASSPATH, aVal, pIni );
+#else
+ BOOL bSet = SetJavaIniEntry_Impl( DEFINE_CONST_UNICODE("UserClassPath"), aVal );
+#endif
bResetSession = TRUE;
}
@@ -1170,7 +1649,13 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
{
DBG_ASSERT(pItem->ISA(SfxBoolItem), "SfxBoolItem expected");
BOOL bExe = ( (const SfxBoolItem *)pItem )->GetValue();
+#if SUPD<613//MUSTINI
pIni->Set( bExe ? 0x0031 : 0x0030 /* ^= '1' or '0' */, SFX_KEY_INET_EXE_PLUGIN );
+#else
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ DBG_ASSERT(sal_False, "SfxApplication::SetOptions_Impl()\nSome INET keys no longer supported!\n");
+#endif
+#endif
bResetSession = TRUE;
}
@@ -1180,7 +1665,13 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
DBG_ASSERT(pItem->ISA(SfxBoolItem), "BoolItem expected");
BOOL bIsAuto = ((const SfxBoolItem *)pItem)->GetValue();
if( bIsAuto )
+ {
+#if SUPD<613//MUSTINI
pIni->Set( String(), SFX_KEY_INET_DNS );
+#else
+ aInetOptions.SetDnsIpAddress( String() );
+#endif
+ }
else
{
String aDNS;
@@ -1189,11 +1680,16 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
DBG_ASSERT(pItem->ISA(SfxStringItem), "SfxStringItem expected");
aDNS = ((const SfxStringItem *)pItem)->GetValue();
}
+#if SUPD<613//MUSTINI
pIni->Set( aDNS, SFX_KEY_INET_DNS );
+#else
+ aInetOptions.SetDnsIpAddress( aDNS );
+#endif
}
bResetSession = TRUE;
}
+#if SUPD<613//MUSTINI
// Noncahed Server
if ( SFX_ITEM_SET == rSet.GetItemState(SID_INET_NONCACHED_SERVER, TRUE, &pItem))
{
@@ -1209,7 +1705,19 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
pIni->Set(((const SfxStringItem *)pItem)->GetValue(), SFX_KEY_INET_USERAGENT);
bResetSession = TRUE;
}
+#else
+ if(
+ ( SFX_ITEM_SET == rSet.GetItemState(SID_INET_NONCACHED_SERVER, TRUE, &pItem)) ||
+ ( SFX_ITEM_SET == rSet.GetItemState(SID_INET_USERAGENT, TRUE, &pItem))
+ )
+ {
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ DBG_ASSERT(sal_False, "SfxApplication::SetOptions_Impl()\nSome INET keys no longer supported!\n");
+#endif
+ }
+#endif
+#if SUPD<613//MUSTINI
// Proxies
for ( USHORT nOfs = 0;
nOfs <= SID_INET_SECURITY_PROXY_PORT - SID_INET_HTTP_PROXY_NAME;
@@ -1219,7 +1727,7 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
{
DBG_ASSERT( pItem->ISA(SfxStringItem), "StringItem expected" );
String aVal( ((const SfxStringItem *)pItem)->GetValue() );
- pIni->Set( aVal, SFX_KEY_INET_HTTPPROXYNAME+nOfs );
+ pIni->Set( aVal, 175+nOfs );
bResetSession = TRUE;
bProxiesModified = TRUE;
}
@@ -1227,12 +1735,57 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
{
DBG_ASSERT( pItem->ISA(SfxInt32Item), "Int32Item expected" );
String aValue = String::CreateFromInt32( ( (const SfxInt32Item*)pItem )->GetValue() );
- pIni->Set( aValue, SFX_KEY_INET_HTTPPROXYPORT + nOfs );
+ pIni->Set( aValue, 176 + nOfs );
bResetSession = TRUE;
bProxiesModified = TRUE;
}
}
+#else
+ if ( SFX_ITEM_SET == rSet.GetItemState( rPool.GetWhich( SID_INET_HTTP_PROXY_NAME ), TRUE, &pItem ) )
+ {
+ DBG_ASSERT( pItem->ISA(SfxStringItem), "StringItem expected" );
+ aInetOptions.SetProxyHttpName( ((const SfxStringItem *)pItem)->GetValue() );
+ bResetSession = TRUE;
+ bProxiesModified = TRUE;
+ }
+ if ( SFX_ITEM_SET == rSet.GetItemState( rPool.GetWhich( SID_INET_HTTP_PROXY_PORT ), TRUE, &pItem ) )
+ {
+ DBG_ASSERT( pItem->ISA(SfxInt32Item), "Int32Item expected" );
+ aInetOptions.SetProxyHttpPort( ( (const SfxInt32Item*)pItem )->GetValue() );
+ bResetSession = TRUE;
+ bProxiesModified = TRUE;
+ }
+ if ( SFX_ITEM_SET == rSet.GetItemState( rPool.GetWhich( SID_INET_FTP_PROXY_NAME ), TRUE, &pItem ) )
+ {
+ DBG_ASSERT( pItem->ISA(SfxStringItem), "StringItem expected" );
+ aInetOptions.SetProxyFtpName( ((const SfxStringItem *)pItem)->GetValue() );
+ bResetSession = TRUE;
+ bProxiesModified = TRUE;
+ }
+ if ( SFX_ITEM_SET == rSet.GetItemState( rPool.GetWhich( SID_INET_FTP_PROXY_PORT ), TRUE, &pItem ) )
+ {
+ DBG_ASSERT( pItem->ISA(SfxInt32Item), "Int32Item expected" );
+ aInetOptions.SetProxyFtpPort( ( (const SfxInt32Item*)pItem )->GetValue() );
+ bResetSession = TRUE;
+ bProxiesModified = TRUE;
+ }
+ if ( SFX_ITEM_SET == rSet.GetItemState( rPool.GetWhich( SID_INET_SOCKS_PROXY_NAME ), TRUE, &pItem ) )
+ {
+ DBG_ASSERT( pItem->ISA(SfxStringItem), "StringItem expected" );
+ aInetOptions.SetProxySocksName( ((const SfxStringItem *)pItem)->GetValue() );
+ bResetSession = TRUE;
+ bProxiesModified = TRUE;
+ }
+ if ( SFX_ITEM_SET == rSet.GetItemState( rPool.GetWhich( SID_INET_SOCKS_PROXY_PORT ), TRUE, &pItem ) )
+ {
+ DBG_ASSERT( pItem->ISA(SfxInt32Item), "Int32Item expected" );
+ aInetOptions.SetProxySocksPort( ( (const SfxInt32Item*)pItem )->GetValue() );
+ bResetSession = TRUE;
+ bProxiesModified = TRUE;
+ }
+#endif
+#if SUPD<613//MUSTINI
// Channels
if ( SFX_ITEM_SET == rSet.GetItemState(SID_INET_CHANNELS_ONOFF, TRUE, &pItem))
{
@@ -1248,6 +1801,17 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
String aValue = String::CreateFromInt32( ( (const SfxUInt16Item*)pItem )->GetValue() );
pIni->Set( aValue, SFX_KEY_INET_COOKIES );
}
+#else
+ if(
+ ( SFX_ITEM_SET == rSet.GetItemState(SID_INET_CHANNELS_ONOFF, TRUE, &pItem)) ||
+ ( SFX_ITEM_SET == rSet.GetItemState(SID_INET_COOKIESHANDLE, TRUE, &pItem))
+ )
+ {
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ DBG_ASSERT(sal_False, "SfxApplication::SetOptions_Impl()\nSome INET keys no longer supported!\n");
+#endif
+ }
+#endif
// Secure-Referers
if ( SFX_ITEM_SET == rSet.GetItemState(SID_SECURE_URL, TRUE, &pItem))
@@ -1256,27 +1820,50 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
DBG_ASSERT(pItem->ISA(SfxStringListItem), "StringListItem expected");
const List *pList = ((SfxStringListItem*)pItem)->GetList();
+#if SUPD<613//MUSTINI
pIni->Set( String::CreateFromInt32( pList->Count() ), SFX_KEY_SECURE_URL );
for ( USHORT n = 0; n < pList->Count(); ++n )
pIni->Set( *(const String*)(pList->GetObject(n)), SFX_KEY_SECURE_URL, n );
+#else
+ sal_uInt32 nCount = pList->Count();
+ ::com::sun::star::uno::Sequence< ::rtl::OUString > seqURLs(nCount);
+ for( sal_uInt32 nPosition=0;nPosition<nCount;++nPosition)
+ {
+ seqURLs[nPosition] = *(const String*)(pList->GetObject(nPosition));
+ }
+ aSecurityOptions.SetSecureURLs( seqURLs );
+#endif
}
// EnableMetafilePrint
if ( SFX_ITEM_SET == rSet.GetItemState( rPool.GetWhich( SID_ENABLE_METAFILEPRINT ), TRUE, &pItem ) )
{
+#if SUPD<613//MUSTINI
DBG_ASSERT( pItem->ISA(SfxBoolItem), "BoolItem expected" );
BOOL bPrint = (( const SfxBoolItem*)pItem )->GetValue();
pIni->Set( bPrint ? 0x0031 : 0x0030 /* ^= '1' or '0' */, SFX_KEY_METAFILEPRINT );
+#else
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ DBG_ASSERT(sal_False, "SfxApplication::SetOptions_Impl()\nsoffice.ini key \"MetafilPrint\" not supported any longer!\n");
+#endif
+#endif
}
// Web-View
if( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_ATTR_ALLOWFOLDERWEBVIEW), TRUE, &pItem))
{
+#if SUPD<613//MUSTINI
DBG_ASSERT(pItem->ISA(SfxStringItem), "SfxStringItem expected");
pIni->Set(((const SfxStringItem*)pItem)->GetValue(), SFX_KEY_ALLOWFOLDERWEBVIEW);
+#else
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ DBG_ASSERT(sal_False, "SfxApplication::SetOptions_Impl()\nsoffice.ini key \"AllowFolderWebView\" not supported any longer!\n");
+#endif
+#endif
}
// Explorer
+#if SUPD<613//MUSTINI
String aIconGrid( pIni->Get(SFX_KEY_ICONGRID) );
Size aGrid( aIconGrid.GetToken(0).ToInt32(), aIconGrid.GetToken(1).ToInt32() );
UINT16 nMode = (UINT16)aIconGrid.GetToken(2).ToInt32();
@@ -1309,6 +1896,7 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
BOOL bRestoreExpand = ( (const SfxBoolItem*)pItem )->GetValue();
pIni->Set( bRestoreExpand ? 0x0031 : 0x0030 /* ^= '1' or '0' */, SFX_KEY_AUTOOPEN );
}
+#endif
if ( bResetSession )
{
@@ -1316,6 +1904,7 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
::vos::ORef< ::inet::INetConfig > xINetConfig;
if ( aWrapper.getINetConfig( xINetConfig ) )
{
+#if SUPD<613//MUSTINI
xINetConfig->setDomainNameServer( pIni->Get( SFX_KEY_INET_DNS ) );
xINetConfig->setUserAgent( pIni->Get( SFX_KEY_INET_USERAGENT ) );
@@ -1346,6 +1935,34 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
xINetConfig->setProxyConfig (aProxyCfg);
}
+#else
+ xINetConfig->setDomainNameServer( aInetOptions.GetDnsIpAddress() );
+
+ if ( bProxiesModified )
+ {
+ ::inet::INetProxyConfig aProxyCfg (xINetConfig->getProxyConfig());
+ SvtInetOptions::ProxyType eProxy = (SvtInetOptions::ProxyType)aInetOptions.GetProxyType();
+
+ if (eProxy == SvtInetOptions::ProxyType::NONE)
+ aProxyCfg.setNoProxyList(aInetOptions.GetProxyNoProxy());
+ else
+ aProxyCfg.setNoProxyList(DEFINE_CONST_UNICODE("*:*"));
+
+ aProxyCfg.setHttpProxy (
+ aInetOptions.GetProxyHttpName(),
+ aInetOptions.GetProxyHttpPort());
+
+ aProxyCfg.setFtpProxy (
+ aInetOptions.GetProxyFtpName(),
+ aInetOptions.GetProxyFtpPort());
+
+ aProxyCfg.setSocksProxy (
+ aInetOptions.GetProxySocksName(),
+ aInetOptions.GetProxySocksPort());
+
+ xINetConfig->setProxyConfig (aProxyCfg);
+ }
+#endif
}
}
@@ -1366,8 +1983,10 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
}
// geaenderte Daten speichern
+#if SUPD<613//MUSTINI
pIni->LeaveLock();
pIni->Flush();
+#endif
SaveConfiguration();
}
@@ -1375,6 +1994,8 @@ void SfxApplication::SetOptions_Impl( const SfxItemSet& rSet )
void SfxApplication::SetOptions(const SfxItemSet &rSet)
{
+ SvtPathOptions aPathOptions;
+
// Daten werden in DocInfo und IniManager gespeichert
SfxDocumentInfo *pDocInf = SfxObjectShell::Current()
? &SfxObjectShell::Current()->GetDocInfo()
@@ -1415,7 +2036,84 @@ void SfxApplication::SetOptions(const SfxItemSet &rSet)
if ( SFX_ITEM_SET == rSet.GetItemState(rPool.GetWhich(SID_ATTR_PATHNAME), TRUE, &pItem))
{
DBG_ASSERT(pItem->ISA(SfxAllEnumItem), "AllEnumItem expected");
+#if SUPD<613//MUSTINI
GetAppIniManager()->Set(SFX_GROUP_DIR, *(const SfxAllEnumItem *)pItem);
+#else
+ const SfxAllEnumItem* pEnumItem = (const SfxAllEnumItem *)pItem;
+ sal_uInt32 nCount = pEnumItem->GetValueCount();
+ for( sal_uInt32 nPath=0; nPath<nCount; ++nPath )
+ {
+ String sValue = pEnumItem->GetValueTextByPos(nPath);
+ switch( nPath )
+ {
+ case 50 : aPathOptions.SetSubIniPath( sValue );
+ break;
+ case 51 : aPathOptions.SetConfigPath( sValue );
+ break;
+ case 52 : aPathOptions.SetWorkPath( sValue );
+ break;
+ case 53 : break; // GRAPHICSPATH
+ case 54 : aPathOptions.SetBitmapPath( sValue );
+ break;
+ case 55 : aPathOptions.SetBasicPath( sValue );
+ break;
+ case 56 : aPathOptions.SetDatabasePath( sValue );
+ break;
+ case 57 : aPathOptions.SetPalettePath( sValue );
+ break;
+ case 58 : aPathOptions.SetBackupPath( sValue );
+ break;
+ case 59 : aPathOptions.SetModulePath( sValue );
+ break;
+ case 60 : aPathOptions.SetTemplatePath( sValue );
+ break;
+ case 61 : aPathOptions.SetAutoTextPath( sValue );
+ break;
+ case 62 : aPathOptions.SetDictionaryPath( sValue );
+ break;
+ case 63 : break; // DESKTOPPATH
+ case 64 : aPathOptions.SetHelpPath( sValue );
+ break;
+ case 65 : break; // BOOKMARKPATH
+ case 66 : aPathOptions.SetGalleryPath( sValue );
+ break;
+ case 67 : aPathOptions.SetNewMenuPath( sValue );
+ break;
+ case 68 : break; // AGENTPATH
+ case 69 : aPathOptions.SetAutoPilotPath( sValue );
+ break;
+ case 70 : break; // EXPLORERPATH
+ case 71 : aPathOptions.SetTrashPath( sValue );
+ break;
+ case 72 : aPathOptions.SetStoragePath( sValue );
+ break;
+ case 73 : break; //SFX_KEY_STARTMENU_DIR
+ case 74 : break; //SFX_KEY_DOWNLOAD_DIR
+ case 75 : break; //SFX_KEY_AUTOSTART_DIR
+ case 76 : break; //SFX_KEY_QUICKSTART_DIR
+ case 77 : break; //SFX_KEY_GROUP_DIR
+ case 78 : aPathOptions.SetPluginPath( sValue );
+ break;
+ case 79 : aPathOptions.SetFavoritesPath( sValue );
+ break;
+ case 80 : aPathOptions.SetFilterPath( sValue );
+ break;
+ case 81 : aPathOptions.SetAddinPath( sValue );
+ break;
+ case 82 : aPathOptions.SetUserConfigPath( sValue );
+ break;
+ case 83 : aPathOptions.SetUserDictionaryPath( sValue );
+ break;
+ case 84 : aPathOptions.SetLinguisticPath( sValue );
+ break;
+ case 85 : aPathOptions.SetAutoCorrectPath( sValue );
+ break;
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ default: DBG_ASSERT(sal_False, "SfxApplication::SetOptions_Impl()\nInvalid path number found for set directories!\n");
+#endif
+ }
+ }
+#endif
aSendSet.ClearItem( rPool.GetWhich( SID_ATTR_PATHNAME ) );
}
@@ -1627,6 +2325,7 @@ static void CorrectUpdateNumber_Impl(String& rName)
void SfxApplicationClass::Property( ApplicationProperty& rProp )
{
+#if SUPD<613//MUSTINI
SfxApplication* pApp = SFX_APP();
SfxIniManager* pIni = pApp->GetIniManager();
@@ -1637,7 +2336,7 @@ void SfxApplicationClass::Property( ApplicationProperty& rProp )
pAppIniMgr->SetIniManager( pIni );
return;
}
-
+#endif
TTProperties* pTTProperties = PTR_CAST( TTProperties, &rProp );
if ( pTTProperties )
{
diff --git a/sfx2/source/appl/appdata.cxx b/sfx2/source/appl/appdata.cxx
index 45643b4d5e..0c883e013c 100644
--- a/sfx2/source/appl/appdata.cxx
+++ b/sfx2/source/appl/appdata.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: appdata.cxx,v $
*
- * $Revision: 1.2 $
+ * $Revision: 1.3 $
*
- * last change: $Author: mba $ $Date: 2000-09-28 11:32:44 $
+ * last change: $Author: as $ $Date: 2000-11-08 14:25:41 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -110,7 +110,9 @@
#include "app.hrc"
#include "sfxresid.hxx"
#include "objshimp.hxx"
+#if SUPD<613//MUSTINI
#include "inimgr.hxx"
+#endif
#include "ucbhelp.hxx"
#include "appuno.hxx"
@@ -212,11 +214,13 @@ SfxDocumentTemplates* SfxAppData_Impl::GetDocumentTemplates()
void SfxAppData_Impl::Notify( SfxBroadcaster &rBC, const SfxHint &rHint )
{
+#if SUPD<613//MUSTINI
const SfxIniManagerHint* pIniManHint = PTR_CAST(SfxIniManagerHint, &rHint);
if ( pIniManHint && pIniManHint->GetIniKey() == SFX_KEY_DONTHIDE_DISABLEDENTRIES )
{
sal_Bool bDontHide = (sal_Bool)(sal_uInt16)pIniManHint->GetNewValue().ToInt32();
UpdateApplicationSettings( bDontHide );
}
+#endif
}
diff --git a/sfx2/source/appl/appdde.cxx b/sfx2/source/appl/appdde.cxx
index d58004d0a2..dddb48830d 100644
--- a/sfx2/source/appl/appdde.cxx
+++ b/sfx2/source/appl/appdde.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: appdde.cxx,v $
*
- * $Revision: 1.1.1.1 $
+ * $Revision: 1.2 $
*
- * last change: $Author: hr $ $Date: 2000-09-18 16:52:26 $
+ * last change: $Author: as $ $Date: 2000-11-08 14:25:41 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -87,6 +87,7 @@
#include <so3/linkmgr.hxx>
#endif
#include <tools/urlobj.hxx>
+#include <svtools/pathoptions.hxx>
#pragma hdrstop
#include "app.hxx"
@@ -97,7 +98,9 @@
#include "dispatch.hxx"
#include "sfxtypes.hxx"
#include "sfxsids.hrc"
+#if SUPD<613//MUSTINI
#include "inimgr.hxx"
+#endif
#include "helper.hxx"
//========================================================================
@@ -514,7 +517,11 @@ BOOL SfxApplication::InitializeDde()
pAppData_Impl->pDdeService->AddFormat( FORMAT_RTF );
// Config-Pfad als Topic wegen Mehrfachstart
+#if SUPD<613//MUSTINI
INetURLObject aOfficeLockFile( GetIniManager()->Get( SFX_KEY_USERCONFIG_PATH ), INET_PROT_FILE );
+#else
+ INetURLObject aOfficeLockFile( SvtPathOptions().GetUserConfigPath(), INET_PROT_FILE );
+#endif
aOfficeLockFile.insertName( DEFINE_CONST_UNICODE( "soffice.lck" ) );
String aService( SfxDdeServiceName_Impl( aOfficeLockFile.PathToFileName() ) );
aService.ToUpperAscii();
@@ -617,7 +624,11 @@ BOOL ImplDdeService::MakeTopic( const String& rNm )
if( !bRet )
{
+#if SUPD<613//MUSTINI
INetURLObject aWorkPath( SFX_INIMANAGER()->Get( SFX_KEY_WORK_PATH ), INET_PROT_FILE );
+#else
+ INetURLObject aWorkPath( SvtPathOptions().GetWorkPath(), INET_PROT_FILE );
+#endif
INetURLObject aFile;
if ( aWorkPath.GetNewAbsURL( rNm, &aFile ) &&
SfxContentHelper::IsDocument( aFile.GetMainURL() ) )
diff --git a/sfx2/source/appl/appinit.cxx b/sfx2/source/appl/appinit.cxx
index b2057ae05f..9e14b929f8 100644
--- a/sfx2/source/appl/appinit.cxx
+++ b/sfx2/source/appl/appinit.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: appinit.cxx,v $
*
- * $Revision: 1.5 $
+ * $Revision: 1.6 $
*
- * last change: $Author: mba $ $Date: 2000-11-06 18:05:33 $
+ * last change: $Author: as $ $Date: 2000-11-08 14:23:12 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -144,6 +144,15 @@
#ifndef _UNOTOOLS_PROCESSFACTORY_HXX
#include <comphelper/processfactory.hxx>
#endif
+#ifndef INCLUDED_SVTOOLS_PATHOPTIONS_HXX
+#include <svtools/pathoptions.hxx>
+#endif
+#ifndef INCLUDED_SVTOOLS_HISTORYOPTIONS_HXX
+#include <svtools/historyoptions.hxx>
+#endif
+#ifndef INCLUDED_SVTOOLS_MODULEOPTIONS_HXX
+#include <svtools/moduleoptions.hxx>
+#endif
#pragma hdrstop
@@ -657,10 +666,11 @@ FASTBOOL SfxApplication::Initialize_Impl()
Help::EnableContextHelp();
Help::EnableExtHelp();
Help::EnableQuickHelp();
-
+#ifdef ENABLE_INIMANAGER//MUSTINI
// falls der IniManager nicht schon durch CreateResManager erzeugt wurde
if ( !pAppIniMgr )
pAppIniMgr = CreateIniManager();
+#endif
// StarObjects initialisieren
if ( !SvFactory::Init() )
@@ -672,7 +682,11 @@ FASTBOOL SfxApplication::Initialize_Impl()
pAppData_Impl->pSfxFrameObjectFactoryPtr = new SfxFrameObjectFactoryPtr;
pAppData_Impl->pSfxFrameObjectFactoryPtr->pSfxFrameObjectFactory = SfxFrameObject::ClassFactory();
SvBindStatusCallback::SetProgressCallback( STATIC_LINK( 0, SfxProgress, DefaultBindingProgress ) );
+#if SUPD<613//MUSTINI
INetURLHistory::GetOrCreate()->SetLocation( GetIniManager()->Get( SFX_KEY_USERCONFIG_PATH ) );
+#else
+ INetURLHistory::GetOrCreate()->SetLocation( SvtPathOptions().GetUserConfigPath() );
+#endif
// merken, falls Applikation normal gestartet wurde
if ( pAppData_Impl->bDirectAliveCount )
@@ -696,9 +710,13 @@ FASTBOOL SfxApplication::Initialize_Impl()
// diverse Pointer
pImp->pAutoSaveTimer = new Timer;
+#if SUPD<613//MUSTINI
String aPickSize = GetIniManager()->Get( SFX_KEY_PICKLIST );
int nPickSize = !aPickSize.Len() ? 4 : (int) aPickSize.ToInt32();
SfxPickList_Impl::GetOrCreate( Min(9, nPickSize) );
+#else
+ SfxPickList_Impl::GetOrCreate( SvtHistoryOptions().GetSize( ePICKLIST ) );
+#endif
/////////////////////////////////////////////////////////////////
@@ -761,6 +779,7 @@ FASTBOOL SfxApplication::Initialize_Impl()
SFX_FILTER_REDIRECT | SFX_FILTER_IMPORT | SFX_FILTER_ALIEN |
SFX_FILTER_NOTINFILEDLG | SFX_FILTER_NOTINCHOOSER );
*/
+#if SUPD<613//MUSTINI
if( _nFeatures & SFX_FEATURE_SCALC &&
_nFeatures & SFX_FEATURE_SIMPRESS &&
_nFeatures & SFX_FEATURE_SDRAW &&
@@ -768,6 +787,14 @@ FASTBOOL SfxApplication::Initialize_Impl()
_nFeatures & SFX_FEATURE_SCHART &&
_nFeatures & SFX_FEATURE_SMATH &&
_nFeatures & SFX_FEATURE_SWRITER )
+#else
+ if( _nFeatures & FEATUREFLAG_CALC &&
+ _nFeatures & FEATUREFLAG_IMPRESS &&
+ _nFeatures & FEATUREFLAG_DRAW &&
+ _nFeatures & FEATUREFLAG_CHART &&
+ _nFeatures & FEATUREFLAG_MATH &&
+ _nFeatures & FEATUREFLAG_WRITER )
+#endif
{
// Office Filter registrieren
SfxFilterContainer* pContainer =
@@ -845,7 +872,7 @@ IMPL_LINK( SfxApplication, SpecialService_Impl, void*, pVoid )
::com::sun::star::uno::Reference< ::com::sun::star::installation::XInstallationCheck > xInst( xMgr->createInstance( DEFINE_CONST_UNICODE("com.sun.star.installation.FontCheck") ), ::com::sun::star::uno::UNO_QUERY );
if ( xInst.is() )
xInst->checkWithDialog( sal_False );
-
+#if SUPD<613//MUSTINI
String aWizard = GetIniManager()->Get( DEFINE_CONST_UNICODE("Common"), 0, 0, DEFINE_CONST_UNICODE("RunWizard") );
sal_Bool bRunWizard = (sal_Bool) (sal_uInt16) aWizard.ToInt32();
if ( bRunWizard )
@@ -867,7 +894,19 @@ IMPL_LINK( SfxApplication, SpecialService_Impl, void*, pVoid )
if( nRegKey == 0 )
GetAppDispatcher_Impl()->Execute(SID_ONLINE_REGISTRATION_DLG, SFX_CALLMODE_ASYNCHRON);
}
-
+#else
+ if ( !pAppData_Impl->bBean )
+ {
+ // StarOffice registration
+ INetURLObject aORegObj( SvtPathOptions().GetUserConfigPath(), INET_PROT_FILE );
+ aORegObj.insertName( DEFINE_CONST_UNICODE( "oreg.ini" ) );
+ Config aCfg( aORegObj.PathToFileName() );
+ aCfg.SetGroup( "reg" );
+ sal_uInt16 nRegKey = (sal_uInt16) aCfg.ReadKey( "registration", "0" ).ToInt32();
+ if( nRegKey == 0 )
+ GetAppDispatcher_Impl()->Execute(SID_ONLINE_REGISTRATION_DLG, SFX_CALLMODE_ASYNCHRON);
+ }
+#endif
return 0;
}
diff --git a/sfx2/source/appl/appmain.cxx b/sfx2/source/appl/appmain.cxx
index 439598290d..6764e38677 100644
--- a/sfx2/source/appl/appmain.cxx
+++ b/sfx2/source/appl/appmain.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: appmain.cxx,v $
*
- * $Revision: 1.4 $
+ * $Revision: 1.5 $
*
- * last change: $Author: mba $ $Date: 2000-10-04 17:34:22 $
+ * last change: $Author: as $ $Date: 2000-11-08 14:25:41 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -71,9 +71,11 @@
#ifndef _URLOBJ_HXX //autogen
#include <tools/urlobj.hxx>
#endif
+#if SUPD<613//MUSTINI
#ifndef _SFXINIMGR_HXX //autogen
#include <svtools/iniman.hxx>
#endif
+#endif
#ifndef _CSTITEM_HXX //autogen
#include <svtools/cstitem.hxx>
#endif
@@ -83,7 +85,9 @@
#ifndef _EHDL_HXX
#include <svtools/ehdl.hxx>
#endif
-
+#ifndef INCLUDED_SVTOOLS_STARTOPTIONS_HXX
+#include <svtools/startoptions.hxx>
+#endif
#include <svtools/itempool.hxx>
#include <svtools/urihelper.hxx>
#include <svtools/helpopt.hxx>
@@ -112,7 +116,9 @@
#include "objuno.hxx"
#include "app.hrc"
#include "docfile.hxx"
+#if SUPD<613//MUSTINI
#include "inimgr.hxx"
+#endif
#ifdef WNT
#include <tools/svwin.h>
@@ -363,6 +369,7 @@ void SfxApplication::StartUpScreen( const char* pLabelPrefix )
pAppData_Impl->nAppEvent != DISPATCH_PRINT && pAppData_Impl->nAppEvent != DISPATCH_SERVER )
{
// und es nicht ausgeschaltet ist
+#if SUPD<613//MUSTINI
String aIntroIni = pAppIniMgr->Get(SFX_KEY_SHOW_INTRO);
ULONG nDisplayTime = ULONG(aIntroIni.ToInt32());
@@ -384,6 +391,18 @@ void SfxApplication::StartUpScreen( const char* pLabelPrefix )
pImp->pIntro = new IntroWindow_Impl(
Bitmap( ResId( nResId, pAppData_Impl->pLabelResMgr ) ) );
}
+#else
+ sal_Bool bIntro = SvtStartOptions().IsIntroEnabled();
+ if( bIntro == sal_True )
+ {
+ USHORT nResId = RID_DEFAULTINTRO;
+ if ( Application::IsRemoteServer() )
+ nResId = RID_DEFAULTINTRO_PORTAL;
+ // die ggf. im System eingestellte Zeit wird hier nicht ber"ucksichtigt
+ pImp->pIntro = new IntroWindow_Impl(
+ Bitmap( ResId( nResId, pAppData_Impl->pLabelResMgr ) ) );
+ }
+#endif
}
}
else
@@ -475,7 +494,9 @@ IMPL_LINK( SfxApplication, LateInitTimerHdl_Impl, void*, pvoid)
{
// LateInit ist fertig
DELETEZ (pAppData_Impl->pInitLinkList);
+#if SUPD<613//MUSTINI
pAppIniMgr->ResetLock();
+#endif
}
return 0;
}
@@ -550,6 +571,7 @@ SfxFilterMatcher& SfxApplication::GetFilterMatcher()
BOOL SfxApplication::IsStandalone() const
{
+#if SUPD<613//MUSTINI
// Wenn ohne UI gestartet, nat"urlich niemals integrierter Desktop
if ( pAppData_Impl->bBean )
return TRUE;
@@ -572,4 +594,7 @@ BOOL SfxApplication::IsStandalone() const
return TRUE;
#endif
}
+#else//MUSTINI
+ return FALSE;
+#endif
}
diff --git a/sfx2/source/appl/appmisc.cxx b/sfx2/source/appl/appmisc.cxx
index 33a5042fe6..7c7207e238 100644
--- a/sfx2/source/appl/appmisc.cxx
+++ b/sfx2/source/appl/appmisc.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: appmisc.cxx,v $
*
- * $Revision: 1.7 $
+ * $Revision: 1.8 $
*
- * last change: $Author: mba $ $Date: 2000-11-03 12:02:31 $
+ * last change: $Author: as $ $Date: 2000-11-08 14:25:41 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -89,6 +89,12 @@
#ifndef _FILTER_HXX //autogen
#include <svtools/filter.hxx>
#endif
+#ifndef INCLUDED_SVTOOLS_INTERNALOPTIONS_HXX
+#include <svtools/internaloptions.hxx>
+#endif
+#ifndef INCLUDED_SVTOOLS_PATHOPTIONS_HXX
+#include <svtools/pathoptions.hxx>
+#endif
#ifndef _COM_SUN_STAR_REGISTRY_INVALIDREGISTRYEXCEPTION_HPP_
#include <com/sun/star/registry/InvalidRegistryException.hpp>
@@ -307,9 +313,11 @@ void SfxApplication::OpenClients()
if ( !( pAppData_Impl->nAppEvent & DISPATCH_SERVER ) )
{
// Crash-Recovery
+#if SUPD<613//MUSTINI
SfxIniManager *pIni = GetIniManager();
sal_Bool bSendMail = (sal_uInt16) pIni->ReadKey( DEFINE_CONST_UNICODE("Common"), DEFINE_CONST_UNICODE("SendCrashMail") ).ToInt32();
String aFileName = pIni->ReadKey( pIni->GetGroupName( SFX_GROUP_WORKINGSET_IMPL ), DEFINE_CONST_UNICODE("Info") );
+
if ( bSendMail && aFileName.Len() )
{
SvFileStream aStr( aFileName, STREAM_STD_READ );
@@ -336,11 +344,25 @@ void SfxApplication::OpenClients()
SfxContentHelper::Kill( aFileName );
}
}
+#else
+ sal_Bool bSendMail = SvtInternalOptions().CrashMailEnabled();
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ DBG_ASSERT(!(bSendMail==sal_True),"SfxApplication::OpenClients()\nSendCrashMail not full supported yet!\n");
+#endif
+#endif
+
sal_Bool bCancel = sal_False;
for ( sal_uInt16 n = 0; sal_True; ++n )
{
+#if SUPD<613//MUSTINI
String aEntry( pIni->Get( SFX_GROUP_WORKINGSET_IMPL, DEFINE_CONST_UNICODE("Recover"), n ) );
+#else
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ DBG_ASSERT(sal_False, "SfxApplication::OpenClients()\nsoffice.ini key \"WorkingSet\\Recover\" no longer supported ...\n");
+#endif
+ String aEntry;
+#endif
if ( !aEntry.GetTokenCount() )
break;
@@ -389,14 +411,18 @@ void SfxApplication::OpenClients()
case RET_NO: // skip this file
// remove ini-entry
+#if SUPD<613//MUSTINI
pIni->Delete( SFX_GROUP_WORKINGSET_IMPL, DEFINE_CONST_UNICODE("Recover"), n );
+#endif
if ( nRet == RET_NO )
SfxContentHelper::Kill( aTempFileName );
break;
case RET_CANCEL: // cancel recovering
// remove ini-entry
+#if SUPD<613//MUSTINI
pIni->Delete( SFX_GROUP_WORKINGSET_IMPL, DEFINE_CONST_UNICODE("Recover"), n );
+#endif
SfxContentHelper::Kill( aTempFileName );
bCancel = sal_True; // and all following
break;
@@ -437,7 +463,14 @@ void SfxApplication::OpenClients()
SfxAllItemSet aSet( GetPool() );
// Dateiname
+#if SUPD<613//MUSTINI
String aName = SFX_INIMANAGER()->ReadKey( DEFINE_CONST_UNICODE("Common"), DEFINE_CONST_UNICODE("StartDocument") );
+#else
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ DBG_ASSERT(sal_False, "SfxApplication::OpenClients()\nsoffice.ini key \"Common\\StartDocument\" no longer supported ...\n");
+#endif
+ String aName;
+#endif
if ( !aName.Len() )
aName = String( DEFINE_CONST_UNICODE("private:factory/swriter" ) );
SfxStringItem aNameItem( SID_FILE_NAME, aName );
@@ -700,7 +733,7 @@ void SfxApplication::StoreConfig()
#ifdef WNT
extern String GetUserID();
#endif
-
+#ifdef ENABLE_INIMANAGER//MUSTINI
SfxIniManager* SfxApplication::CreateIniManager()
{
SfxIniManager *pIniMgr = NULL;
@@ -782,7 +815,7 @@ SfxIniManager* SfxApplication::GetIniManager() const
{
return pViewFrame ? pViewFrame->GetIniManager() : pAppIniMgr;
}
-
+#endif//MUSTINI!
//------------------------------------------------------------------------
SfxProgress* SfxApplication::GetProgress() const
@@ -915,19 +948,28 @@ SvUShorts* SfxApplication::GetDisabledSlotList_Impl()
if ( !pList )
{
// Gibt es eine Slotdatei ?
+#if SUPD<613//MUSTINI
INetURLObject aObj( GetIniManager()->Get( SFX_KEY_CONFIG_DIR ), INET_PROT_FILE );
+#else
+ INetURLObject aObj( SvtPathOptions().GetConfigPath(), INET_PROT_FILE );
+#endif
aObj.insertName( DEFINE_CONST_UNICODE( "slots.cfg" ) );
SvFileStream aStrm( aObj.GetMainURL(), STREAM_STD_READ );
// Speziell f"ur AK: wenn in der INI "Slots=AK" steht, slots.cfg
// ignorieren und weitermachen
+#if SUPD<613//MUSTINI
String aSlotEntry = GetIniManager()->Get( SFX_KEY_SLOTLIST );
if ( aSlotEntry.CompareIgnoreCaseToAscii( "AK" ) == COMPARE_EQUAL )
return NULL;
-
sal_uInt16 nSlotEntry = (sal_uInt16) aSlotEntry.ToInt32();
if ( nSlotEntry )
{
+#else
+ if( SvtInternalOptions().SlotCFGEnabled() == sal_True )
+ {
+#endif
+
// Gibt es einen "Slotlist"-Eintrag ??
if ( aStrm.GetError() )
{
@@ -998,6 +1040,7 @@ SvUShorts* SfxApplication::GetDisabledSlotList_Impl()
Config* SfxApplication::GetFilterIni()
{
+#if SUPD<613//MUSTINI
if( !pAppData_Impl->pFilterIni )
{
String aIniFile( DEFINE_CONST_UNICODE( FILTER_INI ) );
@@ -1009,6 +1052,14 @@ Config* SfxApplication::GetFilterIni()
pAppData_Impl->pFilterIni = new Config();
}
return pAppData_Impl->pFilterIni;
+#else
+ if( !pAppData_Impl->pFilterIni )
+ {
+ String aIniFile( SvtPathOptions().GetModulePath() + DEFINE_CONST_UNICODE("/") + DEFINE_CONST_UNICODE( FILTER_INI ) );
+ pAppData_Impl->pFilterIni = new Config( aIniFile );
+ }
+ return pAppData_Impl->pFilterIni;
+#endif
}
@@ -1090,6 +1141,7 @@ ISfxTemplateCommon* SfxApplication::GetCurrentTemplateCommon( SfxBindings& rBind
PopupMenu* SfxAppData_Impl::GetPopupMenu( sal_uInt16 nSID, sal_Bool bBig, sal_Bool bNew )
{
+#if SUPD<613//MUSTINI
String aPath;
SfxBmkMenu** ppMenu;
sal_uInt16 nKey;
@@ -1119,6 +1171,37 @@ PopupMenu* SfxAppData_Impl::GetPopupMenu( sal_uInt16 nSID, sal_Bool bBig, sal_Bo
(*ppMenu)->Initialize();
}
return ppMenu ? *ppMenu : NULL;
+#else
+ String aPath;
+ SfxBmkMenu** ppMenu;
+ String sKey;
+ switch( nSID )
+ {
+ case SID_NEWDOCDIRECT:
+ ppMenu = &pNewMenu;
+ sKey = SvtPathOptions().GetNewMenuPath();
+ break;
+ case SID_AUTOPILOTMENU:
+ ppMenu = &pAutoPilotMenu;
+ sKey = SvtPathOptions().GetAutoPilotPath();
+ break;
+ default:
+ ppMenu = 0;
+ DBG_ERROR( "Menu ID unknown!" );
+ break;
+ }
+
+ if( ppMenu && ( !*ppMenu || bNew ) )
+ {
+ INetURLObject aObj( sKey, INET_PROT_FILE );
+ String aURL = aObj.GetMainURL();
+ if ( *ppMenu )
+ delete *ppMenu;
+ *ppMenu = new SfxBmkMenu( aURL, aURL );
+ (*ppMenu)->Initialize();
+ }
+ return ppMenu ? *ppMenu : NULL;
+#endif
}
SfxMenuBarManager* SfxApplication::GetMenuBarManager() const
diff --git a/sfx2/source/appl/appopen.cxx b/sfx2/source/appl/appopen.cxx
index 82482afc85..077ef6999e 100644
--- a/sfx2/source/appl/appopen.cxx
+++ b/sfx2/source/appl/appopen.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: appopen.cxx,v $
*
- * $Revision: 1.10 $
+ * $Revision: 1.11 $
*
- * last change: $Author: mba $ $Date: 2000-10-23 12:23:17 $
+ * last change: $Author: as $ $Date: 2000-11-08 14:25:41 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -125,6 +125,10 @@
#include <svtools/urihelper.hxx>
#include <comphelper/processfactory.hxx>
+#ifndef INCLUDED_SVTOOLS_PATHOPTIONS_HXX
+#include <svtools/pathoptions.hxx>
+#endif
+
#pragma hdrstop
#include "app.hxx"
@@ -789,6 +793,7 @@ void SfxApplication::NewDocDirectExec_Impl( SfxRequest& rReq )
BOOL bBookmark=TRUE;
if( aURLObj.GetProtocol() == INET_PROT_FILE )
{
+#if SUPD<613//MUSTINI
SfxIniManager* pMgr = GetIniManager();
SfxIniKey aKey[] =
{
@@ -818,6 +823,24 @@ void SfxApplication::NewDocDirectExec_Impl( SfxRequest& rReq )
}
++nIndex;
}
+#else
+ SvtPathOptions aPathCFG;
+ USHORT nPathLevel = aURLObj.getSegmentCount();
+ INetURLObject aNewPathObj = INetURLObject( aPathCFG.GetNewMenuPath(), INET_PROT_FILE );
+ USHORT nNewLevel = aNewPathObj.getSegmentCount();
+ int nOffset = nPathLevel;
+ nOffset -= nNewLevel;
+ if ( nOffset >= 0 )
+ {
+ INetURLObject aTempObj = aURLObj;
+ for ( ; nOffset > 0; nOffset-- )
+ aTempObj.removeSegment();
+ if ( aTempObj == aNewPathObj )
+ {
+ bBookmark = FALSE;
+ }
+ }
+#endif
}
if ( !bBookmark && pPath )
@@ -1036,6 +1059,7 @@ SfxFrame* SfxApplication::GetTargetFrame_Impl( const SfxItemSet* pSet, BOOL& rbO
aURLObj.SetSmartURL( pRefererItem->GetValue() );
if ( aURLObj.GetProtocol() == INET_PROT_FILE && ( !pFrame || pFrame->IsTop() ) )
{
+#if SUPD<613//MUSTINI
SfxIniManager* pIniMgr = GetIniManager();
INetURLObject aStartMenuObj( pIniMgr->Get( SFX_KEY_STARTMENU_DIR ), INET_PROT_FILE );
INetURLObject aQuickStartObj( pIniMgr->Get( SFX_KEY_QUICKSTART_DIR ), INET_PROT_FILE );
@@ -1044,6 +1068,13 @@ SfxFrame* SfxApplication::GetTargetFrame_Impl( const SfxItemSet* pSet, BOOL& rbO
aTargetName = String::CreateFromAscii( "_blank" );
pTargetItem = NULL;
}
+#else
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ DBG_ASSERT(sal_False, "SfxApplication::GetTargetFrame_Impl()\nStartMenu-Dir & QuickStart-Dir no longer supported!\n");
+#endif
+ aTargetName = String::CreateFromAscii( "_blank" );
+ pTargetItem = NULL;
+#endif
}
}
@@ -1148,7 +1179,11 @@ void SfxApplication::OpenDocExec_Impl( SfxRequest& rReq )
String aPath;
if ( nSID == SID_OPENTEMPLATE )
{
+#if SUPD<613//MUSTINI
aPath = GetIniManager()->Get( SFX_KEY_TEMPLATE_PATH );
+#else
+ aPath = SvtPathOptions().GetTemplatePath();
+#endif
aPath = aPath.GetToken(0,';');
}
diff --git a/sfx2/source/appl/appquit.cxx b/sfx2/source/appl/appquit.cxx
index dc510b420b..b184bc6999 100644
--- a/sfx2/source/appl/appquit.cxx
+++ b/sfx2/source/appl/appquit.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: appquit.cxx,v $
*
- * $Revision: 1.4 $
+ * $Revision: 1.5 $
*
- * last change: $Author: mba $ $Date: 2000-10-04 17:34:23 $
+ * last change: $Author: as $ $Date: 2000-11-08 14:25:41 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -248,7 +248,9 @@ void SfxApplication::Deinitialize()
return;
// Falls man nochmal beim Runterfahren in ein Reschedule l"auft
+#if SUPD<613//MUSTINI
pAppData_Impl->EndListening( *pAppIniMgr );
+#endif
pAppData_Impl->EndListening( *this );
if ( pAppData_Impl->pCancelMgr )
pAppData_Impl->EndListening( *pAppData_Impl->pCancelMgr );
@@ -341,7 +343,9 @@ void SfxApplication::Deinitialize()
DELETEX(pAppData_Impl->pInitLinkList);
#endif
+#if SUPD<613//MUSTINI
pAppIniMgr->LeaveLock();
+#endif
DELETEZ(pCfgMgr);
#ifndef PRODUCT
diff --git a/sfx2/source/appl/appreg.cxx b/sfx2/source/appl/appreg.cxx
index e0af19dcec..9866894936 100644
--- a/sfx2/source/appl/appreg.cxx
+++ b/sfx2/source/appl/appreg.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: appreg.cxx,v $
*
- * $Revision: 1.3 $
+ * $Revision: 1.4 $
*
- * last change: $Author: mba $ $Date: 2000-10-23 12:10:27 $
+ * last change: $Author: as $ $Date: 2000-11-08 14:25:41 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -62,9 +62,13 @@
#ifndef _SV_CONFIG_HXX
#include <vcl/config.hxx>
#endif
+#if SUPD<613//MUSTINI
#ifndef _SFXINIMGR_HXX //autogen
#include <svtools/iniman.hxx>
#endif
+#endif
+
+#include <app.hxx>
#pragma hdrstop
diff --git a/sfx2/source/appl/appserv.cxx b/sfx2/source/appl/appserv.cxx
index 44a69d1edd..b221c8fce2 100644
--- a/sfx2/source/appl/appserv.cxx
+++ b/sfx2/source/appl/appserv.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: appserv.cxx,v $
*
- * $Revision: 1.4 $
+ * $Revision: 1.5 $
*
- * last change: $Author: mba $ $Date: 2000-10-23 12:23:17 $
+ * last change: $Author: as $ $Date: 2000-11-08 14:25:41 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -115,6 +115,8 @@
#include <svtools/ehdl.hxx>
#endif
+#include <svtools/pathoptions.hxx>
+
#pragma hdrstop
#include "appimp.hxx"
@@ -138,7 +140,9 @@
#include "new.hxx"
#include "docinf.hxx"
#include "templdlg.hxx"
+#if SUPD<613//MUSTINI
#include "inimgr.hxx"
+#endif
#include "sfxtypes.hxx"
#include "sfxbasic.hxx"
#include "tabdlg.hxx"
@@ -197,6 +201,7 @@ BOOL SfxApplication::InitOfficeAppType_Impl( USHORT nAppId, ApplicationType& rTy
return FALSE;
// App in Config suchen
String aAppName = String( SfxResId( nAppId ) );
+#if SUPD<613//MUSTINI
SfxIniManager* pIni = SFX_INIMANAGER();
DBG_ASSERT( pIni, "Kein IniManager?!" );
String aFullName;
@@ -206,6 +211,9 @@ BOOL SfxApplication::InitOfficeAppType_Impl( USHORT nAppId, ApplicationType& rTy
if ( !aFullName.Len() )
pIni = pIni->GetSubManager();
}
+#else
+ String aFullName;
+#endif
if ( !aFullName.Len() )
{
@@ -381,8 +389,11 @@ void SfxApplication::BasicLibExec_Impl( SfxRequest &rReq, BasicManager *pMgr )
INetURLObject aOld( aFileName, INET_PROT_FILE );
aDest = aOld.GetName();
}
-
+#if SUPD<613//MUSTINI
INetURLObject aNew( SFX_INIMANAGER()->Get( SFX_KEY_BASIC_PATH ).GetToken( 0, ';' ), INET_PROT_FILE );
+#else
+ INetURLObject aNew( SvtPathOptions().GetBasicPath().GetToken( 0, ';' ), INET_PROT_FILE );
+#endif
aNew.SetExtension( aExt );
pMgr->SetLibStorageName( nLib, aNew.GetFull() );
SaveBasicManager();
@@ -627,7 +638,11 @@ void SfxApplication::MiscExec_Impl( SfxRequest& rReq )
if ( aObj.HasError() )
{
// Wenn relativ, ConfigDir verwenden
+#if SUPD<613//MUSTINI
aObj.SetSmartURL( SFX_INIMANAGER()->Get( SFX_KEY_USERCONFIG_PATH) );
+#else
+ aObj.SetSmartURL( SvtPathOptions().GetUserConfigPath() );
+#endif
aObj.insertName( pStringItem->GetValue() );
aCfgName = aObj.PathToFileName();
}
@@ -690,7 +705,11 @@ void SfxApplication::MiscExec_Impl( SfxRequest& rReq )
if ( aObj.HasError() )
{
// Wenn relativ, ConfigDir verwenden
+#if SUPD<613//MUSTINI
aObj.SetSmartURL( SFX_INIMANAGER()->Get( SFX_KEY_USERCONFIG_PATH) );
+#else
+ aObj.SetSmartURL( SvtPathOptions().GetUserConfigPath() );
+#endif
aObj.insertName( pStringItem->GetValue() );
aCfgName = aObj.PathToFileName();
}
diff --git a/sfx2/source/appl/appuno.cxx b/sfx2/source/appl/appuno.cxx
index 7aebb698b6..ed392894a3 100644
--- a/sfx2/source/appl/appuno.cxx
+++ b/sfx2/source/appl/appuno.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: appuno.cxx,v $
*
- * $Revision: 1.5 $
+ * $Revision: 1.6 $
*
- * last change: $Author: mba $ $Date: 2000-10-23 12:23:17 $
+ * last change: $Author: as $ $Date: 2000-11-08 14:25:41 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -178,7 +178,9 @@ using namespace ::rtl;
#include "sfxuno.hxx"
#include "appdata.hxx"
#include "app.hxx"
+#if SUPD<613//MUSTINI
#include "inimgr.hxx"
+#endif
#include "sfxsids.hrc"
#include "msg.hxx"
#include "msgpool.hxx"
@@ -310,8 +312,14 @@ void TransformParameters( sal_uInt16 nSlotId, const ::com::sun::star::uno::Seque
String aPar = *((::rtl::OUString*)rProp.Value.getValue());
Size aSize;
Point aPos;
+#if SUPD<613//MUSTINI
if ( SfxIniManager::GetPosSize( aPar, aPos, aSize ) )
rSet.Put( SfxRectangleItem( SID_VIEW_POS_SIZE, Rectangle( aPos, aSize ) ) );
+#else
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ DBG_ASSERT( sal_False, "TransformParameters()\nProperty \"PosSize\" isn't supported yet!\n" );
+#endif
+#endif
}
// CharacterSet-Property?
@@ -486,7 +494,13 @@ void TransformItems( sal_uInt16 nSlotId, const SfxItemSet& rSet, ::com::sun::sta
{
pValue[nItems].Name = sPosSize;
Rectangle aRect = pRectItem->GetValue();
+#if SUPD<613//MUSTINI
pValue[nItems++].Value <<= ( ::rtl::OUString(SfxIniManager::GetString( aRect.TopLeft(), aRect.GetSize() ) ) );
+#else
+#ifdef ENABLE_MISSINGKEYASSERTIONS//MUSTINI
+ DBG_ASSERT(sal_False, "TransformItems()\nSfxIniManager::GetString used to set property \"PosSize\" ...!\n");
+#endif
+#endif
}
SFX_ITEMSET_ARG( &rSet, pRefItem, SfxRefItem, SID_POSTLOCKBYTES, sal_False );
@@ -718,11 +732,13 @@ void SfxComponentFactory::Init_Impl()
{
Reference< XFrameLoader > xLoader;
#ifdef WNT
+#if SUPD<613//MUSTINI module iexplorer no longer supported!
SfxIniManager* pIni = SfxIniManager::Get();
if( !Application::IsRemoteServer() && pIni->IsInternetExplorerAvailable() )
xLoader = Reference< XFrameLoader >( createInstance( DEFINE_CONST_UNICODE("private:iexplorer") ), ::com::sun::star::uno::UNO_QUERY );
if ( !xLoader.is() )
#endif
+#endif
xLoader = Reference< XFrameLoader >( createInstance( DEFINE_CONST_UNICODE(".component:Text") ), ::com::sun::star::uno::UNO_QUERY );
return xLoader;
}
diff --git a/sfx2/source/appl/childwin.cxx b/sfx2/source/appl/childwin.cxx
index 8ca86f5cde..8f3b6c3f8c 100644
--- a/sfx2/source/appl/childwin.cxx
+++ b/sfx2/source/appl/childwin.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: childwin.cxx,v $
*
- * $Revision: 1.1.1.1 $
+ * $Revision: 1.2 $
*
- * last change: $Author: hr $ $Date: 2000-09-18 16:52:27 $
+ * last change: $Author: as $ $Date: 2000-11-08 14:25:41 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -59,9 +59,11 @@
*
************************************************************************/
+#if SUPD<613//MUSTINI
#ifndef _SFXINIMGR_HXX //autogen
#include <svtools/iniman.hxx>
#endif
+#endif
#ifndef _TOOLBOX_HXX //autogen
#include <vcl/toolbox.hxx>
#endif
@@ -223,7 +225,8 @@ void SfxChildWindow::SaveStatus(const SfxChildWinInfo& rInfo)
{
// if ( SFX_APP()->Get_Impl()->bBean )
// return;
-
+#if SUPD<613//MUSTINI
+/* TODO: Which key we can use to save this information in our configuration? */
SfxIniManager *pIniMgr = SFX_INIMANAGER();
char cToken = pIniMgr->GetToken();;
String aWinData('V');
@@ -240,6 +243,7 @@ void SfxChildWindow::SaveStatus(const SfxChildWinInfo& rInfo)
aWinData += rInfo.aExtraString;
}
pIniMgr->Set( aWinData, SFX_KEY_WINDOW, GetType() );
+#endif
pImp->pFact->aInfo = rInfo;
}
@@ -282,8 +286,12 @@ sal_uInt16 SfxChildWindow::GetPosition()
void SfxChildWindow::InitializeChildWinFactory_Impl( sal_uInt16 nId, SfxChildWinInfo& rInfo )
{
// Konfiguration aus Ini-Manager laden
+#if SUPD<613//MUSTINI
SfxIniManager *pAppIniMgr = SFX_APP()->GetAppIniManager();
String aWinData( pAppIniMgr->Get( SFX_KEY_WINDOW, nId ) );
+#else
+ String aWinData;
+#endif
if ( /*!SFX_APP()->Get_Impl()->bBean && */ aWinData.Len() )
{
@@ -296,11 +304,16 @@ void SfxChildWindow::InitializeChildWinFactory_Impl( sal_uInt16 nId, SfxChildWin
aWinData.Erase(0,1);
// Version lesen
+#if SUPD<613//MUSTINI
char cToken = pAppIniMgr->GetToken();
+#else
+ char cToken = ',';
+#endif
sal_uInt16 nPos = aWinData.Search( cToken );
sal_uInt16 nVersion = (sal_uInt16) aWinData.Copy( 0, nPos+1 ).ToInt32();
aWinData.Erase(0,nPos+1);
+#if SUPD<613//MUSTINI
// Gr"o\se und Position laden
Point aPos;
Size aSize;
@@ -311,13 +324,17 @@ void SfxChildWindow::InitializeChildWinFactory_Impl( sal_uInt16 nId, SfxChildWin
rInfo.aPos = aPos;
rInfo.aSize = aSize;
}
+#endif
aWinData.Erase(0,aWinData.Search(cToken));
// Sichtbarkeit laden: ist als ein char codiert
rInfo.bVisible = (aWinData.Copy(1,1) == 0x0056); // 'V' = 56h
aWinData.Erase(1,1);
-
+#if SUPD<613//MUSTINI
nPos = aWinData.Search( pAppIniMgr->GetToken(), 2 );
+#else
+ nPos = aWinData.Search( cToken, 2 );
+#endif
if (nPos != STRING_NOTFOUND)
{
// es gibt noch Extra-Information
@@ -561,6 +578,7 @@ sal_Bool SfxChildWinInfo::GetExtraData_Impl
// Dockt nicht in einem Splitwindow
return sal_True;
aStr.Erase(0, nPos+1);
+#if SUPD<613//MUSTINI
SfxIniManager *pAppIniMgr = SFX_APP()->GetAppIniManager();
Point aPos;
Size aSize;
@@ -574,7 +592,7 @@ sal_Bool SfxChildWinInfo::GetExtraData_Impl
*pPos = (sal_uInt16) aPos.Y();
return sal_True;
}
-
+#endif
return sal_False;
}
diff --git a/sfx2/source/appl/sfxhelp.cxx b/sfx2/source/appl/sfxhelp.cxx
index 6cb57e53f4..344d6695ef 100644
--- a/sfx2/source/appl/sfxhelp.cxx
+++ b/sfx2/source/appl/sfxhelp.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: sfxhelp.cxx,v $
*
- * $Revision: 1.3 $
+ * $Revision: 1.4 $
*
- * last change: $Author: mba $ $Date: 2000-10-04 17:34:23 $
+ * last change: $Author: as $ $Date: 2000-11-08 14:25:41 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -71,9 +71,11 @@
#ifndef _SFXITEMSET_HXX //autogen
#include <svtools/itemset.hxx>
#endif
+#if SUPD<613//MUSTINI
#ifndef _SFXINIMGR_HXX //autogen
#include <svtools/iniman.hxx>
#endif
+#endif
#ifndef _WRKWIN_HXX //autogen
#include <vcl/wrkwin.hxx>
#endif
@@ -107,6 +109,7 @@
#endif
#include <automation/automation.hxx>
+#include <svtools/pathoptions.hxx>
#pragma hdrstop
#ifndef _SFXENUMITEM_HXX //autogen
@@ -953,10 +956,14 @@ void SfxHelp_Impl::AssertValidHelpDocInfo()
String SfxHelp_Impl::GetHelpPath()
{
+#if SUPD<613//MUSTINI
SfxIniManager* pIni = SFX_INIMANAGER()->Find( SFX_KEY_HELP_DIR );
if ( !pIni )
pIni = SFX_INIMANAGER();
String aHelpDir = pIni->Get( SFX_KEY_HELP_DIR );
+#else
+ String aHelpDir = SvtPathOptions().GetHelpPath();
+#endif
if ( aHelpDir.Len() )
{
@@ -1083,11 +1090,25 @@ void SfxHelp_Impl::ResetPIStarterList()
String SfxHelp_Impl::GetConfigDir( BOOL bGetSharedConfig )
{
+#if SUPD<613//MUSTINI
ULONG nKey = bGetSharedConfig ? SFX_KEY_CONFIG_DIR : SFX_KEY_USERCONFIG_PATH;
SfxIniManager* pIni = SFX_INIMANAGER()->Find( nKey );
if ( !pIni )
pIni = SFX_INIMANAGER();
return pIni->Get( nKey );
+#else
+ String sConfigDir;
+ SvtPathOptions aPathCFG;
+ if( bGetSharedConfig == sal_True )
+ {
+ sConfigDir = aPathCFG.GetConfigPath();
+ }
+ else
+ {
+ sConfigDir = aPathCFG.GetUserConfigPath();
+ }
+ return sConfigDir;
+#endif
}
String SfxHelp_Impl::GetHelpAgentConfig()