OLD | NEW |
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 "base/macros.h" | 7 #include "base/macros.h" |
8 #include "base/prefs/pref_service.h" | 8 #include "base/prefs/pref_service.h" |
9 #include "chrome/browser/profiles/profile.h" | 9 #include "chrome/browser/profiles/profile.h" |
10 #include "chrome/common/pref_names.h" | 10 #include "chrome/common/pref_names.h" |
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
87 linux_ui->GetInactiveSelectionFgColor(); | 87 linux_ui->GetInactiveSelectionFgColor(); |
88 } | 88 } |
89 | 89 |
90 // If we have a linux_ui object, set the caret blink interval regardless of | 90 // If we have a linux_ui object, set the caret blink interval regardless of |
91 // whether we're in native theme mode. | 91 // whether we're in native theme mode. |
92 prefs->caret_blink_interval = linux_ui->GetCursorBlinkInterval(); | 92 prefs->caret_blink_interval = linux_ui->GetCursorBlinkInterval(); |
93 } | 93 } |
94 #endif | 94 #endif |
95 | 95 |
96 #if defined(OS_LINUX) || defined(OS_ANDROID) | 96 #if defined(OS_LINUX) || defined(OS_ANDROID) |
97 CR_DEFINE_STATIC_LOCAL(const gfx::FontRenderParams, params, | 97 const gfx::FontRenderParams params = |
98 (gfx::GetFontRenderParams(gfx::FontRenderParamsQuery(true), NULL))); | 98 gfx::GetCurrentFontRenderParams(gfx::FontRenderParamsQuery(true), NULL); |
99 prefs->should_antialias_text = params.antialiasing; | 99 prefs->should_antialias_text = params.antialiasing; |
100 prefs->use_subpixel_positioning = params.subpixel_positioning; | 100 prefs->use_subpixel_positioning = params.subpixel_positioning; |
101 prefs->hinting = params.hinting; | 101 prefs->hinting = params.hinting; |
102 prefs->use_autohinter = params.autohinter; | 102 prefs->use_autohinter = params.autohinter; |
103 prefs->use_bitmaps = params.use_bitmaps; | 103 prefs->use_bitmaps = params.use_bitmaps; |
104 prefs->subpixel_rendering = params.subpixel_rendering; | 104 prefs->subpixel_rendering = params.subpixel_rendering; |
105 #endif | 105 #endif |
106 | 106 |
107 #if !defined(OS_MACOSX) | 107 #if !defined(OS_MACOSX) |
108 prefs->plugin_fullscreen_allowed = | 108 prefs->plugin_fullscreen_allowed = |
109 pref_service->GetBoolean(prefs::kFullscreenAllowed); | 109 pref_service->GetBoolean(prefs::kFullscreenAllowed); |
110 #endif | 110 #endif |
111 } | 111 } |
112 | 112 |
113 } // namespace renderer_preferences_util | 113 } // namespace renderer_preferences_util |
OLD | NEW |