Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2534)

Unified Diff: chrome/browser/tab_contents/render_view_host_delegate_helper.cc

Issue 192017: Convert std::wstring encoding names to std::string in a bunch of files. (Closed)
Patch Set: mac and linux fixes Created 11 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/tab_contents/render_view_host_delegate_helper.cc
diff --git a/chrome/browser/tab_contents/render_view_host_delegate_helper.cc b/chrome/browser/tab_contents/render_view_host_delegate_helper.cc
index 2f0eef856ada0bbea109be498b099641d4722b99..9a3821aeaadd20035dea40768ab9fc911ffa1bc1 100644
--- a/chrome/browser/tab_contents/render_view_host_delegate_helper.cc
+++ b/chrome/browser/tab_contents/render_view_host_delegate_helper.cc
@@ -135,7 +135,8 @@ WebPreferences RenderViewHostDelegateHelper::GetWebkitPrefs(
web_prefs.minimum_logical_font_size =
prefs->GetInteger(prefs::kWebKitMinimumLogicalFontSize);
- web_prefs.default_encoding = prefs->GetString(prefs::kDefaultCharset);
+ web_prefs.default_encoding =
+ WideToASCII(prefs->GetString(prefs::kDefaultCharset));
web_prefs.javascript_can_open_windows_automatically =
prefs->GetBoolean(prefs::kWebKitJavascriptCanOpenWindowsAutomatically);
@@ -202,8 +203,8 @@ WebPreferences RenderViewHostDelegateHelper::GetWebkitPrefs(
web_prefs.default_encoding);
if (web_prefs.default_encoding.empty()) {
prefs->ClearPref(prefs::kDefaultCharset);
- web_prefs.default_encoding = prefs->GetString(
- prefs::kDefaultCharset);
+ web_prefs.default_encoding = WideToASCII(
+ prefs->GetString(prefs::kDefaultCharset));
}
DCHECK(!web_prefs.default_encoding.empty());
« no previous file with comments | « chrome/browser/renderer_host/render_view_host_delegate.h ('k') | chrome/browser/tab_contents/tab_contents.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698