00001 00017 #ifndef GFXBASE_H 00018 #define GFXBASE_H 00019 00020 00021 #include <Conventions/PlaneView.h> 00022 00023 #include <TObject.h> 00024 00025 #include <Midad/Util/Signals.h> 00026 00027 class PageDisplay; 00028 class MultiPage; 00029 class Mint; 00030 class GfxCfg; 00031 class GuiMenu; 00032 class ViewState; 00033 00034 class GfxBase : public TObject 00035 { 00036 00037 public: 00038 00039 GfxBase() {} 00040 virtual ~GfxBase() { destroyed.emit(); } 00041 00042 // This is called once just after the object is created. If it 00043 // needs to set up any communication with the MultiPage or the 00044 // PageDisplay it should do it here. Both will exist for the 00045 // lifetime of the Gfx object. 00046 virtual void Init(PageDisplay& /*pd*/, MultiPage& /*mp*/) {} 00047 00051 virtual void Configure(Mint& /*mint*/) {} 00052 00057 virtual GfxCfg& GetCfg() = 0; 00058 00061 SigC::Signal1<void,const char*> text_info; 00062 00064 PlaneView::PlaneView_t GetPlaneView(void) { return fPlaneView; } 00065 void SetPlaneView(PlaneView::PlaneView_t view) { fPlaneView = view; } 00066 00067 ViewState* GetViewState() { return fViewState; } 00068 const ViewState* GetViewState() const { return fViewState; } 00069 void SetViewState(ViewState* vs) { fViewState = vs; } 00070 00072 // void SetMetric(MultiPageCfg::MetricIs_t metric) { fMetric = metric; } 00073 // MultiPageCfg::MetricIs_t GetMetric() { return fMetric; } 00074 00076 00079 00082 00085 00089 00090 00091 // used by GfxProxy. 00092 SigC::Signal0<void> destroyed; 00093 00094 private: 00095 PlaneView::PlaneView_t fPlaneView; 00096 ViewState* fViewState; 00097 00098 }; // end of class GfxBase 00099 00100 00101 #endif // GFXBASE_H