Skip to content
Snippets Groups Projects
Commit d83b708f authored by Lan Dam's avatar Lan Dam
Browse files

correct pref_order is the order of plotting_data1

parent cb8efaff
No related branches found
No related tags found
1 merge request!261Feature for users to hide/show and reorder channels
# Define functions to call processor
from typing import Tuple, Union, Dict, List
from typing import Tuple, Union, Dict, List, Optional
from PySide6 import QtCore
......@@ -33,8 +33,15 @@ class MultiThreadedPlottingWidget(PlottingWidget):
def __init__(self, *args, **kwargs):
PlottingWidget.__init__(self, *args, **kwargs)
self.data_processors: List[PlottingChannelProcessor] = []
# pref_order: order of channels to be plotted
# order of channels to be plotted
self.pref_order: List[str] = []
# object of data to be plotted
self.data_object: Optional[GeneralData] = None
# id of data set to be plotted
self.data_set_id: Union[str, Tuple[str, str]] = ''
self.start_tm: float = 0
self.end_tm: float = 0
# Only one data processor can run at a time, so it is not a big problem
#
self.thread_pool = QtCore.QThreadPool()
......@@ -127,7 +134,6 @@ class MultiThreadedPlottingWidget(PlottingWidget):
chan_order, list(plotting_data.keys()))
chan_order = remove_not_found_chans(
chan_order, list(plotting_data.keys()), self.processing_log)
self.pref_order = chan_order
not_plot_chans = []
for chan_id in chan_order:
......@@ -231,7 +237,7 @@ class MultiThreadedPlottingWidget(PlottingWidget):
return
chan_order1 = self.get_plotting_info(self.plotting_data1, True)
chan_order2 = self.get_plotting_info(self.plotting_data2)
self.pref_order = chan_order1
self.plotting_preset()
self.create_plotting_channel_processors(
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment