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

Side by Side Diff: components/resource_provider/android/android_hooks.cc

Issue 1917193003: Revert of 🍈 Unify application context usage. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 <vector> 5 #include <vector>
6 6
7 #include "base/android/base_jni_onload.h" 7 #include "base/android/base_jni_onload.h"
8 #include "base/android/context_utils.h" 8 #include "base/android/context_utils.h"
9 #include "base/android/jni_android.h" 9 #include "base/android/jni_android.h"
10 #include "base/android/library_loader/library_loader_hooks.h" 10 #include "base/android/library_loader/library_loader_hooks.h"
(...skipping 28 matching lines...) Expand all
39 // There cannot be two AtExitManagers at the same time. Remove the one from 39 // There cannot be two AtExitManagers at the same time. Remove the one from
40 // LibraryLoader as ApplicationRunner also uses one. 40 // LibraryLoader as ApplicationRunner also uses one.
41 base::android::LibraryLoaderExitHook(); 41 base::android::LibraryLoaderExitHook();
42 42
43 return JNI_VERSION_1_4; 43 return JNI_VERSION_1_4;
44 } 44 }
45 45
46 extern "C" JNI_EXPORT void InitApplicationContext( 46 extern "C" JNI_EXPORT void InitApplicationContext(
47 const base::android::JavaRef<jobject>& context) { 47 const base::android::JavaRef<jobject>& context) {
48 JNIEnv* env = base::android::AttachCurrentThread(); 48 JNIEnv* env = base::android::AttachCurrentThread();
49 base::android::InitApplicationContext(env, context);
49 resource_provider::Java_Main_init( 50 resource_provider::Java_Main_init(
50 env, base::android::GetApplicationContext()); 51 env, base::android::GetApplicationContext());
51 } 52 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698