]> git.saurik.com Git - wxWidgets.git/commitdiff
apply XRCID() automatically to XRCSIZERITEM() argument (patch 1798697)
authorVadim Zeitlin <vadim@wxwidgets.org>
Thu, 20 Sep 2007 16:29:05 +0000 (16:29 +0000)
committerVadim Zeitlin <vadim@wxwidgets.org>
Thu, 20 Sep 2007 16:29:05 +0000 (16:29 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@48836 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

docs/latex/wx/txrc.tex
include/wx/xrc/xmlres.h

index e77cfd21f5318db2b406f182deae2ae8e647812d..3a11b955d7721d176f0c0eed54f3c4e5f759e616 100644 (file)
@@ -520,7 +520,7 @@ The code can then access the sizer item by using {\tt XRCSIZERITEM} and
 {\tt XRCID} together.
 
 \begin{verbatim}
-wxSizerItem* item = XRCSIZERITEM(*this, XRCID("area"));
+wxSizerItem* item = XRCSIZERITEM(*this, "area");
 \end{verbatim}
 
 \subsection{Adding new resource handlers}\label{newresourcehandlers}
index efaba14f723acbe3592ebd982b438156c55aa65e..877dc1237db1d2942535acfdce2986e5afc5a45a 100644 (file)
@@ -326,10 +326,10 @@ private:
 //   <size>400, 300</size>
 // </object>
 //
-// wxSizerItem* item = XRCSIZERITEM(*this, wxT("area"))
+// wxSizerItem* item = XRCSIZERITEM(*this, "area")
 
 #define XRCSIZERITEM(window, id) \
-    ((window).GetSizer() ? (window).GetSizer()->GetItemById(id) : NULL)    
+    ((window).GetSizer() ? (window).GetSizer()->GetItemById(XRCID(id)) : NULL)
 
 // wxXmlResourceHandler is an abstract base class for resource handlers
 // capable of creating a control from an XML node.