Changeset 8dfe0fd in sasview for sansview


Ignore:
Timestamp:
Oct 16, 2009 2:42:37 PM (15 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:
17c5868
Parents:
e3a76c8
Message:

Now able to choose parameters (Combobox event) for constrains in the simul. fit panel on MAC.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • sansview/perspectives/fitting/simfitpage.py

    re814734 r8dfe0fd  
    318318        param_cbox = wx.ComboBox(self, -1,style=wx.CB_READONLY) 
    319319        param_cbox.Hide() 
     320         
     321        #This is for GetCLientData() _on_select_param: Was None return on MAC. 
     322        self.param_cbox = param_cbox 
     323         
    320324        wx.EVT_COMBOBOX(param_cbox,-1, self._on_select_param) 
    321325        ctl2 = wx.TextCtrl(self, -1) 
     
    331335            model_cbox.Append( str(model.name), model) 
    332336             
     337        #This is for GetCLientData() passing to self._on_select_param: Was None return on MAC. 
     338        self.model_cbox = model_cbox 
    333339            
    334340        wx.EVT_COMBOBOX(model_cbox,-1, self._on_select_model) 
     
    379385         fill combox box with list of parameters 
    380386        """ 
    381         model = event.GetClientData() 
     387        ##This way PC/MAC both work, instead of using event.GetClientData(). 
     388        n = self.model_cbox.GetCurrentSelection() 
     389        model = self.model_cbox.GetClientData(n) 
     390         
    382391        param_list= get_fittableParam(model) 
    383392        length = len(self.constraints_list) 
     
    402411            Store the appropriate constraint in the page_finder 
    403412        """ 
    404         model = event.GetClientData() 
     413        ##This way PC/MAC both work, instead of using event.GetClientData(). 
     414        n = self.param_cbox.GetCurrentSelection() 
     415        model = self.param_cbox.GetClientData(n) 
    405416        param = event.GetString() 
    406417       
Note: See TracChangeset for help on using the changeset viewer.