PushButton pressed state is not shown for focused buttons in layered windows
----------------------------------------------------------------------------

                 Key: PIVOT-323
                 URL: https://issues.apache.org/jira/browse/PIVOT-323
             Project: Pivot
          Issue Type: Bug
          Components: wtk
    Affects Versions: 1.4
            Reporter: Todd Volkert
             Fix For: 1.4


Steps to reproduce:

1) Launch the kitchen sink demo
2) Open an alert or prompt
3) Mouse down on the focused command button

Result:

The pressed state is not shown.

Analysis:

moveToFront() is being called on the root owner of the alert or prompt, causing 
a focus loss (followed by an immediate focus gain) on the push button.  When 
the focus is lost, the pressed state is cleared.  Thus, by the time paint() is 
called, the button thinks that it is not pressed.

Further, the moving of windows is causing the repaint region to be the entire 
display, even though only the button was pressed.  This can be seen by enabling 
debug paints.

Suggestion:

In moveToFront(), could we somehow detect the order of windows that we hope to 
achieve, and if it's the same as the current order, make it a no-op?

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to