OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/renderer/render_widget_fullscreen_pepper.h" | 5 #include "content/renderer/render_widget_fullscreen_pepper.h" |
6 | 6 |
7 #include "base/message_loop.h" | 7 #include "base/message_loop.h" |
8 #include "content/common/view_messages.h" | 8 #include "content/common/view_messages.h" |
9 #include "content/renderer/gpu/gpu_channel_host.h" | 9 #include "content/renderer/gpu/gpu_channel_host.h" |
10 #include "content/renderer/pepper_platform_context_3d_impl.h" | 10 #include "content/renderer/pepper_platform_context_3d_impl.h" |
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
58 virtual void resize(const WebSize& size) { | 58 virtual void resize(const WebSize& size) { |
59 size_ = size; | 59 size_ = size; |
60 WebRect plugin_rect(0, 0, size_.width, size_.height); | 60 WebRect plugin_rect(0, 0, size_.width, size_.height); |
61 plugin_->ViewChanged(plugin_rect, plugin_rect); | 61 plugin_->ViewChanged(plugin_rect, plugin_rect); |
62 widget_->Invalidate(); | 62 widget_->Invalidate(); |
63 } | 63 } |
64 | 64 |
65 virtual void willEndLiveResize() { | 65 virtual void willEndLiveResize() { |
66 } | 66 } |
67 | 67 |
68 #ifndef WEBWIDGET_HAS_ANIMATE_CHANGES | |
69 virtual void animate() { | |
70 } | |
71 #else | |
72 virtual void animate(double frameBeginTime) { | 68 virtual void animate(double frameBeginTime) { |
73 } | 69 } |
74 #endif | |
75 | 70 |
76 virtual void layout() { | 71 virtual void layout() { |
77 } | 72 } |
78 | 73 |
79 virtual void paint(WebCanvas* canvas, const WebRect& rect) { | 74 virtual void paint(WebCanvas* canvas, const WebRect& rect) { |
80 WebRect plugin_rect(0, 0, size_.width, size_.height); | 75 WebRect plugin_rect(0, 0, size_.width, size_.height); |
81 plugin_->Paint(canvas, plugin_rect, rect); | 76 plugin_->Paint(canvas, plugin_rect, rect); |
82 } | 77 } |
83 | 78 |
84 virtual void composite(bool finish) { | 79 virtual void composite(bool finish) { |
(...skipping 410 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
495 context_ = NULL; | 490 context_ = NULL; |
496 program_ = 0; | 491 program_ = 0; |
497 buffer_ = 0; | 492 buffer_ = 0; |
498 OnSwapBuffersAborted(); | 493 OnSwapBuffersAborted(); |
499 CheckCompositing(); | 494 CheckCompositing(); |
500 } | 495 } |
501 | 496 |
502 void RenderWidgetFullscreenPepper::OnSwapBuffersCompleteByRendererGLContext() { | 497 void RenderWidgetFullscreenPepper::OnSwapBuffersCompleteByRendererGLContext() { |
503 OnSwapBuffersComplete(); | 498 OnSwapBuffersComplete(); |
504 } | 499 } |
OLD | NEW |