MCPcopy Create free account
hub / github.com/OpenMS/OpenMS / tabBarDoubleClicked

Method tabBarDoubleClicked

src/openms_gui/source/VISUAL/DataSelectionTabs.cpp:228–257  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

226 }
227
228 void DataSelectionTabs::tabBarDoubleClicked(int tab_index)
229 {
230 if (!tv_->getActivePlotWidget())
231 {
232 return;
233 }
234 switch (tab_index)
235 {
236 case IDENT_IDX:
237 if (!isTabEnabled(IDENT_IDX))
238 {
239 setTabEnabled(IDENT_IDX, true); // enable identification view
240
241 spectraview_controller_->deactivateBehavior();
242 if (tv_->getActive2DWidget()) // currently 2D window is open
243 {
244 idview_controller_->showSpectrumAsNew1D(0);
245 }
246 idview_controller_->activateBehavior();
247
248 // TODO: check this triggers update!
249 setCurrentIndex(IDENT_IDX); // switch to identification view --> triggers currentTabChanged() slot
250 }
251 case SPECTRA_IDX:
252 default:
253 break;
254 }
255
256 // update here?
257 }
258
259 SpectraIDViewTab* DataSelectionTabs::getSpectraIDViewTab()
260 {

Callers

nothing calls this directly

Calls 5

getActivePlotWidgetMethod · 0.80
getActive2DWidgetMethod · 0.80
deactivateBehaviorMethod · 0.45
showSpectrumAsNew1DMethod · 0.45
activateBehaviorMethod · 0.45

Tested by

no test coverage detected