Beremiz.py
changeset 513 feb2acb04070
parent 509 aa5645a25d64
child 539 6ff2c1d34640
equal deleted inserted replaced
511:518c30f2a507 513:feb2acb04070
   384         self.LogConsole = wx.TextCtrl(id=ID_BEREMIZLOGCONSOLE, value='',
   384         self.LogConsole = wx.TextCtrl(id=ID_BEREMIZLOGCONSOLE, value='',
   385                   name='LogConsole', parent=self.BottomNoteBook, pos=wx.Point(0, 0),
   385                   name='LogConsole', parent=self.BottomNoteBook, pos=wx.Point(0, 0),
   386                   size=wx.Size(0, 0), style=wx.TE_MULTILINE|wx.TE_RICH2)
   386                   size=wx.Size(0, 0), style=wx.TE_MULTILINE|wx.TE_RICH2)
   387         self.LogConsole.Bind(wx.EVT_LEFT_DCLICK, self.OnLogConsoleDClick)
   387         self.LogConsole.Bind(wx.EVT_LEFT_DCLICK, self.OnLogConsoleDClick)
   388         self.BottomNoteBook.AddPage(self.LogConsole, _("Log Console"))
   388         self.BottomNoteBook.AddPage(self.LogConsole, _("Log Console"))
       
   389         self.BottomNoteBook.Split(self.BottomNoteBook.GetPageIndex(self.LogConsole), wx.RIGHT)
   389         
   390         
   390         self._init_beremiz_sizers()
   391         self._init_beremiz_sizers()
   391 
   392 
   392     def __init__(self, parent, projectOpen=None, buildpath=None, plugin_root=None, debug=True):
   393     def __init__(self, parent, projectOpen=None, buildpath=None, plugin_root=None, debug=True):
   393         IDEFrame.__init__(self, parent, debug)
   394         IDEFrame.__init__(self, parent, debug)
   430         self.Bind(wx.EVT_CLOSE, self.OnCloseFrame)
   431         self.Bind(wx.EVT_CLOSE, self.OnCloseFrame)
   431         
   432         
   432         self._Refresh(TITLE, TOOLBAR, FILEMENU, EDITMENU, DISPLAYMENU)
   433         self._Refresh(TITLE, TOOLBAR, FILEMENU, EDITMENU, DISPLAYMENU)
   433 
   434 
   434     def RiseLogConsole(self):
   435     def RiseLogConsole(self):
   435         for idx in xrange(self.BottomNoteBook.GetPageCount()):
   436         self.BottomNoteBook.SetSelection(self.BottomNoteBook.GetPageIndex(self.LogConsole))
   436             window = self.BottomNoteBook.GetPage(idx)
       
   437             if window == self.LogConsole:
       
   438                 self.BottomNoteBook.SetSelection(idx)
       
   439                 break
       
   440         
   437         
   441     def RefreshTitle(self):
   438     def RefreshTitle(self):
   442         name = _("Beremiz")
   439         name = _("Beremiz")
   443         if self.PluginRoot is not None:
   440         if self.PluginRoot is not None:
   444             projectname = self.PluginRoot.GetProjectName()
   441             projectname = self.PluginRoot.GetProjectName()