Community
Participate
Working Groups
Please run the attached sample code on OS X (I'm using OS X 10.11). While clicking the nodes with the left mouse button, the background is painted in full width, but after releasing the mouse, only a part of the item's background is painted. If the SWT.TOOL option is not used for the shell, then the whole tree item's background is painted correctly, independent of the mouse-down state.
Created attachment 266224 [details] Sample code to reproduce
Created attachment 266225 [details] Screenshot while holding the left mouse button pressed (or without using SWT.TOOL)
Created attachment 266226 [details] Screenshot with using SWT.TOOL after releasing the mouse button
Unfortunately, we need to use the SWT.TOOL option to work-around the bug 470062.
Even without the SWT.TOOL there is a problem if a selection listener sets the selection again (this is the essence of existing code stripped by unrelated code): tree.addListener(SWT.Selection, event -> { final TreeItem[] selection = tree.getSelection(); if (selection.length == 1) { tree.setSelection(selection[0]); tree.showItem(selection[0]); } });
This bug hasn't had any activity in quite some time. Maybe the problem got resolved, was a duplicate of something else, or became less pressing for some reason - or maybe it's still relevant but just hasn't been looked at yet. As such, we're closing this bug. If you have further information on the current state of the bug, please add it and reopen this bug. The information can be, for example, that the problem still occurs, that you still want the feature, that more information is needed, or that the bug is (for whatever reason) no longer relevant. -- The automated Eclipse Genie.
Bug still can be reproduced with SWT 4_18_maintenance on macOS 10.14.