summaryrefslogtreecommitdiff
path: root/sw
diff options
context:
space:
mode:
authorMiklos Vajna <vmiklos@collabora.co.uk>2015-05-20 16:56:45 +0200
committerMiklos Vajna <vmiklos@collabora.co.uk>2015-05-26 09:35:02 +0200
commit57840bb2030bdd3d4d4fa41dd77ee4069e854486 (patch)
tree3f0be9d037eef7147f9e3142685b1ab98211d245 /sw
parentb1e1bb2f3c5b32ec8898c006704c3ebacff78bf3 (diff)
SwPaM::Find: forgot to show the cursor after ending the text edit
Without this, if you searched inside a shape, then got a next hit outside the shape, you didn't get your blinking cursor even if you clicked into the writer text. Change-Id: I053af9672dc9290728b16780f21301b3b840cb55 (cherry picked from commit 1633fb2651e32f3dab5104b11074e7904cdcbec3)
Diffstat (limited to 'sw')
-rw-r--r--sw/source/core/crsr/findtxt.cxx7
1 files changed, 5 insertions, 2 deletions
diff --git a/sw/source/core/crsr/findtxt.cxx b/sw/source/core/crsr/findtxt.cxx
index 9a2a8a1e7060..c15e5d1df3fd 100644
--- a/sw/source/core/crsr/findtxt.cxx
+++ b/sw/source/core/crsr/findtxt.cxx
@@ -27,7 +27,7 @@
#include <sfx2/sfxsids.hrc>
#include <editeng/outliner.hxx>
-#include <editsh.hxx>
+#include <wrtsh.hxx>
#include <txatritr.hxx>
#include <fldbas.hxx>
#include <fmtfld.hxx>
@@ -294,7 +294,7 @@ bool SwPaM::Find( const SearchOptions& rSearchOpt, bool bSearchInNotes , utl::Te
}
SwDocShell *const pDocShell = pNode->GetDoc()->GetDocShell();
- SwViewShell *const pWrtShell = (pDocShell) ? pDocShell->GetEditShell() : 0;
+ SwWrtShell *const pWrtShell = (pDocShell) ? pDocShell->GetWrtShell() : 0;
SwPostItMgr *const pPostItMgr = (pWrtShell) ? pWrtShell->GetPostItMgr() : 0;
SvxSearchItem aSearchItem(SID_SEARCH_ITEM);
@@ -311,7 +311,10 @@ bool SwPaM::Find( const SearchOptions& rSearchOpt, bool bSearchInNotes , utl::Te
{
// If not found, end the text edit.
pSdrView->SdrEndTextEdit();
+ const Point aPoint(pSdrView->GetAllMarkedRect().TopLeft());
pSdrView->UnmarkAll();
+ pWrtShell->SetCursor(&aPoint, true);
+ pWrtShell->Edit();
}
else
{