[Libreoffice-commits] core.git: sw/source
Libreoffice Gerrit user
logerrit at kemper.freedesktop.org
Mon Jul 30 15:52:35 UTC 2018
sw/source/uibase/docvw/edtwin.cxx | 30 ++++++++++++++++++++++++++----
1 file changed, 26 insertions(+), 4 deletions(-)
New commits:
commit e1d73cb5552c2566c6d7463ce001e555523f3d92
Author: Xisco Fauli <xiscofauli at libreoffice.org>
AuthorDate: Mon Jul 30 13:12:43 2018 +0200
Commit: Miklos Vajna <vmiklos at collabora.co.uk>
CommitDate: Mon Jul 30 17:52:12 2018 +0200
tdf#118971: allow arrow keys to move images or drawing objects
Partially revert 2d5ce0e1b233c83f91481cd6b9306ac8de7f5ff8
Change-Id: Ie4c91529c1ce878f4b0474d815a3a88ed48769c2
Reviewed-on: https://gerrit.libreoffice.org/58318
Reviewed-by: Heiko Tietze <tietze.heiko at gmail.com>
Tested-by: Heiko Tietze <tietze.heiko at gmail.com>
Tested-by: Jenkins
Reviewed-by: Miklos Vajna <vmiklos at collabora.co.uk>
diff --git a/sw/source/uibase/docvw/edtwin.cxx b/sw/source/uibase/docvw/edtwin.cxx
index 14011cbb7b38..4edc16a3f1e5 100644
--- a/sw/source/uibase/docvw/edtwin.cxx
+++ b/sw/source/uibase/docvw/edtwin.cxx
@@ -1768,7 +1768,11 @@ KEYINPUT_CHECKTABLE:
eFlyState = SwKeyState::Fly_Change;
nDir = MOVE_LEFT_BIG;
}
- break;
+ goto KEYINPUT_CHECKTABLE_INSDEL;
+ }
+ case KEY_RIGHT | KEY_MOD1:
+ {
+ goto KEYINPUT_CHECKTABLE_INSDEL;
}
case KEY_UP:
case KEY_UP | KEY_MOD1:
@@ -1779,7 +1783,7 @@ KEYINPUT_CHECKTABLE:
eFlyState = SwKeyState::Fly_Change;
nDir = MOVE_UP_BIG;
}
- break;
+ goto KEYINPUT_CHECKTABLE_INSDEL;
}
case KEY_DOWN:
case KEY_DOWN | KEY_MOD1:
@@ -1790,8 +1794,26 @@ KEYINPUT_CHECKTABLE:
eFlyState = SwKeyState::Fly_Change;
nDir = MOVE_DOWN_BIG;
}
- break;
+ goto KEYINPUT_CHECKTABLE_INSDEL;
+ }
+
+KEYINPUT_CHECKTABLE_INSDEL:
+ if( rSh.IsTableMode() || !rSh.GetTableFormat() )
+ {
+ const SelectionType nSelectionType = rSh.GetSelectionType();
+
+ eKeyState = SwKeyState::KeyToView;
+ if(SwKeyState::KeyToView != eFlyState)
+ {
+ if((nSelectionType & (SelectionType::DrawObject|SelectionType::DbForm)) &&
+ rSh.GetDrawView()->AreObjectsMarked())
+ eKeyState = SwKeyState::Draw_Change;
+ else if(nSelectionType & (SelectionType::Frame|SelectionType::Ole|SelectionType::Graphic))
+ eKeyState = SwKeyState::Fly_Change;
+ }
}
+ break;
+
case KEY_DELETE:
if ( !rSh.HasReadonlySel() || rSh.CursorInsideInputField())
@@ -1967,7 +1989,7 @@ KEYINPUT_CHECKTABLE:
{
eFlyState = SwKeyState::Fly_Change;
nDir = MOVE_RIGHT_BIG;
- break;
+ goto KEYINPUT_CHECKTABLE_INSDEL;
}
case KEY_TAB:
{
More information about the Libreoffice-commits
mailing list