Ignore:
Timestamp:
Apr 25, 2013 4:16:58 PM (12 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:
523f828
Parents:
8833c77
Message:

Instead of mdi, use wxframe on linux

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sansguiframe/src/sans/guiframe/gui_manager.py

    r8833c77 rd0923a3  
    194194CLOSE_SHOW = True 
    195195TIME_FACTOR = 2 
     196MDI_STYLE = wx.DEFAULT_FRAME_STYLE 
    196197NOT_SO_GRAPH_LIST = ["BoxSum"] 
    197 if sys.platform.count("darwin") > 0: 
     198PARENT_FRAME = wx.MDIParentFrame 
     199CHILD_FRAME = wx.MDIChildFrame 
     200if sys.platform.count("win32") < 1: 
    198201    IS_WIN = False 
    199202    TIME_FACTOR = 2 
     
    201204        if int(str(wx.__version__).split('.')[1]) < 9: 
    202205            CLOSE_SHOW = False 
    203      
    204 class ViewerFrame(wx.MDIParentFrame): 
     206    if sys.platform.count("darwin") < 1: 
     207        PARENT_FRAME = wx.Frame 
     208        CHILD_FRAME = wx.Frame 
     209     
     210class ViewerFrame(PARENT_FRAME): 
    205211    """ 
    206212    Main application frame 
     
    216222        """ 
    217223 
    218         wx.MDIParentFrame.__init__(self, parent=parent, title=title, pos=pos, size=size) 
     224        PARENT_FRAME.__init__(self, parent=parent, title=title, pos=pos, size=size) 
    219225        # title 
    220226        self.title = title 
     
    11761182        p.window_name = windowname + str(self.graph_num) 
    11771183         
    1178         style1 = self.__gui_style & GUIFRAME.FIXED_PANEL 
    1179         style2 = self.__gui_style & GUIFRAME.FLOATING_PANEL 
     1184        #style1 = self.__gui_style & GUIFRAME.FIXED_PANEL 
     1185        #style2 = self.__gui_style & GUIFRAME.FLOATING_PANEL 
    11801186         
    11811187        p.frame.SetTitle(p.window_caption) 
     
    34063412 
    34073413 
    3408 class MDIFrame(wx.MDIChildFrame): 
     3414class MDIFrame(CHILD_FRAME): 
    34093415    """ 
    34103416    Frame for panels 
     
    34183424        kwds['size']= size 
    34193425        kwds['title']= title 
     3426        kwds['style'] = MDI_STYLE 
    34203427        # Initialize the Frame object 
    3421         wx.MDIChildFrame.__init__(self, parent, *args, **kwds) 
     3428        CHILD_FRAME.__init__(self, parent, *args, **kwds) 
    34223429        self.parent = parent 
    34233430        self.name = "Untitled" 
Note: See TracChangeset for help on using the changeset viewer.