X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fremote%2Fremote.h;h=bff56eddc21efa055c46c83ed043a908c96fe41d;hb=HEAD;hp=a9ab92b2c6f876973c4872ea7c21974e5bd6f16f;hpb=fadc35133b1ebbd98af948c1fa529dcde6fddcfd;p=r2c2.git diff --git a/source/remote/remote.h b/source/remote/remote.h index a9ab92b..bff56ed 100644 --- a/source/remote/remote.h +++ b/source/remote/remote.h @@ -1,44 +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 MainPanel; -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 *panel_box; - MainPanel *main_panel; - 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