Ignore:
Timestamp:
Nov 26, 2018 7:07:55 AM (5 years ago)
Author:
Piotr Rozyczko <piotr.rozyczko@…>
Branches:
ESS_GUI, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc
Children:
9c207f5
Parents:
9c05f22
Message:

Redone the widget slightly, to fit with requirements in trac#1135.
Added comboboxes for all available fitpage names
Removed constraint of needing two selected fitpages
Removed the "Swap" button - it is redundant now.
Added context dependence on the "Select All" action.
Removed immediate constraint validation to allow for more complex
formulas

File:
1 edited

Legend:

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

    r72651df r2e5081b  
    3333        self.setDragDropMode(QtWidgets.QAbstractItemView.InternalMove) 
    3434 
    35         self._is_dragged = True 
     35        self._is_dragged = False 
    3636 
    3737    def isDragged(self): 
     
    872872        """ 
    873873        selected_rows = self.selectedParameters(self.tblTabList) 
    874         if len(selected_rows)!=2: 
    875             msg = "Please select two fit pages from the Source Choice table." 
    876             msgbox = QtWidgets.QMessageBox(self.parent) 
    877             msgbox.setIcon(QtWidgets.QMessageBox.Warning) 
    878             msgbox.setText(msg) 
    879             msgbox.setWindowTitle("2 fit page constraints") 
    880             retval = msgbox.exec_() 
    881             return 
    882  
    883         tab_list = [ObjectLibrary.getObject(self.tblTabList.item(s, 0).data(0)) for s in selected_rows] 
     874 
     875        tab_list = [ObjectLibrary.getObject(self.tblTabList.item(s, 0).data(0)) for s in range(self.tblTabList.rowCount())] 
    884876        # Create and display the widget for param1 and param2 
    885877        cc_widget = ComplexConstraint(self, tabs=tab_list) 
Note: See TracChangeset for help on using the changeset viewer.