Changeset 9e9be13 in sasview for fittingview/src


Ignore:
Timestamp:
Oct 14, 2011 1:08:35 PM (13 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:
978feaa
Parents:
87e1d1a
Message:

fixed a bug, not updating models in model_cb

File:
1 edited

Legend:

Unmodified
Added
Removed
  • fittingview/src/sans/perspectives/fitting/simfitpage.py

    r87e1d1a r9e9be13  
    246246        """ 
    247247        if self.model_cbox_left != None and self.model_cbox_right != None: 
    248             self.model_cbox_left.Clear() 
    249             self.model_cbox_right.Clear() 
     248            try: 
     249                # when there is something 
     250                self.model_cbox_left.Clear() 
     251                self.model_cbox_right.Clear() 
     252                self.model_cbox.Clear() 
     253            except: 
     254                # when there is nothing 
     255                pass 
    250256            #for id, model in self.constraint_dict.iteritems(): 
    251257            for item in self.model_toFit: 
     
    257263                if str(model.name) not in self.model_cbox_right.GetItems(): 
    258264                    self.model_cbox_right.Append(str(model.name), model) 
     265                if str(model.name) not in self.model_cbox.GetItems(): 
     266                    self.model_cbox.Append(str(model.name), model) 
    259267            self.model_cbox_left.SetSelection(0) 
    260268            self.sizer2.Layout() 
Note: See TracChangeset for help on using the changeset viewer.