ATLAS Offline Software
IVP12DStandardChannelWidget.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
3 */
4 
6 // //
7 // Header file for class IVP12DStandardChannelWidget //
8 // //
9 // Author: Thomas Kittelmann <Thomas.Kittelmann@cern.ch> //
10 // //
11 // Initial version: April 2007 //
12 // //
14 
15 #ifndef IVP12DSTANDARDCHANNELWIDGET_H
16 #define IVP12DSTANDARDCHANNELWIDGET_H
17 
19 class IVP12DSystem;
20 class IVP12DSystemSimple;
21 
23 
24  Q_OBJECT
25 
26 public:
27  IVP12DStandardChannelWidget(const QString & name, const QString & information, const QString & contact_info);
28  //Fixme: Pass along default backgroundcolor as an option?
29 
30 protected:
31  enum SystemOption {
32  AllowAll = 0x0000,
33  DisallowSelections = 0x0100,//User can not interact with items from this system (movable though, is handled separately)
34  DisallowSwitchable = 0x0400,//User can not turn items from this system on/off.
35  DisallowController = 0x0800,//Custom controllers provided by this wont be present in the GUI
36  DisallowMovable = 0x1000,//Items from this systems are never movable
37  StartDisabled = 0x0010
38  };
39 public: //public instead of protected due to compilation problems on SLC3
40  Q_DECLARE_FLAGS(SystemOptions, SystemOption)
41 protected:
42  //Call the following in constructor of a derived class. Do not delete the systems in the derived class.
43  void addSystem(IVP12DSystem*, const SystemOptions& options = AllowAll );
44 
46 
47  //Convenience so users dont need to cast themselves (needed due to private inheritance in IVP12DSystemSimple):
48  void addSystem(IVP12DSystemSimple*, const SystemOptions& options = AllowAll );
49 public:
50  Type type() const { return TWODIMENSIONAL; };
51 
52  void create();
54  void systemErased(IVP1System*);
56  virtual QByteArray saveState();
57  virtual void restoreFromState(QByteArray);
58 
59 protected Q_SLOTS:
60  void showControlsForSystem();
61 
62 private:
63  class Imp;
64  Imp * m_d;
65 private Q_SLOTS:
66  void toggleSystemActive();
67  void setBackgroundColor(const QColor &);
68 };
69 
70 Q_DECLARE_OPERATORS_FOR_FLAGS(IVP12DStandardChannelWidget::SystemOptions)
71 
72 #endif
IVP12DStandardChannelWidget::saveState
virtual QByteArray saveState()
Definition: IVP12DStandardChannelWidget.cxx:262
IVP12DStandardChannelWidget::DisallowController
@ DisallowController
Definition: IVP12DStandardChannelWidget.h:35
IVP12DStandardChannelWidget::m_d
Imp * m_d
Definition: IVP12DStandardChannelWidget.h:63
IVP12DStandardChannelWidget::DisallowSelections
@ DisallowSelections
Definition: IVP12DStandardChannelWidget.h:33
IVP12DStandardChannelWidget::AllowAll
@ AllowAll
Definition: IVP12DStandardChannelWidget.h:32
IVP12DStandardChannelWidget::IVP12DStandardChannelWidget
IVP12DStandardChannelWidget(const QString &name, const QString &information, const QString &contact_info)
Definition: IVP12DStandardChannelWidget.cxx:59
IVP1ChannelWidget::contact_info
const QString & contact_info() const
Definition: IVP1ChannelWidget.cxx:191
IVP1ChannelWidget::TWODIMENSIONAL
@ TWODIMENSIONAL
Definition: IVP1ChannelWidget.h:46
IVP12DStandardChannelWidget::SystemOption
SystemOption
Definition: IVP12DStandardChannelWidget.h:31
IVP12DSystem
Definition: IVP12DSystem.h:25
IVP12DStandardChannelWidget::toggleSystemActive
void toggleSystemActive()
Definition: IVP12DStandardChannelWidget.cxx:162
IVP1System
Definition: IVP1System.h:36
IVP12DStandardChannelWidget::addSystem
void addSystem(IVP12DSystem *, const SystemOptions &options=AllowAll)
Definition: IVP12DStandardChannelWidget.cxx:85
python.AtlRunQueryLib.options
options
Definition: AtlRunQueryLib.py:379
IVP12DStandardChannelWidget::setBackgroundColor
void setBackgroundColor(const QColor &)
Definition: IVP12DStandardChannelWidget.cxx:229
xAODType
Definition: ObjectType.h:13
IVP12DStandardChannelWidget::StartDisabled
@ StartDisabled
Definition: IVP12DStandardChannelWidget.h:37
IVP12DStandardChannelWidget::DisallowSwitchable
@ DisallowSwitchable
Definition: IVP12DStandardChannelWidget.h:34
IVP12DStandardChannelWidget::showControlsForSystem
void showControlsForSystem()
Definition: IVP12DStandardChannelWidget.cxx:237
IVP1ChannelWidget
Definition: IVP1ChannelWidget.h:34
IVP12DStandardChannelWidget::systemRefreshed
void systemRefreshed(IVP1System *)
Definition: IVP12DStandardChannelWidget.cxx:149
IVP12DStandardChannelWidget::~IVP12DStandardChannelWidget
virtual ~IVP12DStandardChannelWidget()
Definition: IVP12DStandardChannelWidget.cxx:79
IVP12DStandardChannelWidget::type
Type type() const
Definition: IVP12DStandardChannelWidget.h:50
IVP12DStandardChannelWidget::create
void create()
Definition: IVP12DStandardChannelWidget.cxx:121
IVP12DStandardChannelWidget::systemErased
void systemErased(IVP1System *)
Definition: IVP12DStandardChannelWidget.cxx:157
IVP12DSystemSimple
Definition: IVP12DSystemSimple.h:22
IVP1ChannelWidget::name
const QString & name() const
Definition: IVP1ChannelWidget.cxx:180
IVP12DStandardChannelWidget::DisallowMovable
@ DisallowMovable
Definition: IVP12DStandardChannelWidget.h:36
IVP12DStandardChannelWidget
Definition: IVP12DStandardChannelWidget.h:22
IVP12DStandardChannelWidget::Imp
Definition: IVP12DStandardChannelWidget.cxx:37
IVP1ChannelWidget::information
const QString & information() const
Definition: IVP1ChannelWidget.cxx:185
IVP1ChannelWidget.h
IVP12DStandardChannelWidget::restoreFromState
virtual void restoreFromState(QByteArray)
Definition: IVP12DStandardChannelWidget.cxx:305