From eb5bc25a3ce4eb9a650e433a5206f535c54b453c Mon Sep 17 00:00:00 2001 From: Gluzskiy Alexandr Date: Sun, 13 Sep 2015 08:17:15 +0300 Subject: protocol: added "data_required" field to module_download_ui_element_info for download creation ui renamed download_children_menu to download_content_menu as it's more apropriate name server: added "data_required" field to module_download_ui_element_info_s for download creation ui changed "id" field in module_download_menu_element_info_s from string to int implemented helper functions to fill module_info protobuff structure implemented most of module_info structures filling (tested, working) client: basic implementation of "download add widget" "marked_class" template for adding module defined id's to ui elements basic action buttons toolbar in main windows --- server/include/api_module_downloader.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'server/include/api_module_downloader.h') diff --git a/server/include/api_module_downloader.h b/server/include/api_module_downloader.h index dc31811..33a3fce 100644 --- a/server/include/api_module_downloader.h +++ b/server/include/api_module_downloader.h @@ -38,14 +38,16 @@ enum MODULE_UI_ELEMENT_TYPE_e { struct module_download_ui_element_info_s { MODULE_UI_ELEMENT_TYPE_e type = UI_EMPTY_; std::list children; - std::string name; // name can be non unique + std::string name, description; // name can be non unique, description is optional + bool data_required = false; //set to true if ui element require data from client (used in download creation ui) int id; //internal element id used to get element value (should be unique for every loaded module) }; //TODO: some mechanism for module to tell it's abilities, for example if it can provide download content, e.t.c. struct module_download_menu_element_info_s { - std::string id, name, description; //internal element id used to get element value (should be unique for every loaded module), name can be non unique, description is optional + std::string name, description; // name can be non unique, description is optional + int id; //internal element id used to get element value (should be unique for every loaded module) bool data_required = false; //set to true if menu element require data from client std::list children; //element with children cannot be executed, it's just container }; -- cgit v1.2.3