/[classpath]/classpath/gnu/java/awt/peer/gtk/GtkComponentPeer.java
ViewVC logotype

Diff of /classpath/gnu/java/awt/peer/gtk/GtkComponentPeer.java

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.94 by fitzsim, Fri Aug 19 01:29:26 2005 UTC revision 1.95 by fitzsim, Thu Aug 25 02:26:48 2005 UTC
# Line 100  public class GtkComponentPeer extends Gt Line 100  public class GtkComponentPeer extends Gt
100    native void gtkWidgetGetPreferredDimensions (int[] dim);    native void gtkWidgetGetPreferredDimensions (int[] dim);
101    native void gtkWidgetGetLocationOnScreen (int[] point);    native void gtkWidgetGetLocationOnScreen (int[] point);
102    native void gtkWidgetSetCursor (int type);    native void gtkWidgetSetCursor (int type);
103      native void gtkWidgetSetCursorUnlocked (int type);
104    native void gtkWidgetSetBackground (int red, int green, int blue);    native void gtkWidgetSetBackground (int red, int green, int blue);
105    native void gtkWidgetSetForeground (int red, int green, int blue);    native void gtkWidgetSetForeground (int red, int green, int blue);
106    native void gtkWidgetSetSensitive (boolean sensitive);    native void gtkWidgetSetSensitive (boolean sensitive);
# Line 477  public class GtkComponentPeer extends Gt Line 478  public class GtkComponentPeer extends Gt
478    
479    public void setCursor (Cursor cursor)    public void setCursor (Cursor cursor)
480    {    {
481      gtkWidgetSetCursor (cursor.getType ());      if (Thread.currentThread() == GtkToolkit.mainThread)
482          gtkWidgetSetCursorUnlocked (cursor.getType ());
483        else
484          gtkWidgetSetCursor (cursor.getType ());
485    }    }
486    
487    public void setEnabled (boolean b)    public void setEnabled (boolean b)
# Line 510  public class GtkComponentPeer extends Gt Line 514  public class GtkComponentPeer extends Gt
514      return new Color (rgb[0], rgb[1], rgb[2]);      return new Color (rgb[0], rgb[1], rgb[2]);
515    }    }
516    
517      public native void setVisibleNative (boolean b);
518      public native void setVisibleNativeUnlocked (boolean b);
519    
520    public void setVisible (boolean b)    public void setVisible (boolean b)
521    {    {
522      if (b)      if (Thread.currentThread() == GtkToolkit.mainThread)
523        show ();        setVisibleNativeUnlocked (b);
524      else      else
525        hide ();        setVisibleNative (b);
526    }    }
527    
528    public native void hide ();    public void hide ()
529    public native void show ();    {
530        setVisible (false);
531      }
532    
533      public void show ()
534      {
535        setVisible (true);
536      }
537    
538    protected void postMouseEvent(int id, long when, int mods, int x, int y,    protected void postMouseEvent(int id, long when, int mods, int x, int y,
539                                  int clickCount, boolean popupTrigger)                                  int clickCount, boolean popupTrigger)

Legend:
Removed from v.1.94  
changed lines
  Added in v.1.95

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26