diff options
author | Tamás Zolnai <tamas.zolnai@collabora.com> | 2017-07-11 21:32:33 +0200 |
---|---|---|
committer | Miklos Vajna <vmiklos@collabora.co.uk> | 2017-07-14 08:42:28 +0200 |
commit | 73ea880fe1a21af5233b1cbb91618b568b760d8b (patch) | |
tree | e5033e191358cc4b5aa8e41b90680d409d5eab41 | |
parent | e2075593e4d13b6e7c0b32b23912fdeed1ada6bf (diff) |
tdf#109050: Moving table object with ALT+Arrow keys does not work properly
ALT+up/down behaves differently inside a table: cursor is moved
to the left/right neighbouring cell instead of up/down. However
when the whole table is selected a different behavior is expected:
moving the table as an object.
Reviewed-on: https://gerrit.libreoffice.org/39810
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
(cherry picked from commit f5637ae74ad6bb517255510a8ae786fd2a3cf977)
Change-Id: I82c7a3cc7d215b21f19fbf08dcdb7318a7e75289
Reviewed-on: https://gerrit.libreoffice.org/39837
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Miklos Vajna <vmiklos@collabora.co.uk>
-rw-r--r-- | svx/source/table/tablecontroller.cxx | 18 |
1 files changed, 11 insertions, 7 deletions
diff --git a/svx/source/table/tablecontroller.cxx b/svx/source/table/tablecontroller.cxx index 47ca6dbcd5ad..6921f1d4190c 100644 --- a/svx/source/table/tablecontroller.cxx +++ b/svx/source/table/tablecontroller.cxx @@ -1567,15 +1567,19 @@ SvxTableController::TblAction SvxTableController::getKeyboardAction(const KeyEve if( !bMod1 && bMod2 ) { - if( (nCode == awt::Key::UP) || (nCode == awt::Key::NUM8) ) + if(bTextEdit || mbCellSelectionMode) { - nAction = TblAction::GotoLeftCell; - } - else if( (nCode == awt::Key::DOWN) || (nCode == awt::Key::NUM2) ) - { - nAction = TblAction::GotoRightCell; + if( (nCode == awt::Key::UP) || (nCode == awt::Key::NUM8) ) + { + nAction = TblAction::GotoLeftCell; + break; + } + else if( (nCode == awt::Key::DOWN) || (nCode == awt::Key::NUM2) ) + { + nAction = TblAction::GotoRightCell; + break; + } } - break; } bool bTextMove = false; |