diff options
Diffstat (limited to 'Mozo')
-rw-r--r-- | Mozo/MainWindow.py | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/Mozo/MainWindow.py b/Mozo/MainWindow.py index 176c410..74e5fd8 100644 --- a/Mozo/MainWindow.py +++ b/Mozo/MainWindow.py @@ -67,6 +67,8 @@ class MainWindow: self.tree.get_object('move_up_button').set_sensitive(False) self.tree.get_object('move_down_button').set_sensitive(False) self.tree.get_object('new_separator_button').set_sensitive(False) + self.tree.get_object('properties_button').set_sensitive(False) + self.tree.get_object('delete_button').set_sensitive(False) accelgroup = Gtk.AccelGroup() keyval, modifier = Gtk.accelerator_parse('<Ctrl>Z') accelgroup.connect(keyval, modifier, Gtk.AccelFlags.VISIBLE, self.on_mainwindow_undo) @@ -450,14 +452,17 @@ class MainWindow: item = items[iter][3] self.tree.get_object('edit_delete').set_sensitive(True) self.tree.get_object('new_separator_button').set_sensitive(True) + self.tree.get_object('delete_button').set_sensitive(True) if self.editor.canRevert(item): self.tree.get_object('edit_revert_to_original').set_sensitive(True) else: self.tree.get_object('edit_revert_to_original').set_sensitive(False) if not item.get_type() == matemenu.TYPE_SEPARATOR: self.tree.get_object('edit_properties').set_sensitive(True) + self.tree.get_object('properties_button').set_sensitive(True) else: self.tree.get_object('edit_properties').set_sensitive(False) + self.tree.get_object('properties_button').set_sensitive(False) # If first item... if items.get_path(iter).get_indices()[0] == 0: @@ -640,6 +645,12 @@ class MainWindow: pass GLib.timeout_add(10, self.quit) + def on_properties_button_clicked(self, button): + self.on_edit_properties_activate(None) + + def on_delete_button_clicked(self, button): + self.on_edit_delete_activate(None) + def on_style_updated(self, *args): self.loadUpdates() |