summaryrefslogtreecommitdiff
path: root/patches/vba/fix-read-disabled-toolbarimport.diff
diff options
context:
space:
mode:
Diffstat (limited to 'patches/vba/fix-read-disabled-toolbarimport.diff')
-rw-r--r--patches/vba/fix-read-disabled-toolbarimport.diff62
1 files changed, 0 insertions, 62 deletions
diff --git a/patches/vba/fix-read-disabled-toolbarimport.diff b/patches/vba/fix-read-disabled-toolbarimport.diff
deleted file mode 100644
index 8d40a4bc9..000000000
--- a/patches/vba/fix-read-disabled-toolbarimport.diff
+++ /dev/null
@@ -1,62 +0,0 @@
-diff --git sw/source/filter/ww8/ww8toolbar.cxx sw/source/filter/ww8/ww8toolbar.cxx
-index d63fd77..dfcaa17 100644
---- sw/source/filter/ww8/ww8toolbar.cxx
-+++ sw/source/filter/ww8/ww8toolbar.cxx
-@@ -273,7 +273,7 @@ bool Customization::ImportCustomToolBar( CustomToolBarImportHelper& helper )
- {
- if ( bIsDroppedMenuTB )
- return true; // ignore ( will be processed by the ImportMenu )
-- if ( tbidForTBD == 0x25 && customizationDataTBDelta.size() ) // we can handle in a limited way additions the built-in menu bar
-+ if ( tbidForTBD == 0x25 ) // we can handle in a limited way additions the built-in menu bar
- {
- for ( std::vector< TBDelta >::iterator it = customizationDataTBDelta.begin(); it != customizationDataTBDelta.end(); ++it )
- {
-@@ -481,7 +481,8 @@ CTB::Print( FILE* fp )
- bool CTB::ImportCustomToolBar( CustomToolBarImportHelper& helper )
- {
- static rtl::OUString sToolbarPrefix( RTL_CONSTASCII_USTRINGPARAM( "private:resource/toolbar/custom_" ) );
--
-+ if ( !tb.IsEnabled() )
-+ return true; // didn't fail, just ignoring
- // Create default setting
- uno::Reference< container::XIndexContainer > xIndexContainer( helper.getCfgManager()->createSettings(), uno::UNO_QUERY_THROW );
- uno::Reference< container::XIndexAccess > xIndexAccess( xIndexContainer, uno::UNO_QUERY_THROW );
-@@ -491,7 +492,6 @@ bool CTB::ImportCustomToolBar( CustomToolBarImportHelper& helper )
- xProps->setPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("UIName") ), uno::makeAny( name.getString() ) );
-
- rtl::OUString sToolBarName = sToolbarPrefix.concat( name.getString() );
--
- for ( std::vector< TBC >::iterator it = rTBC.begin(); it != rTBC.end(); ++it )
- {
- // createToolBar item for control
-@@ -542,12 +542,17 @@ bool TB::Read( SvStream* pS )
- return name.Read( pS );
- }
-
-+bool TB::IsEnabled()
-+{
-+ return ( bFlags & 0x10 ) != 0x10;
-+}
-+
- void TB::Print( FILE* fp )
- {
- Indent a;
- indent_printf( fp, "[ 0x%x ] TB -- dump\n", nOffSet );
- indent_printf( fp, " bSignature (0x%x), bVersion(0x%x), cCL(0x%x), ltbid(0x%x), cRowsDefault (0x%x), ltbtr(0x%x), bFlags(0x%x)\n", bSignature, bVersion, cCL, static_cast< unsigned int >( ltbid ), static_cast< unsigned int >( ltbtr ), cRowsDefault, bFlags );
-- indent_printf( fp, " name %s\n", rtl::OUStringToOString( name.getString(), RTL_TEXTENCODING_UTF8 ).getStr() );
-+ indent_printf( fp, " name %s state - %s\n", rtl::OUStringToOString( name.getString(), RTL_TEXTENCODING_UTF8 ).getStr(), IsEnabled() ? "true" : "false" );
-
- }
-
-diff --git sw/source/filter/ww8/ww8toolbar.hxx sw/source/filter/ww8/ww8toolbar.hxx
-index c3e57ed..ae23835 100644
---- sw/source/filter/ww8/ww8toolbar.hxx
-+++ sw/source/filter/ww8/ww8toolbar.hxx
-@@ -46,6 +46,7 @@ public:
- ~TB(){}
- bool Read(SvStream *pS);
- void Print( FILE* );
-+ bool IsEnabled();
- };
-
- class CTB : public TBBase