X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=helloworld.cpp;h=4f85964d9d2c45e28aa90bae843237d92d657d47;hb=f0b600c3b1739f7e088da6ab8eb7c2e67adf592c;hp=e41361f2fbb523841ff5b5b6d00e5cbcdd79d9d4;hpb=1c5148b7b63e1ba84073355702972caf6fe83b7e;p=libs%2Fgltk.git diff --git a/helloworld.cpp b/helloworld.cpp index e41361f..4f85964 100644 --- a/helloworld.cpp +++ b/helloworld.cpp @@ -1,17 +1,10 @@ -/* $Id$ - -This file is part of libmspgltk -Copyright © 2008 Mikko Rasa, Mikkosoft Productions -Distributed under the LGPL -*/ - /* A simple graphical Hello World application implemented with mspgltk. Demonstrates some of the most common widget types. */ #include -#include +#include #include #include #include @@ -24,7 +17,7 @@ Demonstrates some of the most common widget types. using namespace Msp; // Application class. Because it's so much nicer than global variables. -class HelloWorld: public Msp::Application +class HelloWorld: public Msp::RegisteredApplication { private: // An OpenGL window to display our widgets in @@ -36,9 +29,6 @@ private: GLtk::Entry *ent_name; GLtk::Label *lbl_hello; - // Indicate our main class to the core library - static Application::RegApp reg; - public: HelloWorld(int, char **); private: @@ -47,8 +37,6 @@ private: }; -Application::RegApp HelloWorld::reg; - HelloWorld::HelloWorld(int, char **): wnd(200, 200), // Load resources. This must be done before the root widget is created.