| 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_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 259 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 270 return is_layer_attached_ && content_view_core_; | 270 return is_layer_attached_ && content_view_core_; |
| 271 } | 271 } |
| 272 | 272 |
| 273 gfx::Rect RenderWidgetHostViewAndroid::GetViewBounds() const { | 273 gfx::Rect RenderWidgetHostViewAndroid::GetViewBounds() const { |
| 274 if (!content_view_core_) | 274 if (!content_view_core_) |
| 275 return gfx::Rect(); | 275 return gfx::Rect(); |
| 276 | 276 |
| 277 return gfx::Rect(content_view_core_->GetDIPSize()); | 277 return gfx::Rect(content_view_core_->GetDIPSize()); |
| 278 } | 278 } |
| 279 | 279 |
| 280 gfx::Size RenderWidgetHostViewAndroid::GetPhysicalBackingSize() const { |
| 281 if (!content_view_core_) |
| 282 return gfx::Size(); |
| 283 |
| 284 return content_view_core_->GetPhysicalSize(); |
| 285 } |
| 286 |
| 280 void RenderWidgetHostViewAndroid::UpdateCursor(const WebCursor& cursor) { | 287 void RenderWidgetHostViewAndroid::UpdateCursor(const WebCursor& cursor) { |
| 281 // There are no cursors on Android. | 288 // There are no cursors on Android. |
| 282 } | 289 } |
| 283 | 290 |
| 284 void RenderWidgetHostViewAndroid::SetIsLoading(bool is_loading) { | 291 void RenderWidgetHostViewAndroid::SetIsLoading(bool is_loading) { |
| 285 // Do nothing. The UI notification is handled through ContentViewClient which | 292 // Do nothing. The UI notification is handled through ContentViewClient which |
| 286 // is TabContentsDelegate. | 293 // is TabContentsDelegate. |
| 287 } | 294 } |
| 288 | 295 |
| 289 void RenderWidgetHostViewAndroid::TextInputStateChanged( | 296 void RenderWidgetHostViewAndroid::TextInputStateChanged( |
| (...skipping 397 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 687 // RenderWidgetHostView, public: | 694 // RenderWidgetHostView, public: |
| 688 | 695 |
| 689 // static | 696 // static |
| 690 RenderWidgetHostView* | 697 RenderWidgetHostView* |
| 691 RenderWidgetHostView::CreateViewForWidget(RenderWidgetHost* widget) { | 698 RenderWidgetHostView::CreateViewForWidget(RenderWidgetHost* widget) { |
| 692 RenderWidgetHostImpl* rwhi = RenderWidgetHostImpl::From(widget); | 699 RenderWidgetHostImpl* rwhi = RenderWidgetHostImpl::From(widget); |
| 693 return new RenderWidgetHostViewAndroid(rwhi, NULL); | 700 return new RenderWidgetHostViewAndroid(rwhi, NULL); |
| 694 } | 701 } |
| 695 | 702 |
| 696 } // namespace content | 703 } // namespace content |
| OLD | NEW |