/[ascend]/trunk/pygtk/interface/gtkbrowser.py
ViewVC logotype

Diff of /trunk/pygtk/interface/gtkbrowser.py

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

revision 172 by johnpye, Sat Jan 7 10:06:13 2006 UTC revision 173 by johnpye, Sat Jan 7 11:20:32 2006 UTC
# Line 64  class Browser: Line 64  class Browser:
64          if not self.window:          if not self.window:
65              raise RuntimeError("Couldn't load window from glade file")              raise RuntimeError("Couldn't load window from glade file")
66    
67          _geom=self.prefs.getGeometry(self.window.get_screen().get_display().get_name(),"browserwin")          _display = self.window.get_screen().get_display().get_name();
68            _geom=self.prefs.getGeometrySizePosition(_display,"browserwin")
69          if _geom:          if _geom:
70              self.window.resize(_geom[0],_geom[1]);              self.window.resize(_geom[0],_geom[1]);
71              self.window.move(_geom[2],_geom[3]);              self.window.move(_geom[2],_geom[3]);
72            
73          self.window.connect("delete_event", self.delete_event)          self.window.connect("delete_event", self.delete_event)
74    
75            self.browserpaned=glade.get_widget("browserpaned");
76            _geom2=self.prefs.getGeometryValue(_display,"browserpaned");
77            if _geom2:
78                self.browserpaned.set_position(_geom2);
79    
80          self.openbutton=glade.get_widget("openbutton")          self.openbutton=glade.get_widget("openbutton")
81          self.openbutton.connect("clicked",self.open_click)          self.openbutton.connect("clicked",self.open_click)
82    
# Line 789  class Browser: Line 795  class Browser:
795          self.reporter.clearPythonErrorCallback()          self.reporter.clearPythonErrorCallback()
796          _w,_h = self.window.get_size()          _w,_h = self.window.get_size()
797          _t,_l = self.window.get_position()          _t,_l = self.window.get_position()
798          self.prefs.setGeometry(self.window.get_screen().get_display().get_name(),"browserwin",_w,_h,_t,_l );          _display = self.window.get_screen().get_display().get_name()
799            self.prefs.setGeometrySizePosition(_display,"browserwin",_w,_h,_t,_l );
800    
801            _p = self.browserpaned.get_position()
802            self.prefs.setGeometryValue(_display,"browserpaned",_p);
803    
804          # causes prefs to be saved unless they are still being used elsewher          # causes prefs to be saved unless they are still being used elsewher
805          del(self.prefs)          del(self.prefs)

Legend:
Removed from v.172  
changed lines
  Added in v.173

john.pye@anu.edu.au
ViewVC Help
Powered by ViewVC 1.1.22