[ooo-build-commit] .: Branch 'ooo-build-3-2-1' - patches/dev300

Muthu Subramanian sumuthu at kemper.freedesktop.org
Thu Sep 2 01:41:09 PDT 2010


 patches/dev300/sc-xml-with-xls-ext.diff |   15 ++++++++-------
 1 file changed, 8 insertions(+), 7 deletions(-)

New commits:
commit 80baeecb8eac99f19155a82552914543c230cdbb
Author: Muthu Subramanian K <sumuthu at novell.com>
Date:   Thu Sep 2 14:06:10 2010 +0530

    If ascii filter is preselected automatically set isXLS to true.
    
    Also rearranged rft check (moved it up).
    
    * patches/dev300/sc-xml-with-xls-ext.diff:

diff --git a/patches/dev300/sc-xml-with-xls-ext.diff b/patches/dev300/sc-xml-with-xls-ext.diff
index e744e82..548fe61 100644
--- a/patches/dev300/sc-xml-with-xls-ext.diff
+++ b/patches/dev300/sc-xml-with-xls-ext.diff
@@ -25,14 +25,15 @@
              lDescriptor[nProperty].Value >>= bRepairPackage;
          else if( lDescriptor[nProperty].Name == OUString(RTL_CONSTASCII_USTRINGPARAM("DocumentTitle")) )
              nIndexOfDocumentTitle = nProperty;
-@@ -436,8 +438,11 @@ static BOOL lcl_IsAnyXMLFilter( const Sf
+@@ -436,8 +438,12 @@ static BOOL lcl_IsAnyXMLFilter( const Sf
              }
              else
              {
 +                bool bIsXLS = false;
                  SvStream* pStream = aMedium.GetInStream();
                  const SfxFilter* pPreselectedFilter = pFilter;
-+                if ( pPreselectedFilter && pPreselectedFilter->GetName().SearchAscii("Excel") != STRING_NOTFOUND )
++                if ( ( pPreselectedFilter && pPreselectedFilter->GetName().SearchAscii("Excel") != STRING_NOTFOUND ) || 
++                     ( !aPreselectedFilterName.Len() && pPreselectedFilter->GetFilterName().EqualsAscii( pFilterAscii ) ) )
 +                    bIsXLS = true;
                  pFilter = 0;
                  if ( pStream )
@@ -101,6 +102,11 @@
 -                                else if ( pPreselectedFilter->GetName().EqualsAscii(pFilterDBase) && lcl_MayBeDBase( rStr ) )
 -                                    pFilter = pPreselectedFilter;
                              }
++                            else if ( aHeader.CompareTo( "{\\rtf", 5 ) == COMPARE_EQUAL )
++                            {
++                                // test for RTF
++                                pFilter = aMatcher.GetFilter4FilterName( String::CreateFromAscii(pFilterRtf) );
++                            }
 +                            else if ( bIsXLS && bMaybeText )
 +                            {
 +                                aHeader.EraseLeadingChars();
@@ -110,11 +116,6 @@
 +                                    pFilter = aMatcher.GetFilter4FilterName( String::CreateFromAscii(pFilterAscii) );
 +                                bFakeXLS = true;
 +                            }
-+                            else if ( aHeader.CompareTo( "{\\rtf", 5 ) == COMPARE_EQUAL )
-+                            {
-+                                // test for RTF
-+                                pFilter = aMatcher.GetFilter4FilterName( String::CreateFromAscii(pFilterRtf) );
-+                            }
 +                            else if ( pPreselectedFilter->GetName().EqualsAscii(pFilterDBase) && lcl_MayBeDBase( rStr ) )
 +                                pFilter = pPreselectedFilter;
 +                            else if ( pPreselectedFilter->GetFilterName().EqualsAscii(pFilterAscii) && bMaybeText )


More information about the ooo-build-commit mailing list