Changeset cee5c78 in sasview for src/sas/qtgui/Perspectives


Ignore:
Timestamp:
Nov 9, 2017 8:41:55 AM (7 years ago)
Author:
Piotr Rozyczko <rozyczko@…>
Branches:
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
Children:
7fb471d
Parents:
b3e8629
git-author:
Piotr Rozyczko <rozyczko@…> (10/27/17 03:42:57)
git-committer:
Piotr Rozyczko <rozyczko@…> (11/09/17 08:41:55)
Message:

Converted more syntax not covered by 2to3

Location:
src/sas/qtgui/Perspectives
Files:
4 edited

Legend:

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

    • Property mode changed from 100755 to 100644
    rb3e8629 rcee5c78  
    156156    """ 
    157157    for i, item in enumerate(model_header_captions): 
    158         #model.setHeaderData(i, QtCore.Qt.Horizontal, QtCore.QVariant(item)) 
    159158        model.setHeaderData(i, QtCore.Qt.Horizontal, item) 
    160159 
  • src/sas/qtgui/Perspectives/Fitting/FittingWidget.py

    rb3e8629 rcee5c78  
    995995        if not dict: 
    996996            return 
     997        if self._model_model.rowCount() == 0: 
     998            return 
    997999 
    9981000        def iterateOverMagnetModel(func): 
     
    10061008            # Utility function for main model update 
    10071009            # internal so can use closure for param_dict 
     1010            if self._magnet_model.item(row, 0) is None: 
     1011                return 
    10081012            param_name = str(self._magnet_model.item(row, 0).text()) 
    10091013            if param_name not in list(param_dict.keys()): 
  • src/sas/qtgui/Perspectives/Fitting/ModelThread.py

    • Property mode changed from 100755 to 100644
    rb3e8629 rcee5c78  
    5353        self.starttime = time.time() 
    5454        # Determine appropriate q range 
    55         if self.qmin == None: 
     55        if self.qmin is None: 
    5656            self.qmin = 0 
    57         if self.qmax == None: 
    58             if self.data != None: 
     57        if self.qmax is None: 
     58            if self.data is not None: 
    5959                newx = math.pow(max(math.fabs(self.data.xmax), 
    6060                                   math.fabs(self.data.xmin)), 2) 
  • src/sas/qtgui/Perspectives/Invariant/InvariantPerspective.py

    • Property mode changed from 100755 to 100644
    rb3e8629 rcee5c78  
    297297 
    298298            # Add the plot to the model item 
    299             # variant_item = QtCore.QVariant(self._plotter) 
    300             variant_item = QtCore.QVariant(extrapolated_data) 
    301  
    302299            # This needs to run in the main thread 
    303300            reactor.callFromThread(GuiUtils.updateModelItemWithPlot, 
    304                     self._model_item, variant_item, title) 
     301                    self._model_item, extrapolated_data, title) 
    305302 
    306303        if self._high_extrapolate: 
     
    322319 
    323320            # Add the plot to the model item 
    324             # variant_item = QtCore.QVariant(self._plotter) 
    325             variant_item = QtCore.QVariant(high_out_data) 
    326321            # This needs to run in the main thread 
    327322            reactor.callFromThread(GuiUtils.updateModelItemWithPlot, 
    328                     self._model_item, variant_item, title) 
     323                    self._model_item, high_out_data, title) 
    329324 
    330325        item = QtGui.QStandardItem(str(float('%.5g'% volume_fraction))) 
     
    561556        # Extract data on 1st child - this is the Data1D/2D component 
    562557        data = GuiUtils.dataFromItem(self._model_item) 
    563         self.model.item(WIDGETS.W_FILENAME).setData(QtCore.QVariant(self._model_item.text())) 
     558        self.model.item(WIDGETS.W_FILENAME).setData(self._model_item.text()) 
    564559 
    565560        ##### DEBUG #### 
Note: See TracChangeset for help on using the changeset viewer.