diff options
author | iovar <iovar@f606c939-3180-4ac9-a4b8-4b8779d57d0a> | 2008-02-04 16:53:56 +0000 |
---|---|---|
committer | iovar <iovar@f606c939-3180-4ac9-a4b8-4b8779d57d0a> | 2008-02-04 16:53:56 +0000 |
commit | 5c56f793ffee0913c1e83baa9dab4cd5382290e6 (patch) | |
tree | 9b09ddfc2459ba44318cf4f78a46a21c30ccccde /gtk-recordmydesktop/src | |
parent | 0c3445c42870fd3f06a6bb349b451413bba18872 (diff) |
src/rmdPrefsWidget.py: added button/dialog, to select workdir
git-svn-id: https://recordmydesktop.svn.sourceforge.net/svnroot/recordmydesktop/trunk@487 f606c939-3180-4ac9-a4b8-4b8779d57d0a
Diffstat (limited to 'gtk-recordmydesktop/src')
-rw-r--r-- | gtk-recordmydesktop/src/rmdPrefsWidget.py | 32 | ||||
-rw-r--r-- | gtk-recordmydesktop/src/rmdSimple.py | 4 |
2 files changed, 26 insertions, 10 deletions
diff --git a/gtk-recordmydesktop/src/rmdPrefsWidget.py b/gtk-recordmydesktop/src/rmdPrefsWidget.py index 479e15a..a3d531b 100644 --- a/gtk-recordmydesktop/src/rmdPrefsWidget.py +++ b/gtk-recordmydesktop/src/rmdPrefsWidget.py @@ -123,7 +123,7 @@ class prefsWidget(object): self.eboxes[i].add(self.boxes[i]) self.labelbox[0].pack_start(self.eboxes[i],expand=False,fill=False) - #self.workdir_layout=gtk.HBox(homogeneous=False, spacing=0) + self.workdir_layout=gtk.HBox(homogeneous=False, spacing=0) self.overwriteFilesButton=gtk.CheckButton(label=None) @@ -134,17 +134,18 @@ class prefsWidget(object): self.workdirEntry= gtk.Entry(max=0) self.workdirEntry.set_text(self.values[17]) self.workdirEntry.show() - self.boxes[1].pack_end(self.workdirEntry,expand=False,fill=False) - + #self.boxes[1].pack_end(self.workdirEntry,expand=False,fill=False) #self.file_button=gtk.Button(None,gtk.STOCK_SAVE_AS) #self.file_button.show() + self.workdir_button=gtk.Button(None,gtk.STOCK_SAVE_AS) + self.workdir_button.show() - #self.workdir_layout.pack_start(self.workdirEntry,expand=True,fill=True) - #self.workdir_layout.pack_start(self.file_button,expand=False,fill=False) - #self.workdir_layout.show() + self.workdir_layout.pack_start(self.workdirEntry,expand=True,fill=True) + self.workdir_layout.pack_start(self.workdir_button,expand=False,fill=False) + self.workdir_layout.show() - #self.labelbox[0].pack_start(self.workdir_layout,expand=False,fill=False) + self.labelbox[0].pack_start(self.workdir_layout,expand=False,fill=False) #Performance page @@ -363,10 +364,25 @@ class prefsWidget(object): if (not failed) and self.values[23]==[]: self.jack_lsp_listview.get_selection().select_path((0,)) #print self.jack_lsp_listview.get_selection().get_selected_rows() + + def __workdirSelect__(self,Event=None): + p=gtk.FileChooserDialog(title=None, + action=gtk.FILE_CHOOSER_ACTION_SELECT_FOLDER, + buttons=(gtk.STOCK_CANCEL,gtk.RESPONSE_CANCEL, + gtk.STOCK_OPEN,gtk.RESPONSE_OK) + ) + p.set_filename(self.workdirEntry.get_text()) + if p.run()==gtk.RESPONSE_OK: + tpath=p.get_filename() + if tpath!= '': + self.workdirEntry.set_text(tpath) + p.hide() + p.destroy() + def __makeCons__(self): self.jack_button.connect("clicked",self.__jack_enabled_check__) self.jack_lsp_refresh.connect("clicked",self.__runJackLSP__) - #self.file_button.connect("clicked",self.__fileSelect__) + self.workdir_button.connect("clicked",self.__workdirSelect__) def __register_shortcuts__(self): self.parent.advanced_button.add_accelerator("clicked",self.accel_group, diff --git a/gtk-recordmydesktop/src/rmdSimple.py b/gtk-recordmydesktop/src/rmdSimple.py index 19ea25c..ffaf5da 100644 --- a/gtk-recordmydesktop/src/rmdSimple.py +++ b/gtk-recordmydesktop/src/rmdSimple.py @@ -488,8 +488,8 @@ class simpleWidget(object): self.s_quality.set_sensitive(self.values[2]) self.s_button.set_active(self.values[2]) self.window.show() - wh=self.window.size_request() - self.window.set_size_request(wh[0],wh[1]) +# wh=self.window.size_request() +# self.window.set_size_request(wh[0],wh[1]) gtk.main() |