Merge "Remove unused parameter displayId"

This commit is contained in:
TreeHugger Robot
2019-10-14 15:54:50 +00:00
committed by Android (Google) Code Review
2 changed files with 8 additions and 11 deletions

View File

@@ -199,8 +199,7 @@ public class InputManagerService extends IInputManager.Stub
int deviceId, int sourceMask, int sw);
private static native boolean nativeHasKeys(long ptr,
int deviceId, int sourceMask, int[] keyCodes, boolean[] keyExists);
private static native void nativeRegisterInputChannel(long ptr, InputChannel inputChannel,
int displayId);
private static native void nativeRegisterInputChannel(long ptr, InputChannel inputChannel);
private static native void nativeRegisterInputMonitor(long ptr, InputChannel inputChannel,
int displayId, boolean isGestureMonitor);
private static native void nativeUnregisterInputChannel(long ptr, InputChannel inputChannel);
@@ -551,7 +550,7 @@ public class InputManagerService extends IInputManager.Stub
}
inputChannel.setToken(new Binder());
nativeRegisterInputChannel(mPtr, inputChannel, Display.INVALID_DISPLAY);
nativeRegisterInputChannel(mPtr, inputChannel);
}
/**

View File

@@ -201,8 +201,7 @@ public:
void setDisplayViewports(JNIEnv* env, jobjectArray viewportObjArray);
status_t registerInputChannel(JNIEnv* env, const sp<InputChannel>& inputChannel,
int32_t displayId);
status_t registerInputChannel(JNIEnv* env, const sp<InputChannel>& inputChannel);
status_t registerInputMonitor(JNIEnv* env, const sp<InputChannel>& inputChannel,
int32_t displayId, bool isGestureMonitor);
status_t unregisterInputChannel(JNIEnv* env, const sp<InputChannel>& inputChannel);
@@ -435,10 +434,9 @@ void NativeInputManager::setDisplayViewports(JNIEnv* env, jobjectArray viewportO
}
status_t NativeInputManager::registerInputChannel(JNIEnv* /* env */,
const sp<InputChannel>& inputChannel, int32_t displayId) {
const sp<InputChannel>& inputChannel) {
ATRACE_CALL();
return mInputManager->getDispatcher()->registerInputChannel(
inputChannel, displayId);
return mInputManager->getDispatcher()->registerInputChannel(inputChannel);
}
status_t NativeInputManager::registerInputMonitor(JNIEnv* /* env */,
@@ -1405,7 +1403,7 @@ static void handleInputChannelDisposed(JNIEnv* env,
}
static void nativeRegisterInputChannel(JNIEnv* env, jclass /* clazz */,
jlong ptr, jobject inputChannelObj, jint displayId) {
jlong ptr, jobject inputChannelObj) {
NativeInputManager* im = reinterpret_cast<NativeInputManager*>(ptr);
sp<InputChannel> inputChannel = android_view_InputChannel_getInputChannel(env,
@@ -1415,7 +1413,7 @@ static void nativeRegisterInputChannel(JNIEnv* env, jclass /* clazz */,
return;
}
status_t status = im->registerInputChannel(env, inputChannel, displayId);
status_t status = im->registerInputChannel(env, inputChannel);
if (status) {
std::string message;
@@ -1757,7 +1755,7 @@ static const JNINativeMethod gInputManagerMethods[] = {
{ "nativeHasKeys", "(JII[I[Z)Z",
(void*) nativeHasKeys },
{ "nativeRegisterInputChannel",
"(JLandroid/view/InputChannel;I)V",
"(JLandroid/view/InputChannel;)V",
(void*) nativeRegisterInputChannel },
{ "nativeRegisterInputMonitor",
"(JLandroid/view/InputChannel;IZ)V",