allpy
changeset 17:18abe8f33d37
class prototype
author | boris <bnagaev@gmail.com> |
---|---|
date | Tue, 14 Sep 2010 22:32:55 +0400 |
parents | 7b37aba2c7db |
children | 1edfb7e96cb4 |
files | blocks3d-wt.C config.C config.h |
diffstat | 3 files changed, 44 insertions(+), 1 deletions(-) [+] |
line diff
1.1 --- a/blocks3d-wt.C Tue Sep 14 22:24:26 2010 +0400 1.2 +++ b/blocks3d-wt.C Tue Sep 14 22:32:55 2010 +0400 1.3 @@ -1,4 +1,43 @@ 1.4 - 1.5 1.6 #include "config.h" 1.7 1.8 +#include <Wt/WEnvironment> 1.9 +#include <Wt/WApplication> 1.10 +#include <Wt/WContainerWidget> 1.11 +#include <Wt/WServer> 1.12 +#include <Wt/WSelectionBox> 1.13 +#include <Wt/WPanel> 1.14 +#include <Wt/WText> 1.15 +#include <Wt/WContainerWidget> 1.16 +#include <Wt/WString> 1.17 +#include <Wt/WHBoxLayout> 1.18 +#include <Wt/WVBoxLayout> 1.19 +#include <Wt/WImage> 1.20 +#include <Wt/WPushButton> 1.21 + 1.22 +class Blocks3DApplication : public WApplication 1.23 +{ 1.24 +public: 1.25 + Blocks3DApplication(const WEnvironment& env); 1.26 +}; 1.27 + 1.28 + 1.29 +Blocks3DApplication* createApplication(const WEnvironment& env) 1.30 +{ 1.31 + return new Blocks3DApplication(env); 1.32 +} 1.33 + 1.34 +int main(int argc, char **argv) 1.35 +{ 1.36 + WServer server(argv[0]); 1.37 + server.setServerConfiguration(argc, argv, WTHTTP_CONFIGURATION); 1.38 + 1.39 + server.addEntryPoint(Application, createApplication, Malakite::main_url); 1.40 + 1.41 + if (server.start()) { 1.42 + WServer::waitForShutdown(); 1.43 + server.stop(); 1.44 + } 1.45 +} 1.46 + 1.47 +