[ooo-build-commit] .: patches/dev300

Kohei Yoshida kohei at kemper.freedesktop.org
Tue Sep 28 09:04:00 PDT 2010


 patches/dev300/apply                                    |    4 
 patches/dev300/calc-find-replace-skip-filtered-sc.diff  |  446 ----------------
 patches/dev300/calc-find-replace-skip-filtered-svl.diff |  155 -----
 3 files changed, 605 deletions(-)

New commits:
commit e35b23c828f4cb16b33645e60eb701ae1391ddd8
Author: Kohei Yoshida <kyoshida at novell.com>
Date:   Tue Sep 28 12:03:13 2010 -0400

    Removed calc-find-replace-skip-filtered-*.diff; moved to the split repos.

diff --git a/patches/dev300/apply b/patches/dev300/apply
index cee5699..fd88701 100644
--- a/patches/dev300/apply
+++ b/patches/dev300/apply
@@ -490,10 +490,6 @@ sfx2-qstartfixes.diff, i#108846, caolan
 
 [ CalcFixes ]
 
-# When finding or replacing cell contents, skip filtered cells.
-calc-find-replace-skip-filtered-svl.diff, n#539282, n#580408, i#108087, kohei
-calc-find-replace-skip-filtered-sc.diff,  n#539282, n#580408, i#108087, kohei
-
 # fix incorrect export of combo boxes, by adding two empty bytes to make Excel
 # 2003 and 2007 happy.
 calc-combo-listbox-export-fix.diff, n#540566, noelp
