Integrating project properties panel into project window
authorlaurent
Sun, 03 Jun 2012 23:53:45 +0200
changeset 756 35cd28825be7
parent 755 9f5dbd90e1e0
child 757 3151495ae5bb
Integrating project properties panel into project window
ProjectNodeEditor.py
--- a/ProjectNodeEditor.py	Sun Jun 03 23:53:22 2012 +0200
+++ b/ProjectNodeEditor.py	Sun Jun 03 23:53:45 2012 +0200
@@ -1,7 +1,7 @@
 
 import wx
 
-from controls import EditorPanel
+from controls import EditorPanel, ProjectPropertiesPanel
 from ConfTreeNodeEditor import ConfTreeNodeEditor, WINDOW_COLOUR
 
 class ProjectNodeEditor(ConfTreeNodeEditor):
@@ -30,9 +30,16 @@
         self.ParamsEditorSizer.AddSizer(buttons_sizer, 0, border=5, 
                                         flag=wx.GROW|wx.LEFT|wx.RIGHT|wx.TOP)
         
+        projectproperties_sizer = wx.BoxSizer(wx.HORIZONTAL)
+        self.ParamsEditorSizer.AddSizer(projectproperties_sizer, 0, border=5, 
+                                        flag=wx.LEFT|wx.RIGHT|wx.BOTTOM)
+        
         self.ConfNodeParamsSizer = wx.BoxSizer(wx.VERTICAL)
-        self.ParamsEditorSizer.AddSizer(self.ConfNodeParamsSizer, 0, border=5, 
-                                        flag=wx.LEFT|wx.RIGHT|wx.BOTTOM)
+        projectproperties_sizer.AddSizer(self.ConfNodeParamsSizer, 0, border=5, 
+                                         flag=wx.RIGHT)
+        
+        self.ProjectProperties = ProjectPropertiesPanel(self.Editor, self.Controler, self.ParentWindow)
+        projectproperties_sizer.AddWindow(self.ProjectProperties, 0, border=0, flag=0)
         
     def __init__(self, parent, controler, window):
         configuration = controler.GetProjectMainConfigurationName()
@@ -55,5 +62,16 @@
     def RefreshView(self):
         EditorPanel.RefreshView(self)
         self.RefreshConfNodeParamsSizer()
+        self.ProjectProperties.RefreshView()
 
-        
\ No newline at end of file
+    def GetBufferState(self):
+        return self.Controler.GetBufferState()
+        
+    def Undo(self):
+        self.Controler.LoadPrevious()
+        self.ParentWindow.CloseTabsWithoutModel()
+            
+    def Redo(self):
+        self.Controler.LoadNext()
+        self.ParentWindow.CloseTabsWithoutModel()
+    
\ No newline at end of file