The Author Online Book Forums are Moving

The Author Online Book Forums will soon redirect to Manning's liveBook and liveVideo. All book forum content will migrate to liveBook's discussion forum and all video forum content will migrate to liveVideo. Log in to liveBook or liveVideo with your Manning credentials to join the discussion!

Thank you for your engagement in the AoF over the years! We look forward to offering you a more enhanced forum experience.

This topic is READ ONLY
import-bot (20211) [Avatar] Offline
#1
[Originally posted by manis]

Hi Matt,
Is the glass pane solution valid on an JApplet?. What adjustments
do I need to make to make that work. I have tried setting the
glass pane of the JApplet to a BusyPane (extended from JPanel and implements
Mouse Listener) as defined by your spec. Thanks as always.
import-bot (20211) [Avatar] Offline
#2
Re: Mouse Cursor - Glass Pane Solution ??
[Originally posted by matt]

That didn't work? Can you post your BusyPane implementation so we can take a
look?
import-bot (20211) [Avatar] Offline
#3
Re: Mouse Cursor - BusyGlassPaneCode Fragment for Matt
[Originally posted by manis]

> That didn't work? Can you post your BusyPane implementation so we can take a
> look?
public class BusyGlassPanel extends com.sun.java.swing.JPanel implements
java.awt.event.MouseListener {
}
public BusyGlassPanel() {
super();
this.setCursor(java.awt.Cursor.getPredefinedCursor(java.awt.Cursor.WAIT_CURSOR));

this.setVisible(true);

}


Then the above BusyGlassPanel is used as follows :-
if (busy)
{
BusyGlassPanel aBusyPane = new BusyGlassPanel();
java.awt.Component aDefaultGP =
((TimeEntryApplet)getParentApplet)).getGlassPane();
((TimeEntryApplet)getParentApplet()).setMyDefaultGlassPane(aDefaultGP);
((TimeEntryApplet)getParentApplet()).setGlassPane(aBusyPane);
System.out.println ("Setting Busy Cursor on Applet");
}
else
{
java.awt.Component aDefaultGP = ((TimeEntryApplet)
getParentApplet)).getMyDefaultGlassPane();
((TimeEntryApplet)getParentApplet()).setGlassPane(aDefaultGP);
System.out.println ("Setting Free Cursor on Applet");
}