| OLD | NEW |
| 1 // Copyright (c) 2014 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2014 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/public/common/renderer_preferences.h" | 5 #include "content/public/common/renderer_preferences.h" |
| 6 #include "content/child/webthemeengine_impl_default.h" | 6 #include "content/child/webthemeengine_impl_default.h" |
| 7 #include "content/renderer/render_view_impl.h" | 7 #include "content/renderer/render_view_impl.h" |
| 8 #include "third_party/WebKit/public/web/win/WebFontRendering.h" | 8 #include "third_party/WebKit/public/web/win/WebFontRendering.h" |
| 9 #include "third_party/skia/include/core/SkFontLCDConfig.h" | 9 #include "third_party/skia/include/core/SkFontLCDConfig.h" |
| 10 #include "ui/gfx/font_render_params.h" | 10 #include "ui/gfx/font_render_params.h" |
| (...skipping 22 matching lines...) Expand all Loading... |
| 33 SkFontLCDConfig::SetSubpixelOrientation( | 33 SkFontLCDConfig::SetSubpixelOrientation( |
| 34 gfx::FontRenderParams::SubpixelRenderingToSkiaLCDOrientation( | 34 gfx::FontRenderParams::SubpixelRenderingToSkiaLCDOrientation( |
| 35 prefs.subpixel_rendering)); | 35 prefs.subpixel_rendering)); |
| 36 | 36 |
| 37 blink::WebFontRendering::setAntialiasedTextEnabled( | 37 blink::WebFontRendering::setAntialiasedTextEnabled( |
| 38 prefs.should_antialias_text); | 38 prefs.should_antialias_text); |
| 39 blink::WebFontRendering::setLCDTextEnabled(prefs.subpixel_rendering | 39 blink::WebFontRendering::setLCDTextEnabled(prefs.subpixel_rendering |
| 40 != gfx::FontRenderParams::SUBPIXEL_RENDERING_NONE); | 40 != gfx::FontRenderParams::SUBPIXEL_RENDERING_NONE); |
| 41 } | 41 } |
| 42 | 42 |
| 43 void RenderViewImpl::UpdateThemePrefs() { |
| 44 WebThemeEngineImpl::cacheScrollBarMetrics( |
| 45 renderer_preferences_.vertical_scroll_bar_width_in_dips, |
| 46 renderer_preferences_.horizontal_scroll_bar_height_in_dips, |
| 47 renderer_preferences_.arrow_bitmap_height_vertical_scroll_bar_in_dips, |
| 48 renderer_preferences_.arrow_bitmap_width_horizontal_scroll_bar_in_dips); |
| 49 } |
| 50 |
| 43 } // namespace content | 51 } // namespace content |
| OLD | NEW |