diff options
author | Lillian Angel <langel@redhat.com> | 2006-02-14 19:40:07 +0000 |
---|---|---|
committer | Lillian Angel <langel@redhat.com> | 2006-02-14 19:40:07 +0000 |
commit | 63720ddd552c66a7442e658b76991ad71d462915 (patch) | |
tree | ffbffe96377cc401d83f7cd577b14089f814deb2 /gnu/java/awt/peer/gtk/GtkDialogPeer.java | |
parent | af89e6c92680517560ba9d83ee1a108672520fb4 (diff) | |
download | classpath-63720ddd552c66a7442e658b76991ad71d462915.tar.gz |
2006-02-14 Lillian Angel <langel@redhat.com>
* gnu/java/awt/peer/gtk/GtkDialogPeer.java
(setVisible): New method to override super. Need to set the
native bounds of the component, so it appears at the
correct location.
Diffstat (limited to 'gnu/java/awt/peer/gtk/GtkDialogPeer.java')
-rw-r--r-- | gnu/java/awt/peer/gtk/GtkDialogPeer.java | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/gnu/java/awt/peer/gtk/GtkDialogPeer.java b/gnu/java/awt/peer/gtk/GtkDialogPeer.java index 3e3125a2b..24af0f7b5 100644 --- a/gnu/java/awt/peer/gtk/GtkDialogPeer.java +++ b/gnu/java/awt/peer/gtk/GtkDialogPeer.java @@ -62,6 +62,16 @@ public class GtkDialogPeer extends GtkWindowPeer g.translate (-insets.left, -insets.top); return g; } + + public void setVisible (boolean b) + { + // Prevent the window manager from automatically placing this + // window when it is shown. + setBounds(awtComponent.getX(), awtComponent.getY(), + awtComponent.getWidth(), awtComponent.getHeight()); + + super.setVisible(b); + } protected void postMouseEvent(int id, long when, int mods, int x, int y, int clickCount, boolean popupTrigger) |