]> git.saurik.com Git - wxWidgets.git/blobdiff - src/common/menucmn.cpp
Generalised WinCE fix for other platforms
[wxWidgets.git] / src / common / menucmn.cpp
index 4383f3cde2105ca102869155a39bea1b6d5c7093..a9d30e2bef68931d4e7dddb61f0449adc5ce3cd8 100644 (file)
@@ -160,10 +160,7 @@ wxAcceleratorEntry *wxGetAccelFromString(const wxString& label)
                 if ( current[0U] == 'f' && wxIsdigit(current[1U]) &&
                      (current.Len() == 2 ||
                      (current.Len() == 3 && wxIsdigit(current[2U]))) ) {
-                    int n;
-                    wxSscanf(current.c_str() + 1, wxT("%d"), &n);
-
-                    keyCode = WXK_F1 + n - 1;
+                    keyCode = WXK_F1 + wxAtoi(current.c_str() + 1) - 1;
                 }
                 else {
                     // several special cases