Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(98)

Side by Side Diff: content/browser/renderer_host/render_widget_host_view_android.cc

Issue 15058004: cc: Rename VSync to BeginFrame (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Rebase Created 7 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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_android.h" 5 #include "content/browser/renderer_host/render_widget_host_view_android.h"
6 6
7 #include <android/bitmap.h> 7 #include <android/bitmap.h>
8 8
9 #include "base/bind.h" 9 #include "base/bind.h"
10 #include "base/bind_helpers.h" 10 #include "base/bind_helpers.h"
(...skipping 121 matching lines...) Expand 10 before | Expand all | Expand 10 after
132 132
133 bool RenderWidgetHostViewAndroid::OnMessageReceived( 133 bool RenderWidgetHostViewAndroid::OnMessageReceived(
134 const IPC::Message& message) { 134 const IPC::Message& message) {
135 bool handled = true; 135 bool handled = true;
136 IPC_BEGIN_MESSAGE_MAP(RenderWidgetHostViewAndroid, message) 136 IPC_BEGIN_MESSAGE_MAP(RenderWidgetHostViewAndroid, message)
137 IPC_MESSAGE_HANDLER(ViewHostMsg_ImeBatchStateChanged_ACK, 137 IPC_MESSAGE_HANDLER(ViewHostMsg_ImeBatchStateChanged_ACK,
138 OnProcessImeBatchStateAck) 138 OnProcessImeBatchStateAck)
139 IPC_MESSAGE_HANDLER(ViewHostMsg_StartContentIntent, OnStartContentIntent) 139 IPC_MESSAGE_HANDLER(ViewHostMsg_StartContentIntent, OnStartContentIntent)
140 IPC_MESSAGE_HANDLER(ViewHostMsg_DidChangeBodyBackgroundColor, 140 IPC_MESSAGE_HANDLER(ViewHostMsg_DidChangeBodyBackgroundColor,
141 OnDidChangeBodyBackgroundColor) 141 OnDidChangeBodyBackgroundColor)
142 IPC_MESSAGE_HANDLER(ViewHostMsg_SetVSyncNotificationEnabled, 142 IPC_MESSAGE_HANDLER(ViewHostMsg_SetNeedsBeginFrame,
143 OnSetVSyncNotificationEnabled) 143 OnSetNeedsBeginFrame)
144 IPC_MESSAGE_UNHANDLED(handled = false) 144 IPC_MESSAGE_UNHANDLED(handled = false)
145 IPC_END_MESSAGE_MAP() 145 IPC_END_MESSAGE_MAP()
146 return handled; 146 return handled;
147 } 147 }
148 148
149 void RenderWidgetHostViewAndroid::InitAsChild(gfx::NativeView parent_view) { 149 void RenderWidgetHostViewAndroid::InitAsChild(gfx::NativeView parent_view) {
150 NOTIMPLEMENTED(); 150 NOTIMPLEMENTED();
151 } 151 }
152 152
153 void RenderWidgetHostViewAndroid::InitAsPopup( 153 void RenderWidgetHostViewAndroid::InitAsPopup(
(...skipping 243 matching lines...) Expand 10 before | Expand all | Expand 10 after
397 void RenderWidgetHostViewAndroid::OnDidChangeBodyBackgroundColor( 397 void RenderWidgetHostViewAndroid::OnDidChangeBodyBackgroundColor(
398 SkColor color) { 398 SkColor color) {
399 if (cached_background_color_ == color) 399 if (cached_background_color_ == color)
400 return; 400 return;
401 401
402 cached_background_color_ = color; 402 cached_background_color_ = color;
403 if (content_view_core_) 403 if (content_view_core_)
404 content_view_core_->OnBackgroundColorChanged(color); 404 content_view_core_->OnBackgroundColorChanged(color);
405 } 405 }
406 406
407 void RenderWidgetHostViewAndroid::SendVSync(base::TimeTicks frame_time) { 407 void RenderWidgetHostViewAndroid::SendBeginFrame(
408 base::TimeTicks frame_time) {
408 if (host_) 409 if (host_)
409 host_->Send(new ViewMsg_DidVSync(host_->GetRoutingID(), frame_time)); 410 host_->Send(new ViewMsg_BeginFrame(host_->GetRoutingID(),
411 frame_time));
410 } 412 }
411 413
412 void RenderWidgetHostViewAndroid::OnSetVSyncNotificationEnabled(bool enabled) { 414 void RenderWidgetHostViewAndroid::OnSetNeedsBeginFrame(
415 bool enabled) {
413 if (content_view_core_) 416 if (content_view_core_)
414 content_view_core_->SetVSyncNotificationEnabled(enabled); 417 content_view_core_->SetVSyncNotificationEnabled(enabled);
415 } 418 }
416 419
417 void RenderWidgetHostViewAndroid::OnStartContentIntent( 420 void RenderWidgetHostViewAndroid::OnStartContentIntent(
418 const GURL& content_url) { 421 const GURL& content_url) {
419 if (content_view_core_) 422 if (content_view_core_)
420 content_view_core_->StartContentIntent(content_url); 423 content_view_core_->StartContentIntent(content_url);
421 } 424 }
422 425
(...skipping 576 matching lines...) Expand 10 before | Expand all | Expand 10 after
999 // RenderWidgetHostView, public: 1002 // RenderWidgetHostView, public:
1000 1003
1001 // static 1004 // static
1002 RenderWidgetHostView* 1005 RenderWidgetHostView*
1003 RenderWidgetHostView::CreateViewForWidget(RenderWidgetHost* widget) { 1006 RenderWidgetHostView::CreateViewForWidget(RenderWidgetHost* widget) {
1004 RenderWidgetHostImpl* rwhi = RenderWidgetHostImpl::From(widget); 1007 RenderWidgetHostImpl* rwhi = RenderWidgetHostImpl::From(widget);
1005 return new RenderWidgetHostViewAndroid(rwhi, NULL); 1008 return new RenderWidgetHostViewAndroid(rwhi, NULL);
1006 } 1009 }
1007 1010
1008 } // namespace content 1011 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/renderer_host/render_widget_host_view_android.h ('k') | content/common/view_messages.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698