5 Copyright © 1995-2011, The AROS Development Team. All rights reserved.
12 /*********************************************************************************************/
14 #include <aros/macros.h>
17 #include <prefs/prefhdr.h>
18 #include <prefs/input.h>
24 /*********************************************************************************************/
26 #define ARRAY_TO_LONG(x) ( ((x)[0] << 24UL) + ((x)[1] << 16UL) + ((x)[2] << 8UL) + ((x)[3]) )
27 #define ARRAY_TO_WORD(x) ( ((x)[0] << 8UL) + ((x)[1]) )
29 #define LONG_TO_ARRAY(x,y) (y)[0] = (UBYTE)(ULONG)((x) >> 24UL); \
30 (y)[1] = (UBYTE)(ULONG)((x) >> 16UL); \
31 (y)[2] = (UBYTE)(ULONG)((x) >> 8UL); \
32 (y)[3] = (UBYTE)(ULONG)((x));
34 #define WORD_TO_ARRAY(x,y) (y)[0] = (UBYTE)(ULONG)((x) >> 8UL); \
35 (y)[1] = (UBYTE)(ULONG)((x));
37 /* Name of default keymap, the same as on AmigaOS, for compatibility */
38 #define DEFAULT_KEYMAP "usa"
40 /*********************************************************************************************/
52 UBYTE ip_PointerTicks
[2];
53 UBYTE ip_DoubleClick_secs
[4];
54 UBYTE ip_DoubleClick_micro
[4];
55 UBYTE ip_KeyRptDelay_secs
[4];
56 UBYTE ip_KeyRptDelay_micro
[4];
57 UBYTE ip_KeyRptSpeed_secs
[4];
58 UBYTE ip_KeyRptSpeed_micro
[4];
59 UBYTE ip_MouseAccel
[2];
60 UBYTE ip_ClassicKeyboard
[4];
61 char ip_KeymapName
[64];
62 UBYTE ip_SwitchMouseButtons
[4];
69 UBYTE kms_SwitchQual
[2];
70 UBYTE kms_SwitchCode
[2];
71 char kms_AltKeymap
[64];
87 #define KEYMAP_NAME_LEN 30
88 #define KEYMAP_FLAG_LEN 128
93 UBYTE layoutname
[KEYMAP_NAME_LEN
];
95 UBYTE displayflag
[KEYMAP_FLAG_LEN
];
100 struct ListviewEntry lve
;
103 /*********************************************************************************************/
105 void Prefs_ScanDirectory(STRPTR pattern
, struct List
*list
, LONG entrysize
);
106 BOOL
Prefs_ImportFH(BPTR fh
);
107 BOOL
Prefs_ExportFH(BPTR fh
);
108 BOOL
Prefs_Default(void);
109 BOOL
Prefs_HandleArgs(STRPTR from
, BOOL use
, BOOL save
);
111 /*********************************************************************************************/
113 extern struct timerequest
*InputIO
;
115 extern struct List keymap_list
;
116 extern struct InputPrefs inputprefs
;
117 extern struct KMSPrefs kmsprefs
;