Ignore:
Timestamp:
Aug 24, 2016 11:15:28 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:
d45d590
Parents:
5a525e1
git-author:
Lewis O'Driscoll <lewis.o'driscoll@…> (08/24/16 10:59:41)
git-committer:
Lewis O'Driscoll <lewis.o'driscoll@…> (08/24/16 11:15:28)
Message:

Implement save analysis in corfunc

File:
1 edited

Legend:

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

    rcaeb382 r96d293da  
    1010from sas.sasgui.guiframe.gui_style import GUIFRAME_ID 
    1111from sas.sasgui.guiframe.dataFitting import Data1D 
     12from sas.sascalc.dataloader.data_info import Data1D as LoaderData1D 
    1213from sas.sascalc.dataloader.loader import Loader 
    1314 
     
    250251    type_name = "Corfunc" 
    251252 
    252     type = ["Invariant file (*.inv)|*.inv", 
     253    type = ["Corfunc file (*.cor)|*.cor", 
    253254            "SASView file (*.svs)|*.svs"] 
    254255 
     
    312313        if datainfo is None: 
    313314            datainfo = Data1D(x=[], y=[]) 
    314         elif not issubclass(datainfo.__class__, Data1D): 
    315             msg = ("The CanSAS writer expects a Data1D instance. {} was ", 
     315        elif not (isinstance(datainfo, Data1D) or isinstance(datainfo, LoaderData1D)): 
     316            msg = ("The CanSAS writer expects a Data1D instance. {} was " 
    316317                "provided").format(datainfo.__class__.__name__) 
    317318            raise RuntimeError, msg 
Note: See TracChangeset for help on using the changeset viewer.