mailr10480 - in /branches/bieri_gui/gui_bieri: ./ oxygen_icons/16x16/apps/


Others Months | Index by Date | Thread Index
>>   [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Header


Content

Posted by edward on January 28, 2010 - 11:27:
Author: bugman
Date: Thu Jan 28 11:27:45 2010
New Revision: 10480

URL: http://svn.gna.org/viewcvs/relax?rev=10480&view=rev
Log:
Added access to the relax controller from the main window.

The 'View' menu has been created with the single entry 'Controller'.  This 
has a new oxygen icon.
The menu entry executes the show_controller() method which simply calls 
self.controller.ShowModal().
The controller will need to be modified to be universally accessible and 
closable at any time.


Added:
    branches/bieri_gui/gui_bieri/oxygen_icons/16x16/apps/
    
branches/bieri_gui/gui_bieri/oxygen_icons/16x16/apps/preferences-system-performance.png
   (with props)
Modified:
    branches/bieri_gui/gui_bieri/paths.py
    branches/bieri_gui/gui_bieri/relax_gui.py

Added: 
branches/bieri_gui/gui_bieri/oxygen_icons/16x16/apps/preferences-system-performance.png
URL: 
http://svn.gna.org/viewcvs/relax/branches/bieri_gui/gui_bieri/oxygen_icons/16x16/apps/preferences-system-performance.png?rev=10480&view=auto
==============================================================================
Binary file - no diff available.

Propchange: 
branches/bieri_gui/gui_bieri/oxygen_icons/16x16/apps/preferences-system-performance.png
------------------------------------------------------------------------------
    svn:mime-type = image/png

Modified: branches/bieri_gui/gui_bieri/paths.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/bieri_gui/gui_bieri/paths.py?rev=10480&r1=10479&r2=10480&view=diff
==============================================================================
--- branches/bieri_gui/gui_bieri/paths.py (original)
+++ branches/bieri_gui/gui_bieri/paths.py Thu Jan 28 11:27:45 2010
@@ -40,6 +40,7 @@
 ABOUT_RELAX_ICON = IMAGE_PATH + 'relax_16x16.png'
 ABOUT_RELAXGUI_ICON = IMAGE_PATH + 'relax_16x16.png'
 CONTACT_ICON = ICON_PATH + 
'16x16'+sep+'actions'+sep+'mail-mark-unread-new.png'
+CONTROLLER_ICON = ICON_PATH + 
'16x16'+sep+'apps'+sep+'preferences-system-performance.png'
 EXIT_ICON = ICON_PATH + '16x16'+sep+'actions'+sep+'system-shutdown.png'
 LOAD_ICON = ICON_PATH + '16x16'+sep+'actions'+sep+'arrow-right.png'
 MANUAL_ICON = ICON_PATH + '16x16'+sep+'actions'+sep+'help-contents.png'

Modified: branches/bieri_gui/gui_bieri/relax_gui.py
URL: 
http://svn.gna.org/viewcvs/relax/branches/bieri_gui/gui_bieri/relax_gui.py?rev=10480&r1=10479&r2=10480&view=diff
==============================================================================
--- branches/bieri_gui/gui_bieri/relax_gui.py (original)
+++ branches/bieri_gui/gui_bieri/relax_gui.py Thu Jan 28 11:27:45 2010
@@ -52,7 +52,7 @@
 from derived_wx_classes import StructureTextCtrl
 from filedialog import multi_openfile, opendir, openfile, savefile
 from message import dir_message, exec_relax, missing_data, question, 
relax_run_ok
-from paths import ABOUT_RELAX_ICON, ABOUT_RELAXGUI_ICON, CONTACT_ICON, 
EXIT_ICON, IMAGE_PATH, LOAD_ICON, MANUAL_ICON, NEW_ICON, OPEN_ICON, REF_ICON, 
SAVE_AS_ICON, SETTINGS_ICON, SETTINGS_GLOBAL_ICON, SETTINGS_RESET_ICON
+from paths import ABOUT_RELAX_ICON, ABOUT_RELAXGUI_ICON, CONTACT_ICON, 
CONTROLLER_ICON, EXIT_ICON, IMAGE_PATH, LOAD_ICON, MANUAL_ICON, NEW_ICON, 
OPEN_ICON, REF_ICON, SAVE_AS_ICON, SETTINGS_ICON, SETTINGS_GLOBAL_ICON, 
SETTINGS_RESET_ICON
 from settings import import_file_settings, load_sequence, 
relax_global_settings
 
 
@@ -1794,6 +1794,14 @@
         self.Bind(wx.EVT_MENU, self.state_save, id=2)
         self.Bind(wx.EVT_MENU, self.exitGUI,    id=3)
 
+        # The 'View' menu entries.
+        menu = wx.Menu()
+        menu.AppendItem(self.build_menu_sub_item(id=50, text="&Controller", 
icon=CONTROLLER_ICON))
+        menubar.Append(menu, "&View")
+
+        # The 'View' actions.
+        self.Bind(wx.EVT_MENU, self.show_controller,    id=50)
+
         # The 'Molecule' menu entries.
         menu = wx.Menu()
         menu.AppendItem(self.build_menu_sub_item(id=10, text="Load &PDB 
File", icon=LOAD_ICON))
@@ -2566,6 +2574,20 @@
         event.Skip()
 
 
+    def show_controller(self, event):
+        """Display the relax controller window.
+
+        @param event:   The wx event.
+        @type event:    wx event
+        """
+
+        # Open the window.
+        self.controller.ShowModal()
+
+        # Terminate the event.
+        event.Skip()
+
+
     def state_load(self, event):
         """Load the program state.
 




Related Messages


Powered by MHonArc, Updated Thu Jan 28 11:40:02 2010