From 14da079a04914eca19be87771d10c464fca9c928 Mon Sep 17 00:00:00 2001 From: Tim Kosse Date: Sun, 8 Jun 2014 16:39:04 +0000 Subject: [PATCH] When loading wxTextCtrl from XRC files, only call SetHint if the XRC specifies a hint. Otherwise an assert is triggered on multi-line text controls. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_3_0_BRANCH@76669 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/xrc/xh_text.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/xrc/xh_text.cpp b/src/xrc/xh_text.cpp index a50bd7e969..c9ba8e42da 100644 --- a/src/xrc/xh_text.cpp +++ b/src/xrc/xh_text.cpp @@ -72,7 +72,8 @@ wxObject *wxTextCtrlXmlHandler::DoCreateResource() if (HasParam(wxT("maxlength"))) text->SetMaxLength(GetLong(wxT("maxlength"))); - text->SetHint(GetText(wxS("hint"))); + if (HasParam(wxT("hint"))) + text->SetHint(GetText(wxS("hint"))); return text; }