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

Unified Diff: ui/base/touch/touch_device_android.cc

Issue 2847523002: Android: Remove GetApplicationContext part 4 (Closed)
Patch Set: Rebase and fix build Created 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « ui/base/device_form_factor_android.cc ('k') | ui/gfx/android/view_configuration.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/base/touch/touch_device_android.cc
diff --git a/ui/base/touch/touch_device_android.cc b/ui/base/touch/touch_device_android.cc
index fdb4a82f5b653bdf82303660bfd921833ae39b5a..2a65323a76d1e1a8f4e3fb26e035f86ace2ba52c 100644
--- a/ui/base/touch/touch_device_android.cc
+++ b/ui/base/touch/touch_device_android.cc
@@ -4,13 +4,11 @@
#include "ui/base/touch/touch_device.h"
-#include "base/android/context_utils.h"
#include "base/android/jni_array.h"
#include "base/logging.h"
#include "jni/TouchDevice_jni.h"
using base::android::AttachCurrentThread;
-using base::android::GetApplicationContext;
namespace ui {
@@ -19,17 +17,14 @@ TouchScreensAvailability GetTouchScreensAvailability() {
}
int MaxTouchPoints() {
- return Java_TouchDevice_maxTouchPoints(AttachCurrentThread(),
- GetApplicationContext());
+ return Java_TouchDevice_maxTouchPoints(AttachCurrentThread());
}
std::pair<int, int> GetAvailablePointerAndHoverTypes() {
JNIEnv* env = AttachCurrentThread();
std::vector<int> pointer_and_hover_types;
base::android::JavaIntArrayToIntVector(
- env, Java_TouchDevice_availablePointerAndHoverTypes(
- env, GetApplicationContext())
- .obj(),
+ env, Java_TouchDevice_availablePointerAndHoverTypes(env).obj(),
&pointer_and_hover_types);
DCHECK_EQ(pointer_and_hover_types.size(), 2u);
return std::make_pair(pointer_and_hover_types[0], pointer_and_hover_types[1]);
« no previous file with comments | « ui/base/device_form_factor_android.cc ('k') | ui/gfx/android/view_configuration.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698