diff options
author | Jérémy Zurcher <jeremy@asynk.ch> | 2012-12-21 15:36:53 +0100 |
---|---|---|
committer | Jérémy Zurcher <jeremy@asynk.ch> | 2012-12-21 15:36:53 +0100 |
commit | 6b6401d08d3fd71fa09b59aa9a2f6ca7d1421e44 (patch) | |
tree | 60d7a695e9d7c2ddb718b3efec9fad27ab299328 | |
parent | 22470ad1d2c5b19526ef9d685dd413aa445cd241 (diff) | |
download | ffi-efl-6b6401d08d3fd71fa09b59aa9a2f6ca7d1421e44.zip ffi-efl-6b6401d08d3fd71fa09b59aa9a2f6ca7d1421e44.tar.gz |
generate efreet_trash native binding
-rw-r--r-- | lib/efl/native/efreet_trash.rb | 48 | ||||
-rwxr-xr-x | tools/extract-api.sh | 1 | ||||
-rwxr-xr-x | tools/genruby.rb | 1 |
3 files changed, 50 insertions, 0 deletions
diff --git a/lib/efl/native/efreet_trash.rb b/lib/efl/native/efreet_trash.rb new file mode 100644 index 0000000..c933037 --- /dev/null +++ b/lib/efl/native/efreet_trash.rb @@ -0,0 +1,48 @@ +#! /usr/bin/env ruby +# -*- coding: UTF-8 -*- +# +require 'efl/native' +require 'efl/native/eina_list' +require 'efl/native/efreet_uri' +# +module Efl + # + module EfreetTrash + # + FCT_PREFIX = 'efreet_trash_' unless const_defined? :FCT_PREFIX + # + def self.method_missing meth, *args, &block + sym = Efl::MethodResolver.resolve self, meth, FCT_PREFIX + self.send sym, *args, &block + end + # + end + # + module Native + # + ffi_lib 'efreet_trash' + # + # FUNCTIONS + fcts = [ + # EAPI int efreet_trash_init(void); + [ :efreet_trash_init, [ ], :int ], + # EAPI int efreet_trash_shutdown(void); + [ :efreet_trash_shutdown, [ ], :int ], + # EAPI const char *efreet_trash_dir_get(const char *for_file); + [ :efreet_trash_dir_get, [ :string ], :string ], + # EAPI int efreet_trash_delete_uri(Efreet_Uri *uri, int force_delete); + [ :efreet_trash_delete_uri, [ :efreet_uri, :int ], :int ], + # EAPI Eina_List *efreet_trash_ls(void); + [ :efreet_trash_ls, [ ], :eina_list ], + # EAPI int efreet_trash_is_empty(void); + [ :efreet_trash_is_empty, [ ], :int ], + # EAPI int efreet_trash_empty_trash(void); + [ :efreet_trash_empty_trash, [ ], :int ], + ] + # + attach_fcts fcts + # + end +end +# +# EOF diff --git a/tools/extract-api.sh b/tools/extract-api.sh index 9e92b0d..5ddefa4 100755 --- a/tools/extract-api.sh +++ b/tools/extract-api.sh @@ -53,6 +53,7 @@ for header in \ "${INCLUDE}/efreet-1/efreet_menu.h" \ "${INCLUDE}/efreet-1/efreet_uri.h" \ "${INCLUDE}/efreet-1/Efreet_Mime.h" \ + "${INCLUDE}/efreet-1/Efreet_Trash.h" \ "${INCLUDE}/ethumb-1/Ethumb.h" \ "${INCLUDE}/ethumb-1/Ethumb_Client.h" \ "${INCLUDE}/ethumb-1/Ethumb_Plugin.h" \ diff --git a/tools/genruby.rb b/tools/genruby.rb index 54ddb3b..ce67cc2 100755 --- a/tools/genruby.rb +++ b/tools/genruby.rb @@ -300,6 +300,7 @@ libs << efl_h('efreet','efreet_desktop.h','EfreetDesktop','efreet_desktop',nil,[ libs << efl_h('efreet','efreet_menu.h','EfreetMenu','efreet_menu',nil,["#{NATIVE}/efreet_desktop"]) libs << efl_h('efreet','efreet_uri.h','EfreetUri','efreet_uri') libs << efl_h('efreet_mime','Efreet_Mime.h','EfreetMime') +libs << efl_h('efreet_trash','Efreet_Trash.h','EfreetTrash',nil,nil,["#{NATIVE}/eina_list","#{NATIVE}/efreet_uri"]) libs << efl_h('ethumb','Ethumb.h','Ethumb') libs << efl_h('ethumb_client','Ethumb_Client.h','EthumbClient',nil,nil,["#{NATIVE}/ethumb"]) libs << efl_h('ethumb','Ethumb_Plugin.h','EthumbPlugin',nil,nil,["#{NATIVE}/evas","#{NATIVE}/ecore_evas","#{NATIVE}/ethumb"]) |