2011-08-07 21:41:54 +04:00
|
|
|
/**
|
2012-10-09 07:02:04 +04:00
|
|
|
* FreeRDP: A Remote Desktop Protocol Implementation
|
2011-08-07 21:41:54 +04:00
|
|
|
* X11 Keyboard Handling
|
|
|
|
*
|
|
|
|
* Copyright 2011 Marc-Andre Moreau <marcandre.moreau@gmail.com>
|
|
|
|
*
|
|
|
|
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
|
|
* you may not use this file except in compliance with the License.
|
|
|
|
* You may obtain a copy of the License at
|
|
|
|
*
|
|
|
|
* http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
*
|
|
|
|
* Unless required by applicable law or agreed to in writing, software
|
|
|
|
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
|
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
|
|
* See the License for the specific language governing permissions and
|
|
|
|
* limitations under the License.
|
|
|
|
*/
|
|
|
|
|
2017-06-06 15:01:41 +03:00
|
|
|
#ifndef FREERDP_CLIENT_X11_XF_KEYBOARD_H
|
|
|
|
#define FREERDP_CLIENT_X11_XF_KEYBOARD_H
|
2011-08-07 21:41:54 +04:00
|
|
|
|
2012-02-18 02:43:00 +04:00
|
|
|
#include <freerdp/locale/keyboard.h>
|
2011-08-26 06:01:33 +04:00
|
|
|
|
2013-06-15 21:41:05 +04:00
|
|
|
#include "xf_client.h"
|
2013-04-28 08:23:36 +04:00
|
|
|
#include "xfreerdp.h"
|
2011-08-07 21:41:54 +04:00
|
|
|
|
2022-02-14 16:59:22 +03:00
|
|
|
typedef struct
|
2014-03-14 08:11:44 +04:00
|
|
|
{
|
|
|
|
BOOL Shift;
|
|
|
|
BOOL LeftShift;
|
|
|
|
BOOL RightShift;
|
|
|
|
BOOL Alt;
|
|
|
|
BOOL LeftAlt;
|
|
|
|
BOOL RightAlt;
|
|
|
|
BOOL Ctrl;
|
|
|
|
BOOL LeftCtrl;
|
|
|
|
BOOL RightCtrl;
|
|
|
|
BOOL Super;
|
|
|
|
BOOL LeftSuper;
|
|
|
|
BOOL RightSuper;
|
2022-02-14 16:59:22 +03:00
|
|
|
} XF_MODIFIER_KEYS;
|
2014-03-14 08:11:44 +04:00
|
|
|
|
2015-06-17 23:08:02 +03:00
|
|
|
BOOL xf_keyboard_init(xfContext* xfc);
|
2014-03-22 22:40:52 +04:00
|
|
|
void xf_keyboard_free(xfContext* xfc);
|
2020-06-29 09:39:09 +03:00
|
|
|
|
2021-09-07 09:31:07 +03:00
|
|
|
void xf_keyboard_key_press(xfContext* xfc, const XKeyEvent* event, KeySym keysym);
|
|
|
|
void xf_keyboard_key_release(xfContext* xfc, const XKeyEvent* event, KeySym keysym);
|
|
|
|
|
2014-03-14 05:10:22 +04:00
|
|
|
void xf_keyboard_release_all_keypress(xfContext* xfc);
|
|
|
|
BOOL xf_keyboard_key_pressed(xfContext* xfc, KeySym keysym);
|
2021-09-10 16:46:33 +03:00
|
|
|
|
2014-03-14 05:10:22 +04:00
|
|
|
int xf_keyboard_read_keyboard_state(xfContext* xfc);
|
|
|
|
BOOL xf_keyboard_get_key_state(xfContext* xfc, int state, int keysym);
|
|
|
|
UINT32 xf_keyboard_get_toggle_keys_state(xfContext* xfc);
|
|
|
|
void xf_keyboard_focus_in(xfContext* xfc);
|
|
|
|
BOOL xf_keyboard_handle_special_keys(xfContext* xfc, KeySym keysym);
|
2016-12-20 12:59:45 +03:00
|
|
|
void xf_keyboard_handle_special_keys_release(xfContext* xfc, KeySym keysym);
|
2015-04-14 11:14:23 +03:00
|
|
|
BOOL xf_keyboard_set_indicators(rdpContext* context, UINT16 led_flags);
|
2019-11-06 17:24:51 +03:00
|
|
|
BOOL xf_keyboard_set_ime_status(rdpContext* context, UINT16 imeId, UINT32 imeState,
|
|
|
|
UINT32 imeConvMode);
|
2011-08-07 21:41:54 +04:00
|
|
|
|
2022-01-22 15:29:28 +03:00
|
|
|
BOOL xf_ungrab(xfContext* xfc);
|
|
|
|
|
2017-06-06 15:01:41 +03:00
|
|
|
#endif /* FREERDP_CLIENT_X11_XF_KEYBOARD_H */
|