source: trunk/FACT++/gui/MainWindow.h@ 10727

Last change on this file since 10727 was 10678, checked in by tbretz, 14 years ago
Implemented a fix which should avoid that the GUI is playing ping-pong with e.g. the ftmctrl. This is done through a wrapper around all infoHandlers. In ceratin circumstances (mainly when signals of the kind valueChanged are emitted) it is advicable to not send the values back to the emitter if their origin is the handler.
File size: 2.7 KB
Line 
1#ifndef FACT_MainWindow
2#define FACT_MainWindow
3
4#include "design.h"
5
6#include <QMainWindow>
7
8class TObject;
9class TCanvas;
10
11class MainWindow : public QMainWindow, protected Ui::MainWindow
12{
13 Q_OBJECT;
14
15 void SelectTab(const QString &name);
16 void SetTriggerSequence();
17 void SetTriggerCoincidence();
18 void SetCalibCoincidence();
19
20protected:
21 QPushButton *fFtuLED[40];
22
23 bool fInHandler;
24
25public:
26 MainWindow(QWidget *p=0);
27
28private slots:
29 // System status
30 void on_fShutdown_clicked();
31 void on_fShutdownAll_clicked();
32
33 // Status LEDs signals
34 void on_fStatusFTULed_clicked();
35 void on_fStatusFTMLed_clicked();
36 void on_fStatusLoggerLed_clicked();
37 void on_fStatusChatLed_clicked();
38 //void on_fStatusFTMEnable_stateChanged(int state);
39
40 // Tab Widget
41 void on_fTabWidget_tabCloseRequested(int which);
42 virtual void on_fTabWidget_currentChanged(int) { }
43
44 // Tab: FTM
45 void on_fEnableTrigger_clicked(bool) { }
46 void on_fEnableExt1_clicked(bool) { }
47 void on_fEnableExt2_clicked(bool) { }
48 void on_fEnableTimeMarker_clicked(bool) { }
49 void on_fEnableVeto_clicked(bool) { }
50
51 void on_fTriggerSeqPed_valueChanged(int) { SetTriggerSequence(); }
52 void on_fTriggerSeqLPint_valueChanged(int) { SetTriggerSequence(); }
53 void on_fTriggerSeqLPext_valueChanged(int) { SetTriggerSequence(); }
54
55 void on_fPhysicsCoincidence_valueChanged(int);
56 void on_fPhysicsWindow_valueChanged(int);
57 void on_fCalibCoincidence_valueChanged(int);
58 void on_fCalibWindow_valueChanged(int);
59
60 void on_fTriggerInterval_valueChanged(int);
61 void on_fTriggerDelay_valueChanged(int);
62 void on_fTimeMarkerDelay_valueChanged(int);
63 void on_fDeadTime_valueChanged(int);
64
65 void on_fClockCondR0_valueChanged(int) { }
66 void on_fClockCondR1_valueChanged(int) { }
67 void on_fClockCondR8_valueChanged(int) { }
68 void on_fClockCondR9_valueChanged(int) { }
69 void on_fClockCondR11_valueChanged(int) { }
70 void on_fClockCondR13_valueChanged(int) { }
71 void on_fClockCondR14_valueChanged(int) { }
72 void on_fClockCondR15_valueChanged(int) { }
73
74 void on_fPrescalingVal_valueChanged(int);
75
76 // Tab: FTUs
77 void slot_fFtuLED_clicked();
78 void on_fPing_toggled(bool);
79
80 // Tab: Rates
81 void on_fThresholdVal_valueChanged(int v);
82 virtual void on_fThresholdIdx_valueChanged(int) { }
83
84 // Tab: Chat
85 void on_fChatSend_clicked();
86
87 // Tab: Commands
88 /// Needs access to DimNetwork thus it is implemented in the derived class
89 virtual void on_fDimCmdSend_clicked() { }
90
91 // Main menu
92 // void on_fMenuLogSaveAs_triggered(bool)
93
94 virtual void slot_RootEventProcessed(TObject *, unsigned int, TCanvas *) { }
95 virtual void slot_RootUpdate() { }
96
97 void slot_TimeUpdate();
98};
99
100#endif
Note: See TracBrowser for help on using the repository browser.