Posted by pietblok
on July 30, 2008 at 6:28 AM PDT
I experimented with JXLayer to create the effect of a disappearing cursor when the mouse is not touched for a few seconds. That worked great!
However, I encountered a problem: my component implements the Scrollable interface to have some custom behavior when used in a JScrollPane.
When I wrap my component in a JXLayer, that behavior is lost.
I cannot subclass JXLayer (you explained why). Is it possible to have JXLayer implement Scrollable and let it delegate the Scrollable methods to the wrapped component (if the wrapped component implements Scrollable)?
I am not sure what values should be returned if the wrapped component does not implement Scrollable. Maybe you could provide two versions of JXLayer, one implementing Scrollable, the other not?
As a temporary workaround I can of course wrap the JScrollPane, containing my component, in a JXLayer, but that has the effect of a disappearing cursor also on the slidebars (which I do not want).