diff options
author | Dennis Francis <dennis.francis@collabora.com> | 2020-02-07 12:08:21 +0530 |
---|---|---|
committer | Andras Timar <andras.timar@collabora.com> | 2020-02-12 21:27:58 +0100 |
commit | 7155d0011ecde39c9ea27ef19d475686d80574ee (patch) | |
tree | 8f4d4edc77a9e49f027e2df81a575dd48ced7c3e /sw | |
parent | c70d31a274b9e7b47dbf6622c84a7a3431360b9e (diff) |
Classify shape(s) selections as 'complex'...
in isComplex() of XTransferable2 implementation SwTransferable.
This method is used by online via doc_getSelectionType() to determine the
type of selection. In writer this method used to classify shape objects as
non-complex which translates to 'text' in online, so if a shape is selected
in online, the js code there would treat it as text. This is problematic
when you want to send the correct align uno commands based on selection type.
So returning true in isComplex() for writer would correctly treat the shape
selections as 'complex' in online Writer.
Change-Id: I09fcd9e4fab48aa0d7e7d04c88bae9e1281a1b0c
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88158
Reviewed-by: Jan Holesovsky <kendy@collabora.com>
Tested-by: Jan Holesovsky <kendy@collabora.com>
(cherry picked from commit c7178a12e6e57e3d85cecd09e9c0373ececbb33f)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/88495
Tested-by: Jenkins
Reviewed-by: Andras Timar <andras.timar@collabora.com>
Diffstat (limited to 'sw')
-rw-r--r-- | sw/source/uibase/dochdl/swdtflvr.cxx | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/sw/source/uibase/dochdl/swdtflvr.cxx b/sw/source/uibase/dochdl/swdtflvr.cxx index a0230ef3630a..6dbb5c50046b 100644 --- a/sw/source/uibase/dochdl/swdtflvr.cxx +++ b/sw/source/uibase/dochdl/swdtflvr.cxx @@ -455,6 +455,9 @@ sal_Bool SAL_CALL SwTransferable::isComplex() } } + if (m_pWrtShell->GetSelectionType() == SelectionType::DrawObject) + return true; // Complex + // Simple return false; } |