[Qt-interest] Changing drag/drop cursors whilst dragging
Tim Edwards
tim.edwards at fxhome.com
Thu Feb 11 14:36:47 CET 2010
Hello,
I'm trying to find a way of changing the mouse cursor when you perform drag/drop operations since I want to give feedback to the user when they drag the object over different targets as to what will happen. I'm aware that you can set a cursor for 4 types under Windows, [Copy, Move, Link, Ignore], and that you can additionally set a QPixmap. While this works I find myself needing to change the cursor after the QDrag has called exec(), for various "Move" operations.
Having looked into the Win32 implementation, the DoDragDrop() Win function will call GiveFeedback() when the target changes. Looking at the QOleDropSource::GiveFeedback(...) class found in qdnd_win.cpp that function does indeed change the cursor via:
SetCursor(m_cursors[m_currentAction].handle());
Is there a way to hook into this? Or perhaps someone give me an alternative solution?
Kind regards,
Tim Edwards
________________________________
This email is confidential. It may also be privileged or otherwise protected by work product immunity or other legal rules. If you are not the intended recipient please notify the sender. Please delete the message from all places in your computer where it is stored. You should not copy the email or use it for any purpose or disclose its contents to any other person.To do so may be unlawful. Email is an informal means of communicating and may be subject to data corruption accidentally or deliberately. For this reason it is inappropriate to rely on advice contained in an email without obtaining written confirmation of it first.
FXhome Limited is a limited company registered in England and Wales. Registered number: 04172812. Registered office: The Henderson Business Centre, Ivy Road, Norwich, Norfolk, NR5 8BF, U.K.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20100211/36f03a9b/attachment.html
More information about the Qt-interest-old
mailing list