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

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

Issue 11269022: Add Vector2d classes that represent offsets, instead of using Point. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: RenderText fixup Created 8 years, 1 month 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 | Annotate | Revision Log
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/logging.h" 10 #include "base/logging.h"
(...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after
191 const_cast<RenderWidgetHostViewAndroid*>(this)); 191 const_cast<RenderWidgetHostViewAndroid*>(this));
192 } 192 }
193 193
194 gfx::NativeViewAccessible 194 gfx::NativeViewAccessible
195 RenderWidgetHostViewAndroid::GetNativeViewAccessible() { 195 RenderWidgetHostViewAndroid::GetNativeViewAccessible() {
196 NOTIMPLEMENTED(); 196 NOTIMPLEMENTED();
197 return NULL; 197 return NULL;
198 } 198 }
199 199
200 void RenderWidgetHostViewAndroid::MovePluginWindows( 200 void RenderWidgetHostViewAndroid::MovePluginWindows(
201 const gfx::Point& scroll_offset, 201 const gfx::Vector2d& scroll_offset,
202 const std::vector<webkit::npapi::WebPluginGeometry>& moves) { 202 const std::vector<webkit::npapi::WebPluginGeometry>& moves) {
203 // We don't have plugin windows on Android. Do nothing. Note: this is called 203 // We don't have plugin windows on Android. Do nothing. Note: this is called
204 // from RenderWidgetHost::OnMsgUpdateRect which is itself invoked while 204 // from RenderWidgetHost::OnMsgUpdateRect which is itself invoked while
205 // processing the corresponding message from Renderer. 205 // processing the corresponding message from Renderer.
206 } 206 }
207 207
208 void RenderWidgetHostViewAndroid::Focus() { 208 void RenderWidgetHostViewAndroid::Focus() {
209 host_->Focus(); 209 host_->Focus();
210 host_->SetInputMethodActive(true); 210 host_->SetInputMethodActive(true);
211 } 211 }
(...skipping 299 matching lines...) Expand 10 before | Expand all | Expand 10 after
511 } 511 }
512 512
513 void RenderWidgetHostViewAndroid::SetCachedPageScaleFactorLimits( 513 void RenderWidgetHostViewAndroid::SetCachedPageScaleFactorLimits(
514 float minimum_scale, 514 float minimum_scale,
515 float maximum_scale) { 515 float maximum_scale) {
516 if (content_view_core_) 516 if (content_view_core_)
517 content_view_core_->UpdatePageScaleLimits(minimum_scale, maximum_scale); 517 content_view_core_->UpdatePageScaleLimits(minimum_scale, maximum_scale);
518 } 518 }
519 519
520 void RenderWidgetHostViewAndroid::UpdateFrameInfo( 520 void RenderWidgetHostViewAndroid::UpdateFrameInfo(
521 const gfx::Point& scroll_offset, 521 const gfx::Vector2d& scroll_offset,
522 float page_scale_factor, 522 float page_scale_factor,
523 const gfx::Size& content_size) { 523 const gfx::Size& content_size) {
524 if (content_view_core_) { 524 if (content_view_core_) {
525 content_view_core_->UpdateContentSize(content_size.width(), 525 content_view_core_->UpdateContentSize(content_size.width(),
526 content_size.height()); 526 content_size.height());
527 content_view_core_->UpdateScrollOffsetAndPageScaleFactor(scroll_offset.x(), 527 content_view_core_->UpdateScrollOffsetAndPageScaleFactor(scroll_offset.x(),
528 scroll_offset.y(), 528 scroll_offset.y(),
529 page_scale_factor); 529 page_scale_factor);
530 } 530 }
531 } 531 }
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after
566 // RenderWidgetHostView, public: 566 // RenderWidgetHostView, public:
567 567
568 // static 568 // static
569 RenderWidgetHostView* 569 RenderWidgetHostView*
570 RenderWidgetHostView::CreateViewForWidget(RenderWidgetHost* widget) { 570 RenderWidgetHostView::CreateViewForWidget(RenderWidgetHost* widget) {
571 RenderWidgetHostImpl* rwhi = RenderWidgetHostImpl::From(widget); 571 RenderWidgetHostImpl* rwhi = RenderWidgetHostImpl::From(widget);
572 return new RenderWidgetHostViewAndroid(rwhi, NULL); 572 return new RenderWidgetHostViewAndroid(rwhi, NULL);
573 } 573 }
574 574
575 } // namespace content 575 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698