#include <boost/shared_ptr.hpp>
#include <Moof/Dispatch.hh>
-#include <Moof/Layer.hh>
#include <Moof/Math.hh>
+#include <Moof/View.hh>
+
+
+namespace Mf
+{
+ class Settings;
+ class View;
+}
class Main;
typedef boost::shared_ptr<Main> MainP;
-class Main : public Mf::Layer
+class Main : public Mf::View
{
public:
- Main();
-
- static MainP alloc()
- {
- return MainP(new Main);
- }
-
- void addedToCore();
+ Main(Mf::Settings& settings, Mf::Video& video);
void update(Mf::Scalar t, Mf::Scalar dt);
void draw(Mf::Scalar alpha) const;
* Set OpenGL to a state we can know and depend on.
*/
static void setupGL();
- static void contextCreated();
- Mf::Dispatch::Handler mDispatchHandler;
+ Mf::Dispatch::Handle mNewContextDispatch;
};