summaryrefslogtreecommitdiff
path: root/svtools
diff options
context:
space:
mode:
Diffstat (limited to 'svtools')
-rw-r--r--svtools/inc/svtools/miscopt.hxx10
-rw-r--r--svtools/source/config/miscopt.cxx144
2 files changed, 152 insertions, 2 deletions
diff --git a/svtools/inc/svtools/miscopt.hxx b/svtools/inc/svtools/miscopt.hxx
index ecd2574c1943..ecee18fbe6b4 100644
--- a/svtools/inc/svtools/miscopt.hxx
+++ b/svtools/inc/svtools/miscopt.hxx
@@ -110,6 +110,12 @@ class SVT_DLLPUBLIC SvtMiscOptions: public utl::detail::Options
void SetUseSystemFileDialog( sal_Bool bSet );
sal_Bool IsUseSystemFileDialogReadOnly() const;
+ sal_Bool TryODMADialog() const;
+ void SetTryODMADialog( sal_Bool bSet );
+ sal_Bool IsTryUseODMADialogReadOnly() const;
+
+ sal_Bool DisableUICustomization() const;
+
sal_Bool IsPluginsEnabled() const;
void SetPluginsEnabled( sal_Bool bEnable );
sal_Bool IsPluginsEnabledReadOnly() const;
@@ -136,6 +142,10 @@ class SVT_DLLPUBLIC SvtMiscOptions: public utl::detail::Options
sal_Bool UseSystemPrintDialog() const;
void SetUseSystemPrintDialog( sal_Bool bSet );
+ sal_Bool ShowLinkWarningDialog() const;
+ void SetShowLinkWarningDialog( sal_Bool bSet );
+ sal_Bool IsShowLinkWarningDialogReadOnly() const;
+
//-------------------------------------------------------------------------------------------------------------
// private methods
//-------------------------------------------------------------------------------------------------------------
diff --git a/svtools/source/config/miscopt.cxx b/svtools/source/config/miscopt.cxx
index 7b04b56104e0..e036225cb5f4 100644
--- a/svtools/source/config/miscopt.cxx
+++ b/svtools/source/config/miscopt.cxx
@@ -78,8 +78,14 @@ using namespace ::com::sun::star;
#define PROPERTYHANDLE_SYMBOLSTYLE 4
#define PROPERTYNAME_USESYSTEMPRINTDIALOG ASCII_STR("UseSystemPrintDialog")
#define PROPERTYHANDLE_USESYSTEMPRINTDIALOG 5
+#define PROPERTYNAME_TRYODMADIALOG ASCII_STR("TryODMADialog")
+#define PROPERTYHANDLE_TRYODMADIALOG 6
+#define PROPERTYNAME_SHOWLINKWARNINGDIALOG ASCII_STR("ShowLinkWarningDialog")
+#define PROPERTYHANDLE_SHOWLINKWARNINGDIALOG 7
+#define PROPERTYNAME_DISABLEUICUSTOMIZATION ASCII_STR("DisableUICustomization")
+#define PROPERTYHANDLE_DISABLEUICUSTOMIZATION 8
-#define PROPERTYCOUNT 6
+#define PROPERTYCOUNT 9
#define VCL_TOOLBOX_STYLE_FLAT ((USHORT)0x0004) // from <vcl/toolbox.hxx>
@@ -99,6 +105,8 @@ class SvtMiscOptions_Impl : public ConfigItem
LinkList aList;
sal_Bool m_bUseSystemFileDialog;
sal_Bool m_bIsUseSystemFileDialogRO;
+ sal_Bool m_bTryODMADialog;
+ sal_Bool m_bIsTryODMADialogRO;
sal_Bool m_bPluginsEnabled;
sal_Bool m_bIsPluginsEnabledRO;
sal_Int16 m_nSymbolsSize;
@@ -108,6 +116,9 @@ class SvtMiscOptions_Impl : public ConfigItem
sal_Bool m_bIsToolboxStyleRO;
sal_Bool m_bUseSystemPrintDialog;
sal_Bool m_bIsUseSystemPrintDialogRO;
+ sal_Bool m_bShowLinkWarningDialog;
+ sal_Bool m_bIsShowLinkWarningDialogRO;
+ sal_Bool m_bDisableUICustomization;
//-------------------------------------------------------------------------------------------------------------
// public methods
@@ -176,6 +187,18 @@ class SvtMiscOptions_Impl : public ConfigItem
inline sal_Bool IsUseSystemFileDialogReadOnly() const
{ return m_bIsUseSystemFileDialogRO; }
+ inline sal_Bool TryODMADialog() const
+ { return m_bTryODMADialog; }
+
+ inline void SetTryODMADialog( sal_Bool bSet )
+ { m_bTryODMADialog = bSet; SetModified(); }
+
+ inline sal_Bool IsTryUseODMADialogReadOnly() const
+ { return m_bIsTryODMADialogRO; }
+
+ inline sal_Bool DisableUICustomization() const
+ { return m_bDisableUICustomization; }
+
inline sal_Bool IsPluginsEnabled() const
{ return m_bPluginsEnabled; }
@@ -224,6 +247,15 @@ class SvtMiscOptions_Impl : public ConfigItem
inline sal_Bool IsUseSystemPrintDialogReadOnly() const
{ return m_bIsUseSystemPrintDialogRO; }
+ inline sal_Bool ShowLinkWarningDialog() const
+ { return m_bShowLinkWarningDialog; }
+
+ void SetShowLinkWarningDialog( sal_Bool bSet )
+ { m_bShowLinkWarningDialog = bSet; SetModified(); }
+
+ sal_Bool IsShowLinkWarningDialogReadOnly() const
+ { return m_bIsShowLinkWarningDialogRO; }
+
void AddListenerLink( const Link& rLink );
void RemoveListenerLink( const Link& rLink );
void CallListeners();
@@ -262,6 +294,8 @@ SvtMiscOptions_Impl::SvtMiscOptions_Impl()
, m_bUseSystemFileDialog( sal_False )
, m_bIsUseSystemFileDialogRO( sal_False )
+ , m_bTryODMADialog( sal_False )
+ , m_bIsTryODMADialogRO( sal_False )
, m_bPluginsEnabled( sal_False )
, m_bIsPluginsEnabledRO( sal_False )
, m_nSymbolsSize( 0 )
@@ -271,6 +305,8 @@ SvtMiscOptions_Impl::SvtMiscOptions_Impl()
, m_bIsToolboxStyleRO( sal_False )
, m_bUseSystemPrintDialog( sal_False )
, m_bIsUseSystemPrintDialogRO( sal_False )
+ , m_bShowLinkWarningDialog( sal_True )
+ , m_bIsShowLinkWarningDialogRO( sal_False )
{
// Use our static list of configuration keys to get his values.
@@ -343,6 +379,26 @@ SvtMiscOptions_Impl::SvtMiscOptions_Impl()
break;
}
+ case PROPERTYHANDLE_TRYODMADIALOG :
+ {
+ if( !(seqValues[nProperty] >>= m_bTryODMADialog) )
+ {
+ DBG_ERROR("Wrong type of \"Misc\\TryODMADialog\"!" );
+ }
+ m_bIsTryODMADialogRO = seqRO[nProperty];
+ break;
+ }
+
+ case PROPERTYHANDLE_SHOWLINKWARNINGDIALOG :
+ {
+ if( !(seqValues[nProperty] >>= m_bShowLinkWarningDialog) )
+ {
+ DBG_ERROR("Wrong type of \"Misc\\ShowLinkWarningDialog\"!" );
+ }
+ m_bIsShowLinkWarningDialogRO = seqRO[nProperty];
+ break;
+ }
+
case PROPERTYHANDLE_SYMBOLSTYLE :
{
::rtl::OUString aSymbolsStyle;
@@ -355,6 +411,13 @@ SvtMiscOptions_Impl::SvtMiscOptions_Impl()
m_bIsSymbolsStyleRO = seqRO[nProperty];
break;
}
+
+ case PROPERTYHANDLE_DISABLEUICUSTOMIZATION :
+ {
+ if( !(seqValues[nProperty] >>= m_bDisableUICustomization) )
+ DBG_ERROR("Wrong type of \"Misc\\DisableUICustomization\"!" );
+ break;
+ }
}
}
@@ -446,6 +509,20 @@ void SvtMiscOptions_Impl::Load( const Sequence< OUString >& rPropertyNames )
}
}
break;
+ case PROPERTYHANDLE_TRYODMADIALOG : {
+ if( !(seqValues[nProperty] >>= m_bTryODMADialog) )
+ {
+ DBG_ERROR("Wrong type of \"Misc\\TryODMADialog\"!" );
+ }
+ }
+ break;
+ case PROPERTYHANDLE_SHOWLINKWARNINGDIALOG : {
+ if( !(seqValues[nProperty] >>= m_bShowLinkWarningDialog) )
+ {
+ DBG_ERROR("Wrong type of \"Misc\\ShowLinkWarningDialog\"!" );
+ }
+ }
+ break;
case PROPERTYHANDLE_SYMBOLSTYLE : {
::rtl::OUString aSymbolsStyle;
if( seqValues[nProperty] >>= aSymbolsStyle )
@@ -456,6 +533,11 @@ void SvtMiscOptions_Impl::Load( const Sequence< OUString >& rPropertyNames )
}
}
break;
+ case PROPERTYHANDLE_DISABLEUICUSTOMIZATION : {
+ if( !(seqValues[nProperty] >>= m_bDisableUICustomization) )
+ DBG_ERROR("Wrong type of \"Misc\\DisableUICustomization\"!" );
+ }
+ break;
}
}
}
@@ -592,6 +674,13 @@ void SvtMiscOptions_Impl::Commit()
break;
}
+ case PROPERTYHANDLE_TRYODMADIALOG :
+ {
+ if ( !m_bIsTryODMADialogRO )
+ seqValues[nProperty] <<= m_bTryODMADialog;
+ break;
+ }
+
case PROPERTYHANDLE_SYMBOLSTYLE :
{
if ( !m_bIsSymbolsStyleRO )
@@ -605,6 +694,19 @@ void SvtMiscOptions_Impl::Commit()
seqValues[nProperty] <<= m_bUseSystemPrintDialog;
break;
}
+
+ case PROPERTYHANDLE_SHOWLINKWARNINGDIALOG :
+ {
+ if ( !m_bIsShowLinkWarningDialogRO )
+ seqValues[nProperty] <<= m_bShowLinkWarningDialog;
+ break;
+ }
+
+ case PROPERTYHANDLE_DISABLEUICUSTOMIZATION :
+ {
+ seqValues[nProperty] <<= m_bDisableUICustomization;
+ break;
+ }
}
}
// Set properties in configuration.
@@ -624,7 +726,10 @@ Sequence< OUString > SvtMiscOptions_Impl::GetPropertyNames()
PROPERTYNAME_TOOLBOXSTYLE,
PROPERTYNAME_USESYSTEMFILEDIALOG,
PROPERTYNAME_SYMBOLSTYLE,
- PROPERTYNAME_USESYSTEMPRINTDIALOG
+ PROPERTYNAME_USESYSTEMPRINTDIALOG,
+ PROPERTYNAME_TRYODMADIALOG,
+ PROPERTYNAME_SHOWLINKWARNINGDIALOG,
+ PROPERTYNAME_DISABLEUICUSTOMIZATION
};
// Initialize return sequence with these list ...
@@ -692,6 +797,21 @@ sal_Bool SvtMiscOptions::IsUseSystemFileDialogReadOnly() const
return m_pDataContainer->IsUseSystemFileDialogReadOnly();
}
+sal_Bool SvtMiscOptions::TryODMADialog() const
+{
+ return m_pDataContainer->TryODMADialog();
+}
+
+void SvtMiscOptions::SetTryODMADialog( sal_Bool bEnable )
+{
+ m_pDataContainer->SetTryODMADialog( bEnable );
+}
+
+sal_Bool SvtMiscOptions::IsTryUseODMADialogReadOnly() const
+{
+ return m_pDataContainer->IsTryUseODMADialogReadOnly();
+}
+
sal_Bool SvtMiscOptions::IsPluginsEnabled() const
{
return m_pDataContainer->IsPluginsEnabled();
@@ -770,6 +890,11 @@ sal_Bool SvtMiscOptions::IsGetSymbolsStyleReadOnly() const
return m_pDataContainer->IsGetSymbolsStyleReadOnly();
}
+sal_Bool SvtMiscOptions::DisableUICustomization() const
+{
+ return m_pDataContainer->DisableUICustomization();
+}
+
sal_Int16 SvtMiscOptions::GetToolboxStyle() const
{
return m_pDataContainer->GetToolboxStyle();
@@ -795,6 +920,21 @@ void SvtMiscOptions::SetUseSystemPrintDialog( sal_Bool bEnable )
m_pDataContainer->SetUseSystemPrintDialog( bEnable );
}
+sal_Bool SvtMiscOptions::ShowLinkWarningDialog() const
+{
+ return m_pDataContainer->ShowLinkWarningDialog();
+}
+
+void SvtMiscOptions::SetShowLinkWarningDialog( sal_Bool bSet )
+{
+ m_pDataContainer->SetShowLinkWarningDialog( bSet );
+}
+
+sal_Bool SvtMiscOptions::IsShowLinkWarningDialogReadOnly() const
+{
+ return m_pDataContainer->IsShowLinkWarningDialogReadOnly();
+}
+
//*****************************************************************************************************************
// private method
//*****************************************************************************************************************