Ticket #712: label_remote_directory.patch

File label_remote_directory.patch, 3.3 KB (added by tes, 16 years ago)

Path for label plugin

Line 
1diff -crB old/label/data/label_options.glade new/label/data/label_options.glade
2*** old/label/data/label_options.glade 2009-01-24 15:01:34.000000000 +0100
3--- new/label/data/label_options.glade 2009-01-24 14:59:51.000000000 +0100
4***************
5*** 447,455 ****
6 <property name="n_rows">3</property>
7 <property name="n_columns">2</property>
8 <child>
9! <widget class="GtkFileChooserButton" id="move_completed_path">
10 <property name="visible">True</property>
11! <property name="action">GTK_FILE_CHOOSER_ACTION_SELECT_FOLDER</property>
12 </widget>
13 <packing>
14 <property name="right_attach">2</property>
15--- 447,455 ----
16 <property name="n_rows">3</property>
17 <property name="n_columns">2</property>
18 <child>
19! <widget class="GtkEntry" id="move_completed_path">
20 <property name="visible">True</property>
21! <property name="can_focus">True</property>
22 </widget>
23 <packing>
24 <property name="right_attach">2</property>
25diff -crB old/label/gtkui/sidebar_menu.py new/label/gtkui/sidebar_menu.py
26*** old/label/gtkui/sidebar_menu.py 2009-01-24 15:01:34.000000000 +0100
27--- new/label/gtkui/sidebar_menu.py 2009-01-24 14:48:19.000000000 +0100
28***************
29*** 191,197 ****
30 for id in self.chk_ids:
31 self.glade.get_widget(id).set_active(bool(options[id]))
32
33! self.glade.get_widget("move_completed_path").set_filename(options["move_completed_path"])
34
35 self.glade.get_widget("auto_add_trackers").get_buffer().set_text("\n".join(options["auto_add_trackers"]))
36
37--- 191,197 ----
38 for id in self.chk_ids:
39 self.glade.get_widget(id).set_active(bool(options[id]))
40
41! self.glade.get_widget("move_completed_path").set_text(options["move_completed_path"])
42
43 self.glade.get_widget("auto_add_trackers").get_buffer().set_text("\n".join(options["auto_add_trackers"]))
44
45***************
46*** 206,212 ****
47 for id in self.chk_ids:
48 options[id] = self.glade.get_widget(id).get_active()
49
50! options["move_completed_path"] = self.glade.get_widget("move_completed_path").get_filename()
51 buff = self.glade.get_widget("auto_add_trackers").get_buffer() #sometimes I hate gtk...
52 tracker_lst = buff.get_text(buff.get_start_iter(), buff.get_end_iter()).strip().split("\n")
53 options["auto_add_trackers"] = [x for x in tracker_lst if x] #filter out empty lines.
54--- 206,212 ----
55 for id in self.chk_ids:
56 options[id] = self.glade.get_widget(id).get_active()
57
58! options["move_completed_path"] = self.glade.get_widget("move_completed_path").get_text()
59 buff = self.glade.get_widget("auto_add_trackers").get_buffer() #sometimes I hate gtk...
60 tracker_lst = buff.get_text(buff.get_start_iter(), buff.get_end_iter()).strip().split("\n")
61 options["auto_add_trackers"] = [x for x in tracker_lst if x] #filter out empty lines.