This repository has been archived by the owner on Oct 12, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 1
/
input.h
45 lines (36 loc) · 1.65 KB
/
input.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
/* Xep128: Minimalistic Enterprise-128 emulator with focus on "exotic" hardware
Copyright (C)2015,2016 LGB (Gábor Lénárt) <lgblgblgb@gmail.com>
http://xep128.lgb.hu/
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program 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, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */
#ifndef __XEP128_INPUT_H_INCLUDED
#define __XEP128_INPUT_H_INCLUDED
#include <SDL_keyboard.h>
#define JOY_SCAN_FIRE1 0
#define JOY_SCAN_UP 1
#define JOY_SCAN_DOWN 2
#define JOY_SCAN_LEFT 3
#define JOY_SCAN_RIGHT 4
#define JOY_SCAN_FIRE2 5
#define JOY_SCAN_FIRE3 6
extern int mouse_grab, show_keys, mouse_mode;
extern int mouse_mode_description ( int cfg, char *buffer );
extern void mouse_reset_button ( void );
extern void emu_mouse_button ( Uint8 sdl_button, int press );
extern void emu_mouse_motion ( int dx, int dy );
extern void emu_mouse_wheel ( int x, int y, int flipped );
extern void mouse_reset ( void );
extern Uint8 read_control_port_bits ( void );
extern void mouse_check_data_shift ( Uint8 val );
extern int mouse_setup ( int cfg );
extern int emu_kbd ( SDL_Keysym sym, int press );
#endif