Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2021-08-03 04:09:59

0001 #ifndef Fireworks_Core_FWParameterSetterBase_h
0002 #define Fireworks_Core_FWParameterSetterBase_h
0003 // -*- C++ -*-
0004 //
0005 // Package:     Core
0006 // Class  :     FWParameterSetterBase
0007 //
0008 /**\class FWParameterSetterBase FWParameterSetterBase.h Fireworks/Core/interface/FWParameterSetterBase.h
0009 
0010    Description: <one line class summary>
0011 
0012    Usage:
0013     <usage>
0014 
0015  */
0016 //
0017 // Original Author:  Chris Jones
0018 //         Created:  Fri Mar  7 14:16:14 EST 2008
0019 //
0020 
0021 // system include files
0022 #include <memory>
0023 
0024 // user include files
0025 
0026 // forward declarations
0027 class FWParameterBase;
0028 class FWParameterSetterEditorBase;
0029 class TGFrame;
0030 
0031 class FWParameterSetterBase {
0032 public:
0033   FWParameterSetterBase();
0034   virtual ~FWParameterSetterBase();
0035 
0036   // ---------- const member functions ---------------------
0037 
0038   // ---------- static member functions --------------------
0039 
0040   static std::shared_ptr<FWParameterSetterBase> makeSetterFor(FWParameterBase*);
0041 
0042   // ---------- member functions ---------------------------
0043 
0044   void attach(FWParameterBase*, FWParameterSetterEditorBase*);
0045   virtual TGFrame* build(TGFrame* iParent, bool labelBack = true) = 0;
0046 
0047   virtual void setEnabled(bool);
0048 
0049 protected:
0050   void update() const;
0051   FWParameterSetterEditorBase* frame() const { return m_frame; }
0052 
0053 public:
0054   FWParameterSetterBase(const FWParameterSetterBase&) = delete;                   // stop default
0055   const FWParameterSetterBase& operator=(const FWParameterSetterBase&) = delete;  // stop default
0056 
0057 private:
0058   virtual void attach(FWParameterBase*) = 0;
0059 
0060   // ---------- member data --------------------------------
0061 
0062   FWParameterSetterEditorBase* m_frame;
0063 };
0064 
0065 #endif