Main Page   Namespace List   Class Hierarchy   Compound List   File List   Compound Members   File Members  

menudata_generic.cpp

Go to the documentation of this file.
00001 /*
00002         ClanGUI, copyrights by various people. Have a look in the CREDITS file.
00003         
00004         This sourcecode is distributed using the Library GNU Public Licence,
00005         version 2 or (at your option) any later version. Please read LICENSE
00006         for details.
00007 */
00008 
00009 #include "precomp.h"
00010 #include "../API/GUI/menudata.h"
00011 #include "../API/Core/System/error.h"
00012 
00013 CL_MenuData::CL_MenuData(CL_Component *parent) : CL_Component(parent)
00014 {
00015         real_parent = NULL;
00016 }
00017 
00018 CL_MenuData::~CL_MenuData()
00019 {
00020 }
00021 
00022 int CL_MenuData::generate_id(int id)
00023 {
00024         if(id != -1)
00025                 return count();
00026         else 
00027                 return id;
00028 }
00029 
00030 int CL_MenuData::insert_item(const std::string &text, int id, int index)
00031 {
00032         int new_id = generate_id(id);
00033 //      items.push_back(new CL_MenuItem(text, new_id));
00034         return new_id;
00035 }
00036 
00037 int CL_MenuData::insert_separator(int id, int index)
00038 {
00039         int new_id = generate_id(id);
00040 //      items.push_back(new CL_MenuItem(new_id));
00041         return new_id;
00042 }
00043 
00044 void CL_MenuData::remove_item(int id)
00045 {
00046         throw CL_Error("remove_item() not implemented");
00047 }
00048 
00049 void CL_MenuData::remove_item_at(int index)
00050 {
00051         throw CL_Error("remove_item_at() not implemented");
00052 }
00053 
00054 unsigned int CL_MenuData::count() const
00055 {
00056         return get_children().size();
00057 }
00058 
00059 void CL_MenuData::clear()
00060 {
00061         throw CL_Error("clear() not implemented");
00062 }
00063 
00064 const std::string &CL_MenuData::get_text(int id) const
00065 {
00066         throw CL_Error("get_text() not implemented");
00067 }
00068 
00069 void CL_MenuData::change_item(const std::string &text, int id)
00070 {
00071         throw CL_Error("change_item() not implemented");
00072 }
00073 
00074 bool CL_MenuData::is_item_enabled(int id) const
00075 {
00076         throw CL_Error("is_item_enabled() not implemented");
00077 }
00078 
00079 void CL_MenuData::enable_item(int id, bool enable)
00080 {
00081         throw CL_Error("enable_item() not implemented");
00082 }
00083 
00084 bool CL_MenuData::is_item_checked(int id) const
00085 {
00086         throw CL_Error("is_item_checked() not implemented");
00087 }
00088 
00089 void CL_MenuData::check_item(int id, bool check)
00090 {
00091         throw CL_Error("check_item() not implemented");
00092 }
00093 
00094 int CL_MenuData::get_index(int id) const
00095 {
00096         throw CL_Error("get_index() not implemented");
00097 }
00098 
00099 int CL_MenuData::get_id(int index) const
00100 {
00101         throw CL_Error("get_id() not implemented");
00102 }
00103 
00104 void CL_MenuData::set_id(int index, int id)
00105 {
00106         throw CL_Error("set_id() not implemented");
00107 }

Generated at Wed Apr 4 19:54:01 2001 for ClanLib by doxygen1.2.6 written by Dimitri van Heesch, © 1997-2001