X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;f=src%2FMainLayer.hh;h=4f0fc77d3b2d254905b301734fc7f22895d85d66;hb=be9ebc1104574e5e81e19c5caba0c23b54df826d;hp=44a0f23ddabc73553ec161937d7718cbe20f573b;hpb=a4debfe4a5f5d339410788971b698ba00cb7f09c;p=chaz%2Fyoink diff --git a/src/MainLayer.hh b/src/MainLayer.hh index 44a0f23..4f0fc77 100644 --- a/src/MainLayer.hh +++ b/src/MainLayer.hh @@ -39,6 +39,7 @@ #include +#include #include #include #include @@ -47,32 +48,32 @@ class MainLayer; typedef boost::shared_ptr MainLayerP; -struct MainLayer : public Mf::Layer +class MainLayer : public Mf::Layer { +public: + MainLayer(); - ~MainLayer(); static MainLayerP alloc() { return MainLayerP(new MainLayer); } - void pushed(Mf::Engine& engine); + void pushedOntoEngine(); + void update(Mf::Scalar t, Mf::Scalar dt); void draw(Mf::Scalar alpha) const; bool handleEvent(const Mf::Event& event); - void quit(); - private: /** * Set OpenGL to a state we can know and depend on. */ void setupGL(); - void contextRecreated(const Mf::Notification* note); + void contextRecreated(); - Mf::Engine* engine; + Mf::Dispatch::Handler mDispatchHandler; };