summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2013-11-20 23:39:21 +0100
committerStephan Bergmann <sbergman@redhat.com>2013-11-20 23:39:21 +0100
commit380007d64716fc93fa265133eaa264132a242768 (patch)
treeb405a09114e0f9aa11f0b1d08973399cac36cde6 /vcl
parent2d81c8f01771585e5f6bac87722051e0582f8453 (diff)
Elide utl::ConfigItem_Impl
...and utl::ConfigItem::IsValidConfigMgr is always true. Change-Id: I37e295729c3d0ae12719f0ae6f5a5628c58d0b9f
Diffstat (limited to 'vcl')
-rw-r--r--vcl/source/gdi/configsettings.cxx6
-rw-r--r--vcl/unx/generic/dtrans/config.cxx45
2 files changed, 19 insertions, 32 deletions
diff --git a/vcl/source/gdi/configsettings.cxx b/vcl/source/gdi/configsettings.cxx
index 9b6dcdd2eed9..75ea7eb39034 100644
--- a/vcl/source/gdi/configsettings.cxx
+++ b/vcl/source/gdi/configsettings.cxx
@@ -61,9 +61,6 @@ SettingsConfigItem::~SettingsConfigItem()
void SettingsConfigItem::Commit()
{
- if( ! IsValidConfigMgr() )
- return;
-
boost::unordered_map< OUString, SmallOUStrMap, OUStringHash >::const_iterator group;
for( group = m_aSettings.begin(); group != m_aSettings.end(); ++group )
@@ -96,9 +93,6 @@ void SettingsConfigItem::Notify( const Sequence< OUString >& )
void SettingsConfigItem::getValues()
{
- if( ! IsValidConfigMgr() )
- return;
-
m_aSettings.clear();
Sequence< OUString > aNames( GetNodeNames( OUString() ) );
diff --git a/vcl/unx/generic/dtrans/config.cxx b/vcl/unx/generic/dtrans/config.cxx
index 05a7d678ed00..a359dc77a921 100644
--- a/vcl/unx/generic/dtrans/config.cxx
+++ b/vcl/unx/generic/dtrans/config.cxx
@@ -71,42 +71,35 @@ DtransX11ConfigItem::DtransX11ConfigItem() :
CONFIG_MODE_DELAYED_UPDATE ),
m_nSelectionTimeout( 3 )
{
- if( IsValidConfigMgr() )
- {
- Sequence< OUString > aKeys( 1 );
- aKeys.getArray()[0] = OUString( SELECTION_PROPERTY );
- Sequence< Any > aValues = GetProperties( aKeys );
+ Sequence< OUString > aKeys( 1 );
+ aKeys.getArray()[0] = OUString( SELECTION_PROPERTY );
+ Sequence< Any > aValues = GetProperties( aKeys );
#if OSL_DEBUG_LEVEL > 1
- fprintf( stderr, "found %" SAL_PRIdINT32 " properties for %s\n", aValues.getLength(), SELECTION_PROPERTY );
+ fprintf( stderr, "found %" SAL_PRIdINT32 " properties for %s\n", aValues.getLength(), SELECTION_PROPERTY );
#endif
- Any* pValue = aValues.getArray();
- for( int i = 0; i < aValues.getLength(); i++, pValue++ )
+ Any* pValue = aValues.getArray();
+ for( int i = 0; i < aValues.getLength(); i++, pValue++ )
+ {
+ if( pValue->getValueTypeClass() == TypeClass_STRING )
{
- if( pValue->getValueTypeClass() == TypeClass_STRING )
+ const OUString* pLine = (const OUString*)pValue->getValue();
+ if( !pLine->isEmpty() )
{
- const OUString* pLine = (const OUString*)pValue->getValue();
- if( !pLine->isEmpty() )
- {
- m_nSelectionTimeout = pLine->toInt32();
- if( m_nSelectionTimeout < 1 )
- m_nSelectionTimeout = 1;
- }
-#if OSL_DEBUG_LEVEL > 1
- fprintf( stderr, "found SelectionTimeout \"%s\"\n",
- OUStringToOString( *pLine, osl_getThreadTextEncoding() ).getStr() );
-#endif
+ m_nSelectionTimeout = pLine->toInt32();
+ if( m_nSelectionTimeout < 1 )
+ m_nSelectionTimeout = 1;
}
#if OSL_DEBUG_LEVEL > 1
- else
- fprintf( stderr, "found SelectionTimeout of type \"%s\"\n",
- OUStringToOString( pValue->getValueType().getTypeName(), osl_getThreadTextEncoding() ).getStr() );
+ fprintf( stderr, "found SelectionTimeout \"%s\"\n",
+ OUStringToOString( *pLine, osl_getThreadTextEncoding() ).getStr() );
#endif
}
- }
#if OSL_DEBUG_LEVEL > 1
- else
- fprintf( stderr, "no valid configmanager, could not read timeout setting\n" );
+ else
+ fprintf( stderr, "found SelectionTimeout of type \"%s\"\n",
+ OUStringToOString( pValue->getValueType().getTypeName(), osl_getThreadTextEncoding() ).getStr() );
#endif
+ }
}
/*