summaryrefslogtreecommitdiffstats
path: root/lib/efl/elm/elm_menu.rb
diff options
context:
space:
mode:
authorJérémy Zurcher <jeremy@asynk.ch>2012-02-27 15:25:27 +0100
committerJérémy Zurcher <jeremy@asynk.ch>2012-02-27 15:25:27 +0100
commit7d085da91d5c2c7da74f9eaca50cca9faa4e33ef (patch)
tree433d03e5f3767c3f4c5e3ce680a0e0091b6c2967 /lib/efl/elm/elm_menu.rb
parent979cdad00dc4617cf1614f4d4bbdc07a1e7bc1d1 (diff)
downloadffi-efl-7d085da91d5c2c7da74f9eaca50cca9faa4e33ef.zip
ffi-efl-7d085da91d5c2c7da74f9eaca50cca9faa4e33ef.tar.gz
parse elm_menu.h, generate elm_menu.rb
Diffstat (limited to 'lib/efl/elm/elm_menu.rb')
-rw-r--r--lib/efl/elm/elm_menu.rb55
1 files changed, 55 insertions, 0 deletions
diff --git a/lib/efl/elm/elm_menu.rb b/lib/efl/elm/elm_menu.rb
new file mode 100644
index 0000000..f285011
--- /dev/null
+++ b/lib/efl/elm/elm_menu.rb
@@ -0,0 +1,55 @@
+#! /usr/bin/env ruby
+# -*- coding: UTF-8 -*-
+#
+require 'efl/elm/elm_object'
+require 'efl/elm/elm_object_item'
+require 'efl/native/elm/elm_menu'
+#
+module Efl
+ #
+ module Elm
+ #
+ class ElmMenu < ElmObject
+ #
+ include Helper
+ constructor :elm_menu_add
+ search_prefixes 'elm_menu_'
+ #
+ def item_add parent, icon=nil, label=nil, cb=nil, data=nil
+ ElmObjectItem.new Native::elm_menu_item_add @ptr, parent, icon, label, cb, data
+ end
+ #
+ def item_add_object parent, subobj, cb=nil, data=nil
+ ElmObjectItem.new Native::elm_menu_item_add_object @ptr, parent, subobj, cb, data
+ end
+ #
+ def item_separator_add parent
+ ElmObjectItem.new Native::elm_menu_item_separator_add @ptr, parent
+ end
+ #
+ def selected_item_get
+ ElmObjectItem.new Native::elm_menu_selected_item_get @ptr
+ end
+ #
+ def last_item_get
+ ElmObjectItem.new Native::elm_menu_last_item_get @ptr
+ end
+ #
+ def first_item_get
+ ElmObjectItem.new Native::elm_menu_first_item_get @ptr
+ end
+ #
+ def item_next_get it
+ ElmObjectItem.new Native::elm_menu_item_next_get it
+ end
+ #
+ def item_prev_get it
+ ElmObjectItem.new Native::elm_menu_item_prev_get it
+ end
+ #
+ end
+ #
+ end
+end
+#
+# EOF