Issue 122497 - Can't drag gallery to in Calc on Mac
Summary: Can't drag gallery to in Calc on Mac
Alias: None
Product: Calc
Classification: Application
Component: editing (show other issues)
Version: 4.0.0-dev
Hardware: Mac OS X 10.8
: P3 Critical (vote)
Target Milestone: 4.0.0
Assignee: AOO issues mailing list
QA Contact:
Depends on:
Reported: 2013-06-08 09:06 UTC by liuping
Modified: 2017-05-20 11:42 UTC (History)
5 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---
jsc: 4.0.0_release_blocker+


Note You need to log in before you can comment on or make changes to this issue.
Description liuping 2013-06-08 09:06:58 UTC
Build :AOO400m2(Build:9701)  -  Rev. 1489073
on Mac OS

1. New a spreadsheet
2. Drag picture from gallery

Fail to add picture by dragging

In writer and presentation on Mac ,it passed
In Calc on Windows7 ,it passed
Comment 1 Andre 2013-06-18 10:09:50 UTC
The Calc edit view does not accept the gallery graphic.  The graphic can still be inserted via the context menu (Insert -> Copy).
Comment 2 Armin Le Grand 2013-06-18 13:30:23 UTC
ALG: Taking a look. Indeed, simple drag on mac in calc shows the symbol that indicates that the D&D is not accepted. Pressing CTRL+SHIFT works, and D&D on existing draw objects (holding CTRL+ALT) works, too. Taking a look...
Comment 3 Armin Le Grand 2013-06-18 16:18:52 UTC
ALG: Pressing any of the qualifier keys CTRL, ALT or CMD, makes it work. Checked GalleryTransferable::AddSupportedFormats, the correct formats are added. Checked ScGridWindow::AcceptDrop, the correct actions arrive, but nMyAction (and thus rEvt.mnAction) is on '5' which is wrong. Allowed values are from ::com::sun::star::datatransfer::dnd::DNDConstants and allow 0..4 and 0x80. Need to check how this happens (probably on the system-dependent side of things)...
Comment 4 Armin Le Grand 2013-06-18 16:49:43 UTC
ALG: On mac SystemToOfficeDragActions is used to convert between mac D&D actions and ::com::sun::star::datatransfer::dnd::DNDConstants. This method shows why a '5' is set in ScGridWindow::AcceptDrop in nMyAction; the value is a flag-value, not a numerical one. Thus the switch/case in ScGridWindow::AcceptDrop is basically wrong, but has to use the values as flag values. I am only curious why this ever had worked; maybe DND_ACTION_LINK was added in the near past somehow...?
Comment 5 Armin Le Grand 2013-06-18 16:50:44 UTC
ALG: Adding hdu to cc, he may know more if in the close past the mac D&D actions might have expanded.
Comment 6 Armin Le Grand 2013-06-19 10:00:12 UTC
ALG: Checked in sd, mnAction is handled as flag values. Sw is using a mix of comparisons and flag handling, (hopefully) filtering everywhere before usage as needed. Adapting code in Sc to handle as flag values, too...
Comment 7 Armin Le Grand 2013-06-19 11:16:21 UTC
ALG: Added filtering to ScGridWindow::ExecuteDrop, added handling to have direct D&D for objects. Checking on other plattforms...
Comment 8 Armin Le Grand 2013-06-19 13:11:01 UTC
ALG: Checked commited change on win, looks well, done.
Comment 9 Armin Le Grand 2013-06-19 15:11:30 UTC
LG: Also checked on linux, looks good, too.
Comment 10 jsc 2013-07-02 12:24:52 UTC
grant showstopper flag, fixed already
Comment 11 liuping 2013-07-10 06:09:37 UTC
Verify on Mac on Rev. 1499347