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

Side by Side Diff: content/browser/android/content_view_render_view.cc

Issue 1874893002: Convert //content/browser from scoped_ptr to std::unique_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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/android/content_view_render_view.h" 5 #include "content/browser/android/content_view_render_view.h"
6 6
7 #include <android/bitmap.h>
8 #include <android/native_window_jni.h>
9
10 #include <memory>
11
7 #include "base/android/jni_android.h" 12 #include "base/android/jni_android.h"
8 #include "base/android/jni_string.h" 13 #include "base/android/jni_string.h"
9 #include "base/android/scoped_java_ref.h" 14 #include "base/android/scoped_java_ref.h"
10 #include "base/bind.h" 15 #include "base/bind.h"
11 #include "base/lazy_instance.h" 16 #include "base/lazy_instance.h"
12 #include "base/memory/scoped_ptr.h"
13 #include "base/message_loop/message_loop.h" 17 #include "base/message_loop/message_loop.h"
14 #include "cc/layers/layer.h" 18 #include "cc/layers/layer.h"
15 #include "content/browser/android/content_view_core_impl.h" 19 #include "content/browser/android/content_view_core_impl.h"
16 #include "content/public/browser/android/compositor.h" 20 #include "content/public/browser/android/compositor.h"
17 #include "content/public/browser/android/content_view_layer_renderer.h" 21 #include "content/public/browser/android/content_view_layer_renderer.h"
18 #include "jni/ContentViewRenderView_jni.h" 22 #include "jni/ContentViewRenderView_jni.h"
19 #include "ui/gfx/android/java_bitmap.h" 23 #include "ui/gfx/android/java_bitmap.h"
20 #include "ui/gfx/geometry/size.h" 24 #include "ui/gfx/geometry/size.h"
21 25
22 #include <android/bitmap.h>
23 #include <android/native_window_jni.h>
24
25 using base::android::ScopedJavaLocalRef; 26 using base::android::ScopedJavaLocalRef;
26 27
27 namespace content { 28 namespace content {
28 29
29 // static 30 // static
30 bool ContentViewRenderView::RegisterContentViewRenderView(JNIEnv* env) { 31 bool ContentViewRenderView::RegisterContentViewRenderView(JNIEnv* env) {
31 return RegisterNativesImpl(env); 32 return RegisterNativesImpl(env);
32 } 33 }
33 34
34 ContentViewRenderView::ContentViewRenderView(JNIEnv* env, 35 ContentViewRenderView::ContentViewRenderView(JNIEnv* env,
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
111 JNIEnv* env = base::android::AttachCurrentThread(); 112 JNIEnv* env = base::android::AttachCurrentThread();
112 Java_ContentViewRenderView_onSwapBuffersCompleted(env, java_obj_.obj()); 113 Java_ContentViewRenderView_onSwapBuffersCompleted(env, java_obj_.obj());
113 } 114 }
114 115
115 void ContentViewRenderView::InitCompositor() { 116 void ContentViewRenderView::InitCompositor() {
116 if (!compositor_) 117 if (!compositor_)
117 compositor_.reset(Compositor::Create(this, root_window_)); 118 compositor_.reset(Compositor::Create(this, root_window_));
118 } 119 }
119 120
120 } // namespace content 121 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/android/content_view_render_view.h ('k') | content/browser/android/date_time_chooser_android.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698