Java Solaris Communities Sun Store Join SDN My Profile Why Join?
 
Bug Database
Bug Detail
Quick Lists
Top 25 Bugs
Top 25 RFE's
Recently Closed Bugs
Printable Page Printable Page


Bug Database
Bug ID: 6458700
Votes 0
Synopsis WinLaF : Vista : JScrollbar button updates on rollover instead of entire scrollbar
Category java:classes_swing
Reported Against
Release Fixed mustang(b97)
State 10-Fix Delivered, bug
Priority: 4-Low
Related Bugs 6461337 , 6462156
Submit Date 09-AUG-2006
Description
In a native Vista applications when the user moves the mouse over a scrollbar button all the of the internal scrollbar comopnents change the state (the thumb, the buttons at the end, the track, etc).  In Swing only the button the mouse is over has the state changed.
Posted Date : 2006-08-09 22:09:40.0
Work Around
N/A
Evaluation
Initial thoughts:

On Vista there are new HOVER states defined for the buttons. This state appears to mean that if another attached component is in the HOT state then this component is in the HOVER state. In other words, it's the rollover state when you should show an effect but the mouse cursor isn't actually over you. An example of this is the native Vista scrollbar. When the mouse moves over the thumb in the middle of the bar the buttons at the ends will repaint to show a rollover effect.  

Since the thumb already as a mouse listener it should be possible to modify it to include this effect. It would trigger a repaint on the buttons (or perhaps just the entire scrollbar). When the buttons are repainted they will calculate their STATE based on the button model. They could also take into account the state of their associated thumb. If the thumb == HOT then they should be in HOVER. This same logic should be applied to the thumb and the other button as well, so that they all move into the HOT and HOVER states together.  Once in the HOVER state the components should draw appropriately.

To ensure this behavior only happens on Vista the code should check that the HOVER state is actually on each affected component, since that state doesn't exist in previous versions of Windows.
Posted Date : 2006-08-15 00:45:50.0
Comments
  
  Include a link with my name & email   


PLEASE NOTE: JDK6 is formerly known as Project Mustang