X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/3cb3b8b84de3ff3b660108724139c24b39746449..3515776ea5638d93b85c871667a77f9d1ed44f6c:/src/xrc/xh_hyperlink.cpp diff --git a/src/xrc/xh_hyperlink.cpp b/src/xrc/xh_hyperlink.cpp index a5a0cd3eb8..b70eb3f1fe 100644 --- a/src/xrc/xh_hyperlink.cpp +++ b/src/xrc/xh_hyperlink.cpp @@ -1,5 +1,5 @@ ///////////////////////////////////////////////////////////////////////////// -// Name: src/xrc/hyperlink.cpp +// Name: src/xrc/xh_hyperlink.cpp // Purpose: Hyperlink control // Author: David Norris // Modified by: Ryan Norton, Francesco Montorsi @@ -51,6 +51,12 @@ IMPLEMENT_DYNAMIC_CLASS(wxHyperlinkCtrlXmlHandler, wxXmlResourceHandler) wxHyperlinkCtrlXmlHandler::wxHyperlinkCtrlXmlHandler() { + XRC_ADD_STYLE(wxHL_CONTEXTMENU); + XRC_ADD_STYLE(wxHL_ALIGN_LEFT); + XRC_ADD_STYLE(wxHL_ALIGN_RIGHT); + XRC_ADD_STYLE(wxHL_ALIGN_CENTRE); + XRC_ADD_STYLE(wxHL_DEFAULT_STYLE); + AddWindowStyles(); } @@ -58,10 +64,18 @@ wxObject *wxHyperlinkCtrlXmlHandler::DoCreateResource() { XRC_MAKE_INSTANCE(control, wxHyperlinkCtrl) + control->Create + ( + m_parentAsWindow, + GetID(), + GetText(wxT("label")), + GetParamValue(wxT("url")), + GetPosition(), GetSize(), + GetStyle(wxT("style"), wxHL_DEFAULT_STYLE), + GetName() + ); + SetupWindow(control); - control->Create(m_parentAsWindow, GetID(), - GetParamValue(wxT("label")), GetParamValue(wxT("url")), - GetPosition(), GetSize(), GetStyle()); return control; }