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/android/sys_utils.h" | 9 #include "base/android/sys_utils.h" |
10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
(...skipping 528 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
539 needs_begin_frame_ = enabled; | 539 needs_begin_frame_ = enabled; |
540 } | 540 } |
541 | 541 |
542 void RenderWidgetHostViewAndroid::OnStartContentIntent( | 542 void RenderWidgetHostViewAndroid::OnStartContentIntent( |
543 const GURL& content_url) { | 543 const GURL& content_url) { |
544 if (content_view_core_) | 544 if (content_view_core_) |
545 content_view_core_->StartContentIntent(content_url); | 545 content_view_core_->StartContentIntent(content_url); |
546 } | 546 } |
547 | 547 |
548 void RenderWidgetHostViewAndroid::OnSmartClipDataExtracted( | 548 void RenderWidgetHostViewAndroid::OnSmartClipDataExtracted( |
549 const base::string16& result, | 549 const base::string16& text, |
| 550 const base::string16& html, |
550 const gfx::Rect rect) { | 551 const gfx::Rect rect) { |
551 if (content_view_core_) | 552 if (content_view_core_) |
552 content_view_core_->OnSmartClipDataExtracted(rect, result); | 553 content_view_core_->OnSmartClipDataExtracted(text, html, rect); |
553 } | 554 } |
554 | 555 |
555 bool RenderWidgetHostViewAndroid::OnTouchEvent( | 556 bool RenderWidgetHostViewAndroid::OnTouchEvent( |
556 const ui::MotionEvent& event) { | 557 const ui::MotionEvent& event) { |
557 if (!host_) | 558 if (!host_) |
558 return false; | 559 return false; |
559 | 560 |
560 if (!gesture_provider_.OnTouchEvent(event)) | 561 if (!gesture_provider_.OnTouchEvent(event)) |
561 return false; | 562 return false; |
562 | 563 |
(...skipping 916 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1479 results->availableRect = display.work_area(); | 1480 results->availableRect = display.work_area(); |
1480 results->deviceScaleFactor = display.device_scale_factor(); | 1481 results->deviceScaleFactor = display.device_scale_factor(); |
1481 results->orientationAngle = display.RotationAsDegree(); | 1482 results->orientationAngle = display.RotationAsDegree(); |
1482 gfx::DeviceDisplayInfo info; | 1483 gfx::DeviceDisplayInfo info; |
1483 results->depth = info.GetBitsPerPixel(); | 1484 results->depth = info.GetBitsPerPixel(); |
1484 results->depthPerComponent = info.GetBitsPerComponent(); | 1485 results->depthPerComponent = info.GetBitsPerComponent(); |
1485 results->isMonochrome = (results->depthPerComponent == 0); | 1486 results->isMonochrome = (results->depthPerComponent == 0); |
1486 } | 1487 } |
1487 | 1488 |
1488 } // namespace content | 1489 } // namespace content |
OLD | NEW |