Changeset 1767884 in sasview


Ignore:
Timestamp:
Feb 2, 2011 12:17:02 PM (13 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:
3385795
Parents:
193416e
Message:

move the code to initialize prview to guiframe

File:
1 edited

Legend:

Unmodified
Added
Removed
  • prview/PrView.py

    r75df58b r1767884  
    1111APP_HEIGHT = 780 
    1212APP_WIDTH  = 850 
    13  
     13PROG_SPLASH_SCREEN = "images/ball.png" 
    1414class PrFrame(gui_manager.ViewerFrame): 
    1515    """ 
     
    2424    """ 
    2525    """ 
    26     def OnInit(self): 
    27         """ 
    28         """ 
    29         # Check the size of the screen 
    30         # Add some padding to make sure to clear any OS tool bar 
    31         screen_size = wx.GetDisplaySize() 
    32         app_height = APP_HEIGHT if screen_size[1]>APP_HEIGHT else screen_size[1]-50 
    33         app_width  = APP_WIDTH if screen_size[0]>APP_WIDTH else screen_size[0]-50 
    34          
    35         self.frame = PrFrame(None, -1, local_config.__appname__,  
    36                              window_height=app_height, window_width=app_width)     
    37         self.frame.Show(True) 
    38  
    39         if hasattr(self.frame, 'special'): 
    40             self.frame.special.SetCurrent() 
    41         self.SetTopWindow(self.frame) 
    42         return True 
     26    SIZE = (APP_WIDTH, APP_HEIGHT) 
     27    TITLE = local_config.__appname__ 
     28    PROG_SPLASH_PATH = None 
    4329     
    44 class SansView(): 
     30class PrView(): 
    4531    """ 
    4632    """ 
     
    5137        #self.gui = gui_manager.ViewApp(0)  
    5238        self.gui = PrApp(0) 
    53          
    5439        # Add perspectives to the basic application 
    5540        # Additional perspectives can still be loaded 
     
    7055 
    7156if __name__ == "__main__":  
    72     sansview = SansView() 
     57    sansview = PrView() 
Note: See TracChangeset for help on using the changeset viewer.