Changeset 957723f in sasview for guiframe/local_perspectives


Ignore:
Timestamp:
Mar 25, 2011 10:37:30 AM (14 years ago)
Author:
Gervaise Alina <gervyh@…>
Branches:
master, ESS_GUI, ESS_GUI_Docs, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_iss959, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc, costrafo411, magnetic_scatt, release-4.1.1, release-4.1.2, release-4.2.2, release_4.0.1, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
Children:
3e943e8
Parents:
68b7d43
Message:

working on guiframe config

Location:
guiframe/local_perspectives
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • guiframe/local_perspectives/data_loader/data_loader.py

    re88ebfd r957723f  
    1717from sans.guiframe.utils import parse_name 
    1818from sans.guiframe.gui_style import GUIFRAME 
    19  
    20 EXTENSIONS = ['.svs', '.prv','.fitv', '.inv'] 
     19try: 
     20    # Try to find a local config 
     21    import imp 
     22    path = os.getcwd() 
     23    if(os.path.isfile("%s/%s.py" % (path, 'local_config'))) or \ 
     24        (os.path.isfile("%s/%s.pyc" % (path, 'local_config'))): 
     25        fObj, path, descr = imp.find_module('local_config', [path]) 
     26        config = imp.load_module('local_config', fObj, path, descr)   
     27    else: 
     28        # Try simply importing local_config 
     29        import local_config as config 
     30except: 
     31    # Didn't find local config, load the default  
     32    import config 
     33  
     34extension_list = [] 
     35if APPLICATION_STATE_EXTENSION is not None: 
     36    extension_list.append(APPLICATION_STATE_EXTENSION) 
     37EXTENSIONS = PLUGIN_STATE_EXTENSIONS + extension_list    
    2138 
    2239class Plugin(PluginBase): 
  • guiframe/local_perspectives/plotting/plotting.py

    r783940c r957723f  
    8989        return False 
    9090         
    91     def clear_panel(self, group_id): 
     91    def clear_panel(self): 
     92        """ 
     93        """ 
     94        pass 
     95     
     96    def clear_panel_by_id(self, group_id): 
    9297        """ 
    9398        clear the graph 
     
    239244                return self.delete_panel(group_id) 
    240245            if event.action.lower() == "clear": 
    241                 return self.clear_panel(group_id) 
     246                return self.clear_panel_by_id(group_id) 
    242247             
    243248        title = None 
Note: See TracChangeset for help on using the changeset viewer.