diff options
author | mmentovai@google.com <mmentovai@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-08-14 00:41:45 +0000 |
---|---|---|
committer | mmentovai@google.com <mmentovai@google.com@0039d316-1c4b-4281-b951-d872f2087c98> | 2008-08-14 00:41:45 +0000 |
commit | 5115474e2e2c773b53fc1e111426e8924deeadb7 (patch) | |
tree | 6bdd56cdd544a3b331db7612781ae347739c4e82 /chrome/test/automation | |
parent | 609990b5b4254601504935427483e3fc22cfde80 (diff) | |
download | chromium_src-5115474e2e2c773b53fc1e111426e8924deeadb7.zip chromium_src-5115474e2e2c773b53fc1e111426e8924deeadb7.tar.gz chromium_src-5115474e2e2c773b53fc1e111426e8924deeadb7.tar.bz2 |
Use %ls instead of %s in wprintf format strings for wchar_t fields.
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@846 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/test/automation')
-rw-r--r-- | chrome/test/automation/autocomplete_edit_proxy.h | 18 | ||||
-rw-r--r-- | chrome/test/automation/automation_proxy_uitest.cc | 7 |
2 files changed, 17 insertions, 8 deletions
diff --git a/chrome/test/automation/autocomplete_edit_proxy.h b/chrome/test/automation/autocomplete_edit_proxy.h index 608d1f1..01fab33 100644 --- a/chrome/test/automation/autocomplete_edit_proxy.h +++ b/chrome/test/automation/autocomplete_edit_proxy.h @@ -121,11 +121,19 @@ struct ParamTraits<AutocompleteMatchData> { } static void Log(const param_type& p, std::wstring* l) { - l->append(StringPrintf(L"[%S %s %S %S %S %d %s %s %d %s %S]", - p.contents, p.deletable ? "true" : "false", p.description, - p.destination_url, p.fill_into_edit, p.inline_autocomplete_offset, - p.is_history_what_you_typed_match ? "true" : "false", p.provider_name, - p.relevance, p.starred ? "true" : "false", p.str_type)); + std::wstring provider_name_wide = UTF8ToWide(p.provider_name); + l->append(StringPrintf(L"[%ls %ls %ls %ls %ls %d %ls %ls %d %ls %ls]", + p.contents, + p.deletable ? L"true" : L"false", + p.description, + p.destination_url, + p.fill_into_edit, + p.inline_autocomplete_offset, + p.is_history_what_you_typed_match ? L"true" : L"false", + provider_name_wide, + p.relevance, + p.starred ? L"true" : L"false", + p.str_type)); } }; } // namespace IPC diff --git a/chrome/test/automation/automation_proxy_uitest.cc b/chrome/test/automation/automation_proxy_uitest.cc index c1bd5b8..0d75389e 100644 --- a/chrome/test/automation/automation_proxy_uitest.cc +++ b/chrome/test/automation/automation_proxy_uitest.cc @@ -522,7 +522,8 @@ class AutomationProxyTest4 : public UITest { std::wstring SynthesizeJSURL(const std::wstring& value) { std::wstring jscript; SStringPrintf(&jscript, - L"javascript:void(window.domAutomationController.send(%s));", value.c_str()); + L"javascript:void(window.domAutomationController.send(%ls));", + value.c_str()); return jscript; } @@ -599,8 +600,8 @@ std::wstring SynthesizeJSURLForDOMQuery(const std::wstring& id) { std::wstring jscript; SStringPrintf(&jscript, L"javascript:void(window.domAutomationController)"); - StringAppendF(&jscript, L".send(document.getElementById('%s').nodeName);", - id.c_str()); + StringAppendF(&jscript, L".send(document.getElementById('%ls').nodeName);", + id.c_str()); return jscript; } |