Ignore:
Timestamp:
Jul 11, 2016 2:36:55 AM (8 years ago)
Author:
lewis
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, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
Children:
d4f5637
Parents:
d888abf
git-author:
Lewis O'Driscoll <lewis.o'driscoll@…> (07/11/16 02:31:53)
git-committer:
Lewis O'Driscoll <lewis.o'driscoll@…> (07/11/16 02:36:55)
Message:

On project load, only plot extrapolation/transform if they were plotted before project save

File:
1 edited

Legend:

Unmodified
Added
Removed
  • src/sas/sasgui/perspectives/corfunc/corfunc_panel.py

    r6ccf18e r2ff9e37  
    9898        if self.state.background is not None: 
    9999            self.set_background(self.state.background) 
     100        if self.state.is_extrapolated: 
     101            self.compute_extrapolation() 
     102        else: 
     103            return 
     104        if self.state.is_transformed: 
     105            self.compute_transform() 
     106        else: 
     107            return 
    100108        if self.state.outputs is not None and self.state.outputs != {}: 
    101109            self.set_extracted_params(self.state.outputs) 
    102             self.compute_extrapolation() 
    103             self.compute_transform() 
    104110 
    105111    def get_state(self): 
     
    116122            state.file = self._data.title 
    117123            state.data = self._data 
     124        if self._extrapolated_data is not None: 
     125            state.is_extrapolated = True 
     126        if self._transformed_data is not None: 
     127            state.is_transformed = True 
    118128        self.state = state 
    119129 
     
    236246        state = self.get_state() 
    237247        if data is not None: 
     248            import pdb; pdb.set_trace() 
    238249            new_doc, sasentry = self._manager.state_reader._to_xml_doc(data) 
    239250            new_doc = state.toXML(doc=new_doc, entry_node=sasentry) 
Note: See TracChangeset for help on using the changeset viewer.