def __init__(self, parent):
"""Initialize the UploaderAppPanel.
Args:
parent: the parent Window for this panel.
"""
wx.Panel.__init__(self, parent)
self._parent = parent
self._discovered_runs = []
self._selected_directory = None
self._sizer = wx.BoxSizer(wx.VERTICAL)
# topics to handle from directory scanning
pub.subscribe(self._add_run, DirectoryScannerTopics.run_discovered)
pub.subscribe(self._finished_loading, DirectoryScannerTopics.finished_run_scan)
pub.subscribe(self._sample_sheet_error, DirectoryScannerTopics.garbled_sample_sheet)
pub.subscribe(self._sample_sheet_error, DirectoryScannerTopics.missing_files)
# topics to handle when settings have changed in the settings frame
pub.subscribe(self._settings_changed, SettingsDialog.settings_closed_topic)
# topics to handle when a directory is selected by File > Open
pub.subscribe(self._directory_selected, UploaderAppFrame.directory_selected_topic)
self._settings_changed()
self.SetSizerAndFit(self._sizer)
评论列表
文章目录