diff --git a/patches/dev300/calc-find-replace-skip-filtered-sc.diff b/patches/dev300/calc-find-replace-skip-filtered-sc.diff
deleted file mode 100644
index eb47459..0000000
--- a/patches/dev300/calc-find-replace-skip-filtered-sc.diff
+++ /dev/null
@@ -1,446 +0,0 @@
----
- sc/inc/table.hxx                |    2 +
- sc/inc/unonames.hxx             |    1 +
- sc/source/core/data/table6.cxx  |  219 +++++++++++++++++++++++++++------------
- sc/source/ui/unoobj/srchuno.cxx |    2 +
- 4 files changed, 157 insertions(+), 67 deletions(-)
-
-diff --git sc/inc/table.hxx sc/inc/table.hxx
-index 87320cf..f7edb92 100644
---- sc/inc/table.hxx
-+++ sc/inc/table.hxx
-@@ -872,6 +872,8 @@ private:
-     void        InvalidateTextWidth( const ScAddress* pAdrFrom, const ScAddress* pAdrTo,
-                                      BOOL bNumFormatChanged, BOOL bBroadcast );
- 
-+    void        SkipFilteredRows(SCROW& rRow, SCROW& rLastNonFilteredRow, bool bForward);
-+
-     /** 
-      * In case the cell text goes beyond the column width, move the max column 
-      * position to the right.  This is called from ExtendPrintArea.
-diff --git sc/inc/unonames.hxx sc/inc/unonames.hxx
-index 250c9c2..497fd00 100644
---- sc/inc/unonames.hxx
-+++ sc/inc/unonames.hxx
-@@ -354,6 +354,7 @@
- #define SC_UNO_SRCHSTYLES			"SearchStyles"
- #define SC_UNO_SRCHTYPE				"SearchType"
- #define SC_UNO_SRCHWORDS			"SearchWords"
-+#define SC_UNO_SRCHFILTERED         "SearchFiltered"
- 
- //	old (5.2) property names for page styles - for compatibility only!
- #define OLD_UNO_PAGE_BACKCOLOR		"BackgroundColor"
-diff --git sc/source/core/data/table6.cxx sc/source/core/data/table6.cxx
-index 0194b44..90a741e 100644
---- sc/source/core/data/table6.cxx
-+++ sc/source/core/data/table6.cxx
-@@ -248,6 +248,42 @@ BOOL ScTable::SearchCell(const SvxSearchItem& rSearchItem, SCCOL nCol, SCROW nRo
-     return bFound;
- }
- 
-+void ScTable::SkipFilteredRows(SCROW& rRow, SCROW& rLastNonFilteredRow, bool bForward)
-+{
-+    if (bForward)
-+    {
-+        // forward search
-+
-+        if (rRow <= rLastNonFilteredRow)
-+            return;
-+
-+        SCROW nLastRow = rRow;
-+        if (RowFiltered(rRow, NULL, &nLastRow))
-+            // move to the first non-filtered row.
-+            rRow = nLastRow + 1;
-+        else
-+            // record the last non-filtered row to avoid checking
-+            // the filtered state for each and every row.
-+            rLastNonFilteredRow = nLastRow;
-+    }
-+    else
-+    {
-+        // backward search
-+
-+        if (rRow >= rLastNonFilteredRow)
-+            return;
-+
-+        SCROW nFirstRow = rRow;
-+        if (RowFiltered(rRow, &nFirstRow, NULL))
-+            // move to the first non-filtered row.
-+            rRow = nFirstRow - 1;
-+        else
-+            // record the last non-filtered row to avoid checking
-+            // the filtered state for each and every row.
-+            rLastNonFilteredRow = nFirstRow;
-+    }
-+}
-+
- BOOL ScTable::Search(const SvxSearchItem& rSearchItem, SCCOL& rCol, SCROW& rRow,
-                         const ScMarkData& rMark, String& rUndoStr, ScDocument* pUndoDoc)
- {
-@@ -259,8 +295,10 @@ BOOL ScTable::Search(const SvxSearchItem& rSearchItem, SCCOL& rCol, SCROW& rRow,
-     SCCOL nLastCol;
-     SCROW nLastRow;
-     GetLastDataPos(nLastCol, nLastRow);
-+    bool bSkipFiltered = !rSearchItem.IsSearchFiltered();
-     if (!bAll && rSearchItem.GetBackward())
-     {
-+        SCROW nLastNonFilteredRow = MAXROW + 1;
-         nCol = Min(nCol, (SCCOL)(nLastCol + 1));
-         nRow = Min(nRow, (SCROW)(nLastRow + 1));
-         if (rSearchItem.GetRowDirection())
-@@ -268,6 +306,9 @@ BOOL ScTable::Search(const SvxSearchItem& rSearchItem, SCCOL& rCol, SCROW& rRow,
-             nCol--;
-             while (!bFound && ((SCsROW)nRow >= 0))
-             {
-+                if (bSkipFiltered)
-+                    SkipFilteredRows(nRow, nLastNonFilteredRow, false);
-+
-                 while (!bFound && ((SCsCOL)nCol >= 0))
-                 {
-                     bFound = SearchCell(rSearchItem, nCol, nRow, rMark, rUndoStr, pUndoDoc);
-@@ -299,6 +340,9 @@ BOOL ScTable::Search(const SvxSearchItem& rSearchItem, SCCOL& rCol, SCROW& rRow,
-             {
-                 while (!bFound && ((SCsROW)nRow >= 0))
-                 {
-+                    if (bSkipFiltered)
-+                        SkipFilteredRows(nRow, nLastNonFilteredRow, false);
-+
-                     bFound = SearchCell(rSearchItem, nCol, nRow, rMark, rUndoStr, pUndoDoc);
-                     if (!bFound)
-                     {
-@@ -308,8 +352,10 @@ BOOL ScTable::Search(const SvxSearchItem& rSearchItem, SCCOL& rCol, SCROW& rRow,
-                 }
-                 if (!bFound)
-                 {
-+                    // Not found in this column.  Move to the next column.
-                     BOOL bIsEmpty;
-                     nRow = nLastRow;
-+                    nLastNonFilteredRow = MAXROW + 1;
-                     do
-                     {
-                         nCol--;
-@@ -325,11 +371,15 @@ BOOL ScTable::Search(const SvxSearchItem& rSearchItem, SCCOL& rCol, SCROW& rRow,
-     }
-     else
-     {
-+        SCROW nLastNonFilteredRow = -1;
-         if (!bAll && rSearchItem.GetRowDirection())
-         {
-             nCol++;
-             while (!bFound && (nRow <= nLastRow))
-             {
-+                if (bSkipFiltered)
-+                    SkipFilteredRows(nRow, nLastNonFilteredRow, true);
-+
-                 while (!bFound && (nCol <= nLastCol))
-                 {
-                     bFound = SearchCell(rSearchItem, nCol, nRow, rMark, rUndoStr, pUndoDoc);
-@@ -353,6 +403,9 @@ BOOL ScTable::Search(const SvxSearchItem& rSearchItem, SCCOL& rCol, SCROW& rRow,
-             {
-                 while (!bFound && (nRow <= nLastRow))
-                 {
-+                    if (bSkipFiltered)
-+                        SkipFilteredRows(nRow, nLastNonFilteredRow, true);
-+
-                     bFound = SearchCell(rSearchItem, nCol, nRow, rMark, rUndoStr, pUndoDoc);
-                     if (!bFound)
-                     {
-@@ -362,7 +415,9 @@ BOOL ScTable::Search(const SvxSearchItem& rSearchItem, SCCOL& rCol, SCROW& rRow,
-                 }
-                 if (!bFound)
-                 {
-+                    // Not found in this column.  Move to the next column.
-                     nRow = 0;
-+                    nLastNonFilteredRow = -1;
-                     nCol++;
-                     while ((nCol <= nLastCol) && aCol[nCol].IsEmptyData()) nCol++;
-                 }
-@@ -767,20 +822,51 @@ bool ScTable::SearchAndReplaceEmptyCells(
-     return false;
- }
- 
-+namespace {
-+
-+bool lcl_maybeReplaceCellString(
-+    ScColumn& rColObj, SCCOL& rCol, SCROW& rRow, String& rUndoStr, SCCOL nCol, SCROW nRow, const SvxSearchItem& rSearchItem)
-+{
-+    ScBaseCell* pCell = rColObj.GetCell(nRow);
-+    if (!pCell || pCell->GetCellType() == CELLTYPE_NOTE)
-+    {
-+        // empty cell found.
-+        rCol = nCol;
-+        rRow = nRow;
-+        if (rSearchItem.GetCommand() == SVX_SEARCHCMD_REPLACE &&
-+            rSearchItem.GetReplaceString().Len())
-+        {
-+            rColObj.Insert(nRow, new ScStringCell(rSearchItem.GetReplaceString()));
-+            rUndoStr = String();
-+        }
-+        return true;
-+    }
-+    return false;
-+}
-+
-+}
-+
- bool ScTable::SearchRangeForEmptyCell(
-     const ScRange& rRange, const SvxSearchItem& rSearchItem,
-     SCCOL& rCol, SCROW& rRow, String& rUndoStr, ScDocument* /*pUndoDoc*/)
- {
-     sal_uInt16 nCmd = rSearchItem.GetCommand();
-+    bool bSkipFiltered = rSearchItem.IsSearchFiltered();
-     if (rSearchItem.GetBackward())
-     {
-         // backward search
-         if (rSearchItem.GetRowDirection())
-         {
-             // row direction.
-+            SCROW nLastNonFilteredRow = MAXROW + 1;
-             SCROW nBeginRow = rRange.aEnd.Row() > rRow ? rRow : rRange.aEnd.Row();
-             for (SCROW nRow = nBeginRow; nRow >= rRange.aStart.Row(); --nRow)
-             {
-+                if (bSkipFiltered)
-+                    SkipFilteredRows(nRow, nLastNonFilteredRow, false);
-+                if (nRow < rRange.aStart.Row())
-+                    break;
-+
-                 SCCOL nBeginCol = rRange.aEnd.Col();
-                 if (nRow == rRow && nBeginCol >= rCol)
-                     // always start from one cell before the cursor.
-@@ -788,20 +874,8 @@ bool ScTable::SearchRangeForEmptyCell(
- 
-                 for (SCCOL nCol = nBeginCol; nCol >= rRange.aStart.Col(); --nCol)
-                 {
--                    ScBaseCell* pCell = aCol[nCol].GetCell(nRow);
--                    if (!pCell)
--                    {
--                        // empty cell found.
--                        rCol = nCol;
--                        rRow = nRow;
--                        if (rSearchItem.GetCommand() == SVX_SEARCHCMD_REPLACE &&
--                            rSearchItem.GetReplaceString().Len())
--                        {
--                            aCol[nCol].Insert(nRow, new ScStringCell(rSearchItem.GetReplaceString()));
--                            rUndoStr = String();
--                        }
-+                    if (lcl_maybeReplaceCellString(aCol[nCol], rCol, rRow, rUndoStr, nCol, nRow, rSearchItem))
-                         return true;
--                    }
-                 }
-             }
-         }
-@@ -811,26 +885,20 @@ bool ScTable::SearchRangeForEmptyCell(
-             SCCOL nBeginCol = rRange.aEnd.Col() > rCol ? rCol : rRange.aEnd.Col();
-             for (SCCOL nCol = nBeginCol; nCol >= rRange.aStart.Col(); --nCol)
-             {
-+                SCROW nLastNonFilteredRow = MAXROW + 1;
-                 SCROW nBeginRow = rRange.aEnd.Row();
-                 if (nCol == rCol && nBeginRow >= rRow)
-                     // always start from one cell before the cursor.
-                     nBeginRow = rRow - (nCmd == SVX_SEARCHCMD_FIND ? 1 : 0);
-                 for (SCROW nRow = nBeginRow; nRow >= rRange.aStart.Row(); --nRow)
-                 {
--                    ScBaseCell* pCell = aCol[nCol].GetCell(nRow);
--                    if (!pCell)
--                    {
--                        // empty cell found.
--                        rCol = nCol;
--                        rRow = nRow;
--                        if (rSearchItem.GetCommand() == SVX_SEARCHCMD_REPLACE &&
--                            rSearchItem.GetReplaceString().Len())
--                        {
--                            aCol[nCol].Insert(nRow, new ScStringCell(rSearchItem.GetReplaceString()));
--                            rUndoStr = String();
--                        }
-+                    if (bSkipFiltered)
-+                        SkipFilteredRows(nRow, nLastNonFilteredRow, false);
-+                    if (nRow < rRange.aStart.Row())
-+                        break;
-+
-+                    if (lcl_maybeReplaceCellString(aCol[nCol], rCol, rRow, rUndoStr, nCol, nRow, rSearchItem))
-                         return true;
--                    }
-                 }
-             }
-         }
-@@ -841,29 +909,23 @@ bool ScTable::SearchRangeForEmptyCell(
-         if (rSearchItem.GetRowDirection())
-         {
-             // row direction.
-+            SCROW nLastNonFilteredRow = -1;
-             SCROW nBeginRow = rRange.aStart.Row() < rRow ? rRow : rRange.aStart.Row();
-             for (SCROW nRow = nBeginRow; nRow <= rRange.aEnd.Row(); ++nRow)
-             {
-+                if (bSkipFiltered)
-+                    SkipFilteredRows(nRow, nLastNonFilteredRow, true);
-+                if (nRow > rRange.aEnd.Row())
-+                    break;
-+
-                 SCCOL nBeginCol = rRange.aStart.Col();
-                 if (nRow == rRow && nBeginCol <= rCol)
-                     // always start from one cell past the cursor.
-                     nBeginCol = rCol + (nCmd == SVX_SEARCHCMD_FIND ? 1 : 0);
-                 for (SCCOL nCol = nBeginCol; nCol <= rRange.aEnd.Col(); ++nCol)
-                 {
--                    ScBaseCell* pCell = aCol[nCol].GetCell(nRow);
--                    if (!pCell)
--                    {
--                        // empty cell found.
--                        rCol = nCol;
--                        rRow = nRow;
--                        if (rSearchItem.GetCommand() == SVX_SEARCHCMD_REPLACE &&
--                            rSearchItem.GetReplaceString().Len())
--                        {
--                            aCol[nCol].Insert(nRow, new ScStringCell(rSearchItem.GetReplaceString()));
--                            rUndoStr = String();
--                        }
-+                    if (lcl_maybeReplaceCellString(aCol[nCol], rCol, rRow, rUndoStr, nCol, nRow, rSearchItem))
-                         return true;
--                    }
-                 }
-             }
-         }
-@@ -873,26 +935,20 @@ bool ScTable::SearchRangeForEmptyCell(
-             SCCOL nBeginCol = rRange.aStart.Col() < rCol ? rCol : rRange.aStart.Col();
-             for (SCCOL nCol = nBeginCol; nCol <= rRange.aEnd.Col(); ++nCol)
-             {
-+                SCROW nLastNonFilteredRow = -1;
-                 SCROW nBeginRow = rRange.aStart.Row();
-                 if (nCol == rCol && nBeginRow <= rRow)
-                     // always start from one cell past the cursor.
-                     nBeginRow = rRow + (nCmd == SVX_SEARCHCMD_FIND ? 1 : 0);
-                 for (SCROW nRow = nBeginRow; nRow <= rRange.aEnd.Row(); ++nRow)
-                 {
--                    ScBaseCell* pCell = aCol[nCol].GetCell(nRow);
--                    if (!pCell)
--                    {
--                        // empty cell found.
--                        rCol = nCol;
--                        rRow = nRow;
--                        if (rSearchItem.GetCommand() == SVX_SEARCHCMD_REPLACE &&
--                            rSearchItem.GetReplaceString().Len())
--                        {
--                            aCol[nCol].Insert(nRow, new ScStringCell(rSearchItem.GetReplaceString()));
--                            rUndoStr = String();
--                        }
-+                    if (bSkipFiltered)
-+                        SkipFilteredRows(nRow, nLastNonFilteredRow, true);
-+                    if (nRow > rRange.aEnd.Row())
-+                        break;
-+
-+                    if (lcl_maybeReplaceCellString(aCol[nCol], rCol, rRow, rUndoStr, nCol, nRow, rSearchItem))
-                         return true;
--                    }
-                 }
-             }
-         }
-@@ -907,35 +963,49 @@ bool ScTable::SearchRangeForAllEmptyCells(
-     bool bFound = false;
-     bool bReplace = (rSearchItem.GetCommand() == SVX_SEARCHCMD_REPLACE_ALL) &&
-                     (rSearchItem.GetReplaceString().Len() > 0);
-+    bool bSkipFiltered = rSearchItem.IsSearchFiltered();
- 
-     for (SCCOL nCol = rRange.aStart.Col(); nCol <= rRange.aEnd.Col(); ++nCol)
-     {
-+        SCROW nLastNonFilteredRow = -1;
-         if (aCol[nCol].IsEmptyData())
-         {
--            // The entire column is empty.  Add the whole column and move on.
--            rMark.SetMultiMarkArea(
--                ScRange(nCol, rRange.aStart.Row(), nTab, nCol, rRange.aEnd.Row(), nTab));
--            bFound = true;
--
--            if (bReplace)
-+            // The entire column is empty.
-+            for (SCROW nRow = rRange.aStart.Row(); nRow <= rRange.aEnd.Row(); ++nRow)
-             {
--                const String& rNewStr = rSearchItem.GetReplaceString();
--                for (SCROW nRow = rRange.aStart.Row(); nRow <= rRange.aEnd.Row(); ++nRow)
-+                SCROW nLastRow;
-+                if (!RowFiltered(nRow, NULL, &nLastRow))
-                 {
--                    aCol[nCol].Insert(nRow, new ScStringCell(rNewStr));
--                    if (pUndoDoc)
--                        // TODO: I'm using a string cell with empty content to
--                        // trigger deletion of cell instance on undo.  Maybe I
--                        // should create a new cell type for this?
--                        pUndoDoc->PutCell(nCol, nRow, nTab, new ScStringCell(String()));
-+                    rMark.SetMultiMarkArea(ScRange(nCol, nRow, nTab, nCol, nLastRow, nTab));
-+                    if (bReplace)
-+                    {
-+                        const String& rNewStr = rSearchItem.GetReplaceString();
-+                        for (SCROW i = nRow; i <= nLastRow; ++i)
-+                        {
-+                            aCol[nCol].Insert(i, new ScStringCell(rNewStr));
-+                            if (pUndoDoc)
-+                                // TODO: I'm using a string cell with empty content to
-+                                // trigger deletion of cell instance on undo.  Maybe I
-+                                // should create a new cell type for this?
-+                                pUndoDoc->PutCell(nCol, i, nTab, new ScStringCell(String()));
-+                        }
-+                        rUndoStr = String();
-+                    }
-                 }
--                rUndoStr = String();
-+
-+                nRow = nLastRow; // move to the last filtered row.
-             }
-+            bFound = true;
-             continue;
-         }
- 
-         for (SCROW nRow = rRange.aStart.Row(); nRow <= rRange.aEnd.Row(); ++nRow)
-         {
-+            if (bSkipFiltered)
-+                SkipFilteredRows(nRow, nLastNonFilteredRow, true);
-+            if (nRow > rRange.aEnd.Row())
-+                break;
-+
-             ScBaseCell* pCell = aCol[nCol].GetCell(nRow);
-             if (!pCell)
-             {
-@@ -953,6 +1023,21 @@ bool ScTable::SearchRangeForAllEmptyCells(
-                         pUndoDoc->PutCell(nCol, nRow, nTab, new ScStringCell(String()));
-                 }
-             }
-+            else if (pCell->GetCellType() == CELLTYPE_NOTE)
-+            {
-+                rMark.SetMultiMarkArea(ScRange(nCol, nRow, nTab));
-+                bFound = true;
-+
-+                if (bReplace)
-+                {
-+                    if (pUndoDoc)
-+                    {
-+                        ScAddress aCellPos(nCol, nRow, nTab);
-+                        pUndoDoc->PutCell(nCol, nRow, nTab, pCell->CloneWithNote(aCellPos, *pUndoDoc, aCellPos));
-+                    }
-+                    aCol[nCol].SetString(nRow, nTab, rSearchItem.GetReplaceString());
-+                }
-+            }
-         }
-     }
-     return bFound;
-diff --git sc/source/ui/unoobj/srchuno.cxx sc/source/ui/unoobj/srchuno.cxx
-index 15f45ce..57aee9f 100644
---- sc/source/ui/unoobj/srchuno.cxx
-+++ sc/source/ui/unoobj/srchuno.cxx
-@@ -172,6 +172,7 @@ void SAL_CALL ScCellSearchObj::setPropertyValue(
-     else if (aString.EqualsAscii( SC_UNO_SRCHSIMEX ))  pSearchItem->SetLEVOther( ScUnoHelpFunctions::GetInt16FromAny( aValue ) );
-     else if (aString.EqualsAscii( SC_UNO_SRCHSIMREM )) pSearchItem->SetLEVShorter( ScUnoHelpFunctions::GetInt16FromAny( aValue ) );
-     else if (aString.EqualsAscii( SC_UNO_SRCHTYPE ))   pSearchItem->SetCellType( ScUnoHelpFunctions::GetInt16FromAny( aValue ) );
-+    else if (aString.EqualsAscii( SC_UNO_SRCHFILTERED )) pSearchItem->SetSearchFiltered( ScUnoHelpFunctions::GetBoolFromAny(aValue) );
- }
- 
- uno::Any SAL_CALL ScCellSearchObj::getPropertyValue( const rtl::OUString& aPropertyName )
-@@ -194,6 +195,7 @@ uno::Any SAL_CALL ScCellSearchObj::getPropertyValue( const rtl::OUString& aPrope
-     else if (aString.EqualsAscii( SC_UNO_SRCHSIMEX ))  aRet <<= (sal_Int16) pSearchItem->GetLEVOther();
-     else if (aString.EqualsAscii( SC_UNO_SRCHSIMREM )) aRet <<= (sal_Int16) pSearchItem->GetLEVShorter();
-     else if (aString.EqualsAscii( SC_UNO_SRCHTYPE ))   aRet <<= (sal_Int16) pSearchItem->GetCellType();
-+    else if (aString.EqualsAscii( SC_UNO_SRCHFILTERED )) ScUnoHelpFunctions::SetBoolInAny( aRet, pSearchItem->IsSearchFiltered() );
- 
-     return aRet;
- }
--- 
-1.7.0.1
-
diff --git a/patches/dev300/calc-find-replace-skip-filtered-svl.diff b/patches/dev300/calc-find-replace-skip-filtered-svl.diff
deleted file mode 100644
index 2faa1ca..0000000
--- a/patches/dev300/calc-find-replace-skip-filtered-svl.diff
+++ /dev/null
@@ -1,155 +0,0 @@
----
- svl/inc/svl/memberid.hrc      |   29 +++++++++++++++--------------
- svl/inc/svl/srchitem.hxx      |    4 ++++
- svl/source/items/srchitem.cxx |   17 ++++++++++++++++-
- 3 files changed, 35 insertions(+), 15 deletions(-)
-
-diff --git svl/inc/svl/memberid.hrc svl/inc/svl/memberid.hrc
-index 8ff0d91..71620ed 100644
---- svl/inc/svl/memberid.hrc
-+++ svl/inc/svl/memberid.hrc
-@@ -49,20 +49,21 @@
- #define MID_SEARCH_CELLTYPE             2
- #define MID_SEARCH_ROWDIRECTION         3
- #define MID_SEARCH_ALLTABLES            4
--#define MID_SEARCH_BACKWARD             5
--#define MID_SEARCH_PATTERN              6
--#define MID_SEARCH_CONTENT              7
--#define MID_SEARCH_ASIANOPTIONS         8
--#define MID_SEARCH_ALGORITHMTYPE        9
--#define MID_SEARCH_FLAGS                10
--#define MID_SEARCH_SEARCHSTRING         11
--#define MID_SEARCH_REPLACESTRING        12
--#define MID_SEARCH_LOCALE               13
--#define MID_SEARCH_CHANGEDCHARS         14
--#define MID_SEARCH_DELETEDCHARS         15
--#define MID_SEARCH_INSERTEDCHARS        16
--#define MID_SEARCH_TRANSLITERATEFLAGS   17
--#define MID_SEARCH_COMMAND          	18
-+#define MID_SEARCH_SEARCHFILTERED       5
-+#define MID_SEARCH_BACKWARD             6 
-+#define MID_SEARCH_PATTERN              7 
-+#define MID_SEARCH_CONTENT              8 
-+#define MID_SEARCH_ASIANOPTIONS         9 
-+#define MID_SEARCH_ALGORITHMTYPE        10
-+#define MID_SEARCH_FLAGS                11
-+#define MID_SEARCH_SEARCHSTRING         12
-+#define MID_SEARCH_REPLACESTRING        13
-+#define MID_SEARCH_LOCALE               14
-+#define MID_SEARCH_CHANGEDCHARS         15
-+#define MID_SEARCH_DELETEDCHARS         16
-+#define MID_SEARCH_INSERTEDCHARS        17
-+#define MID_SEARCH_TRANSLITERATEFLAGS   18
-+#define MID_SEARCH_COMMAND              19
- 
- 
- #endif
-diff --git svl/inc/svl/srchitem.hxx svl/inc/svl/srchitem.hxx
-index be210fa..d8caf48 100644
---- svl/inc/svl/srchitem.hxx
-+++ svl/inc/svl/srchitem.hxx
-@@ -73,6 +73,7 @@ class SVL_DLLPUBLIC SvxSearchItem :
-     sal_uInt16		nAppFlag;   		// Fuer welche Applikation ist der Dialog ueberhaupt
-     sal_Bool		bRowDirection;		// Suchrichtung Zeilenweise/Spaltenweise
-     sal_Bool		bAllTables;			// in alle Tabellen suchen
-+    sal_Bool        bSearchFiltered;      // search filtered cells.
- 
-     // Writer-spezifisch
-     sal_Bool		bNotes;
-@@ -142,6 +143,9 @@ public:
-             sal_Bool		IsAllTables() const { return bAllTables; }
-             void			SetAllTables(sal_Bool bNew) { bAllTables = bNew; }
- 
-+            sal_Bool        IsSearchFiltered() const { return bSearchFiltered; }
-+            void            SetSearchFiltered(sal_Bool b) { bSearchFiltered = b; }
-+
-             sal_uInt16		GetCellType() const { return nCellType; }
-             void			SetCellType(sal_uInt16 nNewCellType) { nCellType = nNewCellType; }
- 
-diff --git svl/source/items/srchitem.cxx svl/source/items/srchitem.cxx
-index c2e89d0..4b0d1d9 100644
---- svl/source/items/srchitem.cxx
-+++ svl/source/items/srchitem.cxx
-@@ -51,7 +51,7 @@ using namespace com::sun::star::util;
- 
- #define CFG_ROOT_NODE       "Office.Common/SearchOptions"
- 
--#define SRCH_PARAMS         11
-+#define SRCH_PARAMS         12
- #define SRCH_PARA_OPTIONS   "Options"
- #define SRCH_PARA_FAMILY    "Family"
- #define SRCH_PARA_COMMAND   "Command"
-@@ -59,6 +59,7 @@ using namespace com::sun::star::util;
- #define SRCH_PARA_APPFLAG   "AppFlag"
- #define SRCH_PARA_ROWDIR    "RowDirection"
- #define SRCH_PARA_ALLTABLES "AllTables"
-+#define SRCH_PARA_SEARCHFILTERED "SearchFiltered"
- #define SRCH_PARA_BACKWARD  "Backward"
- #define SRCH_PARA_PATTERN   "Pattern"
- #define SRCH_PARA_CONTENT   "Content"
-@@ -124,6 +125,7 @@ SvxSearchItem::SvxSearchItem( const sal_uInt16 nId ) :
-     nAppFlag		( SVX_SEARCHAPP_WRITER ),
-     bRowDirection	( sal_True ),
-     bAllTables		( sal_False ),
-+    bSearchFiltered   ( sal_False ),
-     bNotes			( sal_False),
-     bBackward		( sal_False ),
-     bPattern		( sal_False ),
-@@ -205,6 +207,7 @@ SvxSearchItem::SvxSearchItem( const SvxSearchItem& rItem ) :
-     nAppFlag		( rItem.nAppFlag ),
-     bRowDirection	( rItem.bRowDirection ),
-     bAllTables		( rItem.bAllTables ),
-+    bSearchFiltered   ( rItem.bSearchFiltered ),
-     bNotes			( rItem.bNotes),
-     bBackward		( rItem.bBackward ),
-     bPattern		( rItem.bPattern ),
-@@ -254,6 +257,7 @@ int SvxSearchItem::operator==( const SfxPoolItem& rItem ) const
-            ( eFamily 		== rSItem.eFamily )			&&
-            ( bRowDirection 	== rSItem.bRowDirection )	&&
-            ( bAllTables 	== rSItem.bAllTables )		&&
-+           ( bSearchFiltered  == rSItem.bSearchFiltered )   &&
-            ( nCellType 		== rSItem.nCellType )		&&
-            ( nAppFlag 		== rSItem.nAppFlag )		&&
-            ( bAsianOptions	== rSItem.bAsianOptions )	&&
-@@ -447,6 +451,8 @@ sal_Bool SvxSearchItem::QueryValue( com::sun::star::uno::Any& rVal, BYTE nMember
-             aSeq[5].Value <<= bRowDirection;
-             aSeq[6].Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( SRCH_PARA_ALLTABLES ));
-             aSeq[6].Value <<= bAllTables;
-+            aSeq[6].Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( SRCH_PARA_SEARCHFILTERED ));
-+            aSeq[6].Value <<= bSearchFiltered;
-             aSeq[7].Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( SRCH_PARA_BACKWARD ));
-             aSeq[7].Value <<= bBackward;
-             aSeq[8].Name = rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( SRCH_PARA_PATTERN ));
-@@ -468,6 +474,8 @@ sal_Bool SvxSearchItem::QueryValue( com::sun::star::uno::Any& rVal, BYTE nMember
-             rVal <<= (sal_Bool) bRowDirection; break;
-         case MID_SEARCH_ALLTABLES:
-             rVal <<= (sal_Bool) bAllTables; break;
-+        case MID_SEARCH_SEARCHFILTERED:
-+            rVal <<= (sal_Bool) bSearchFiltered; break;
-         case MID_SEARCH_BACKWARD:
-             rVal <<= (sal_Bool) bBackward; break;
-         case MID_SEARCH_PATTERN:
-@@ -567,6 +575,11 @@ sal_Bool SvxSearchItem::PutValue( const com::sun::star::uno::Any& rVal, BYTE nMe
-                         if ( ( aSeq[i].Value >>= bAllTables ) == sal_True )
-                             ++nConvertedCount;
-                     }
-+                    else if ( aSeq[i].Name.equalsAscii( SRCH_PARA_SEARCHFILTERED ) )
-+                    {
-+                        if ( ( aSeq[i].Value >>= bSearchFiltered ) == sal_True )
-+                            ++nConvertedCount;
-+                    }
-                     else if ( aSeq[i].Name.equalsAscii( SRCH_PARA_BACKWARD ) )
-                     {
-                         if ( ( aSeq[i].Value >>= bBackward ) == sal_True )
-@@ -603,6 +616,8 @@ sal_Bool SvxSearchItem::PutValue( const com::sun::star::uno::Any& rVal, BYTE nMe
-             bRet = (rVal >>= bRowDirection); break;
-         case MID_SEARCH_ALLTABLES:
-             bRet = (rVal >>= bAllTables); break;
-+        case MID_SEARCH_SEARCHFILTERED:
-+            bRet = (rVal >>= bSearchFiltered); break;
-         case MID_SEARCH_BACKWARD:
-             bRet = (rVal >>= bBackward); break;
-         case MID_SEARCH_PATTERN:
--- 
-1.7.0.1
-


More information about the ooo-build-commit mailing list