diff --git a/sample/CameraPosition/appl/main.cpp b/sample/CameraPosition/appl/main.cpp index 48896c3..14486a0 100644 --- a/sample/CameraPosition/appl/main.cpp +++ b/sample/CameraPosition/appl/main.cpp @@ -17,43 +17,44 @@ #include #include - -class MainApplication : public ewol::context::Application { - public: - void onCreate(ewol::Context& _context) override { - APPL_INFO(" == > CREATE ... " << PROJECT_NAME << " v" << APPL_VERSION << " (START) [" << gale::getBoardType() << "] (" << gale::getCompilationMode() << ") (BEGIN)"); - for( int32_t iii=0 ; iii<_context.getCmd().size(); iii++) { - etk::String tmpppp = _context.getCmd().get(iii); - if ( tmpppp == "-h" - || tmpppp == "--help") { - APPL_INFO(" -h/--help display this help" ); - exit(0); +namespace appl { + class MainApplication : public ewol::context::Application { + public: + void onCreate(ewol::Context& _context) override { + APPL_INFO(" == > CREATE ... " << PROJECT_NAME << " v" << APPL_VERSION << " (START) [" << gale::getBoardType() << "] (" << gale::getCompilationMode() << ") (BEGIN)"); + for( int32_t iii=0 ; iii<_context.getCmd().size(); iii++) { + etk::String tmpppp = _context.getCmd().get(iii); + if ( tmpppp == "-h" + || tmpppp == "--help") { + APPL_INFO(" -h/--help display this help" ); + exit(0); + } } + // TODO : Remove this : Move if in the windows properties + _context.setSize(vec2(800, 600)); + + // select internal data for font ... + _context.getFontDefault().setUseExternal(true); + _context.getFontDefault().set("FreeSerif;DejaVuSansMono", 19); + + ememory::SharedPtr basicWindows = appl::Windows::create(); + // create the specific windows + _context.setWindows(basicWindows); + APPL_INFO("==> CREATE ... " PROJECT_NAME " (END)"); } - // TODO : Remove this : Move if in the windows properties - _context.setSize(vec2(800, 600)); - // select internal data for font ... - _context.getFontDefault().setUseExternal(true); - _context.getFontDefault().set("FreeSerif;DejaVuSansMono", 19); - - ememory::SharedPtr basicWindows = appl::Windows::create(); - // create the specific windows - _context.setWindows(basicWindows); - APPL_INFO("==> CREATE ... " PROJECT_NAME " (END)"); - } - - void onStart(ewol::Context& _context) override { - APPL_INFO("==> START ... " PROJECT_NAME " (BEGIN)"); - // nothing to do ... - APPL_INFO("==> START ... " PROJECT_NAME " (END)"); - } - void onStop(ewol::Context& _context) override { - APPL_INFO("==> STOP ... " PROJECT_NAME " (START)"); - // nothing to do ... - APPL_INFO("==> STOP ... " PROJECT_NAME " (END)"); - } -}; + void onStart(ewol::Context& _context) override { + APPL_INFO("==> START ... " PROJECT_NAME " (BEGIN)"); + // nothing to do ... + APPL_INFO("==> START ... " PROJECT_NAME " (END)"); + } + void onStop(ewol::Context& _context) override { + APPL_INFO("==> STOP ... " PROJECT_NAME " (START)"); + // nothing to do ... + APPL_INFO("==> STOP ... " PROJECT_NAME " (END)"); + } + }; +} /** * @brief Main of the program (This can be set in every case, but it is not used in Andoid...). @@ -62,7 +63,7 @@ class MainApplication : public ewol::context::Application { */ int main(int _argc, const char *_argv[]) { // second possibility - return ewol::run(ETK_NEW(appl::MainApplication)(), _argc, _argv); + return ewol::run(ETK_NEW(appl::MainApplication), _argc, _argv); } diff --git a/sample/Collision/appl/main.cpp b/sample/Collision/appl/main.cpp index 48896c3..8ef4174 100644 --- a/sample/Collision/appl/main.cpp +++ b/sample/Collision/appl/main.cpp @@ -17,44 +17,44 @@ #include #include - -class MainApplication : public ewol::context::Application { - public: - void onCreate(ewol::Context& _context) override { - APPL_INFO(" == > CREATE ... " << PROJECT_NAME << " v" << APPL_VERSION << " (START) [" << gale::getBoardType() << "] (" << gale::getCompilationMode() << ") (BEGIN)"); - for( int32_t iii=0 ; iii<_context.getCmd().size(); iii++) { - etk::String tmpppp = _context.getCmd().get(iii); - if ( tmpppp == "-h" - || tmpppp == "--help") { - APPL_INFO(" -h/--help display this help" ); - exit(0); +namespace appl { + class MainApplication : public ewol::context::Application { + public: + void onCreate(ewol::Context& _context) override { + APPL_INFO(" == > CREATE ... " << PROJECT_NAME << " v" << APPL_VERSION << " (START) [" << gale::getBoardType() << "] (" << gale::getCompilationMode() << ") (BEGIN)"); + for( int32_t iii=0 ; iii<_context.getCmd().size(); iii++) { + etk::String tmpppp = _context.getCmd().get(iii); + if ( tmpppp == "-h" + || tmpppp == "--help") { + APPL_INFO(" -h/--help display this help" ); + exit(0); + } } + // TODO : Remove this : Move if in the windows properties + _context.setSize(vec2(800, 600)); + + // select internal data for font ... + _context.getFontDefault().setUseExternal(true); + _context.getFontDefault().set("FreeSerif;DejaVuSansMono", 19); + + ememory::SharedPtr basicWindows = appl::Windows::create(); + // create the specific windows + _context.setWindows(basicWindows); + APPL_INFO("==> CREATE ... " PROJECT_NAME " (END)"); } - // TODO : Remove this : Move if in the windows properties - _context.setSize(vec2(800, 600)); - // select internal data for font ... - _context.getFontDefault().setUseExternal(true); - _context.getFontDefault().set("FreeSerif;DejaVuSansMono", 19); - - ememory::SharedPtr basicWindows = appl::Windows::create(); - // create the specific windows - _context.setWindows(basicWindows); - APPL_INFO("==> CREATE ... " PROJECT_NAME " (END)"); - } - - void onStart(ewol::Context& _context) override { - APPL_INFO("==> START ... " PROJECT_NAME " (BEGIN)"); - // nothing to do ... - APPL_INFO("==> START ... " PROJECT_NAME " (END)"); - } - void onStop(ewol::Context& _context) override { - APPL_INFO("==> STOP ... " PROJECT_NAME " (START)"); - // nothing to do ... - APPL_INFO("==> STOP ... " PROJECT_NAME " (END)"); - } -}; - + void onStart(ewol::Context& _context) override { + APPL_INFO("==> START ... " PROJECT_NAME " (BEGIN)"); + // nothing to do ... + APPL_INFO("==> START ... " PROJECT_NAME " (END)"); + } + void onStop(ewol::Context& _context) override { + APPL_INFO("==> STOP ... " PROJECT_NAME " (START)"); + // nothing to do ... + APPL_INFO("==> STOP ... " PROJECT_NAME " (END)"); + } + }; +} /** * @brief Main of the program (This can be set in every case, but it is not used in Andoid...). * @param std IO @@ -62,7 +62,7 @@ class MainApplication : public ewol::context::Application { */ int main(int _argc, const char *_argv[]) { // second possibility - return ewol::run(ETK_NEW(appl::MainApplication)(), _argc, _argv); + return ewol::run(ETK_NEW(appl::MainApplication), _argc, _argv); } diff --git a/sample/DoubleView/appl/main.cpp b/sample/DoubleView/appl/main.cpp index 48896c3..8ef4174 100644 --- a/sample/DoubleView/appl/main.cpp +++ b/sample/DoubleView/appl/main.cpp @@ -17,44 +17,44 @@ #include #include - -class MainApplication : public ewol::context::Application { - public: - void onCreate(ewol::Context& _context) override { - APPL_INFO(" == > CREATE ... " << PROJECT_NAME << " v" << APPL_VERSION << " (START) [" << gale::getBoardType() << "] (" << gale::getCompilationMode() << ") (BEGIN)"); - for( int32_t iii=0 ; iii<_context.getCmd().size(); iii++) { - etk::String tmpppp = _context.getCmd().get(iii); - if ( tmpppp == "-h" - || tmpppp == "--help") { - APPL_INFO(" -h/--help display this help" ); - exit(0); +namespace appl { + class MainApplication : public ewol::context::Application { + public: + void onCreate(ewol::Context& _context) override { + APPL_INFO(" == > CREATE ... " << PROJECT_NAME << " v" << APPL_VERSION << " (START) [" << gale::getBoardType() << "] (" << gale::getCompilationMode() << ") (BEGIN)"); + for( int32_t iii=0 ; iii<_context.getCmd().size(); iii++) { + etk::String tmpppp = _context.getCmd().get(iii); + if ( tmpppp == "-h" + || tmpppp == "--help") { + APPL_INFO(" -h/--help display this help" ); + exit(0); + } } + // TODO : Remove this : Move if in the windows properties + _context.setSize(vec2(800, 600)); + + // select internal data for font ... + _context.getFontDefault().setUseExternal(true); + _context.getFontDefault().set("FreeSerif;DejaVuSansMono", 19); + + ememory::SharedPtr basicWindows = appl::Windows::create(); + // create the specific windows + _context.setWindows(basicWindows); + APPL_INFO("==> CREATE ... " PROJECT_NAME " (END)"); } - // TODO : Remove this : Move if in the windows properties - _context.setSize(vec2(800, 600)); - // select internal data for font ... - _context.getFontDefault().setUseExternal(true); - _context.getFontDefault().set("FreeSerif;DejaVuSansMono", 19); - - ememory::SharedPtr basicWindows = appl::Windows::create(); - // create the specific windows - _context.setWindows(basicWindows); - APPL_INFO("==> CREATE ... " PROJECT_NAME " (END)"); - } - - void onStart(ewol::Context& _context) override { - APPL_INFO("==> START ... " PROJECT_NAME " (BEGIN)"); - // nothing to do ... - APPL_INFO("==> START ... " PROJECT_NAME " (END)"); - } - void onStop(ewol::Context& _context) override { - APPL_INFO("==> STOP ... " PROJECT_NAME " (START)"); - // nothing to do ... - APPL_INFO("==> STOP ... " PROJECT_NAME " (END)"); - } -}; - + void onStart(ewol::Context& _context) override { + APPL_INFO("==> START ... " PROJECT_NAME " (BEGIN)"); + // nothing to do ... + APPL_INFO("==> START ... " PROJECT_NAME " (END)"); + } + void onStop(ewol::Context& _context) override { + APPL_INFO("==> STOP ... " PROJECT_NAME " (START)"); + // nothing to do ... + APPL_INFO("==> STOP ... " PROJECT_NAME " (END)"); + } + }; +} /** * @brief Main of the program (This can be set in every case, but it is not used in Andoid...). * @param std IO @@ -62,7 +62,7 @@ class MainApplication : public ewol::context::Application { */ int main(int _argc, const char *_argv[]) { // second possibility - return ewol::run(ETK_NEW(appl::MainApplication)(), _argc, _argv); + return ewol::run(ETK_NEW(appl::MainApplication), _argc, _argv); } diff --git a/sample/LowPoly/appl/main.cpp b/sample/LowPoly/appl/main.cpp index 48896c3..27c65e7 100644 --- a/sample/LowPoly/appl/main.cpp +++ b/sample/LowPoly/appl/main.cpp @@ -17,52 +17,51 @@ #include #include - -class MainApplication : public ewol::context::Application { - public: - void onCreate(ewol::Context& _context) override { - APPL_INFO(" == > CREATE ... " << PROJECT_NAME << " v" << APPL_VERSION << " (START) [" << gale::getBoardType() << "] (" << gale::getCompilationMode() << ") (BEGIN)"); - for( int32_t iii=0 ; iii<_context.getCmd().size(); iii++) { - etk::String tmpppp = _context.getCmd().get(iii); - if ( tmpppp == "-h" - || tmpppp == "--help") { - APPL_INFO(" -h/--help display this help" ); - exit(0); +namespace appl { + class MainApplication : public ewol::context::Application { + public: + void onCreate(ewol::Context& _context) override { + APPL_INFO(" == > CREATE ... " << PROJECT_NAME << " v" << APPL_VERSION << " (START) [" << gale::getBoardType() << "] (" << gale::getCompilationMode() << ") (BEGIN)"); + for( int32_t iii=0 ; iii<_context.getCmd().size(); iii++) { + etk::String tmpppp = _context.getCmd().get(iii); + if ( tmpppp == "-h" + || tmpppp == "--help") { + APPL_INFO(" -h/--help display this help" ); + exit(0); + } } + // TODO : Remove this : Move if in the windows properties + _context.setSize(vec2(800, 600)); + + // select internal data for font ... + _context.getFontDefault().setUseExternal(true); + _context.getFontDefault().set("FreeSerif;DejaVuSansMono", 19); + + ememory::SharedPtr basicWindows = appl::Windows::create(); + // create the specific windows + _context.setWindows(basicWindows); + APPL_INFO("==> CREATE ... " PROJECT_NAME " (END)"); } - // TODO : Remove this : Move if in the windows properties - _context.setSize(vec2(800, 600)); - // select internal data for font ... - _context.getFontDefault().setUseExternal(true); - _context.getFontDefault().set("FreeSerif;DejaVuSansMono", 19); - - ememory::SharedPtr basicWindows = appl::Windows::create(); - // create the specific windows - _context.setWindows(basicWindows); - APPL_INFO("==> CREATE ... " PROJECT_NAME " (END)"); - } - - void onStart(ewol::Context& _context) override { - APPL_INFO("==> START ... " PROJECT_NAME " (BEGIN)"); - // nothing to do ... - APPL_INFO("==> START ... " PROJECT_NAME " (END)"); - } - void onStop(ewol::Context& _context) override { - APPL_INFO("==> STOP ... " PROJECT_NAME " (START)"); - // nothing to do ... - APPL_INFO("==> STOP ... " PROJECT_NAME " (END)"); - } -}; - + void onStart(ewol::Context& _context) override { + APPL_INFO("==> START ... " PROJECT_NAME " (BEGIN)"); + // nothing to do ... + APPL_INFO("==> START ... " PROJECT_NAME " (END)"); + } + void onStop(ewol::Context& _context) override { + APPL_INFO("==> STOP ... " PROJECT_NAME " (START)"); + // nothing to do ... + APPL_INFO("==> STOP ... " PROJECT_NAME " (END)"); + } + }; +} /** * @brief Main of the program (This can be set in every case, but it is not used in Andoid...). * @param std IO * @return std IO */ int main(int _argc, const char *_argv[]) { - // second possibility - return ewol::run(ETK_NEW(appl::MainApplication)(), _argc, _argv); + return ewol::run(ETK_NEW(appl::MainApplication), _argc, _argv); } diff --git a/sample/MeshCreator/appl/main.cpp b/sample/MeshCreator/appl/main.cpp index 3318987..84de4b8 100644 --- a/sample/MeshCreator/appl/main.cpp +++ b/sample/MeshCreator/appl/main.cpp @@ -17,59 +17,59 @@ #include #include - -class MainApplication : public ewol::context::Application { - public: - void onCreate(ewol::Context& _context) override { - APPL_INFO(" == > CREATE ... " << PROJECT_NAME << " v" << APPL_VERSION << " (START) [" << gale::getBoardType() << "] (" << gale::getCompilationMode() << ") (BEGIN)"); - - // TODO : Remove this : Move if in the windows properties - _context.setSize(vec2(800, 600)); - - // select internal data for font ... - _context.getFontDefault().setUseExternal(true); - _context.getFontDefault().set("FreeSerif;DejaVuSansMono", 19); - - ememory::SharedPtr basicWindows = appl::Windows::create(); - - for( int32_t iii=0 ; iii<_context.getCmd().size(); iii++) { - etk::String tmpppp = _context.getCmd().get(iii); - if ( tmpppp == "-h" - || tmpppp == "--help") { - APPL_PRINT(" -h/--help display this help"); - APPL_PRINT(" --mesh=XXX Load this mesh file"); - APPL_PRINT(" --debug-normal Display normal"); - APPL_PRINT(" --debug-AABB Display AABB box"); - APPL_PRINT(" --debug-shape Display Shape"); - exit(0); - } else if (etk::start_with(tmpppp, "--mesh=") == true) { - etk::String fileName = &tmpppp[7]; - basicWindows->setMeshName(fileName); - } else if (tmpppp == "--debug-normal") { - basicWindows->setDebugNormal(); - } else if (tmpppp == "--debug-AABB") { - basicWindows->setDebugAABB(); - } else if (tmpppp == "--debug-shape") { - basicWindows->setDebugShape(); +namespace appl { + class MainApplication : public ewol::context::Application { + public: + void onCreate(ewol::Context& _context) override { + APPL_INFO(" == > CREATE ... " << PROJECT_NAME << " v" << APPL_VERSION << " (START) [" << gale::getBoardType() << "] (" << gale::getCompilationMode() << ") (BEGIN)"); + + // TODO : Remove this : Move if in the windows properties + _context.setSize(vec2(800, 600)); + + // select internal data for font ... + _context.getFontDefault().setUseExternal(true); + _context.getFontDefault().set("FreeSerif;DejaVuSansMono", 19); + + ememory::SharedPtr basicWindows = appl::Windows::create(); + + for( int32_t iii=0 ; iii<_context.getCmd().size(); iii++) { + etk::String tmpppp = _context.getCmd().get(iii); + if ( tmpppp == "-h" + || tmpppp == "--help") { + APPL_PRINT(" -h/--help display this help"); + APPL_PRINT(" --mesh=XXX Load this mesh file"); + APPL_PRINT(" --debug-normal Display normal"); + APPL_PRINT(" --debug-AABB Display AABB box"); + APPL_PRINT(" --debug-shape Display Shape"); + exit(0); + } else if (etk::start_with(tmpppp, "--mesh=") == true) { + etk::String fileName = &tmpppp[7]; + basicWindows->setMeshName(fileName); + } else if (tmpppp == "--debug-normal") { + basicWindows->setDebugNormal(); + } else if (tmpppp == "--debug-AABB") { + basicWindows->setDebugAABB(); + } else if (tmpppp == "--debug-shape") { + basicWindows->setDebugShape(); + } } + // create the specific windows + _context.setWindows(basicWindows); + APPL_INFO("==> CREATE ... " PROJECT_NAME " (END)"); } - // create the specific windows - _context.setWindows(basicWindows); - APPL_INFO("==> CREATE ... " PROJECT_NAME " (END)"); - } - - void onStart(ewol::Context& _context) override { - APPL_INFO("==> START ... " PROJECT_NAME " (BEGIN)"); - // nothing to do ... - APPL_INFO("==> START ... " PROJECT_NAME " (END)"); - } - void onStop(ewol::Context& _context) override { - APPL_INFO("==> STOP ... " PROJECT_NAME " (START)"); - // nothing to do ... - APPL_INFO("==> STOP ... " PROJECT_NAME " (END)"); - } -}; - + + void onStart(ewol::Context& _context) override { + APPL_INFO("==> START ... " PROJECT_NAME " (BEGIN)"); + // nothing to do ... + APPL_INFO("==> START ... " PROJECT_NAME " (END)"); + } + void onStop(ewol::Context& _context) override { + APPL_INFO("==> STOP ... " PROJECT_NAME " (START)"); + // nothing to do ... + APPL_INFO("==> STOP ... " PROJECT_NAME " (END)"); + } + }; +} /** * @brief Main of the program (This can be set in every case, but it is not used in Andoid...). * @param std IO @@ -77,7 +77,7 @@ class MainApplication : public ewol::context::Application { */ int main(int _argc, const char *_argv[]) { // second possibility - return ewol::run(ETK_NEW(appl::MainApplication)(), _argc, _argv); + return ewol::run(ETK_NEW(appl::MainApplication), _argc, _argv); } diff --git a/sample/RayTest/appl/main.cpp b/sample/RayTest/appl/main.cpp index 48896c3..8ef4174 100644 --- a/sample/RayTest/appl/main.cpp +++ b/sample/RayTest/appl/main.cpp @@ -17,44 +17,44 @@ #include #include - -class MainApplication : public ewol::context::Application { - public: - void onCreate(ewol::Context& _context) override { - APPL_INFO(" == > CREATE ... " << PROJECT_NAME << " v" << APPL_VERSION << " (START) [" << gale::getBoardType() << "] (" << gale::getCompilationMode() << ") (BEGIN)"); - for( int32_t iii=0 ; iii<_context.getCmd().size(); iii++) { - etk::String tmpppp = _context.getCmd().get(iii); - if ( tmpppp == "-h" - || tmpppp == "--help") { - APPL_INFO(" -h/--help display this help" ); - exit(0); +namespace appl { + class MainApplication : public ewol::context::Application { + public: + void onCreate(ewol::Context& _context) override { + APPL_INFO(" == > CREATE ... " << PROJECT_NAME << " v" << APPL_VERSION << " (START) [" << gale::getBoardType() << "] (" << gale::getCompilationMode() << ") (BEGIN)"); + for( int32_t iii=0 ; iii<_context.getCmd().size(); iii++) { + etk::String tmpppp = _context.getCmd().get(iii); + if ( tmpppp == "-h" + || tmpppp == "--help") { + APPL_INFO(" -h/--help display this help" ); + exit(0); + } } + // TODO : Remove this : Move if in the windows properties + _context.setSize(vec2(800, 600)); + + // select internal data for font ... + _context.getFontDefault().setUseExternal(true); + _context.getFontDefault().set("FreeSerif;DejaVuSansMono", 19); + + ememory::SharedPtr basicWindows = appl::Windows::create(); + // create the specific windows + _context.setWindows(basicWindows); + APPL_INFO("==> CREATE ... " PROJECT_NAME " (END)"); } - // TODO : Remove this : Move if in the windows properties - _context.setSize(vec2(800, 600)); - // select internal data for font ... - _context.getFontDefault().setUseExternal(true); - _context.getFontDefault().set("FreeSerif;DejaVuSansMono", 19); - - ememory::SharedPtr basicWindows = appl::Windows::create(); - // create the specific windows - _context.setWindows(basicWindows); - APPL_INFO("==> CREATE ... " PROJECT_NAME " (END)"); - } - - void onStart(ewol::Context& _context) override { - APPL_INFO("==> START ... " PROJECT_NAME " (BEGIN)"); - // nothing to do ... - APPL_INFO("==> START ... " PROJECT_NAME " (END)"); - } - void onStop(ewol::Context& _context) override { - APPL_INFO("==> STOP ... " PROJECT_NAME " (START)"); - // nothing to do ... - APPL_INFO("==> STOP ... " PROJECT_NAME " (END)"); - } -}; - + void onStart(ewol::Context& _context) override { + APPL_INFO("==> START ... " PROJECT_NAME " (BEGIN)"); + // nothing to do ... + APPL_INFO("==> START ... " PROJECT_NAME " (END)"); + } + void onStop(ewol::Context& _context) override { + APPL_INFO("==> STOP ... " PROJECT_NAME " (START)"); + // nothing to do ... + APPL_INFO("==> STOP ... " PROJECT_NAME " (END)"); + } + }; +} /** * @brief Main of the program (This can be set in every case, but it is not used in Andoid...). * @param std IO @@ -62,7 +62,7 @@ class MainApplication : public ewol::context::Application { */ int main(int _argc, const char *_argv[]) { // second possibility - return ewol::run(ETK_NEW(appl::MainApplication)(), _argc, _argv); + return ewol::run(ETK_NEW(appl::MainApplication), _argc, _argv); } diff --git a/sample/TorqueApply/appl/main.cpp b/sample/TorqueApply/appl/main.cpp index 48896c3..8ef4174 100644 --- a/sample/TorqueApply/appl/main.cpp +++ b/sample/TorqueApply/appl/main.cpp @@ -17,44 +17,44 @@ #include #include - -class MainApplication : public ewol::context::Application { - public: - void onCreate(ewol::Context& _context) override { - APPL_INFO(" == > CREATE ... " << PROJECT_NAME << " v" << APPL_VERSION << " (START) [" << gale::getBoardType() << "] (" << gale::getCompilationMode() << ") (BEGIN)"); - for( int32_t iii=0 ; iii<_context.getCmd().size(); iii++) { - etk::String tmpppp = _context.getCmd().get(iii); - if ( tmpppp == "-h" - || tmpppp == "--help") { - APPL_INFO(" -h/--help display this help" ); - exit(0); +namespace appl { + class MainApplication : public ewol::context::Application { + public: + void onCreate(ewol::Context& _context) override { + APPL_INFO(" == > CREATE ... " << PROJECT_NAME << " v" << APPL_VERSION << " (START) [" << gale::getBoardType() << "] (" << gale::getCompilationMode() << ") (BEGIN)"); + for( int32_t iii=0 ; iii<_context.getCmd().size(); iii++) { + etk::String tmpppp = _context.getCmd().get(iii); + if ( tmpppp == "-h" + || tmpppp == "--help") { + APPL_INFO(" -h/--help display this help" ); + exit(0); + } } + // TODO : Remove this : Move if in the windows properties + _context.setSize(vec2(800, 600)); + + // select internal data for font ... + _context.getFontDefault().setUseExternal(true); + _context.getFontDefault().set("FreeSerif;DejaVuSansMono", 19); + + ememory::SharedPtr basicWindows = appl::Windows::create(); + // create the specific windows + _context.setWindows(basicWindows); + APPL_INFO("==> CREATE ... " PROJECT_NAME " (END)"); } - // TODO : Remove this : Move if in the windows properties - _context.setSize(vec2(800, 600)); - // select internal data for font ... - _context.getFontDefault().setUseExternal(true); - _context.getFontDefault().set("FreeSerif;DejaVuSansMono", 19); - - ememory::SharedPtr basicWindows = appl::Windows::create(); - // create the specific windows - _context.setWindows(basicWindows); - APPL_INFO("==> CREATE ... " PROJECT_NAME " (END)"); - } - - void onStart(ewol::Context& _context) override { - APPL_INFO("==> START ... " PROJECT_NAME " (BEGIN)"); - // nothing to do ... - APPL_INFO("==> START ... " PROJECT_NAME " (END)"); - } - void onStop(ewol::Context& _context) override { - APPL_INFO("==> STOP ... " PROJECT_NAME " (START)"); - // nothing to do ... - APPL_INFO("==> STOP ... " PROJECT_NAME " (END)"); - } -}; - + void onStart(ewol::Context& _context) override { + APPL_INFO("==> START ... " PROJECT_NAME " (BEGIN)"); + // nothing to do ... + APPL_INFO("==> START ... " PROJECT_NAME " (END)"); + } + void onStop(ewol::Context& _context) override { + APPL_INFO("==> STOP ... " PROJECT_NAME " (START)"); + // nothing to do ... + APPL_INFO("==> STOP ... " PROJECT_NAME " (END)"); + } + }; +} /** * @brief Main of the program (This can be set in every case, but it is not used in Andoid...). * @param std IO @@ -62,7 +62,7 @@ class MainApplication : public ewol::context::Application { */ int main(int _argc, const char *_argv[]) { // second possibility - return ewol::run(ETK_NEW(appl::MainApplication)(), _argc, _argv); + return ewol::run(ETK_NEW(appl::MainApplication), _argc, _argv); }