[Libreoffice-commits] core.git: sc/source

Julien Nabet serval2412 at yahoo.fr
Mon Aug 19 13:55:59 PDT 2013


 sc/source/ui/unoobj/scdetect.cxx |    5 +++++
 1 file changed, 5 insertions(+)

New commits:
commit c43a0e35e59b9ccf179852f04784a0f6db5dc191
Author: Julien Nabet <serval2412 at yahoo.fr>
Date:   Mon Aug 19 22:55:04 2013 +0200

    Revert "Seems unused too"
    
    This reverts commit 0654a592df05df676540764c004bd5b4e8b693a9.
    Sorry Kohei for the noise

diff --git a/sc/source/ui/unoobj/scdetect.cxx b/sc/source/ui/unoobj/scdetect.cxx
index 159b52c..ffdb7ea 100644
--- a/sc/source/ui/unoobj/scdetect.cxx
+++ b/sc/source/ui/unoobj/scdetect.cxx
@@ -308,6 +308,7 @@ OUString SAL_CALL ScFilterDetect::detect( uno::Sequence<beans::PropertyValue>& l
     // now some parameters that can already be in the array, but may be overwritten or new inserted here
     // remember their indices in the case new values must be added to the array
     sal_Int32 nPropertyCount = lDescriptor.getLength();
+    sal_Int32 nIndexOfFilterName = -1;
     sal_Int32 nIndexOfInputStream = -1;
     sal_Int32 nIndexOfContent = -1;
     sal_Int32 nIndexOfReadOnlyFlag = -1;
@@ -336,6 +337,10 @@ OUString SAL_CALL ScFilterDetect::detect( uno::Sequence<beans::PropertyValue>& l
         {
             lDescriptor[nProperty].Value >>= sTemp;
             aPreselectedFilterName = sTemp;
+
+            // if the preselected filter name is not correct, it must be erased after detection
+            // remember index of property to get access to it later
+            nIndexOfFilterName = nProperty;
         }
         else if ( lDescriptor[nProperty].Name == "InputStream" )
             nIndexOfInputStream = nProperty;


More information about the Libreoffice-commits mailing list