OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "chrome/browser/android/compositor/tab_content_manager.h" | 5 #include "chrome/browser/android/compositor/tab_content_manager.h" |
6 | 6 |
7 #include <android/bitmap.h> | 7 #include <android/bitmap.h> |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 | 9 |
10 #include <utility> | 10 #include <utility> |
(...skipping 14 matching lines...) Expand all Loading... |
25 #include "content/public/browser/render_widget_host.h" | 25 #include "content/public/browser/render_widget_host.h" |
26 #include "content/public/browser/render_widget_host_view.h" | 26 #include "content/public/browser/render_widget_host_view.h" |
27 #include "content/public/browser/web_contents.h" | 27 #include "content/public/browser/web_contents.h" |
28 #include "jni/TabContentManager_jni.h" | 28 #include "jni/TabContentManager_jni.h" |
29 #include "ui/android/resources/ui_resource_provider.h" | 29 #include "ui/android/resources/ui_resource_provider.h" |
30 #include "ui/gfx/android/java_bitmap.h" | 30 #include "ui/gfx/android/java_bitmap.h" |
31 #include "ui/gfx/geometry/dip_util.h" | 31 #include "ui/gfx/geometry/dip_util.h" |
32 #include "ui/gfx/geometry/rect.h" | 32 #include "ui/gfx/geometry/rect.h" |
33 #include "url/gurl.h" | 33 #include "url/gurl.h" |
34 | 34 |
| 35 using base::android::JavaParamRef; |
| 36 |
35 namespace { | 37 namespace { |
36 | 38 |
37 const size_t kMaxReadbacks = 1; | 39 const size_t kMaxReadbacks = 1; |
38 typedef base::Callback<void(float, const SkBitmap&)> TabReadbackCallback; | 40 typedef base::Callback<void(float, const SkBitmap&)> TabReadbackCallback; |
39 | 41 |
40 } // namespace | 42 } // namespace |
41 | 43 |
42 namespace chrome { | 44 namespace chrome { |
43 namespace android { | 45 namespace android { |
44 | 46 |
(...skipping 297 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
342 jboolean use_approximation_thumbnail) { | 344 jboolean use_approximation_thumbnail) { |
343 TabContentManager* manager = new TabContentManager( | 345 TabContentManager* manager = new TabContentManager( |
344 env, obj, default_cache_size, approximation_cache_size, | 346 env, obj, default_cache_size, approximation_cache_size, |
345 compression_queue_max_size, write_queue_max_size, | 347 compression_queue_max_size, write_queue_max_size, |
346 use_approximation_thumbnail); | 348 use_approximation_thumbnail); |
347 return reinterpret_cast<intptr_t>(manager); | 349 return reinterpret_cast<intptr_t>(manager); |
348 } | 350 } |
349 | 351 |
350 } // namespace android | 352 } // namespace android |
351 } // namespace chrome | 353 } // namespace chrome |
OLD | NEW |