Skip to content

Commit

Permalink
[ADD] onCloseAbout
Browse files Browse the repository at this point in the history
  • Loading branch information
franlu committed Mar 31, 2012
1 parent bd5eeb3 commit d1ca88c
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 deletions.
7 changes: 4 additions & 3 deletions rF1.glade
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@
<property name="border_width">5</property>
<property name="type_hint">dialog</property>
<property name="program_name">Reglajes F1</property>
<signal name="close" handler="onDeleteWindow" swapped="no"/>
<signal name="response" handler="onDeleteWindow" swapped="no"/>
<signal name="close" handler="onCloseAbout" swapped="no"/>
<signal name="response" handler="onCloseAbout" swapped="no"/>
<child internal-child="vbox">
<object class="GtkBox" id="aboutdialog-vbox1">
<property name="can_focus">False</property>
Expand Down Expand Up @@ -285,7 +285,7 @@
<object class="GtkImage" id="image20">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="pixbuf">resources/aut1.gif</property>
<property name="pixbuf">resources/aut2.gif</property>
</object>
<object class="GtkImage" id="image3">
<property name="visible">True</property>
Expand Down Expand Up @@ -432,6 +432,7 @@
<property name="image">image20</property>
<property name="use_stock">False</property>
<property name="always_show_image">True</property>
<signal name="activate" handler="onCircuitActivate" swapped="no"/>
</object>
</child>
<child>
Expand Down
8 changes: 6 additions & 2 deletions reglajesF1.py
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,9 @@ def onAboutDialog(self, *args):
self.about = self.builder.get_object("aboutdialog1")
self.about.show_all()

def onCloseAbout(self, *args):
self.about = self.builder.get_object("aboutdialog1")
self.about.hide()


def __init__(self):
Expand All @@ -90,10 +93,11 @@ def __init__(self):
self.handlers = {"onDeleteWindow": Gtk.main_quit,
"onButtonPressed": self.onButtonPressed,
"onCircuitActivate": self.onCircuitActivate,
"onAboutDialog": self.onAboutDialog,}
"onAboutDialog": self.onAboutDialog,
"onCloseAbout": self.onCloseAbout,}

self.builder.connect_signals(self.handlers)
self.init_combobox()
self.init_combobox()
self.window = self.builder.get_object("reglajes")
self.window.show_all()

Expand Down

0 comments on commit d1ca88c

Please sign in to comment.