| 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 "content/browser/renderer_host/render_widget_host_impl.h" | 5 #include "content/browser/renderer_host/render_widget_host_impl.h" |
| 6 | 6 |
| 7 #include <math.h> | 7 #include <math.h> |
| 8 #include <utility> | 8 #include <utility> |
| 9 | 9 |
| 10 #include "base/auto_reset.h" | 10 #include "base/auto_reset.h" |
| (...skipping 1091 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1102 keyboard_listeners_.remove(listener); | 1102 keyboard_listeners_.remove(listener); |
| 1103 } | 1103 } |
| 1104 | 1104 |
| 1105 void RenderWidgetHostImpl::NotifyScreenInfoChanged() { | 1105 void RenderWidgetHostImpl::NotifyScreenInfoChanged() { |
| 1106 WebKit::WebScreenInfo screen_info; | 1106 WebKit::WebScreenInfo screen_info; |
| 1107 GetWebScreenInfo(&screen_info); | 1107 GetWebScreenInfo(&screen_info); |
| 1108 Send(new ViewMsg_ScreenInfoChanged(GetRoutingID(), screen_info)); | 1108 Send(new ViewMsg_ScreenInfoChanged(GetRoutingID(), screen_info)); |
| 1109 } | 1109 } |
| 1110 | 1110 |
| 1111 void RenderWidgetHostImpl::SetDeviceScaleFactor(float scale) { | 1111 void RenderWidgetHostImpl::SetDeviceScaleFactor(float scale) { |
| 1112 #if defined(USE_AURA) | |
| 1113 // Send secreen info as well because JavaScript API |window.open| | |
| 1114 // uses screen info to determine the scale factor (crbug.com/155201). | |
| 1115 // TODO(oshima|thakis): Consolidate SetDeviceScaleFactor and | |
| 1116 // ScreenInfoChanged. crbug.com/155213. | |
| 1117 NotifyScreenInfoChanged(); | |
| 1118 #endif | |
| 1119 Send(new ViewMsg_SetDeviceScaleFactor(GetRoutingID(), scale)); | 1112 Send(new ViewMsg_SetDeviceScaleFactor(GetRoutingID(), scale)); |
| 1120 } | 1113 } |
| 1121 | 1114 |
| 1122 void RenderWidgetHostImpl::UpdateVSyncParameters(base::TimeTicks timebase, | 1115 void RenderWidgetHostImpl::UpdateVSyncParameters(base::TimeTicks timebase, |
| 1123 base::TimeDelta interval) { | 1116 base::TimeDelta interval) { |
| 1124 Send(new ViewMsg_UpdateVSyncParameters(GetRoutingID(), timebase, interval)); | 1117 Send(new ViewMsg_UpdateVSyncParameters(GetRoutingID(), timebase, interval)); |
| 1125 } | 1118 } |
| 1126 | 1119 |
| 1127 void RenderWidgetHostImpl::RendererExited(base::TerminationStatus status, | 1120 void RenderWidgetHostImpl::RendererExited(base::TerminationStatus status, |
| 1128 int exit_code) { | 1121 int exit_code) { |
| (...skipping 1036 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2165 return; | 2158 return; |
| 2166 | 2159 |
| 2167 OnRenderAutoResized(new_size); | 2160 OnRenderAutoResized(new_size); |
| 2168 } | 2161 } |
| 2169 | 2162 |
| 2170 void RenderWidgetHostImpl::DetachDelegate() { | 2163 void RenderWidgetHostImpl::DetachDelegate() { |
| 2171 delegate_ = NULL; | 2164 delegate_ = NULL; |
| 2172 } | 2165 } |
| 2173 | 2166 |
| 2174 } // namespace content | 2167 } // namespace content |
| OLD | NEW |