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

Side by Side Diff: chrome/browser/renderer_preferences_util.cc

Issue 2498733002: Remove some global UI defines (Closed)
Patch Set: Merge Created 4 years, 1 month 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
« no previous file with comments | « build/config/ui.gni ('k') | content/DEPS » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "chrome/browser/renderer_preferences_util.h" 5 #include "chrome/browser/renderer_preferences_util.h"
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/macros.h" 9 #include "base/macros.h"
10 #include "base/strings/string_number_conversions.h" 10 #include "base/strings/string_number_conversions.h"
11 #include "base/strings/string_util.h" 11 #include "base/strings/string_util.h"
12 #include "build/build_config.h" 12 #include "build/build_config.h"
13 #include "chrome/browser/profiles/profile.h" 13 #include "chrome/browser/profiles/profile.h"
14 #include "chrome/common/pref_names.h" 14 #include "chrome/common/pref_names.h"
15 #include "components/prefs/pref_service.h" 15 #include "components/prefs/pref_service.h"
16 #include "content/public/browser/web_contents.h" 16 #include "content/public/browser/web_contents.h"
17 #include "content/public/common/renderer_preferences.h" 17 #include "content/public/common/renderer_preferences.h"
18 #include "content/public/common/webrtc_ip_handling_policy.h" 18 #include "content/public/common/webrtc_ip_handling_policy.h"
19 #include "third_party/WebKit/public/public_features.h"
19 #include "third_party/skia/include/core/SkColor.h" 20 #include "third_party/skia/include/core/SkColor.h"
20 21
21 #if defined(OS_LINUX) || defined(OS_ANDROID) 22 #if defined(OS_LINUX) || defined(OS_ANDROID)
22 #include "ui/gfx/font_render_params.h" 23 #include "ui/gfx/font_render_params.h"
23 #endif 24 #endif
24 25
25 #if defined(TOOLKIT_VIEWS) 26 #if defined(TOOLKIT_VIEWS)
26 #include "ui/views/controls/textfield/textfield.h" 27 #include "ui/views/controls/textfield/textfield.h"
27 #endif 28 #endif
28 29
(...skipping 75 matching lines...) Expand 10 before | Expand all | Expand 10 after
104 if (prefs->webrtc_ip_handling_policy.empty()) { 105 if (prefs->webrtc_ip_handling_policy.empty()) {
105 prefs->webrtc_ip_handling_policy = 106 prefs->webrtc_ip_handling_policy =
106 pref_service->GetString(prefs::kWebRTCIPHandlingPolicy); 107 pref_service->GetString(prefs::kWebRTCIPHandlingPolicy);
107 } 108 }
108 std::string webrtc_udp_port_range = 109 std::string webrtc_udp_port_range =
109 pref_service->GetString(prefs::kWebRTCUDPPortRange); 110 pref_service->GetString(prefs::kWebRTCUDPPortRange);
110 ParsePortRange(webrtc_udp_port_range, &prefs->webrtc_udp_min_port, 111 ParsePortRange(webrtc_udp_port_range, &prefs->webrtc_udp_min_port,
111 &prefs->webrtc_udp_max_port); 112 &prefs->webrtc_udp_max_port);
112 #endif 113 #endif
113 114
114 #if defined(USE_DEFAULT_RENDER_THEME) 115 #if BUILDFLAG(USE_DEFAULT_RENDER_THEME)
115 prefs->focus_ring_color = SkColorSetRGB(0x4D, 0x90, 0xFE); 116 prefs->focus_ring_color = SkColorSetRGB(0x4D, 0x90, 0xFE);
116 #if defined(OS_CHROMEOS) 117 #if defined(OS_CHROMEOS)
117 // This color is 0x544d90fe modulated with 0xffffff. 118 // This color is 0x544d90fe modulated with 0xffffff.
118 prefs->active_selection_bg_color = SkColorSetRGB(0xCB, 0xE4, 0xFA); 119 prefs->active_selection_bg_color = SkColorSetRGB(0xCB, 0xE4, 0xFA);
119 prefs->active_selection_fg_color = SK_ColorBLACK; 120 prefs->active_selection_fg_color = SK_ColorBLACK;
120 prefs->inactive_selection_bg_color = SkColorSetRGB(0xEA, 0xEA, 0xEA); 121 prefs->inactive_selection_bg_color = SkColorSetRGB(0xEA, 0xEA, 0xEA);
121 prefs->inactive_selection_fg_color = SK_ColorBLACK; 122 prefs->inactive_selection_fg_color = SK_ColorBLACK;
122 #endif 123 #endif
123 #endif 124 #endif
124 125
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
165 prefs->subpixel_rendering = params.subpixel_rendering; 166 prefs->subpixel_rendering = params.subpixel_rendering;
166 #endif 167 #endif
167 168
168 #if !defined(OS_MACOSX) 169 #if !defined(OS_MACOSX)
169 prefs->plugin_fullscreen_allowed = 170 prefs->plugin_fullscreen_allowed =
170 pref_service->GetBoolean(prefs::kFullscreenAllowed); 171 pref_service->GetBoolean(prefs::kFullscreenAllowed);
171 #endif 172 #endif
172 } 173 }
173 174
174 } // namespace renderer_preferences_util 175 } // namespace renderer_preferences_util
OLDNEW
« no previous file with comments | « build/config/ui.gni ('k') | content/DEPS » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698