X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fremote%2Fremote.h;h=bff56eddc21efa055c46c83ed043a908c96fe41d;hb=3ffe8b384fabeee1c3e636b83dd0006f3f5acfe1;hp=0d6d413d2e2db93ff38a6874a1cbfba1c9f34797;hpb=1ff06c5bc46a677fa389ef86c6b26664368f1653;p=r2c2.git diff --git a/source/remote/remote.h b/source/remote/remote.h index 0d6d413..bff56ed 100644 --- a/source/remote/remote.h +++ b/source/remote/remote.h @@ -1,42 +1,39 @@ -/* $Id$ - -This file is part of R²C² -Copyright © 2009-2010 Mikkosoft Productions, Mikko Rasa -Distributed under the GPL -*/ - #ifndef REMOTE_H_ #define REMOTE_H_ -#include -#include -#include #include +#include +#include +#include +#include +#include #include "network/client.h" +#include "statusbar.h" +#include "trainpanel.h" +#include "trainselector.h" -class TrainPanel; - -class Remote: public Msp::Application +class Remote: public Msp::RegisteredApplication { private: - Msp::IO::EventDispatcher event_disp; + Msp::Graphics::SimpleGLWindow window; R2C2::Catalogue catalogue; R2C2::Client client; - Gtk::Main gtk; - Gtk::Window window; - Gtk::Box *train_box; - std::vector train_panels; - - static Msp::Application::RegApp reg; + Msp::IO::EventDispatcher ev_disp; + Msp::GLtk::Resources ui_resources; + Msp::GLtk::Root root; + Msp::GLtk::Layout *root_layout; + TrainSelector *selectors[2]; + TrainPanel *panels[2]; + StatusBar status_bar; + Msp::Time::TimeStamp next_frame; public: - Remote(int argc, char **argv); + Remote(int, char **); - const R2C2::Catalogue &get_catalogue() const { return catalogue; } + virtual int main(); private: - void tick(); - - void train_added(R2C2::NetTrain &); + virtual void tick(); + void train_selected(R2C2::NetTrain *, unsigned); }; #endif