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_view_aura.h" | 5 #include "content/browser/renderer_host/render_widget_host_view_aura.h" |
6 | 6 |
7 #include "base/bind.h" | 7 #include "base/bind.h" |
8 #include "base/bind_helpers.h" | 8 #include "base/bind_helpers.h" |
9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
10 #include "base/debug/trace_event.h" | 10 #include "base/debug/trace_event.h" |
(...skipping 1104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1115 return it == resize_locks_.end() || ++it != resize_locks_.end(); | 1115 return it == resize_locks_.end() || ++it != resize_locks_.end(); |
1116 } | 1116 } |
1117 | 1117 |
1118 void RenderWidgetHostViewAura::UpdateExternalTexture() { | 1118 void RenderWidgetHostViewAura::UpdateExternalTexture() { |
1119 // Delay processing accelerated compositing state change till here where we | 1119 // Delay processing accelerated compositing state change till here where we |
1120 // act upon the state change. (Clear the external texture if switching to | 1120 // act upon the state change. (Clear the external texture if switching to |
1121 // software mode or set the external texture if going to accelerated mode). | 1121 // software mode or set the external texture if going to accelerated mode). |
1122 if (accelerated_compositing_state_changed_) | 1122 if (accelerated_compositing_state_changed_) |
1123 accelerated_compositing_state_changed_ = false; | 1123 accelerated_compositing_state_changed_ = false; |
1124 | 1124 |
| 1125 CHECK(false); |
| 1126 printf("\t%d\5 host_: %p host_->is_accelerated_compositing_active(): %d\n", |
| 1127 getpid(), host_, |
| 1128 host_ ? host_->is_accelerated_compositing_active() : -1); |
1125 if (current_surface_ && host_->is_accelerated_compositing_active()) { | 1129 if (current_surface_ && host_->is_accelerated_compositing_active()) { |
1126 window_->SetExternalTexture(current_surface_.get()); | 1130 window_->SetExternalTexture(current_surface_.get()); |
1127 | 1131 |
1128 ResizeLockList::iterator it = resize_locks_.begin(); | 1132 ResizeLockList::iterator it = resize_locks_.begin(); |
1129 while (it != resize_locks_.end()) { | 1133 while (it != resize_locks_.end()) { |
1130 gfx::Size container_size = ConvertSizeToDIP(this, | 1134 gfx::Size container_size = ConvertSizeToDIP(this, |
1131 current_surface_->size()); | 1135 current_surface_->size()); |
1132 if ((*it)->expected_size() == container_size) | 1136 if ((*it)->expected_size() == container_size) |
1133 break; | 1137 break; |
1134 ++it; | 1138 ++it; |
(...skipping 1302 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2437 RenderWidgetHost* widget) { | 2441 RenderWidgetHost* widget) { |
2438 return new RenderWidgetHostViewAura(widget); | 2442 return new RenderWidgetHostViewAura(widget); |
2439 } | 2443 } |
2440 | 2444 |
2441 // static | 2445 // static |
2442 void RenderWidgetHostViewPort::GetDefaultScreenInfo(WebScreenInfo* results) { | 2446 void RenderWidgetHostViewPort::GetDefaultScreenInfo(WebScreenInfo* results) { |
2443 GetScreenInfoForWindow(results, NULL); | 2447 GetScreenInfoForWindow(results, NULL); |
2444 } | 2448 } |
2445 | 2449 |
2446 } // namespace content | 2450 } // namespace content |
OLD | NEW |