aboutsummaryrefslogtreecommitdiffstats
path: root/lib/wx/src/gen/wxFindReplaceDialog.erl
diff options
context:
space:
mode:
authorDan Gudmundsson <[email protected]>2016-10-05 16:25:59 +0200
committerDan Gudmundsson <[email protected]>2016-10-05 16:25:59 +0200
commit097cc3f6679a7c3769111cdb15a630186218d015 (patch)
treec92a39384d8989695e4318fc16edef10faf7da19 /lib/wx/src/gen/wxFindReplaceDialog.erl
parent1de609cb262ff34216dce8fbefdb9a153bdd2c93 (diff)
downloadotp-097cc3f6679a7c3769111cdb15a630186218d015.tar.gz
otp-097cc3f6679a7c3769111cdb15a630186218d015.tar.bz2
otp-097cc3f6679a7c3769111cdb15a630186218d015.zip
Fix guard test for chardata
Previously only accepted lists tough a call is made to unicode:characters_to_binary/1, and the functions where specified to handle chardata.
Diffstat (limited to 'lib/wx/src/gen/wxFindReplaceDialog.erl')
-rw-r--r--lib/wx/src/gen/wxFindReplaceDialog.erl8
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/wx/src/gen/wxFindReplaceDialog.erl b/lib/wx/src/gen/wxFindReplaceDialog.erl
index 6cc4943f8d..b5cd3350d2 100644
--- a/lib/wx/src/gen/wxFindReplaceDialog.erl
+++ b/lib/wx/src/gen/wxFindReplaceDialog.erl
@@ -99,7 +99,7 @@ new() ->
Parent::wxWindow:wxWindow(), Data::wxFindReplaceData:wxFindReplaceData(), Title::unicode:chardata().
new(Parent,Data,Title)
- when is_record(Parent, wx_ref),is_record(Data, wx_ref),is_list(Title) ->
+ when is_record(Parent, wx_ref),is_record(Data, wx_ref),?is_chardata(Title) ->
new(Parent,Data,Title, []).
%% @doc See <a href="http://www.wxwidgets.org/manuals/2.8.12/wx_wxfindreplacedialog.html#wxfindreplacedialogwxfindreplacedialog">external documentation</a>.
@@ -107,7 +107,7 @@ new(Parent,Data,Title)
Parent::wxWindow:wxWindow(), Data::wxFindReplaceData:wxFindReplaceData(), Title::unicode:chardata(),
Option :: {'style', integer()}.
new(#wx_ref{type=ParentT,ref=ParentRef},#wx_ref{type=DataT,ref=DataRef},Title, Options)
- when is_list(Title),is_list(Options) ->
+ when ?is_chardata(Title),is_list(Options) ->
?CLASS(ParentT,wxWindow),
?CLASS(DataT,wxFindReplaceData),
Title_UC = unicode:characters_to_binary([Title,0]),
@@ -122,7 +122,7 @@ new(#wx_ref{type=ParentT,ref=ParentRef},#wx_ref{type=DataT,ref=DataRef},Title, O
This::wxFindReplaceDialog(), Parent::wxWindow:wxWindow(), Data::wxFindReplaceData:wxFindReplaceData(), Title::unicode:chardata().
create(This,Parent,Data,Title)
- when is_record(This, wx_ref),is_record(Parent, wx_ref),is_record(Data, wx_ref),is_list(Title) ->
+ when is_record(This, wx_ref),is_record(Parent, wx_ref),is_record(Data, wx_ref),?is_chardata(Title) ->
create(This,Parent,Data,Title, []).
%% @doc See <a href="http://www.wxwidgets.org/manuals/2.8.12/wx_wxfindreplacedialog.html#wxfindreplacedialogcreate">external documentation</a>.
@@ -130,7 +130,7 @@ create(This,Parent,Data,Title)
This::wxFindReplaceDialog(), Parent::wxWindow:wxWindow(), Data::wxFindReplaceData:wxFindReplaceData(), Title::unicode:chardata(),
Option :: {'style', integer()}.
create(#wx_ref{type=ThisT,ref=ThisRef},#wx_ref{type=ParentT,ref=ParentRef},#wx_ref{type=DataT,ref=DataRef},Title, Options)
- when is_list(Title),is_list(Options) ->
+ when ?is_chardata(Title),is_list(Options) ->
?CLASS(ThisT,wxFindReplaceDialog),
?CLASS(ParentT,wxWindow),
?CLASS(DataT,wxFindReplaceData),