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

Unified Diff: mojo/services/native_viewport/native_viewport_android.cc

Issue 404913002: Break dependency of native_viewport_service on mojo::shell::Context (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Cleanup Created 6 years, 5 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 side-by-side diff with in-line comments
Download patch
Index: mojo/services/native_viewport/native_viewport_android.cc
diff --git a/mojo/services/native_viewport/native_viewport_android.cc b/mojo/services/native_viewport/native_viewport_android.cc
index 1763f170ad307617f906427f3cf0f6ec931f0880..121289c61941fb31fc2dc82295ccef8dd8a7dcfa 100644
--- a/mojo/services/native_viewport/native_viewport_android.cc
+++ b/mojo/services/native_viewport/native_viewport_android.cc
@@ -9,7 +9,7 @@
#include "base/android/jni_android.h"
#include "jni/NativeViewportAndroid_jni.h"
-#include "mojo/shell/context.h"
+#include "mojo/services/native_viewport/native_viewport_context.h"
#include "ui/events/event.h"
#include "ui/gfx/point.h"
@@ -38,7 +38,7 @@ bool NativeViewportAndroid::Register(JNIEnv* env) {
return RegisterNativesImpl(env);
}
-NativeViewportAndroid::NativeViewportAndroid(shell::Context* context,
+NativeViewportAndroid::NativeViewportAndroid(NativeViewportContext* context,
NativeViewportDelegate* delegate)
: delegate_(delegate),
context_(context),
@@ -103,7 +103,7 @@ bool NativeViewportAndroid::TouchEvent(JNIEnv* env, jobject obj,
void NativeViewportAndroid::Init(const gfx::Rect& bounds) {
JNIEnv* env = base::android::AttachCurrentThread();
- Java_NativeViewportAndroid_createForActivity(env, context_->activity(),
+ Java_NativeViewportAndroid_createForActivity(env, context_->GetActivity(),
qsr 2014/07/21 08:20:25 Any reason not to use base::android::GetApplicatio
reinterpret_cast<jlong>(this));
}
@@ -151,7 +151,7 @@ void NativeViewportAndroid::ReleaseWindow() {
// static
scoped_ptr<NativeViewport> NativeViewport::Create(
- shell::Context* context,
+ NativeViewportContext* context,
NativeViewportDelegate* delegate) {
return scoped_ptr<NativeViewport>(
new NativeViewportAndroid(context, delegate)).Pass();

Powered by Google App Engine
This is Rietveld 408576698