diff options
author | José Alburquerque <jaalburqu@svn.gnome.org> | 2012-02-22 16:44:33 -0500 |
---|---|---|
committer | José Alburquerque <jaalburqu@svn.gnome.org> | 2012-02-22 16:54:38 -0500 |
commit | 40e6a8e55e6558d44fa601b1549e2788fa15dd76 (patch) | |
tree | 6b203bafed279d8dc805e5cf325058476d804499 /gio/src/menulinkiter.hg | |
parent | 59ab32d4e40baabe21901f9893e07cb0fdd3b268 (diff) | |
download | glibmm-40e6a8e55e6558d44fa601b1549e2788fa15dd76.tar.gz |
giomm: Add the MenuModel and Menu[Attribute|Link]Iter classes.
* gio/src/menuattributeiter.{ccg,hg}:
* gio/src/menulinkiter.{ccg,hg}:
* gio/src/menumodel.{ccg,hg}:
* gio/src/filelist.am: Add the sources for the classes and include
them in the list of source files to build.
* tools/m4/convert_gio.m4:
* tools/m4/convert_glib.m4: Add the necessary conversions.
Diffstat (limited to 'gio/src/menulinkiter.hg')
-rw-r--r-- | gio/src/menulinkiter.hg | 49 |
1 files changed, 49 insertions, 0 deletions
diff --git a/gio/src/menulinkiter.hg b/gio/src/menulinkiter.hg new file mode 100644 index 00000000..d2b406a6 --- /dev/null +++ b/gio/src/menulinkiter.hg @@ -0,0 +1,49 @@ +/* Copyright (C) 2012 The giomm Development Team + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free + * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. + */ + +#include <glibmm/object.h> + +_DEFS(giomm,gio) +_PINCLUDE(glibmm/private/object_p.h) + +namespace Gio +{ + +class MenuModel; + +/** TODO (When the docs is available from the C API). + */ +class MenuLinkIter : public Glib::Object +{ + _CLASS_GOBJECT(MenuLinkIter, GMenuLinkIter, G_MENU_LINK_ITER, Glib::Object, GObject) + +protected: + _CTOR_DEFAULT + +public: + _WRAP_METHOD(Glib::ustring get_name() const, g_menu_link_iter_get_name) + + _WRAP_METHOD_DOCS_ONLY(g_menu_link_iter_get_next) + bool get_next(Glib::ustring& out_link, Glib::RefPtr<MenuModel>& value); + + _WRAP_METHOD(Glib::RefPtr<MenuModel> get_value(), g_menu_link_iter_get_value) + _WRAP_METHOD(Glib::RefPtr<const MenuModel> get_value() const, g_menu_link_iter_get_value, constversion) + + _WRAP_METHOD(bool next(), g_menu_link_iter_next) +}; + +} // namespace Gio |