00001 #ifndef __RUNNABLE_STATE_H 00002 #define __RUNNABLE_STATE_H 00003 00004 #include "AppTypes.h" 00005 #include "State.h" 00006 00007 class AppInterface; 00008 00009 class RunnableState : public State 00010 { 00011 public: 00012 virtual void Update(AppTime curTimeMS, AppTime elapsedTimeMS)=0; 00013 virtual void UpdateEnd(AppTime curTimeMS, AppTime elapsedTimeMS) {}; 00014 virtual void Render(AppTime curTimeMS)=0; 00015 void SetParentApp(AppInterface *parent); 00016 // Call when internal variables set and the state is ready to use 00017 virtual void OnStateReady(void); 00018 00019 // Don't do this so I can override by return type in derived classes 00020 //virtual AppInterface *GetParentApp(void) const; 00021 00022 virtual void SetFocus(bool hasFocus); 00023 00024 protected: 00025 AppInterface *parent; 00026 00027 }; 00028 00029 00030 #endif
1.7.1