summaryrefslogtreecommitdiff
path: root/unotools/source/config
diff options
context:
space:
mode:
Diffstat (limited to 'unotools/source/config')
-rw-r--r--unotools/source/config/accelcfg.cxx33
-rw-r--r--unotools/source/config/cmdoptions.cxx109
-rw-r--r--unotools/source/config/dynamicmenuoptions.cxx108
-rw-r--r--unotools/source/config/fontoptions.cxx60
-rw-r--r--unotools/source/config/historyoptions.cxx63
-rw-r--r--unotools/source/config/lingucfg.cxx37
-rw-r--r--unotools/source/config/localisationoptions.cxx60
-rw-r--r--unotools/source/config/pathoptions.cxx23
-rw-r--r--unotools/source/config/saveopt.cxx31
-rw-r--r--unotools/source/config/startoptions.cxx50
-rw-r--r--unotools/source/config/syslocaleoptions.cxx7
11 files changed, 1 insertions, 580 deletions
diff --git a/unotools/source/config/accelcfg.cxx b/unotools/source/config/accelcfg.cxx
index 200266cd17f3..f780df1f3442 100644
--- a/unotools/source/config/accelcfg.cxx
+++ b/unotools/source/config/accelcfg.cxx
@@ -202,25 +202,6 @@ SvtAcceleratorConfiguration::~SvtAcceleratorConfiguration()
}
}
-::rtl::OUString SvtAcceleratorConfiguration::GetCommand( const ::com::sun::star::awt::KeyEvent& rKeyEvent )
-{
- sal_Int16 nCode=rKeyEvent.KeyCode, nModifier=rKeyEvent.Modifiers;
- if ( !nCode )
- nCode = rKeyEvent.KeyFunc;
-
- std::list< SvtAcceleratorConfigItem>::const_iterator p;
- for ( p = pImp->aList.begin(); p != pImp->aList.end(); ++p )
- if ( p->nCode == nCode && p->nModifier == nModifier )
- return p->aCommand;
-
- return ::rtl::OUString();
-}
-
-const SvtAcceleratorItemList& SvtAcceleratorConfiguration::GetItems()
-{
- return pImp->aList;
-}
-
void SvtAcceleratorConfiguration::SetCommand( const SvtAcceleratorConfigItem& rItem )
{
std::list< SvtAcceleratorConfigItem>::iterator p;
@@ -235,20 +216,6 @@ void SvtAcceleratorConfiguration::SetCommand( const SvtAcceleratorConfigItem& rI
}
-void SvtAcceleratorConfiguration::SetItems( const SvtAcceleratorItemList& rItems, bool bClear )
-{
- if ( bClear )
- {
- pImp->aList = rItems;
- }
- else
- {
- std::list< SvtAcceleratorConfigItem>::const_iterator p;
- for ( p = rItems.begin(); p != rItems.end(); ++p )
- SetCommand( *p );
- }
-}
-
String SvtAcceleratorConfiguration::GetStreamName()
{
return String::CreateFromAscii("KeyBindings.xml");
diff --git a/unotools/source/config/cmdoptions.cxx b/unotools/source/config/cmdoptions.cxx
index e6568bc4d683..e17672b1464d 100644
--- a/unotools/source/config/cmdoptions.cxx
+++ b/unotools/source/config/cmdoptions.cxx
@@ -26,11 +26,6 @@
*
************************************************************************/
-
-//_________________________________________________________________________________________________________________
-// includes
-//_________________________________________________________________________________________________________________
-
#include <unotools/cmdoptions.hxx>
#include <unotools/configmgr.hxx>
#include <unotools/configitem.hxx>
@@ -47,10 +42,6 @@
#include <algorithm>
#include <boost/unordered_map.hpp>
-//_________________________________________________________________________________________________________________
-// namespaces
-//_________________________________________________________________________________________________________________
-
using namespace ::std ;
using namespace ::utl ;
using namespace ::rtl ;
@@ -58,10 +49,6 @@ using namespace ::osl ;
using namespace ::com::sun::star::uno ;
using namespace ::com::sun::star::beans ;
-//_________________________________________________________________________________________________________________
-// const
-//_________________________________________________________________________________________________________________
-
#define ROOTNODE_CMDOPTIONS OUString(RTL_CONSTASCII_USTRINGPARAM("Office.Commands/Execute" ))
#define PATHDELIMITER OUString(RTL_CONSTASCII_USTRINGPARAM("/" ))
@@ -73,10 +60,6 @@ using namespace ::com::sun::star::beans ;
#define OFFSET_CMD 0
-//_________________________________________________________________________________________________________________
-// private declarations!
-//_________________________________________________________________________________________________________________
-
// Method to retrieve a hash code from a string. May be we have to change it to decrease collisions in the hash map
struct OUStringHashCode
{
@@ -156,23 +139,11 @@ typedef ::std::vector< ::com::sun::star::uno::WeakReference< ::com::sun::star::f
class SvtCommandOptions_Impl : public ConfigItem
{
- //-------------------------------------------------------------------------------------------------------------
- // public methods
- //-------------------------------------------------------------------------------------------------------------
-
public:
- //---------------------------------------------------------------------------------------------------------
- // constructor / destructor
- //---------------------------------------------------------------------------------------------------------
-
SvtCommandOptions_Impl();
~SvtCommandOptions_Impl();
- //---------------------------------------------------------------------------------------------------------
- // overloaded methods of baseclass
- //---------------------------------------------------------------------------------------------------------
-
/*-****************************************************************************************************//**
@short called for notify of configmanager
@descr These method is called from the ConfigManager before application ends or from the
@@ -204,10 +175,6 @@ class SvtCommandOptions_Impl : public ConfigItem
virtual void Commit();
- //---------------------------------------------------------------------------------------------------------
- // public interface
- //---------------------------------------------------------------------------------------------------------
-
/*-****************************************************************************************************//**
@short base implementation of public interface for "SvtDynamicMenuOptions"!
@descr These class is used as static member of "SvtDynamicMenuOptions" ...
@@ -221,18 +188,10 @@ class SvtCommandOptions_Impl : public ConfigItem
@onerror -
*//*-*****************************************************************************************************/
- void Clear ( SvtCommandOptions::CmdOption eCmdOption );
sal_Bool HasEntries ( SvtCommandOptions::CmdOption eOption ) const;
sal_Bool Lookup ( SvtCommandOptions::CmdOption eCmdOption, const OUString& ) const;
- Sequence< OUString > GetList ( SvtCommandOptions::CmdOption eCmdOption ) const ;
- void AddCommand ( SvtCommandOptions::CmdOption eCmdOption,
- const OUString& sURL );
void EstablisFrameCallback(const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& xFrame);
- //-------------------------------------------------------------------------------------------------------------
- // private methods
- //-------------------------------------------------------------------------------------------------------------
-
private:
/*-****************************************************************************************************//**
@@ -250,19 +209,11 @@ class SvtCommandOptions_Impl : public ConfigItem
Sequence< OUString > impl_GetPropertyNames();
- //-------------------------------------------------------------------------------------------------------------
- // private member
- //-------------------------------------------------------------------------------------------------------------
-
private:
SvtCmdOptions m_aDisabledCommands;
SvtFrameVector m_lFrames;
};
-//_________________________________________________________________________________________________________________
-// definitions
-//_________________________________________________________________________________________________________________
-
//*****************************************************************************************************************
// constructor
//*****************************************************************************************************************
@@ -367,25 +318,6 @@ void SvtCommandOptions_Impl::Commit()
//*****************************************************************************************************************
// public method
//*****************************************************************************************************************
-void SvtCommandOptions_Impl::Clear( SvtCommandOptions::CmdOption eCmdOption )
-{
- switch( eCmdOption )
- {
- case SvtCommandOptions::CMDOPTION_DISABLED:
- {
- m_aDisabledCommands.Clear();
- SetModified();
- }
- break;
-
- default:
- DBG_ASSERT( sal_False, "SvtCommandOptions_Impl::Clear()\nUnknown option type given!\n" );
- }
-}
-
-//*****************************************************************************************************************
-// public method
-//*****************************************************************************************************************
sal_Bool SvtCommandOptions_Impl::HasEntries( SvtCommandOptions::CmdOption eOption ) const
{
if ( eOption == SvtCommandOptions::CMDOPTION_DISABLED )
@@ -397,28 +329,6 @@ sal_Bool SvtCommandOptions_Impl::HasEntries( SvtCommandOptions::CmdOption eOptio
//*****************************************************************************************************************
// public method
//*****************************************************************************************************************
-Sequence< OUString > SvtCommandOptions_Impl::GetList( SvtCommandOptions::CmdOption eCmdOption ) const
-{
- Sequence< OUString > lReturn;
-
- switch( eCmdOption )
- {
- case SvtCommandOptions::CMDOPTION_DISABLED:
- {
- lReturn = m_aDisabledCommands.GetList();
- }
- break;
-
- default:
- DBG_ASSERT( sal_False, "SvtCommandOptions_Impl::GetList()\nUnknown option type given!\n" );
- }
-
- return lReturn;
-}
-
-//*****************************************************************************************************************
-// public method
-//*****************************************************************************************************************
sal_Bool SvtCommandOptions_Impl::Lookup( SvtCommandOptions::CmdOption eCmdOption, const OUString& aCommand ) const
{
switch( eCmdOption )
@@ -437,25 +347,6 @@ sal_Bool SvtCommandOptions_Impl::Lookup( SvtCommandOptions::CmdOption eCmdOption
//*****************************************************************************************************************
// public method
//*****************************************************************************************************************
-void SvtCommandOptions_Impl::AddCommand( SvtCommandOptions::CmdOption eCmdOption, const OUString& sCmd )
-{
- switch( eCmdOption )
- {
- case SvtCommandOptions::CMDOPTION_DISABLED:
- {
- m_aDisabledCommands.AddCommand( sCmd );
- SetModified();
- }
- break;
-
- default:
- DBG_ASSERT( sal_False, "SvtCommandOptions_Impl::GetList()\nUnknown option type given!\n" );
- }
-}
-
-//*****************************************************************************************************************
-// public method
-//*****************************************************************************************************************
void SvtCommandOptions_Impl::EstablisFrameCallback(const ::com::sun::star::uno::Reference< ::com::sun::star::frame::XFrame >& xFrame)
{
// check if frame already exists inside list
diff --git a/unotools/source/config/dynamicmenuoptions.cxx b/unotools/source/config/dynamicmenuoptions.cxx
index 2f676be1ddeb..c972c933b400 100644
--- a/unotools/source/config/dynamicmenuoptions.cxx
+++ b/unotools/source/config/dynamicmenuoptions.cxx
@@ -41,10 +41,6 @@
#include <algorithm>
-//_________________________________________________________________________________________________________________
-// namespaces
-//_________________________________________________________________________________________________________________
-
using namespace ::std ;
using namespace ::utl ;
using namespace ::rtl ;
@@ -52,10 +48,6 @@ using namespace ::osl ;
using namespace ::com::sun::star::uno ;
using namespace ::com::sun::star::beans ;
-//_________________________________________________________________________________________________________________
-// const
-//_________________________________________________________________________________________________________________
-
#define ROOTNODE_MENUS OUString(RTL_CONSTASCII_USTRINGPARAM("Office.Common/Menus/" ))
#define PATHDELIMITER OUString(RTL_CONSTASCII_USTRINGPARAM("/" ))
@@ -78,10 +70,6 @@ using namespace ::com::sun::star::beans ;
#define PATHPREFIX_SETUP OUString(RTL_CONSTASCII_USTRINGPARAM("m" ))
#define PATHPREFIX_USER OUString(RTL_CONSTASCII_USTRINGPARAM("u" ))
-//_________________________________________________________________________________________________________________
-// private declarations!
-//_________________________________________________________________________________________________________________
-
/*-****************************************************************************************************************
@descr struct to hold information about one menu entry.
****************************************************************************************************************-*/
@@ -115,7 +103,6 @@ struct SvtDynMenuEntry
class SvtDynMenu
{
public:
- //---------------------------------------------------------------------------------------------------------
// append setup written menu entry
// Don't touch name of entry. It was defined by setup and must be the same everytime!
// Look for double menu entries here too ... may be some seperator items are supeflous ...
@@ -130,7 +117,6 @@ class SvtDynMenu
}
}
- //---------------------------------------------------------------------------------------------------------
// append user specific menu entry
// We must find unique name for it by using special prefix
// and next count of user setted entries!
@@ -148,7 +134,6 @@ class SvtDynMenu
}
}
- //---------------------------------------------------------------------------------------------------------
// the only way to free memory!
void Clear()
{
@@ -156,7 +141,6 @@ class SvtDynMenu
lUserEntries.clear();
}
- //---------------------------------------------------------------------------------------------------------
// convert internal list to external format
// for using it on right menus realy
// Notice: We build a property list with 4 entries and set it on result list then.
@@ -212,7 +196,7 @@ class SvtDynMenu
}
private:
- //---------------------------------------------------------------------------------------------------------
+
// search for an entry named "ux" with x=[0..i] inside our menu
// which has set highest number x. So we can add another user entry.
sal_Int32 impl_getNextUserEntryNr() const
@@ -244,23 +228,11 @@ class SvtDynMenu
class SvtDynamicMenuOptions_Impl : public ConfigItem
{
- //-------------------------------------------------------------------------------------------------------------
- // public methods
- //-------------------------------------------------------------------------------------------------------------
-
public:
- //---------------------------------------------------------------------------------------------------------
- // constructor / destructor
- //---------------------------------------------------------------------------------------------------------
-
SvtDynamicMenuOptions_Impl();
~SvtDynamicMenuOptions_Impl();
- //---------------------------------------------------------------------------------------------------------
- // overloaded methods of baseclass
- //---------------------------------------------------------------------------------------------------------
-
/*-****************************************************************************************************//**
@short called for notify of configmanager
@descr These method is called from the ConfigManager before application ends or from the
@@ -292,10 +264,6 @@ class SvtDynamicMenuOptions_Impl : public ConfigItem
virtual void Commit();
- //---------------------------------------------------------------------------------------------------------
- // public interface
- //---------------------------------------------------------------------------------------------------------
-
/*-****************************************************************************************************//**
@short base implementation of public interface for "SvtDynamicMenuOptions"!
@descr These class is used as static member of "SvtDynamicMenuOptions" ...
@@ -309,17 +277,7 @@ class SvtDynamicMenuOptions_Impl : public ConfigItem
@onerror -
*//*-*****************************************************************************************************/
- void Clear ( EDynamicMenuType eMenu );
Sequence< Sequence< PropertyValue > > GetMenu ( EDynamicMenuType eMenu ) const ;
- void AppendItem ( EDynamicMenuType eMenu ,
- const OUString& sURL ,
- const OUString& sTitle ,
- const OUString& sImageIdentifier,
- const OUString& sTargetName );
-
- //-------------------------------------------------------------------------------------------------------------
- // private methods
- //-------------------------------------------------------------------------------------------------------------
private:
@@ -393,10 +351,6 @@ class SvtDynamicMenuOptions_Impl : public ConfigItem
SvtDynMenu m_aHelpBookmarksMenu ;
};
-//_________________________________________________________________________________________________________________
-// definitions
-//_________________________________________________________________________________________________________________
-
//*****************************************************************************************************************
// constructor
//*****************************************************************************************************************
@@ -624,33 +578,6 @@ void SvtDynamicMenuOptions_Impl::Commit()
//*****************************************************************************************************************
// public method
//*****************************************************************************************************************
-void SvtDynamicMenuOptions_Impl::Clear( EDynamicMenuType eMenu )
-{
- switch( eMenu )
- {
- case E_NEWMENU : {
- m_aNewMenu.Clear();
- SetModified();
- }
- break;
-
- case E_WIZARDMENU : {
- m_aWizardMenu.Clear();
- SetModified();
- }
- break;
-
- case E_HELPBOOKMARKS : {
- m_aHelpBookmarksMenu.Clear();
- SetModified();
- }
- break;
- }
-}
-
-//*****************************************************************************************************************
-// public method
-//*****************************************************************************************************************
Sequence< Sequence< PropertyValue > > SvtDynamicMenuOptions_Impl::GetMenu( EDynamicMenuType eMenu ) const
{
Sequence< Sequence< PropertyValue > > lReturn;
@@ -675,39 +602,6 @@ Sequence< Sequence< PropertyValue > > SvtDynamicMenuOptions_Impl::GetMenu( EDyna
}
//*****************************************************************************************************************
-// public method
-//*****************************************************************************************************************
-void SvtDynamicMenuOptions_Impl::AppendItem( EDynamicMenuType eMenu ,
- const OUString& sURL ,
- const OUString& sTitle ,
- const OUString& sImageIdentifier,
- const OUString& sTargetName )
-{
- SvtDynMenuEntry aItem( sURL, sTitle, sImageIdentifier, sTargetName );
-
- switch( eMenu )
- {
- case E_NEWMENU : {
- m_aNewMenu.AppendUserEntry( aItem );
- SetModified();
- }
- break;
-
- case E_WIZARDMENU : {
- m_aWizardMenu.AppendUserEntry( aItem );
- SetModified();
- }
- break;
-
- case E_HELPBOOKMARKS : {
- m_aHelpBookmarksMenu.AppendUserEntry( aItem );
- SetModified();
- }
- break;
- }
-}
-
-//*****************************************************************************************************************
// private method
//*****************************************************************************************************************
Sequence< OUString > SvtDynamicMenuOptions_Impl::impl_GetPropertyNames( sal_uInt32& nNewCount, sal_uInt32& nWizardCount, sal_uInt32& nHelpBookmarksCount )
diff --git a/unotools/source/config/fontoptions.cxx b/unotools/source/config/fontoptions.cxx
index 96f5fe6ca25c..d4b52609697f 100644
--- a/unotools/source/config/fontoptions.cxx
+++ b/unotools/source/config/fontoptions.cxx
@@ -38,19 +38,11 @@
#include <rtl/instance.hxx>
#include "itemholder1.hxx"
-//_________________________________________________________________________________________________________________
-// namespaces
-//_________________________________________________________________________________________________________________
-
using namespace ::utl ;
using namespace ::rtl ;
using namespace ::osl ;
using namespace ::com::sun::star::uno ;
-//_________________________________________________________________________________________________________________
-// const
-//_________________________________________________________________________________________________________________
-
#define ROOTNODE_FONT OUString(RTL_CONSTASCII_USTRINGPARAM("Office.Common/Font" ))
#define PROPERTYNAME_REPLACEMENTTABLE OUString(RTL_CONSTASCII_USTRINGPARAM("Substitution/Replacement" ))
@@ -63,29 +55,13 @@ using namespace ::com::sun::star::uno ;
#define PROPERTYCOUNT 3
-//_________________________________________________________________________________________________________________
-// private declarations!
-//_________________________________________________________________________________________________________________
-
class SvtFontOptions_Impl : public ConfigItem
{
- //-------------------------------------------------------------------------------------------------------------
- // public methods
- //-------------------------------------------------------------------------------------------------------------
-
public:
- //---------------------------------------------------------------------------------------------------------
- // constructor / destructor
- //---------------------------------------------------------------------------------------------------------
-
SvtFontOptions_Impl();
~SvtFontOptions_Impl();
- //---------------------------------------------------------------------------------------------------------
- // overloaded methods of baseclass
- //---------------------------------------------------------------------------------------------------------
-
/*-****************************************************************************************************//**
@short called for notify of configmanager
@descr These method is called from the ConfigManager before application ends or from the
@@ -117,10 +93,6 @@ class SvtFontOptions_Impl : public ConfigItem
virtual void Commit();
- //---------------------------------------------------------------------------------------------------------
- // public interface
- //---------------------------------------------------------------------------------------------------------
-
/*-****************************************************************************************************//**
@short access method to get internal values
@descr These method give us a chance to regulate acces to ouer internal values.
@@ -134,19 +106,12 @@ class SvtFontOptions_Impl : public ConfigItem
@onerror -
*//*-*****************************************************************************************************/
- sal_Bool IsReplacementTableEnabled ( ) const ;
- void EnableReplacementTable ( sal_Bool bState ) ;
-
sal_Bool IsFontHistoryEnabled ( ) const ;
void EnableFontHistory ( sal_Bool bState ) ;
sal_Bool IsFontWYSIWYGEnabled ( ) const ;
void EnableFontWYSIWYG ( sal_Bool bState ) ;
- //-------------------------------------------------------------------------------------------------------------
- // private methods
- //-------------------------------------------------------------------------------------------------------------
-
private:
/*-****************************************************************************************************//**
@@ -164,10 +129,6 @@ class SvtFontOptions_Impl : public ConfigItem
static Sequence< OUString > impl_GetPropertyNames();
- //-------------------------------------------------------------------------------------------------------------
- // private member
- //-------------------------------------------------------------------------------------------------------------
-
private:
sal_Bool m_bReplacementTable ;
@@ -175,10 +136,6 @@ class SvtFontOptions_Impl : public ConfigItem
sal_Bool m_bFontWYSIWYG ;
};
-//_________________________________________________________________________________________________________________
-// definitions
-//_________________________________________________________________________________________________________________
-
//*****************************************************************************************************************
// constructor
//*****************************************************************************************************************
@@ -314,23 +271,6 @@ void SvtFontOptions_Impl::Commit()
//*****************************************************************************************************************
// public method
//*****************************************************************************************************************
-sal_Bool SvtFontOptions_Impl::IsReplacementTableEnabled() const
-{
- return m_bReplacementTable;
-}
-
-//*****************************************************************************************************************
-// public method
-//*****************************************************************************************************************
-void SvtFontOptions_Impl::EnableReplacementTable( sal_Bool bState )
-{
- m_bReplacementTable = bState;
- SetModified();
-}
-
-//*****************************************************************************************************************
-// public method
-//*****************************************************************************************************************
sal_Bool SvtFontOptions_Impl::IsFontHistoryEnabled() const
{
return m_bFontHistory;
diff --git a/unotools/source/config/historyoptions.cxx b/unotools/source/config/historyoptions.cxx
index 6c94d5bd6c0d..91b5a88648f6 100644
--- a/unotools/source/config/historyoptions.cxx
+++ b/unotools/source/config/historyoptions.cxx
@@ -55,10 +55,6 @@
#include <unotools/loghelper.hxx>
-//_________________________________________________________________________________________________________________
-// namespaces
-//_________________________________________________________________________________________________________________
-
using namespace ::std ;
using namespace ::utl ;
using namespace ::rtl ;
@@ -68,10 +64,6 @@ using namespace ::com::sun::star::beans ;
namespace css = ::com::sun::star;
-//_________________________________________________________________________________________________________________
-// const
-//_________________________________________________________________________________________________________________
-
namespace {
static const ::sal_Int32 s_nOffsetURL = 0;
static const ::sal_Int32 s_nOffsetFilter = 1;
@@ -79,10 +71,6 @@ namespace {
static const ::sal_Int32 s_nOffsetPassword = 3;
}
-//_________________________________________________________________________________________________________________
-// private declarations!
-//_________________________________________________________________________________________________________________
-
struct IMPL_THistoryItem
{
IMPL_THistoryItem()
@@ -122,7 +110,6 @@ public:
~SvtHistoryOptions_Impl();
sal_uInt32 GetSize( EHistoryType eHistory );
- void SetSize( EHistoryType eHistory, sal_uInt32 nSize );
void Clear( EHistoryType eHistory );
Sequence< Sequence< PropertyValue > > GetList( EHistoryType eHistory );
void AppendItem( EHistoryType eHistory ,
@@ -218,56 +205,6 @@ sal_uInt32 SvtHistoryOptions_Impl::GetSize( EHistoryType eHistory )
}
//*****************************************************************************************************************
-// public method
-// Attention: We return the max. size of our internal lists - That is the capacity not the size!
-//*****************************************************************************************************************
-void SvtHistoryOptions_Impl::SetSize( EHistoryType eHistory, sal_uInt32 nSize )
-{
- css::uno::Reference< css::beans::XPropertySet > xListAccess(m_xCommonXCU, css::uno::UNO_QUERY);
- if (! xListAccess.is ())
- return;
-
- try
- {
- switch( eHistory )
- {
- case ePICKLIST:
- if(nSize!=GetSize(ePICKLIST))
- {
- xListAccess->setPropertyValue(s_sPickListSize, css::uno::makeAny(nSize));
- ::comphelper::ConfigurationHelper::flush(m_xCommonXCU);
- }
- break;
-
- case eHISTORY:
- if(nSize!=GetSize(eHISTORY))
- {
- xListAccess->setPropertyValue(s_sURLHistorySize, css::uno::makeAny(nSize));
- ::comphelper::ConfigurationHelper::flush(m_xCommonXCU);
- }
- break;
-
- case eHELPBOOKMARKS:
- if(nSize!=GetSize(eHELPBOOKMARKS))
- {
- xListAccess->setPropertyValue(s_sHelpBookmarksSize, css::uno::makeAny(nSize));
- ::comphelper::ConfigurationHelper::flush(m_xCommonXCU);
- }
- break;
-
- default:
- break;
- }
-
- impl_truncateList (eHistory, nSize);
- }
- catch(const css::uno::Exception& ex)
- {
- LogHelper::logIt(ex);
- }
-}
-
-//*****************************************************************************************************************
void SvtHistoryOptions_Impl::impl_truncateList ( EHistoryType eHistory, sal_uInt32 nSize )
{
css::uno::Reference< css::container::XNameAccess > xList;
diff --git a/unotools/source/config/lingucfg.cxx b/unotools/source/config/lingucfg.cxx
index 096ccb2950d1..eb4b38164935 100644
--- a/unotools/source/config/lingucfg.cxx
+++ b/unotools/source/config/lingucfg.cxx
@@ -26,8 +26,6 @@
*
************************************************************************/
-
-
#include <com/sun/star/lang/Locale.hpp>
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
#include <com/sun/star/lang/XSingleServiceFactory.hpp>
@@ -59,16 +57,12 @@ using ::rtl::Uri;
#define EXPAND_PROTOCOL "vnd.sun.star.expand:"
#define FILE_PROTOCOL "file:///"
-///////////////////////////////////////////////////////////////////////////
-
namespace
{
class theSvtLinguConfigItemMutex :
public rtl::Static< osl::Mutex, theSvtLinguConfigItemMutex > {};
}
-///////////////////////////////////////////////////////////////////////////
-
static sal_Bool lcl_SetLocale( sal_Int16 &rLanguage, const uno::Any &rVal )
{
sal_Bool bSucc = sal_False;
@@ -86,7 +80,6 @@ static sal_Bool lcl_SetLocale( sal_Int16 &rLanguage, const uno::Any &rVal )
return bSucc;
}
-
static inline const OUString lcl_LanguageToCfgLocaleStr( sal_Int16 nLanguage )
{
OUString aRes;
@@ -95,7 +88,6 @@ static inline const OUString lcl_LanguageToCfgLocaleStr( sal_Int16 nLanguage )
return aRes;
}
-
static sal_Int16 lcl_CfgAnyToLanguage( const uno::Any &rVal )
{
OUString aTmp;
@@ -103,9 +95,6 @@ static sal_Int16 lcl_CfgAnyToLanguage( const uno::Any &rVal )
return (aTmp.getLength() == 0) ? LANGUAGE_SYSTEM : MsLangId::convertIsoStringToLanguage( aTmp );
}
-
-//////////////////////////////////////////////////////////////////////
-
SvtLinguOptions::SvtLinguOptions()
{
nDefaultLanguage = LANGUAGE_NONE;
@@ -154,10 +143,6 @@ SvtLinguOptions::SvtLinguOptions()
}
-
-//////////////////////////////////////////////////////////////////////
-
-
class SvtLinguConfigItem : public utl::ConfigItem
{
SvtLinguOptions aOpt;
@@ -856,7 +841,6 @@ SvtLinguConfig::SvtLinguConfig()
++nCfgItemRefCount;
}
-
SvtLinguConfig::~SvtLinguConfig()
{
osl::MutexGuard aGuard(theSvtLinguConfigItemMutex::get());
@@ -872,7 +856,6 @@ SvtLinguConfig::~SvtLinguConfig()
}
}
-
SvtLinguConfigItem & SvtLinguConfig::GetConfigItem()
{
// Global access, must be guarded (multithreading)
@@ -885,72 +868,52 @@ SvtLinguConfigItem & SvtLinguConfig::GetConfigItem()
return *pCfgItem;
}
-
uno::Sequence< OUString > SvtLinguConfig::GetNodeNames( const OUString &rNode )
{
return GetConfigItem().GetNodeNames( rNode );
}
-
uno::Sequence< uno::Any > SvtLinguConfig::GetProperties( const uno::Sequence< OUString > &rNames )
{
return GetConfigItem().GetProperties(rNames);
}
-
sal_Bool SvtLinguConfig::ReplaceSetProperties(
const OUString &rNode, uno::Sequence< beans::PropertyValue > rValues )
{
return GetConfigItem().ReplaceSetProperties( rNode, rValues );
}
-
uno::Any SvtLinguConfig::GetProperty( const OUString &rPropertyName ) const
{
return GetConfigItem().GetProperty( rPropertyName );
}
-
uno::Any SvtLinguConfig::GetProperty( sal_Int32 nPropertyHandle ) const
{
return GetConfigItem().GetProperty( nPropertyHandle );
}
-
sal_Bool SvtLinguConfig::SetProperty( const OUString &rPropertyName, const uno::Any &rValue )
{
return GetConfigItem().SetProperty( rPropertyName, rValue );
}
-
sal_Bool SvtLinguConfig::SetProperty( sal_Int32 nPropertyHandle, const uno::Any &rValue )
{
return GetConfigItem().SetProperty( nPropertyHandle, rValue );
}
-
sal_Bool SvtLinguConfig::GetOptions( SvtLinguOptions &rOptions ) const
{
return GetConfigItem().GetOptions( rOptions );
}
-
-sal_Bool SvtLinguConfig::SetOptions( const SvtLinguOptions &rOptions )
-{
- return GetConfigItem().SetOptions( rOptions );
-}
-
-
sal_Bool SvtLinguConfig::IsReadOnly( const rtl::OUString &rPropertyName ) const
{
return GetConfigItem().IsReadOnly( rPropertyName );
}
-sal_Bool SvtLinguConfig::IsReadOnly( sal_Int32 nPropertyHandle ) const
-{
- return GetConfigItem().IsReadOnly( nPropertyHandle );
-}
-
sal_Bool SvtLinguConfig::GetElementNamesFor(
const rtl::OUString &rNodeName,
uno::Sequence< rtl::OUString > &rElementNames ) const
diff --git a/unotools/source/config/localisationoptions.cxx b/unotools/source/config/localisationoptions.cxx
index 6bb02fce8352..6b8ab5dc6337 100644
--- a/unotools/source/config/localisationoptions.cxx
+++ b/unotools/source/config/localisationoptions.cxx
@@ -37,19 +37,11 @@
#include <rtl/logfile.hxx>
#include "itemholder1.hxx"
-//_________________________________________________________________________________________________________________
-// namespaces
-//_________________________________________________________________________________________________________________
-
using namespace ::utl ;
using namespace ::rtl ;
using namespace ::osl ;
using namespace ::com::sun::star::uno ;
-//_________________________________________________________________________________________________________________
-// const
-//_________________________________________________________________________________________________________________
-
#define ROOTNODE_LOCALISATION OUString(RTL_CONSTASCII_USTRINGPARAM("Office.Common/View/Localisation"))
#define DEFAULT_AUTOMNEMONIC sal_False
#define DEFAULT_DIALOGSCALE 0
@@ -62,29 +54,13 @@ using namespace ::com::sun::star::uno ;
#define PROPERTYCOUNT 2
-//_________________________________________________________________________________________________________________
-// private declarations!
-//_________________________________________________________________________________________________________________
-
class SvtLocalisationOptions_Impl : public ConfigItem
{
- //-------------------------------------------------------------------------------------------------------------
- // public methods
- //-------------------------------------------------------------------------------------------------------------
-
public:
- //---------------------------------------------------------------------------------------------------------
- // constructor / destructor
- //---------------------------------------------------------------------------------------------------------
-
SvtLocalisationOptions_Impl();
~SvtLocalisationOptions_Impl();
- //---------------------------------------------------------------------------------------------------------
- // overloaded methods of baseclass
- //---------------------------------------------------------------------------------------------------------
-
/*-****************************************************************************************************//**
@short called for notify of configmanager
@descr These method is called from the ConfigManager before application ends or from the
@@ -116,10 +92,6 @@ class SvtLocalisationOptions_Impl : public ConfigItem
virtual void Commit();
- //---------------------------------------------------------------------------------------------------------
- // public interface
- //---------------------------------------------------------------------------------------------------------
-
/*-****************************************************************************************************//**
@short access method to get internal values
@descr These method give us a chance to regulate acces to ouer internal values.
@@ -134,13 +106,7 @@ class SvtLocalisationOptions_Impl : public ConfigItem
*//*-*****************************************************************************************************/
sal_Bool IsAutoMnemonic ( ) const ;
- void SetAutoMnemonic ( sal_Bool bState ) ;
sal_Int32 GetDialogScale ( ) const ;
- void SetDialogScale ( sal_Int32 nScale ) ;
-
- //-------------------------------------------------------------------------------------------------------------
- // private methods
- //-------------------------------------------------------------------------------------------------------------
private:
@@ -159,20 +125,12 @@ class SvtLocalisationOptions_Impl : public ConfigItem
static Sequence< OUString > GetPropertyNames();
- //-------------------------------------------------------------------------------------------------------------
- // private member
- //-------------------------------------------------------------------------------------------------------------
-
private:
sal_Bool m_bAutoMnemonic ;
sal_Int32 m_nDialogScale ;
};
-//_________________________________________________________________________________________________________________
-// definitions
-//_________________________________________________________________________________________________________________
-
//*****************************************************************************************************************
// constructor
//*****************************************************************************************************************
@@ -303,29 +261,11 @@ sal_Bool SvtLocalisationOptions_Impl::IsAutoMnemonic() const
//*****************************************************************************************************************
// public method
//*****************************************************************************************************************
-void SvtLocalisationOptions_Impl::SetAutoMnemonic( sal_Bool bState )
-{
- m_bAutoMnemonic = bState;
- SetModified();
-}
-
-//*****************************************************************************************************************
-// public method
-//*****************************************************************************************************************
sal_Int32 SvtLocalisationOptions_Impl::GetDialogScale() const
{
return m_nDialogScale;
}
-//*****************************************************************************************************************
-// public method
-//*****************************************************************************************************************
-void SvtLocalisationOptions_Impl::SetDialogScale( sal_Int32 nScale )
-{
- m_nDialogScale = nScale;
- SetModified();
-}
-
Sequence< OUString > SvtLocalisationOptions_Impl::GetPropertyNames()
{
// Build static list of configuration key names.
diff --git a/unotools/source/config/pathoptions.cxx b/unotools/source/config/pathoptions.cxx
index beb37edb5058..1411d79d3f0c 100644
--- a/unotools/source/config/pathoptions.cxx
+++ b/unotools/source/config/pathoptions.cxx
@@ -26,7 +26,6 @@
*
************************************************************************/
-
#include <unotools/pathoptions.hxx>
#include <unotools/configitem.hxx>
#include <unotools/configmgr.hxx>
@@ -189,8 +188,6 @@ class SvtPathOptions_Impl
rtl::OUString UsePathVariables( const rtl::OUString& rPath ) const;
::com::sun::star::lang::Locale GetLocale() const { return m_aLocale; }
-
- sal_Bool IsPathReadonly(SvtPathOptions::Pathes ePath)const;
};
// global ----------------------------------------------------------------
@@ -287,26 +284,6 @@ const String& SvtPathOptions_Impl::GetPath( SvtPathOptions::Pathes ePath )
return m_aEmptyString;
}
-// -----------------------------------------------------------------------
-sal_Bool SvtPathOptions_Impl::IsPathReadonly(SvtPathOptions::Pathes ePath)const
-{
- ::osl::MutexGuard aGuard( m_aMutex );
- sal_Bool bReadonly = sal_False;
- if ( ePath < SvtPathOptions::PATH_COUNT )
- {
- Reference<XPropertySet> xPrSet(m_xPathSettings, UNO_QUERY);
- if(xPrSet.is())
- {
- Reference<XPropertySetInfo> xInfo = xPrSet->getPropertySetInfo();
- const char* pA = aPropNames[ePath].pPropName;
- ::rtl::OUString sU = OUString::createFromAscii(pA);
- Property aProperty = xInfo->getPropertyByName(sU);
- bReadonly = 0 != (aProperty.Attributes & PropertyAttribute::READONLY);
- }
- }
- return bReadonly;
-}
-// -----------------------------------------------------------------------
void SvtPathOptions_Impl::SetPath( SvtPathOptions::Pathes ePath, const String& rNewPath )
{
diff --git a/unotools/source/config/saveopt.cxx b/unotools/source/config/saveopt.cxx
index 787b644c5781..e0846d8ceaf2 100644
--- a/unotools/source/config/saveopt.cxx
+++ b/unotools/source/config/saveopt.cxx
@@ -26,7 +26,6 @@
*
************************************************************************/
-
#include <unotools/saveopt.hxx>
#include "rtl/instance.hxx"
#include <unotools/configmgr.hxx>
@@ -138,12 +137,9 @@ public:
void SetSaveDocView( sal_Bool b );
void SetSaveRelINet( sal_Bool b );
void SetSaveRelFSys( sal_Bool b );
- void SetSaveUnpacked( sal_Bool b );
void EnablePrettyPrinting( sal_Bool _bDoPP );
void SetWarnAlienFormat( sal_Bool _bDoPP );
void SetLoadDocPrinter( sal_Bool bNew );
- void SetUseSHA1InODF12( sal_Bool bUse );
- void SetUseBlowfishInODF12( sal_Bool bUse );
void SetODFDefaultVersion( SvtSaveOptions::ODFDefaultVersion eNew );
sal_Bool IsReadOnly( SvtSaveOptions::EOption eOption ) const;
@@ -241,15 +237,6 @@ void SvtSaveOptions_Impl::SetSaveRelFSys( sal_Bool b )
}
}
-void SvtSaveOptions_Impl::SetSaveUnpacked( sal_Bool b )
-{
- if (!bROSaveUnpacked && bSaveUnpacked!=b)
- {
- bSaveUnpacked = b;
- SetModified();
- }
-}
-
void SvtSaveOptions_Impl::EnablePrettyPrinting( sal_Bool _bDoPP )
{
if (!bRODoPrettyPrinting && bDoPrettyPrinting!=_bDoPP)
@@ -286,24 +273,6 @@ void SvtSaveOptions_Impl::SetODFDefaultVersion( SvtSaveOptions::ODFDefaultVersio
}
}
-void SvtSaveOptions_Impl::SetUseSHA1InODF12( sal_Bool bUse )
-{
- if ( !bROUseSHA1InODF12 && bUseSHA1InODF12 != bUse )
- {
- bUseSHA1InODF12 = bUse;
- SetModified();
- }
-}
-
-void SvtSaveOptions_Impl::SetUseBlowfishInODF12( sal_Bool bUse )
-{
- if ( !bROUseBlowfishInODF12 && bUseBlowfishInODF12 != bUse )
- {
- bUseBlowfishInODF12 = bUse;
- SetModified();
- }
-}
-
sal_Bool SvtSaveOptions_Impl::IsReadOnly( SvtSaveOptions::EOption eOption ) const
{
sal_Bool bReadOnly = CFG_READONLY_DEFAULT;
diff --git a/unotools/source/config/startoptions.cxx b/unotools/source/config/startoptions.cxx
index 093a4c5b1318..18653e38e3a0 100644
--- a/unotools/source/config/startoptions.cxx
+++ b/unotools/source/config/startoptions.cxx
@@ -26,7 +26,6 @@
*
************************************************************************/
-
#include <unotools/startoptions.hxx>
#include <unotools/configmgr.hxx>
#include <unotools/configitem.hxx>
@@ -36,19 +35,12 @@
#include <rtl/logfile.hxx>
#include "itemholder1.hxx"
-//_________________________________________________________________________________________________________________
-// namespaces
-//_________________________________________________________________________________________________________________
using namespace ::utl ;
using namespace ::rtl ;
using namespace ::osl ;
using namespace ::com::sun::star::uno ;
-//_________________________________________________________________________________________________________________
-// const
-//_________________________________________________________________________________________________________________
-
#define DEFAULT_SHOWINTRO sal_True
#define DEFAULT_CONNECTIONURL OUString()
@@ -61,29 +53,13 @@ using namespace ::com::sun::star::uno ;
#define PROPERTYCOUNT 2
-//_________________________________________________________________________________________________________________
-// private declarations!
-//_________________________________________________________________________________________________________________
-
class SvtStartOptions_Impl : public ConfigItem
{
- //-------------------------------------------------------------------------------------------------------------
- // public methods
- //-------------------------------------------------------------------------------------------------------------
-
public:
- //---------------------------------------------------------------------------------------------------------
- // constructor / destructor
- //---------------------------------------------------------------------------------------------------------
-
SvtStartOptions_Impl();
~SvtStartOptions_Impl();
- //---------------------------------------------------------------------------------------------------------
- // overloaded methods of baseclass
- //---------------------------------------------------------------------------------------------------------
-
/*-****************************************************************************************************//**
@short called for notify of configmanager
@descr These method is called from the ConfigManager before application ends or from the
@@ -119,10 +95,6 @@ class SvtStartOptions_Impl : public ConfigItem
virtual void Commit();
- //---------------------------------------------------------------------------------------------------------
- // public interface
- //---------------------------------------------------------------------------------------------------------
-
/*-****************************************************************************************************//**
@short access method to get internal values
@descr These method give us a chance to regulate acces to ouer internal values.
@@ -137,11 +109,6 @@ class SvtStartOptions_Impl : public ConfigItem
*//*-*****************************************************************************************************/
OUString GetConnectionURL( ) const ;
- void SetConnectionURL( const OUString& sURL ) ;
-
- //-------------------------------------------------------------------------------------------------------------
- // private methods
- //-------------------------------------------------------------------------------------------------------------
private:
@@ -161,20 +128,12 @@ class SvtStartOptions_Impl : public ConfigItem
static Sequence< OUString > impl_GetPropertyNames();
- //-------------------------------------------------------------------------------------------------------------
- // private member
- //-------------------------------------------------------------------------------------------------------------
-
private:
sal_Bool m_bShowIntro ; /// cache "ShowIntro" of Start section
OUString m_sConnectionURL ; /// cache "Connection" of Start section
};
-//_________________________________________________________________________________________________________________
-// definitions
-//_________________________________________________________________________________________________________________
-
//*****************************************************************************************************************
// constructor
//*****************************************************************************************************************
@@ -300,15 +259,6 @@ OUString SvtStartOptions_Impl::GetConnectionURL() const
}
//*****************************************************************************************************************
-// public method
-//*****************************************************************************************************************
-void SvtStartOptions_Impl::SetConnectionURL( const OUString& sURL )
-{
- m_sConnectionURL = sURL;
- SetModified();
-}
-
-//*****************************************************************************************************************
// private method
//*****************************************************************************************************************
Sequence< OUString > SvtStartOptions_Impl::impl_GetPropertyNames()
diff --git a/unotools/source/config/syslocaleoptions.cxx b/unotools/source/config/syslocaleoptions.cxx
index b37108413c77..d0ca93131bcc 100644
--- a/unotools/source/config/syslocaleoptions.cxx
+++ b/unotools/source/config/syslocaleoptions.cxx
@@ -26,7 +26,6 @@
*
************************************************************************/
-
#include <com/sun/star/uno/Sequence.hxx>
#include <rtl/ustrbuf.hxx>
#include <rtl/instance.hxx>
@@ -545,12 +544,6 @@ void SvtSysLocaleOptions::SetLocaleConfigString( const OUString& rStr )
pOptions->SetLocaleString( rStr );
}
-const OUString& SvtSysLocaleOptions::GetUILocaleConfigString() const
-{
- MutexGuard aGuard( GetMutex() );
- return pOptions->GetUILocaleString();
-}
-
void SvtSysLocaleOptions::SetUILocaleConfigString( const OUString& rStr )
{
MutexGuard aGuard( GetMutex() );