Trolltech Home | Qt-interest Home | Recent Threads | All Threads | Author | Date
All threads index page 2

Qt-interest Archive, March 2008
window (proxy) icon handling on Mac OS X


Message 1 in thread

I'm currently using Qt 4.3.2, and trying to implement proxy icon  
support (click and drag to copy the file, and command-click for menu  
showing file location) on Mac OS X. There is example code at http:// 
doc.trolltech.com/qq/qq18-macfeatures.html#newevents showing how to  
handle the QEvent::IconDrag event to achieve this.

However, as far as I can tell, when I Command-click on the icon,  
there is no IconDrag event sent, only NonClientAreaMouseButtonPress,  
which isn't specific to clicks in the proxy icon. (IconDrag is sent  
for clicks in the icon with other modifier keys, just not with the  
Command key.)

Is this a bug, or is there some other way Command-click (i.e. click  
with Qt::ControlModifier) in the proxy icon should be handled? I  
couldn't find any other relevant event in the documentation, nor by  
watching the events sent to my window.

Actually, for the correct user experience, we should respond to  
Command-click in the window title as well as the actual proxy icon  
(not within the entire title bar, only the width of the actual text).  
Can anyone suggest how to do this in Qt?

Thanks,

Jonathan

--
 [ signature omitted ] 

Message 2 in thread

Yeah, I reported this issue to the Trolls a while back (see tracker
192527) which now shows they've fixed the bug in Qt4.4.0. For now you
can respond to shift clicks instead of command clicks. In Qt4.4 you
can rip out all your slick proxy icon code since Trenton basically did
all the wrk for you and it looks far more native (wrt icons etc) then
ever before using a few easy to use methods...

Will

On Thu, Mar 6, 2008 at 4:01 PM, Jonathan Kew <jonathan_kew@xxxxxxx> wrote:
> I'm currently using Qt 4.3.2, and trying to implement proxy icon
>  support (click and drag to copy the file, and command-click for menu
>  showing file location) on Mac OS X. There is example code at http://
>  doc.trolltech.com/qq/qq18-macfeatures.html#newevents showing how to
>  handle the QEvent::IconDrag event to achieve this.
>
>  However, as far as I can tell, when I Command-click on the icon,
>  there is no IconDrag event sent, only NonClientAreaMouseButtonPress,
>  which isn't specific to clicks in the proxy icon. (IconDrag is sent
>  for clicks in the icon with other modifier keys, just not with the
>  Command key.)
>
>  Is this a bug, or is there some other way Command-click (i.e. click
>  with Qt::ControlModifier) in the proxy icon should be handled? I
>  couldn't find any other relevant event in the documentation, nor by
>  watching the events sent to my window.
>
>  Actually, for the correct user experience, we should respond to
>  Command-click in the window title as well as the actual proxy icon
>  (not within the entire title bar, only the width of the actual text).
>  Can anyone suggest how to do this in Qt?
>
>  Thanks,
>
>  Jonathan
>
>  --
>  To unsubscribe - send a mail to qt-interest-request@xxxxxxxxxxxxx with "unsubscribe" in the subject or the body.
>  List archive and information: http://lists.trolltech.com/qt-interest/
>
>

--
 [ signature omitted ]