Work at SourceForge, help us to make it a better place! We have an immediate need for a Support Technician in our San Francisco or Denver office.

Close

#26 ColumnSpanLabelProvider does not paint correct background color of selected item when focus is lost

1.0.1
open-fixed
None (24)
5
2010-10-16
2010-10-16
jfirechief
No

DO NOT EDIT OR ANSWER THIS ISSUE. SEE THE ORIGINAL ISSUE INSTEAD:
https://www.jfire.org/modules/bugs/view.php?id=1581
ORIGINAL REPORTER: daniel

When an Implementation of ColumnSpanLabelProvider is used then the background color of a selected item (e.g. in a tree) still remains "active". Under Windows selected items which does not have the focus anymore turn grey. When an ColumnSpanLabelProvider is used the background remains blue (the behaviour when the selected item has the focus).
When a different LabelProvider is used the behaviour is correct.

Discussion

  • jfirechief
    jfirechief
    2010-10-16

    • labels: --> None
    • milestone: --> 1.0.1
    • assigned_to: nobody --> danielmazurek
    • status: open --> open-fixed
     
  • jfirechief
    jfirechief
    2010-10-16

    ORIGINAL COMMENT BY alex, VIEW IT HERE:
    https://www.jfire.org/modules/bugs/view.php?id=1581

    The problem here is the erase-method of the super-class of ColumnSpanLabelProvider: OwnerDrawLabelProvider. It forces the color SWT.COLOR_LIST_SELECTION to be drawn as background if an item is selected, the foreground then changes to the default (os-setting).

    I've overridden the method and commented the call to super, afaik this should yield default behaviour for background and foreground. I could verify this on linux, but not for windows.

    The change is checked in in trunk and a patch is attached here.
    Please verify the fix for windows and port to the jfire 1.0 branch.