CMS 3D CMS Logo

/data/refman/pasoursint/CMSSW_5_2_7_hltpatch2/src/Fireworks/Core/interface/CmsShowModelPopup.h

Go to the documentation of this file.
00001 #ifndef Fireworks_Core_CmsShowModelPopup_h
00002 #define Fireworks_Core_CmsShowModelPopup_h
00003 // -*- C++ -*-
00004 //
00005 // Package:     Core
00006 // Class  :     CmsShowModelPopup
00007 //
00016 //
00017 // Original Author:
00018 //         Created:  Fri Jun 27 11:23:31 EDT 2008
00019 // $Id: CmsShowModelPopup.h,v 1.19 2010/11/11 19:45:49 amraktad Exp $
00020 //
00021 
00022 // system include files
00023 #include <set>
00024 #include <vector>
00025 #ifndef __CINT__
00026 #include <sigc++/connection.h>
00027 #endif
00028 #include "GuiTypes.h"
00029 #include "TGFrame.h"
00030 
00031 // user include files
00032 #ifndef __CINT__
00033 #include "Fireworks/Core/interface/FWModelChangeSignal.h"
00034 #endif
00035 
00036 // forward declarations
00037 class FWEventItem;
00038 class FWSelectionManager;
00039 class FWColorManager;
00040 //class FWModelId;
00041 class FWColorSelect;
00042 class TGLabel;
00043 class TGTextButton;
00044 class TGTextButton;
00045 class TGHSlider;
00046 class FWDetailViewManager;
00047 class FWSelectionManager;
00048 class FWDialogBuilder;
00049 
00050 class CmsShowModelPopup;
00051 
00052 class CmsShowModelPopup : public TGTransientFrame
00053 {
00054 
00055 public:
00056    friend class CmsShowModelPopupDetailViewButtonAdapter;
00057    
00058    CmsShowModelPopup(FWDetailViewManager*, FWSelectionManager*, 
00059                      const FWColorManager*, const TGWindow* p = 0, 
00060                      UInt_t w = 1, UInt_t h = 1);
00061    virtual ~CmsShowModelPopup();
00062 
00063    virtual void CloseWindow() { UnmapWindow(); }
00064    // ---------- const member functions ---------------------
00065 
00066    // ---------- static member functions --------------------
00067 
00068    // ---------- member functions ---------------------------
00069    void fillModelPopup(const FWSelectionManager& iSelMgr);
00070    void updateDisplay();
00071    void colorSetChanged();
00072    void disconnectAll();
00073    void changeModelColor(Color_t iColor);
00074    void changeModelOpacity(Int_t opacity = 100);
00075    void toggleModelVisible(Bool_t on = kTRUE);
00076    void openDetailedView();
00077 
00078    void clicked();
00079 
00080    ClassDef(CmsShowModelPopup, 0);
00081 
00082 private:
00083    CmsShowModelPopup(const CmsShowModelPopup&);    // stop default
00084 
00085    const CmsShowModelPopup& operator=(const CmsShowModelPopup&);    // stop default
00086 
00087    
00088    // ---------- member data --------------------------------
00089    TGLabel* m_modelLabel;
00090    FWColorSelect* m_colorSelectWidget;
00091    TGCheckButton* m_isVisibleButton;
00092    std::vector<TGTextButton*> m_openDetailedViewButtons;
00093 
00094 #ifndef __CINT__
00095    std::set<FWModelId> m_models;
00096    sigc::connection m_modelChangedConn;
00097    sigc::connection m_destroyedConn;
00098    sigc::connection m_changes;
00099 #endif
00100    FWDetailViewManager* m_detailViewManager;
00101    const FWColorManager* m_colorManager;
00102    TGHSlider            *m_opacitySlider;
00103    FWDialogBuilder*      m_dialogBuilder;
00104 };
00105 
00106 
00107 #endif