2012-06-10 16:50:54 +00:00
|
|
|
/*
|
2024-09-17 19:00:25 +00:00
|
|
|
* Deskflow -- mouse and keyboard sharing utility
|
2016-09-07 14:24:00 +00:00
|
|
|
* Copyright (C) 2012-2016 Symless Ltd.
|
2012-09-04 02:09:56 +00:00
|
|
|
* Copyright (C) 2002 Chris Schoeneman
|
2024-07-02 19:07:06 +00:00
|
|
|
*
|
2012-06-10 16:50:54 +00:00
|
|
|
* This package is free software; you can redistribute it and/or
|
|
|
|
|
* modify it under the terms of the GNU General Public License
|
2015-05-03 02:33:52 +00:00
|
|
|
* found in the file LICENSE that should have accompanied this file.
|
2024-07-02 19:07:06 +00:00
|
|
|
*
|
2012-06-10 16:50:54 +00:00
|
|
|
* This package is distributed in the hope that it will be useful,
|
|
|
|
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
|
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
|
|
|
|
* GNU General Public License for more details.
|
|
|
|
|
*
|
|
|
|
|
* You should have received a copy of the GNU General Public License
|
|
|
|
|
* along with this program. If not, see <http://www.gnu.org/licenses/>.
|
|
|
|
|
*/
|
|
|
|
|
|
2014-02-28 12:36:45 +00:00
|
|
|
#pragma once
|
2012-06-10 16:50:54 +00:00
|
|
|
|
2014-02-28 12:36:45 +00:00
|
|
|
#include "base/EventTypes.h"
|
|
|
|
|
|
2012-06-10 16:50:54 +00:00
|
|
|
#define WIN32_LEAN_AND_MEAN
|
2014-02-28 12:36:45 +00:00
|
|
|
#include <Windows.h>
|
2012-06-10 16:50:54 +00:00
|
|
|
|
2024-09-17 19:00:25 +00:00
|
|
|
#if defined(dfwhook_EXPORTS)
|
|
|
|
|
#define CDESKFLOWHOOK_API __declspec(dllexport)
|
2012-06-10 16:50:54 +00:00
|
|
|
#else
|
2024-09-17 19:00:25 +00:00
|
|
|
#define CDESKFLOWHOOK_API __declspec(dllimport)
|
2012-06-10 16:50:54 +00:00
|
|
|
#endif
|
|
|
|
|
|
2024-09-17 19:00:25 +00:00
|
|
|
#define DESKFLOW_MSG_MARK WM_APP + 0x0011 // mark id; <unused>
|
|
|
|
|
#define DESKFLOW_MSG_KEY WM_APP + 0x0012 // vk code; key data
|
|
|
|
|
#define DESKFLOW_MSG_MOUSE_BUTTON WM_APP + 0x0013 // button msg; <unused>
|
|
|
|
|
#define DESKFLOW_MSG_MOUSE_WHEEL WM_APP + 0x0014 // delta; <unused>
|
|
|
|
|
#define DESKFLOW_MSG_MOUSE_MOVE WM_APP + 0x0015 // x; y
|
|
|
|
|
#define DESKFLOW_MSG_POST_WARP WM_APP + 0x0016 // <unused>; <unused>
|
|
|
|
|
#define DESKFLOW_MSG_PRE_WARP WM_APP + 0x0017 // x; y
|
|
|
|
|
#define DESKFLOW_MSG_SCREEN_SAVER WM_APP + 0x0018 // activated; <unused>
|
|
|
|
|
#define DESKFLOW_MSG_DEBUG WM_APP + 0x0019 // data, data
|
|
|
|
|
#define DESKFLOW_MSG_INPUT_FIRST DESKFLOW_MSG_KEY
|
|
|
|
|
#define DESKFLOW_MSG_INPUT_LAST DESKFLOW_MSG_PRE_WARP
|
|
|
|
|
#define DESKFLOW_HOOK_LAST_MSG DESKFLOW_MSG_DEBUG
|
|
|
|
|
|
|
|
|
|
#define DESKFLOW_HOOK_FAKE_INPUT_VIRTUAL_KEY VK_CANCEL
|
|
|
|
|
#define DESKFLOW_HOOK_FAKE_INPUT_SCANCODE 0
|
2012-06-10 16:50:54 +00:00
|
|
|
|
2024-10-17 18:04:35 +00:00
|
|
|
extern "C"
|
|
|
|
|
{
|
2012-06-10 16:50:54 +00:00
|
|
|
|
2024-10-17 18:04:35 +00:00
|
|
|
enum EHookResult
|
|
|
|
|
{
|
|
|
|
|
kHOOK_FAILED,
|
|
|
|
|
kHOOK_OKAY,
|
|
|
|
|
kHOOK_OKAY_LL
|
|
|
|
|
};
|
2012-06-10 16:50:54 +00:00
|
|
|
|
2024-10-17 18:04:35 +00:00
|
|
|
enum EHookMode
|
|
|
|
|
{
|
|
|
|
|
kHOOK_DISABLE,
|
|
|
|
|
kHOOK_WATCH_JUMP_ZONE,
|
|
|
|
|
kHOOK_RELAY_EVENTS
|
|
|
|
|
};
|
2012-06-10 16:50:54 +00:00
|
|
|
}
|