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

Side by Side Diff: content/shell/common/webkit_test_helpers.cc

Issue 121033002: Update uses of UTF conversions in content/ to use the base:: namespace. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 12 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/shell/common/webkit_test_helpers.h" 5 #include "content/shell/common/webkit_test_helpers.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/file_util.h" 8 #include "base/file_util.h"
9 #include "base/path_service.h" 9 #include "base/path_service.h"
10 #include "base/strings/utf_string_conversions.h" 10 #include "base/strings/utf_string_conversions.h"
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
67 prefs->java_enabled = false; 67 prefs->java_enabled = false;
68 prefs->application_cache_enabled = true; 68 prefs->application_cache_enabled = true;
69 prefs->tabs_to_links = false; 69 prefs->tabs_to_links = false;
70 prefs->hyperlink_auditing_enabled = false; 70 prefs->hyperlink_auditing_enabled = false;
71 prefs->allow_displaying_insecure_content = true; 71 prefs->allow_displaying_insecure_content = true;
72 prefs->allow_running_insecure_content = true; 72 prefs->allow_running_insecure_content = true;
73 prefs->webgl_errors_to_console_enabled = false; 73 prefs->webgl_errors_to_console_enabled = false;
74 base::string16 serif; 74 base::string16 serif;
75 #if defined(OS_MACOSX) 75 #if defined(OS_MACOSX)
76 prefs->cursive_font_family_map[webkit_glue::kCommonScript] = 76 prefs->cursive_font_family_map[webkit_glue::kCommonScript] =
77 ASCIIToUTF16("Apple Chancery"); 77 base::ASCIIToUTF16("Apple Chancery");
78 prefs->fantasy_font_family_map[webkit_glue::kCommonScript] = 78 prefs->fantasy_font_family_map[webkit_glue::kCommonScript] =
79 ASCIIToUTF16("Papyrus"); 79 base::ASCIIToUTF16("Papyrus");
80 serif = ASCIIToUTF16("Times"); 80 serif = base::ASCIIToUTF16("Times");
81 #else 81 #else
82 prefs->cursive_font_family_map[webkit_glue::kCommonScript] = 82 prefs->cursive_font_family_map[webkit_glue::kCommonScript] =
83 ASCIIToUTF16("Comic Sans MS"); 83 base::ASCIIToUTF16("Comic Sans MS");
84 prefs->fantasy_font_family_map[webkit_glue::kCommonScript] = 84 prefs->fantasy_font_family_map[webkit_glue::kCommonScript] =
85 ASCIIToUTF16("Impact"); 85 base::ASCIIToUTF16("Impact");
86 serif = ASCIIToUTF16("times new roman"); 86 serif = base::ASCIIToUTF16("times new roman");
87 #endif 87 #endif
88 prefs->serif_font_family_map[webkit_glue::kCommonScript] = 88 prefs->serif_font_family_map[webkit_glue::kCommonScript] =
89 serif; 89 serif;
90 prefs->standard_font_family_map[webkit_glue::kCommonScript] = 90 prefs->standard_font_family_map[webkit_glue::kCommonScript] =
91 serif; 91 serif;
92 prefs->fixed_font_family_map[webkit_glue::kCommonScript] = 92 prefs->fixed_font_family_map[webkit_glue::kCommonScript] =
93 ASCIIToUTF16("Courier"); 93 base::ASCIIToUTF16("Courier");
94 prefs->sans_serif_font_family_map[ 94 prefs->sans_serif_font_family_map[
95 webkit_glue::kCommonScript] = ASCIIToUTF16("Helvetica"); 95 webkit_glue::kCommonScript] = base::ASCIIToUTF16("Helvetica");
96 prefs->minimum_logical_font_size = 9; 96 prefs->minimum_logical_font_size = 9;
97 prefs->asynchronous_spell_checking_enabled = false; 97 prefs->asynchronous_spell_checking_enabled = false;
98 prefs->threaded_html_parser = true; 98 prefs->threaded_html_parser = true;
99 prefs->accelerated_2d_canvas_enabled = 99 prefs->accelerated_2d_canvas_enabled =
100 command_line.HasSwitch(switches::kEnableAccelerated2DCanvas); 100 command_line.HasSwitch(switches::kEnableAccelerated2DCanvas);
101 prefs->force_compositing_mode = 101 prefs->force_compositing_mode =
102 command_line.HasSwitch(switches::kForceCompositingMode); 102 command_line.HasSwitch(switches::kForceCompositingMode);
103 prefs->accelerated_compositing_for_video_enabled = false; 103 prefs->accelerated_compositing_for_video_enabled = false;
104 prefs->mock_scrollbars_enabled = false; 104 prefs->mock_scrollbars_enabled = false;
105 prefs->fixed_position_creates_stacking_context = false; 105 prefs->fixed_position_creates_stacking_context = false;
106 prefs->smart_insert_delete_enabled = true; 106 prefs->smart_insert_delete_enabled = true;
107 prefs->minimum_accelerated_2d_canvas_size = 0; 107 prefs->minimum_accelerated_2d_canvas_size = 0;
108 #if defined(OS_ANDROID) 108 #if defined(OS_ANDROID)
109 prefs->text_autosizing_enabled = false; 109 prefs->text_autosizing_enabled = false;
110 #endif 110 #endif
111 prefs->viewport_enabled = false; 111 prefs->viewport_enabled = false;
112 } 112 }
113 113
114 base::FilePath GetWebKitRootDirFilePath() { 114 base::FilePath GetWebKitRootDirFilePath() {
115 base::FilePath base_path; 115 base::FilePath base_path;
116 PathService::Get(base::DIR_SOURCE_ROOT, &base_path); 116 PathService::Get(base::DIR_SOURCE_ROOT, &base_path);
117 return base_path.Append(FILE_PATH_LITERAL("third_party/WebKit")); 117 return base_path.Append(FILE_PATH_LITERAL("third_party/WebKit"));
118 } 118 }
119 119
120 } // namespace content 120 } // namespace content
OLDNEW
« no previous file with comments | « content/shell/common/shell_content_client.cc ('k') | content/shell/geolocation/shell_access_token_store.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698