Bug 18403 - ToolItems with the DROP_DOWN style should stay pushed
Summary: ToolItems with the DROP_DOWN style should stay pushed
Status: RESOLVED WONTFIX
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 2.0   Edit
Hardware: PC Windows All
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Felipe Heidrich CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2002-05-30 23:44 EDT by Rob Hughes CLA
Modified: 2003-01-06 15:51 EST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Rob Hughes CLA 2002-05-30 23:44:17 EDT
The default behavior for ToolItems with a DROP_DOWN style on a win32 platform 
is for the arrow to stay pushed while the popup menu is displayed.

This can be fixed with a simple code change.  The TBN_DROPDOWN message needs 
to be processed immediately for the arrow part of the ToolItem to stay pushed 
instead of being posted to the queue for later processing.

In the ToolBar.wmNotifyChild() method, changing child.postEvent() to 
child.sendEvent() will rectify the problem.
Comment 1 Steve Northover CLA 2002-05-31 17:26:18 EDT
Thanks.  You are right but there are issues surrounding send vs post for 
SWT.Selection events.  It think your change is good and should go in but it is 
way to late in the freeze cycle for R2.0 to risk it.
Comment 2 Felipe Heidrich CLA 2003-01-03 12:44:59 EST
we should re-consider this for 2.1
Comment 3 Steve Northover CLA 2003-01-06 15:51:31 EST
Changing this the post to the send will no longer fix the problem for menus in 
2.1 because Menu.setVisible() defers the menu pop up to the event loop.  This 
is to be consistent with the other platforms where pop up menus do not start a 
modal menu loop in the application code but instead, run from 
Display.readAndDispatch()).

I don't believe we should change this (sorry Rob).