OSDN Git Service

Add menuitem for showing board window and board list window
authorAiwota Programmer <aiwotaprog@tetteke.tk>
Mon, 21 Aug 2006 03:36:46 +0000 (12:36 +0900)
committerAiwota Programmer <aiwotaprog@tetteke.tk>
Mon, 21 Aug 2006 03:36:46 +0000 (12:36 +0900)
src/Hage1/thread_window.py
src/data/thread_window.glade

index 759224b..25b8865 100644 (file)
@@ -30,6 +30,8 @@ import datfile
 import barehtmlparser
 import idxfile
 import windowlist
+import board_window
+import brdlist_window
 
 GLADE_DIR = os.path.join(os.path.dirname(os.path.realpath(__file__)),
                          "..", "data")
@@ -74,6 +76,9 @@ class WinWrap:
                   "on_refresh_activate": self.update,
                   "on_close_activate": self.on_close_activate,
                   "on_quit_activate": self.on_quit_activate,
+                  "on_show_board_activate": self.on_show_board_activate,
+                  "on_show_board_list_activate":
+                  self.on_show_board_list_activate,
                   "on_thread_window_destroy": self.on_thread_window_destroy}
         self.widget_tree.signal_autoconnect(sigdic)
 
@@ -88,6 +93,12 @@ class WinWrap:
     def on_quit_activate(self, widget):
         gtk.main_quit()
 
+    def on_show_board_activate(self, widget):
+        board_window.open_board(self.bbs, self.board)
+
+    def on_show_board_list_activate(self, widget):
+        brdlist_window.open_brdlist(self.bbs)
+
     def http_get_dat(self, on_get_res):
         datfile_url = misc.get_thread_dat_url(self.bbs, self.board, self.thread)
 
index 88d43e1..85ff461 100644 (file)
                    <widget class="GtkMenu" id="file1_menu">
 
                      <child>
+                       <widget class="GtkMenuItem" id="show_board">
+                         <property name="visible">True</property>
+                         <property name="label" translatable="yes">Show Board</property>
+                         <property name="use_underline">True</property>
+                         <signal name="activate" handler="on_show_board_activate" last_modification_time="Mon, 21 Aug 2006 03:30:53 GMT"/>
+                       </widget>
+                     </child>
+
+                     <child>
+                       <widget class="GtkMenuItem" id="show_board_list">
+                         <property name="visible">True</property>
+                         <property name="label" translatable="yes">Show Board List</property>
+                         <property name="use_underline">True</property>
+                         <signal name="activate" handler="on_show_board_list_activate" last_modification_time="Mon, 21 Aug 2006 03:30:53 GMT"/>
+                       </widget>
+                     </child>
+
+                     <child>
                        <widget class="GtkImageMenuItem" id="refresh">
                          <property name="visible">True</property>
                          <property name="label" translatable="yes">_Refresh</property>