Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 329576 - Toolbar buttons highlight background on Cocoa
Summary: Toolbar buttons highlight background on Cocoa
Status: RESOLVED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 3.7   Edit
Hardware: PC Mac OS X
: P3 normal (vote)
Target Milestone: 3.7 M4   Edit
Assignee: Silenio Quarti CLA
QA Contact:
URL:
Whiteboard:
Keywords:
: 258182 (view as bug list)
Depends on:
Blocks:
 
Reported: 2010-11-05 14:18 EDT by Bogdan Gheorghe CLA
Modified: 2010-12-07 17:29 EST (History)
2 users (show)

See Also:


Attachments
patch (1.59 KB, patch)
2010-11-05 15:37 EDT, Silenio Quarti CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Bogdan Gheorghe CLA 2010-11-05 14:18:23 EDT
In 3.x and 4.1, pressing a toolbar button on Cocoa will cause the button image to darken and the entire button to highlight which is rather jarring. This should be changed to only have the image on the button darken.
Comment 1 Scott Kovatch CLA 2010-11-05 14:23:18 EDT
I had fixed this in the NSToolbar case. We just need cell.setHighlightsBy(OS.NSContentsCellMask) to always be set, not just when we are using the unified toolbar.
Comment 2 Silenio Quarti CLA 2010-11-05 14:33:59 EDT
yes, I am about to make this change, but I want to check what happens when the there is no image.
Comment 3 Silenio Quarti CLA 2010-11-05 14:48:31 EDT
If we turn off the background highlight all the time, toolitems that only have text (no image) will have no indication that they are pushed in.
Comment 4 Scott Kovatch CLA 2010-11-05 15:06:07 EDT
Carbon does the same thing right now.

If you remove the "parent.nsToolbar != null" check in drawTitleWithFrameInView the text will highlight when you click on it.
Comment 5 Silenio Quarti CLA 2010-11-05 15:37:16 EDT
Created attachment 182519 [details]
patch

I am releasing this patch which makes the background not highlight anymore (only the image gets darken). When there is no image the text gets highlighted the same way it is done for the window toolbar. I am not sure this is how other apps handle this case, but I could not find any example.
Comment 6 Silenio Quarti CLA 2010-11-05 15:40:56 EDT
Fixed > 20101105
Comment 7 Scott Kovatch CLA 2010-12-07 17:29:21 EST
*** Bug 258182 has been marked as a duplicate of this bug. ***