OLD | NEW |
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2010 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/renderer/render_view.h" | 5 #include "chrome/renderer/render_view.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <string> | 8 #include <string> |
9 #include <vector> | 9 #include <vector> |
10 | 10 |
(...skipping 3345 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3356 send_preferred_size_changes_ = true; | 3356 send_preferred_size_changes_ = true; |
3357 } | 3357 } |
3358 | 3358 |
3359 void RenderView::OnSetRendererPrefs(const RendererPreferences& renderer_prefs) { | 3359 void RenderView::OnSetRendererPrefs(const RendererPreferences& renderer_prefs) { |
3360 renderer_preferences_ = renderer_prefs; | 3360 renderer_preferences_ = renderer_prefs; |
3361 UpdateFontRenderingFromRendererPrefs(); | 3361 UpdateFontRenderingFromRendererPrefs(); |
3362 #if defined(OS_LINUX) && !defined(TOOLKIT_VIEWS) | 3362 #if defined(OS_LINUX) && !defined(TOOLKIT_VIEWS) |
3363 WebColorName name = WebKit::WebColorWebkitFocusRingColor; | 3363 WebColorName name = WebKit::WebColorWebkitFocusRingColor; |
3364 WebKit::setNamedColors(&name, &renderer_prefs.focus_ring_color, 1); | 3364 WebKit::setNamedColors(&name, &renderer_prefs.focus_ring_color, 1); |
3365 | 3365 |
3366 if (webview()) | 3366 if (webview()) { |
3367 webview()->setScrollbarColors( | 3367 webview()->setScrollbarColors( |
3368 renderer_prefs.thumb_inactive_color, | 3368 renderer_prefs.thumb_inactive_color, |
3369 renderer_prefs.thumb_active_color, | 3369 renderer_prefs.thumb_active_color, |
3370 renderer_prefs.track_color); | 3370 renderer_prefs.track_color); |
| 3371 webview()->setSelectionColors( |
| 3372 renderer_prefs.active_selection_bg_color, |
| 3373 renderer_prefs.active_selection_fg_color, |
| 3374 renderer_prefs.inactive_selection_bg_color, |
| 3375 renderer_prefs.inactive_selection_fg_color); |
| 3376 } |
3371 #endif | 3377 #endif |
3372 } | 3378 } |
3373 | 3379 |
3374 void RenderView::OnMediaPlayerActionAt(const gfx::Point& location, | 3380 void RenderView::OnMediaPlayerActionAt(const gfx::Point& location, |
3375 const WebMediaPlayerAction& action) { | 3381 const WebMediaPlayerAction& action) { |
3376 if (webview()) | 3382 if (webview()) |
3377 webview()->performMediaPlayerAction(action, location); | 3383 webview()->performMediaPlayerAction(action, location); |
3378 } | 3384 } |
3379 | 3385 |
3380 void RenderView::OnNotifyRendererViewType(ViewType::Type type) { | 3386 void RenderView::OnNotifyRendererViewType(ViewType::Type type) { |
(...skipping 668 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4049 new PluginMsg_SignalModalDialogEvent(host_window_)); | 4055 new PluginMsg_SignalModalDialogEvent(host_window_)); |
4050 | 4056 |
4051 message->EnableMessagePumping(); // Runs a nested message loop. | 4057 message->EnableMessagePumping(); // Runs a nested message loop. |
4052 bool rv = Send(message); | 4058 bool rv = Send(message); |
4053 | 4059 |
4054 PluginChannelHost::Broadcast( | 4060 PluginChannelHost::Broadcast( |
4055 new PluginMsg_ResetModalDialogEvent(host_window_)); | 4061 new PluginMsg_ResetModalDialogEvent(host_window_)); |
4056 | 4062 |
4057 return rv; | 4063 return rv; |
4058 } | 4064 } |
OLD | NEW |