Ejemplo n.º 1
0
 def __init__(self, parent, operation):
     wx.Dialog.__init__(self, parent, -1, "Choose an object/entity",
         style = wx.DEFAULT_DIALOG_STYLE|wx.RESIZE_BORDER|wx.TAB_TRAVERSAL)
     self.operation = operation
     self.current_obj = None
     
     # Global objects
     self.global_objects = [
         ("Game message window", servers.get_game_message_window_proxy()),
         ("Mission handler", servers.get_mission_handler()),
         ("Music handler", servers.get_music_table())
         ]
     
     self.sizer_global_staticbox = wx.StaticBox(self, -1, "Global objects")
     self.sizer_current_staticbox = wx.StaticBox(
                                                 self, 
                                                 -1, 
                                                 "Current selected entity"
                                                 )
     self.label_entity = wx.StaticText(self, -1, "Entity:")
     self.label_name = wx.StaticText(self, -1, "<none>")
     self.button_current = wx.Button(self, -1, "Choose")
     self.list_globals = wx.ListBox(self, -1, choices=[])
     self.button_global = wx.Button(self, -1, "Choose")
     self.button_cancel = wx.Button(self, -1, "Cancel")
     
     self.__set_properties()
     self.__do_layout()
     self.__bind_events()
Ejemplo n.º 2
0
    def __init__(self, parent, operation):
        wx.Dialog.__init__(self,
                           parent,
                           -1,
                           "Choose an object/entity",
                           style=wx.DEFAULT_DIALOG_STYLE | wx.RESIZE_BORDER
                           | wx.TAB_TRAVERSAL)
        self.operation = operation
        self.current_obj = None

        # Global objects
        self.global_objects = [
            ("Game message window", servers.get_game_message_window_proxy()),
            ("Mission handler", servers.get_mission_handler()),
            ("Music handler", servers.get_music_table())
        ]

        self.sizer_global_staticbox = wx.StaticBox(self, -1, "Global objects")
        self.sizer_current_staticbox = wx.StaticBox(self, -1,
                                                    "Current selected entity")
        self.label_entity = wx.StaticText(self, -1, "Entity:")
        self.label_name = wx.StaticText(self, -1, "<none>")
        self.button_current = wx.Button(self, -1, "Choose")
        self.list_globals = wx.ListBox(self, -1, choices=[])
        self.button_global = wx.Button(self, -1, "Choose")
        self.button_cancel = wx.Button(self, -1, "Cancel")

        self.__set_properties()
        self.__do_layout()
        self.__bind_events()
Ejemplo n.º 3
0
 def on_mission_objectives(self, event):
     path = servers.get_mission_handler().getfullname()
     objdlg.create_window(self.get_frame(), path)
Ejemplo n.º 4
0
 def on_mission_objectives(self, event):
     path = servers.get_mission_handler().getfullname()
     objdlg.create_window( self.get_frame(), path )