#include "controller/root.h" #include "service/window.h" root_controller_t::root_controller_t(root_controller_t::configuration_t configuration_p) { configuration_m = configuration_p; } root_controller_t root_controller_factory_t::create(root_controller_t::configuration_t configuration_p) { return new root_controller_t(configuration_p); } controller_t::status_t root_controller_t::on_event(controller_t::event_t event_p) { if ( window_service_t* window_service = new window_service_t(); window_service_t::status_t window_status = window_service->create_window(); controller_t::status_t controller_status; switch (window_status) { case window_service_t::status_t::ok: controller_status = controller_t::status_t::ok; break; case window_service_t::status_t::error: default: controller_status = controller_t::status_t::error; break; } return controller_status; }