diff options
author | Miklos Vajna <vmiklos@collabora.co.uk> | 2015-03-30 16:20:13 +0200 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2015-04-07 09:18:01 +0200 |
commit | 046be649beec4393490fd189e953eb19c472d4ee (patch) | |
tree | c5aa260acebd994a4647ccaa797f55d999d99252 /sd | |
parent | 32cfef5cb32d944df81d2e1aa8a81d175b4101cb (diff) |
sd tiled rendering: support turning an editeng selection into a table one
With this, it's possible to drag the selection handle of an editeng
selection in an Impress table and drag it outside the table cell to
create an Impress table selection. Some unexpected graphic selection
still appears, though.
Change-Id: Ia7b36036ce2bda5cca570e8b6075238d5167090f
Diffstat (limited to 'sd')
-rw-r--r-- | sd/source/ui/view/viewshel.cxx | 17 |
1 files changed, 7 insertions, 10 deletions
diff --git a/sd/source/ui/view/viewshel.cxx b/sd/source/ui/view/viewshel.cxx index 9ffd64317c3d..54e652648db2 100644 --- a/sd/source/ui/view/viewshel.cxx +++ b/sd/source/ui/view/viewshel.cxx @@ -536,17 +536,14 @@ void ViewShell::SetCursorLogicPosition(const Point& rPosition, bool bPoint, bool { if (SdrView* pSdrView = GetView()) { - if (pSdrView->GetTextEditObject()) + rtl::Reference<sdr::SelectionController> xSelectionController(GetView()->getSelectionController()); + if (!xSelectionController.is() || !xSelectionController->setCursorLogicPosition(rPosition, bPoint)) { - EditView& rEditView = pSdrView->GetTextEditOutlinerView()->GetEditView(); - rEditView.SetCursorLogicPosition(rPosition, bPoint, bClearMark); - } - else - { - // No text edit object, then try to adjust table selection. - rtl::Reference<sdr::SelectionController> xSelectionController(GetView()->getSelectionController()); - if (xSelectionController.is()) - xSelectionController->setCursorLogicPosition(rPosition, bPoint); + if (pSdrView->GetTextEditObject()) + { + EditView& rEditView = pSdrView->GetTextEditOutlinerView()->GetEditView(); + rEditView.SetCursorLogicPosition(rPosition, bPoint, bClearMark); + } } } } |