Changeset c91ef7e in sasview


Ignore:
Timestamp:
May 10, 2011 5:06:37 PM (14 years ago)
Author:
Jae Cho <jhjcho@…>
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:
ad1e49c
Parents:
25c1576
Message:

trying to fix MAC active Show/Hide/On/Off? menu

Location:
guiframe
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • guiframe/gui_manager.py

    r0c26793 rc91ef7e  
    7474    PLUGINS_WLIST = '' 
    7575APPLICATION_WLIST = config.APPLICATION_WLIST 
    76  
     76if sys.platform.count("darwin")==0: 
     77    IS_WIN = True 
     78else: 
     79    IS_WIN = False 
     80     
    7781class ViewerFrame(wx.Frame): 
    7882    """ 
     
    503507                              Left(). 
    504508                              MinimizeButton(). 
    505                               CloseButton(True). 
     509                              CloseButton(IS_WIN). 
    506510                              TopDockable(False). 
    507511                              BottomDockable(False). 
  • guiframe/local_perspectives/plotting/plotting.py

    r25c1576 rc91ef7e  
    2424 
    2525if sys.platform.count("darwin")==0: 
    26     IS_MAC = False 
     26    IS_WIN = True 
    2727else: 
    28     IS_MAC = True 
     28    IS_WIN = False 
    2929 
    3030class Plugin(PluginBase): 
     
    158158        self.menu.AppendCheckItem(event_id, new_panel.window_caption,  
    159159                         "Show %s plot panel" % new_panel.window_caption) 
    160         self.menu.Check(event_id, True) 
     160        self.menu.Check(event_id, IS_WIN) 
    161161        wx.EVT_MENU(self.parent, event_id, self._on_check_menu) 
    162          
    163         if IS_MAC: 
    164             wx.EVT_CLOSE(new_panel, self._on_close_panel) 
    165         else: 
    166             wx.EVT_SHOW(new_panel, self._on_close_panel) 
     162 
     163        wx.EVT_SHOW(new_panel, self._on_close_panel) 
    167164         
    168165        # Set UID to allow us to reference the panel later 
     
    305302        if self.menu.IsChecked(event_id): 
    306303            self.parent.on_view(event) 
    307             self.menu.Check(event_id, True) 
     304            self.menu.Check(event_id, IS_WIN) 
    308305        else: 
    309306            self.parent.hide_panel(event_id) 
Note: See TracChangeset for help on using the changeset viewer.