]> git.saurik.com Git - wxWidgets.git/commitdiff
dont use wxChar* arguments in wxHTML API
authorVáclav Slavík <vslavik@fastmail.fm>
Thu, 28 Jun 2007 17:33:59 +0000 (17:33 +0000)
committerVáclav Slavík <vslavik@fastmail.fm>
Thu, 28 Jun 2007 17:33:59 +0000 (17:33 +0000)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@47005 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775

include/wx/html/htmltag.h
src/html/htmltag.cpp

index b73ffc7441e4bdb50e9bfe7ebc2236498df562c2..92a93438a33a55f4f0b2f7bce3307b2979e8d19f 100644 (file)
@@ -105,7 +105,8 @@ public:
     // (like sscanf() does)
     // NOTE: unlike scanf family, this function only accepts
     //       *one* parameter !
-    int ScanParam(const wxString& par, const wxChar *format, void *param) const;
+    int ScanParam(const wxString& par, const char *format, void *param) const;
+    int ScanParam(const wxString& par, const wchar_t *format, void *param) const;
 
     // Returns string containing all params.
     wxString GetAllParams() const;
index ceb353297c68e79c14b255fbeaa8b3ad29ffb7b3..05b9c77a2539221f269cc60298ca156d72c171b9 100644 (file)
@@ -407,7 +407,15 @@ wxString wxHtmlTag::GetParam(const wxString& par, bool with_commas) const
 }
 
 int wxHtmlTag::ScanParam(const wxString& par,
-                         const wxChar *format,
+                         const char *format,
+                         void *param) const
+{
+    wxString parval = GetParam(par);
+    return wxSscanf(parval, format, param);
+}
+
+int wxHtmlTag::ScanParam(const wxString& par,
+                         const wchar_t *format,
                          void *param) const
 {
     wxString parval = GetParam(par);