Files
jlibwinapi/native/MsgHook/org_synthuse_MsgHook.cpp
Edward Jakubowski b5ede5e6cb MsgHook Native library updates
MsgHook Native library works from native test application, still
introducing library to java side through jni.
2014-05-23 06:50:49 -04:00

29 lines
675 B
C++

/*
* Copyright 2014, Synthuse.org
* Released under the Apache Version 2.0 License.
*
* last modified by ejakubowski7@gmail.com
*/
#include "stdafx.h"
#include "org_synthuse_MsgHook.h"
/*
* Class: org_synthuse_MsgHook
* Method: setMessageHook
* Signature: (JJ)Z
*/
JNIEXPORT jboolean JNICALL Java_org_synthuse_MsgHook_setMessageHook(JNIEnv *env, jobject obj, jlong jhWnd, jlong jthreadId)
{
return SetMsgHook((HWND)jhWnd, (DWORD)jthreadId);
}
/*
* Class: org_synthuse_MsgHook
* Method: removeMessageHook
* Signature: ()Z
*/
JNIEXPORT jboolean JNICALL Java_org_synthuse_MsgHook_removeMessageHook(JNIEnv *env, jobject obj)
{
return RemoveHook();
}