Changeset ef01be4 in sasview for src/sas/qtgui/DataExplorer.py


Ignore:
Timestamp:
Dec 2, 2016 4:28:23 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:
b94889a
Parents:
ded2ce3
Message:

More context menu functionality in plots - SASVIEW-167

File:
1 edited

Legend:

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

    r8548d739 ref01be4  
    410410                raise AttributeError, msg 
    411411 
    412  
    413412        if plots and \ 
    414413           hasattr(new_plot, 'data') and \ 
     
    765764        data = GuiUtils.dataFromItem(model_item) 
    766765 
    767         dimension = 1 if isinstance(data, Data1D) else 2 
     766        method_name = 'Plotter' 
     767        if isinstance(data, Data2D): 
     768            method_name='Plotter2D' 
    768769 
    769770        # TODO: Replace this with the proper MaskPlotPanel from plottools 
    770         new_plot = Plotter(self) 
    771         new_plot.data(data) 
     771        new_plot = globals()[method_name](self, quickplot=True) 
     772        new_plot.data = data 
    772773        new_plot.plot(marker='o', linestyle='') 
    773774 
Note: See TracChangeset for help on using the changeset viewer.