[Libreoffice-commits] .: Branch 'libreoffice-3-4' - binfilter/bf_sw binfilter/inc

Petr Mladek pmladek at kemper.freedesktop.org
Mon Oct 24 08:46:41 PDT 2011


 binfilter/bf_sw/source/filter/basflt/sw_fltini.cxx  |   13 ++++++++++
 binfilter/bf_sw/source/filter/basflt/sw_shellio.cxx |   24 --------------------
 binfilter/inc/bf_sw/iodetect.hxx                    |    5 +---
 3 files changed, 16 insertions(+), 26 deletions(-)

New commits:
commit 46c7ac486e44899cce3057727eccc502ee995a4d
Author: Caolán McNamara <caolanm at redhat.com>
Date:   Wed Apr 13 13:48:19 2011 +0100

    add these back in to silence the MAXFILTER assert
    
    Signed-off-by: Petr Mladek <pmladek at suse.cz>

diff --git a/binfilter/bf_sw/source/filter/basflt/sw_fltini.cxx b/binfilter/bf_sw/source/filter/basflt/sw_fltini.cxx
index 8aaedf4..ed36043 100644
--- a/binfilter/bf_sw/source/filter/basflt/sw_fltini.cxx
+++ b/binfilter/bf_sw/source/filter/basflt/sw_fltini.cxx
@@ -89,10 +89,23 @@ inline void _SetFltPtr( USHORT& rPos, SwRead pReader, const sal_Char* pNm )
 
 void _InitFilter()
 {
+    SwRead pRd;
+
     USHORT nCnt = 0;
     _SetFltPtr( nCnt, (ReadSw3 = new Sw3Reader), FILTER_SW5 );
     _SetFltPtr( nCnt, ReadSw3, FILTER_SW4 );
     _SetFltPtr( nCnt, ReadSw3, FILTER_SW3 );
+    _SetFltPtr( nCnt, (ReadSwg = new SwgReader), FILTER_SWG );
+    _SetFltPtr( nCnt, ReadSwg, FILTER_SWGV );
+    _SetFltPtr( nCnt, new Sw6Reader, sSwDos );
+    _SetFltPtr( nCnt, (ReadAscii = new AsciiReader), FILTER_BAS );
+    _SetFltPtr( nCnt, new W4WReader, FILTER_W4W );
+    _SetFltPtr( nCnt, ( pRd = new ExcelReader ), sCExcel );
+    _SetFltPtr( nCnt, pRd, sExcel );
+    _SetFltPtr( nCnt, new LotusReader, sLotusD );
+    _SetFltPtr( nCnt, ReadSwg, sSwg1 );
+
+    _SetFltPtr( nCnt, ReadAscii, FILTER_TEXT );
 
     OSL_ENSURE( MAXFILTER == nCnt, "Anzahl Filter ungleich der Definierten" );
 }
diff --git a/binfilter/bf_sw/source/filter/basflt/sw_shellio.cxx b/binfilter/bf_sw/source/filter/basflt/sw_shellio.cxx
index 606aaa9..50180b3 100644
--- a/binfilter/bf_sw/source/filter/basflt/sw_shellio.cxx
+++ b/binfilter/bf_sw/source/filter/basflt/sw_shellio.cxx
@@ -351,29 +351,7 @@ using namespace ::com::sun::star;
 /*?*/ 				// we cannot create a SwDocShell. We could create a
 /*?*/ 				// SwWebDocShell however, because this exists always
 /*?*/ 				// for the help.
-                    OSL_ASSERT("ReadXML removed");
-
-//               SvtModuleOptions aModuleOptions;
-//              if( aModuleOptions.IsWriter() )
-//              {
-//                  SwDocShell *pDocSh =
-//                      new SwDocShell ( SFX_CREATE_MODE_INTERNAL );
-//                  SvEmbeddedObjectRef xDocSh = pDocSh;
-//                  if( pDocSh->DoInitNew( 0 ) )
-//                  {
-//                      pTemplate = pDocSh->GetDoc();
-//                      pTemplate->SetOle2Link( Link() );
-//                      pTemplate->SetBrowseMode( bTmplBrowseMode );
-//                      pTemplate->RemoveAllFmtLanguageDependencies();
-//
-//                      ReadXML->SetOrganizerMode( TRUE );
-//                      SwReader aRdr( *xStor, aEmptyStr, pTemplate );
-//                      aRdr.Read( *ReadXML );
-//                      ReadXML->SetOrganizerMode( FALSE );
-//
-//                      pTemplate->AddLink();
-//                  }
-//                }
+                                OSL_ASSERT("ReadXML removed");
 /*?*/ 			}
 /*?*/ 			else
 /*?*/ 			{
diff --git a/binfilter/inc/bf_sw/iodetect.hxx b/binfilter/inc/bf_sw/iodetect.hxx
index 02e2416..ed4697a 100644
--- a/binfilter/inc/bf_sw/iodetect.hxx
+++ b/binfilter/inc/bf_sw/iodetect.hxx
@@ -105,7 +105,7 @@ struct SwIoDetect
 #endif
 
 
-const USHORT MAXFILTER = 14;
+const USHORT MAXFILTER = 13;
 
 #define FORAMTNAME_SW4 		"StarWriter 4.0"
 #define FORAMTNAME_SW3   	"StarWriter 3.0"
@@ -161,8 +161,7 @@ SwIoDetect aReaderWriter[ MAXFILTER ] = {                      \
     {/* 9*/ SwIoEntry(sExcel,         4,            FALSE)},   \
     {/*10*/ SwIoEntry(sLotusD,        5,            TRUE)},    \
     {/*11*/ SwIoEntry(sSwg1,          4,            FALSE)},   \
-    {/*12*/ SwIoEntry(FILTER_XML,     4,            TRUE)},    \
-    {/*13*/ SwIoEntry(FILTER_TEXT,    4,            TRUE)}     \
+    {/*12*/ SwIoEntry(FILTER_TEXT,    4,            TRUE)}     \
 };
 
 // Filter erkennung


More information about the Libreoffice-commits mailing list