Changeset f86343bd in sasview


Ignore:
Timestamp:
Mar 29, 2019 7:03:31 AM (7 weeks ago)
Author:
ibressler
Branches:
ESS_GUI_bumps_abstraction
Children:
691e268
Parents:
ccfe03b
git-author:
Ingo Breßler <dev@…> (03/29/19 06:54:09)
git-committer:
Ingo Breßler <dev@…> (03/29/19 07:03:31)
Message:

FittingOptions?: minor consistency fix

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/sas/qtgui/Perspectives/Fitting/FittingOptions.py

    rccfe03b rf86343bd  
    423423        fm = self.fittingMethods[self.currentOptimizer] 
    424424        for param in fm.params.values(): 
    425             # Find the widget name of the option 
    426             # e.g. 'samples' for 'dream' is 'self.samples_dream' 
    427             widget_name = 'self.'+param.shortName+'_'+fm.shortName 
     425            # get the widget name of the option 
     426            widget = self.paramWidget(fm, param.shortName) 
    428427            if isinstance(param.type, (tuple, list)): 
    429                 control = eval(widget_name) 
    430                 control.setCurrentIndex(control.findText(str(param.value))) 
     428                widget.setCurrentIndex(widget.findText(str(param.value))) 
    431429            else: 
    432                 eval(widget_name).setText(str(param.value)) 
     430                widget.setText(str(param.value)) 
    433431 
    434432    def updateConfigFromWidget(self, fittingMethod): 
Note: See TracChangeset for help on using the changeset viewer.