X-Git-Url: http://git.localhorst.tv/?a=blobdiff_plain;f=src%2Fmenu%2FInventoryMenu.h;fp=src%2Fmenu%2FInventoryMenu.h;h=20cbe17f54ef388786488f9d98941f9b46e3c01c;hb=c1de2db3755c2cffd790c58bbd92e7fc993afcb5;hp=0000000000000000000000000000000000000000;hpb=17afcc24569b38a9816f616bc025ba871ad3e48e;p=l2e.git diff --git a/src/menu/InventoryMenu.h b/src/menu/InventoryMenu.h new file mode 100644 index 0000000..20cbe17 --- /dev/null +++ b/src/menu/InventoryMenu.h @@ -0,0 +1,53 @@ +/* + * InventoryMenu.h + * + * Created on: Nov 4, 2012 + * Author: holy + */ + +#ifndef MENU_INVENTORYMENU_H_ +#define MENU_INVENTORYMENU_H_ + +#include "fwd.h" +#include "../app/State.h" +#include "../common/fwd.h" +#include "../geometry/Vector.h" +#include "../graphics/Menu.h" + +namespace menu { + +class InventoryMenu +: public app::State { + +public: + explicit InventoryMenu(PartyMenu *parent); + +public: + virtual void HandleEvents(const app::Input &); + virtual void UpdateWorld(float deltaT); + virtual void Render(SDL_Surface *); + + int Width() const; + int Height() const; + +private: + virtual void OnEnterState(SDL_Surface *screen); + virtual void OnExitState(SDL_Surface *screen); + virtual void OnResumeState(SDL_Surface *screen); + virtual void OnPauseState(SDL_Surface *screen); + + virtual void OnResize(int width, int height); + + void RenderMenu(SDL_Surface *screen, const geometry::Vector &offset) const; + void RenderInventory(SDL_Surface *screen, const geometry::Vector &offset) const; + +private: + PartyMenu *parent; + graphics::Menu menu; + graphics::Menu itemMenu; + +}; + +} + +#endif /* MENU_INVENTORYMENU_H_ */