Changeset d4dac80 in sasview for src/sas/qtgui/MainWindow


Ignore:
Timestamp:
Apr 25, 2018 6:59:33 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:
017b285
Parents:
93c79b5
git-author:
Piotr Rozyczko <rozyczko@…> (03/22/18 16:46:19)
git-committer:
Piotr Rozyczko <rozyczko@…> (04/25/18 06:59:33)
Message:

Merge branch 'ESS_GUI' into ESS_GUI_better_batch

Location:
src/sas/qtgui/MainWindow
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • src/sas/qtgui/MainWindow/DataExplorer.py

    rd6e38661 rd4dac80  
    476476        self.chkBatch.setEnabled(self.parent.perspective().allowBatch()) 
    477477 
     478    def itemFromFilename(self, filename): 
     479        """ 
     480        Retrieves model item corresponding to the given filename 
     481        """ 
     482        item = GuiUtils.itemFromFilename(filename, self.model) 
     483        return item 
     484 
    478485    def displayFile(self, filename=None, is_data=True): 
    479486        """ 
  • src/sas/qtgui/MainWindow/GuiManager.py

    r3b8cc00 rd4dac80  
    2121from sas.qtgui.Utilities.TabbedModelEditor import TabbedModelEditor 
    2222from sas.qtgui.Utilities.PluginManager import PluginManager 
     23from sas.qtgui.Utilities.GridPanel import BatchOutputPanel 
     24 
    2325from sas.qtgui.MainWindow.UI.AcknowledgementsUI import Ui_Acknowledgements 
    2426from sas.qtgui.MainWindow.AboutBox import AboutBox 
     
    130132        self.aboutWidget = AboutBox() 
    131133        self.welcomePanel = WelcomePanel() 
     134        self.grid_window = None 
    132135 
    133136        # Add calculators - floating for usability 
     
    263266            msg = "Guiframe does not have a current perspective" 
    264267            logging.info(msg) 
     268 
     269    def findItemFromFilename(self, filename): 
     270        """ 
     271        Queries the data explorer for the index corresponding to the filename within 
     272        """ 
     273        return self.filesWidget.itemFromFilename(filename) 
    265274 
    266275    def quitApplication(self): 
     
    405414        self._workspace.actionGPU_Options.triggered.connect(self.actionGPU_Options) 
    406415        self._workspace.actionFit_Results.triggered.connect(self.actionFit_Results) 
    407         self._workspace.actionChain_Fitting.triggered.connect(self.actionChain_Fitting) 
    408416        self._workspace.actionAdd_Custom_Model.triggered.connect(self.actionAdd_Custom_Model) 
    409417        self._workspace.actionEdit_Custom_Model.triggered.connect(self.actionEdit_Custom_Model) 
     
    428436        self._workspace.actionCheck_for_update.triggered.connect(self.actionCheck_for_update) 
    429437 
     438        self.communicate.sendDataToGridSignal.connect(self.showBatchOutput) 
     439 
    430440    #============ FILE ================= 
    431441    def actionLoadData(self): 
     
    527537        """ 
    528538        """ 
    529         print("actionShow_Grid_Window TRIGGERED") 
    530         pass 
     539        self.showBatchOutput(None) 
     540 
     541    def showBatchOutput(self, output_data): 
     542        """ 
     543        Display/redisplay the batch fit viewer 
     544        """ 
     545        if self.grid_window is None: 
     546            self.grid_window = BatchOutputPanel(parent=self, output_data=output_data) 
     547            subwindow = self._workspace.workspace.addSubWindow(self.grid_window) 
     548 
     549            #self.grid_window = BatchOutputPanel(parent=self, output_data=output_data) 
     550            self.grid_window.show() 
     551            return 
     552        if output_data: 
     553            self.grid_window.addFitResults(output_data) 
     554        self.grid_window.show() 
     555        if self.grid_window.windowState() == Qt.WindowMinimized: 
     556            self.grid_window.setWindowState(Qt.WindowActive) 
    531557 
    532558    def actionHide_Toolbar(self): 
     
    658684        """ 
    659685        print("actionFit_Results TRIGGERED") 
    660         pass 
    661  
    662     def actionChain_Fitting(self): 
    663         """ 
    664         """ 
    665         print("actionChain_Fitting TRIGGERED") 
    666686        pass 
    667687 
  • src/sas/qtgui/MainWindow/UI/MainWindowUI.ui

    r01ef3f7 rd4dac80  
    106106    <addaction name="actionFit_Results"/> 
    107107    <addaction name="separator"/> 
    108     <addaction name="actionChain_Fitting"/> 
    109     <addaction name="separator"/> 
    110108    <addaction name="actionAdd_Custom_Model"/> 
    111109    <addaction name="actionEdit_Custom_Model"/> 
Note: See TracChangeset for help on using the changeset viewer.