[gtkmm] ToolItemGroup: Slight API improvements.
- From: Murray Cumming <murrayc src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [gtkmm] ToolItemGroup: Slight API improvements.
- Date: Sat, 16 Jan 2010 12:55:05 +0000 (UTC)
commit 8b07381e73d46c2923b3c1abf523105b5bedf0a2
Author: Murray Cumming <murrayc murrayc com>
Date: Sat Jan 16 13:54:11 2010 +0100
ToolItemGroup: Slight API improvements.
* gtk/src/toolitemgroup.[hg|ccg]: Added insert() with no position parameter.
get_item_position(): Made this const.
gtk/src/toolitemgroup.ccg | 4 ++++
gtk/src/toolitemgroup.hg | 9 ++++++++-
gtk/src/toolpalette.hg | 2 ++
3 files changed, 14 insertions(+), 1 deletions(-)
---
diff --git a/gtk/src/toolitemgroup.ccg b/gtk/src/toolitemgroup.ccg
index a87190c..210df48 100644
--- a/gtk/src/toolitemgroup.ccg
+++ b/gtk/src/toolitemgroup.ccg
@@ -25,6 +25,10 @@
namespace Gtk
{
+void ToolItemGroup::insert(ToolItem& item)
+{
+ gtk_tool_item_group_insert(gobj(), (item).gobj(), -1 /* see docs */);
+}
} // namespace Gtk
diff --git a/gtk/src/toolitemgroup.hg b/gtk/src/toolitemgroup.hg
index fe4e5f1..b27dcde 100644
--- a/gtk/src/toolitemgroup.hg
+++ b/gtk/src/toolitemgroup.hg
@@ -53,8 +53,15 @@ public:
_WRAP_METHOD(ReliefStyle get_header_relief() const, gtk_tool_item_group_get_header_relief)
_WRAP_METHOD(void insert(ToolItem& item, int position), gtk_tool_item_group_insert)
+
+ /** Inserts @a item at the end of the list of children of the group.
+ *
+ * @param item The ToolItem to insert into the group.
+ */
+ void insert(ToolItem& item);
+
_WRAP_METHOD(void set_item_position(ToolItem& item, int position), gtk_tool_item_group_set_item_position)
- _WRAP_METHOD(int get_item_position(const ToolItem& item), gtk_tool_item_group_get_item_position)
+ _WRAP_METHOD(int get_item_position(const ToolItem& item) const, gtk_tool_item_group_get_item_position)
_WRAP_METHOD(guint get_n_items() const, gtk_tool_item_group_get_n_items)
diff --git a/gtk/src/toolpalette.hg b/gtk/src/toolpalette.hg
index a99a8f3..17e4377 100644
--- a/gtk/src/toolpalette.hg
+++ b/gtk/src/toolpalette.hg
@@ -41,6 +41,8 @@ _WRAP_ENUM(ToolPaletteDragTargets, GtkToolPaletteDragTargets)
* target widget. Then get_drag_item() can be used to get the dragged item in
* the "drag-data-received" signal handler of the drag target.
*
+ * @newin2p20
+ *
* @ingroup Widgets
* @ingroup Containers
*/
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]