Re: [Java-gnome-developer] Quitting windows and apps
                
                Brought to you by:
                
                    afcowie
                    
                
            
            
        
        
        
    | 
      
      
      From: Andrew C. <an...@op...> - 2011-04-28 13:50:01
      
     | 
| On Tue, 2011-04-26 at 11:08 -0600, Adam Balan wrote:
> My issue is that when I close one window I don’t want all my windows
> to close. Current I am using Gtk.mainQuit(); to close windows. 
To force a Window to "close", call Widget's hide() on the Window
you're finished with.
        // I'm done
        window.hide();
        
http://java-gnome.laptop/4.0/doc/api/org/gnome/gtk/Widget.html#hide()
java-gnome takes care of the interaction between the underlying GObject
and our Java Proxy object; actual disposal of the Window won't happen
until all your Java references to the Window go out of scope (else you
could resurrect it with show(), right?)
AfC
Ko Phi Phi
P.S. Hackers: it is probable that the Widget.destroy() method  newly
available in 4.0.20 will have the same effect; someone needs to enable
reference management debugging and test the has-user-ref interaction.
See src/bindings/org/gnome/gtk/GtkWindowOverride.c
 |