00001 #ifndef MYTHSCREEN_STACK_H_ 00002 #define MYTHSCREEN_STACK_H_ 00003 00004 #include <qvaluevector.h> 00005 #include <qobject.h> 00006 00007 class MythScreenType; 00008 class MythMainWindow; 00009 00010 class MythScreenStack : public QObject 00011 { 00012 public: 00013 MythScreenStack(MythMainWindow *parent, const char *name, 00014 bool main = false); 00015 virtual ~MythScreenStack(); 00016 00017 void AddScreen(MythScreenType *screen, bool allowFade = true); 00018 void PopScreen(bool allowFade = true); 00019 00020 MythScreenType *GetTopScreen(void); 00021 00022 void GetDrawOrder(QValueVector<MythScreenType *> &screens); 00023 int TotalScreens(); 00024 00025 void DisableEffects(void) { m_DoTransitions = false; } 00026 00027 protected: 00028 void RecalculateDrawOrder(void); 00029 void DoNewFadeTransition(); 00030 void CheckNewFadeTransition(); 00031 void CheckDeletes(); 00032 00033 QValueVector<MythScreenType *> m_Children; 00034 QValueVector<MythScreenType *> m_DrawOrder; 00035 00036 MythScreenType *topScreen; 00037 00038 bool m_DoTransitions; 00039 bool m_InNewTransition; 00040 MythScreenType *newTop; 00041 00042 QValueVector<MythScreenType *> m_ToDelete; 00043 }; 00044 00045 #endif 00046
1.5.5