[Libreoffice-commits] core.git: Branch 'libreoffice-4-2' - 2 commits - sc/source
Matúš Kukan
matus.kukan at collabora.com
Mon Dec 9 00:25:00 PST 2013
sc/source/ui/dialogs/searchresults.cxx | 3 +++
1 file changed, 3 insertions(+)
New commits:
commit b51c840735029e8c61af4035f8db1d41ee8650ce
Author: Matúš Kukan <matus.kukan at collabora.com>
Date: Sat Dec 7 17:55:52 2013 +0100
SearchResults dialog: Use also AlignToCursor when setting cursor.
Change-Id: I4c802b5164bc0f0dc11da80c2225f9fc274e227c
(cherry picked from commit d45bc3429c859392aa9fd7932908e50b0716a39c)
diff --git a/sc/source/ui/dialogs/searchresults.cxx b/sc/source/ui/dialogs/searchresults.cxx
index f5cc439..3b27a2a 100644
--- a/sc/source/ui/dialogs/searchresults.cxx
+++ b/sc/source/ui/dialogs/searchresults.cxx
@@ -69,6 +69,7 @@ IMPL_LINK_NOARG( SearchResults, ListSelectHdl )
ScTabViewShell* pScViewShell = ScTabViewShell::GetActiveViewShell();
pScViewShell->SetTabNo(aAddress.Tab());
pScViewShell->SetCursor(aAddress.Col(), aAddress.Row());
+ pScViewShell->AlignToCursor(aAddress.Col(), aAddress.Row(), SC_FOLLOW_JUMP);
return 0;
}
commit 1a8afa24ffc1ba1e606617f263e1f8833ad4d0a9
Author: Matúš Kukan <matus.kukan at collabora.com>
Date: Mon Dec 9 08:52:59 2013 +0100
fdo#72413: Fix O(n^2) in inserting SearchResults' items.
Thanks to moggi, who pointed to this, should be documented somewhere.
Change-Id: I96ba2cca930e4b784a825987ea19e4fc9aacb6d6
(cherry picked from commit dc22a2aa1b2858394ad70806f34d1327936af7a0)
diff --git a/sc/source/ui/dialogs/searchresults.cxx b/sc/source/ui/dialogs/searchresults.cxx
index fa89eb7..f5cc439 100644
--- a/sc/source/ui/dialogs/searchresults.cxx
+++ b/sc/source/ui/dialogs/searchresults.cxx
@@ -41,6 +41,7 @@ SearchResults::~SearchResults()
void SearchResults::Show(const ScRangeList &rMatchedRanges)
{
mpList->Clear();
+ mpList->SetUpdateMode(false);
for (size_t i = 0, n = rMatchedRanges.size(); i < n; ++i)
{
ScCellIterator aIter(mpDoc, *rMatchedRanges[i]);
@@ -53,6 +54,7 @@ void SearchResults::Show(const ScRangeList &rMatchedRanges)
mpList->InsertEntry(sAddress.replace('.', '\t') + "\t" + mpDoc->GetString(aAddress));
}
}
+ mpList->SetUpdateMode(true);
ModelessDialog::Show();
}
More information about the Libreoffice-commits
mailing list