>).
%% @spec (This::wxIconBundle()) -> wxIcon:wxIcon()
%% @equiv getIcon(This, [])
getIcon(This)
when is_record(This, wx_ref) ->
getIcon(This, []).
%% @spec (This::wxIconBundle(),X::term()) -> wxIcon:wxIcon()
%% @doc See external documentation.
%%
Alternatives:
%%
%% getIcon(This::wxIconBundle(), [Option]) -> wxIcon:wxIcon()
%%
Option = {size, integer()}
%%
%%
%% getIcon(This::wxIconBundle(), Size::{W::integer(), H::integer()}) -> wxIcon:wxIcon()
%%
getIcon(#wx_ref{type=ThisT,ref=ThisRef}, Options)
when is_list(Options) ->
?CLASS(ThisT,wxIconBundle),
MOpts = fun({size, Size}, Acc) -> [<<1:32/?UI,Size:32/?UI>>|Acc];
(BadOpt, _) -> erlang:error({badoption, BadOpt}) end,
BinOpt = list_to_binary(lists:foldl(MOpts, [<<0:32>>], Options)),
wxe_util:call(?wxIconBundle_GetIcon_1_0,
<>);
getIcon(#wx_ref{type=ThisT,ref=ThisRef},{SizeW,SizeH})
when is_integer(SizeW),is_integer(SizeH) ->
?CLASS(ThisT,wxIconBundle),
wxe_util:call(?wxIconBundle_GetIcon_1_1,
<>).
%% @spec (This::wxIconBundle()) -> ok
%% @doc Destroys this object, do not use object again
destroy(Obj=#wx_ref{type=Type}) ->
?CLASS(Type,wxIconBundle),
wxe_util:destroy(?wxIconBundle_destruct,Obj),
ok.