Commit Graph

309 Commits

Author SHA1 Message Date
Sascha Hlusiak
7f6e390fb1 Use preset keyboard layout instead of custom generated keymap.
Restored compatibility with recent xkb changes and xorg-server-1.7.
Keys are configured now using scancodes instead of keysyms. Depends on
set keymap; people could write custom layouts.
2009-04-11 14:19:58 +02:00
Sascha Hlusiak
4fbfcb17d6 Remove parsing of keysyms.
Key options are expected to be scancodes/plain numbers now.
2009-04-11 13:13:16 +02:00
Sascha Hlusiak
7c677b3d26 Remove ks_tables.h
No more keysym parsing
2009-04-11 13:12:17 +02:00
Sascha Hlusiak
8075ee4808 Remove parsing of keysyms
Change of configuration semantics again. Keys are specified in scancodes instead of keysyms.
2009-04-11 13:11:24 +02:00
Sascha Hlusiak
e171007239 Fix compiler warning about stray INT8-CARD8 conversion 2009-03-19 21:14:22 +01:00
Sascha Hlusiak
7af61c78fd Merge branch 'pwm' 2009-03-19 21:13:13 +01:00
Sascha Hlusiak
bc430cc2aa Missing initialization of button amplify
Always initialize button[]->amplify with 1.0
2009-03-19 21:08:30 +01:00
Sascha Hlusiak
dca19bde2b Merge branch 'master' of sascha:develop/xorg/xf86-input-joystick 2009-03-19 08:36:10 +01:00
Sascha Hlusiak
4b9aafd82b Mention PWM mode in man page 2009-03-18 18:13:12 +01:00
Sascha Hlusiak
6f2a211b7c Fix build on FreeBSD with USB2
Including dev/usb/usb_ioctl.h fixes missing declaration
of USB_GET_REPORT_ID on FreeBSD-Current.
2009-03-18 17:39:07 +01:00
Sascha Hlusiak
c6217b5849 Comment float properties in joystick-properties.h
Signed-off-by: Sascha Hlusiak <saschahlusiak@arcor.de>
2009-03-01 21:06:52 +01:00
Sascha Hlusiak
367c32bab5 Support for float properties
Signed-off-by: Sascha Hlusiak <saschahlusiak@arcor.de>
2009-03-01 21:00:18 +01:00
Sascha Hlusiak
4978e78e7c Add PWM key generation when axis in accelerated mode
When axis is in accelerated mode and keyhigh/keylow is set,
the deflection of the axis will be linked to the _percent of time_ the key
will be down. Full deflection will set the key permanently down (old behaviour).

50% deflection will result in the key being  50ms down and 50ms up.
75% deflection will result in the key being 150ms down and 50ms up.
etc.
Minimum interval is 50ms, maximum is 600ms.
2009-02-19 23:40:58 +01:00
Sascha Hlusiak
d4bb86ddb0 Don't set axis.oldvalue in backend
The value needs to be set where it's needed, like in timers.
2009-02-19 23:37:46 +01:00
Sascha Hlusiak
4ec4376522 Fix for sparse warning of uninitialized variable
If axis is inside deadzone, 0.0 should be assumed.
2009-02-17 20:18:05 +01:00
Paulo Cesar Pereira de Andrade
b70b1f7d82 Janitor: gcc 4.5 and sparse warnings.
It is still required a patch in the X Server sdk to correct some
remaining warnings. Isn't it amazing that <X11/extensions/XKBsrv.h>
and $sdkdir/xkbsrv.h both use the #ifndef _XKBSRV_H_ include guard?

Signed-off-by: Paulo Cesar Pereira de Andrade <pcpa@mandriva.com.br>
2009-02-17 20:15:18 +01:00
Paulo Cesar Pereira de Andrade
76b82a41a6 Janitor: make distcheck, .gitignore.
The correction for make distcheck uses the same solution proposed
for xf86-input-evdev, that uses the new configure option --with-sdkdir.

Signed-off-by: Paulo Cesar Pereira de Andrade <pcpa@mandriva.com.br>
2009-02-17 20:06:44 +01:00
Sascha Hlusiak
4671904035 Use InitKeyboardDeviceStruct instead of nonexistant XkbInitKeyboardDeviceStruct
Realizing XkbInitKeyboardDeviceStruct has been removed, we do need to use InitKeyboardDeviceStruct.
This breaks custom keymaps on ABI_XINPUT_VERSION >= 5.

Hopefully this can be reimplemented later.
2009-02-02 00:10:42 +01:00
Alan Coopersmith
3984947ada Add README with pointers to mailing list, bugzilla & git repos 2009-01-30 20:23:09 -08:00
Sascha Hlusiak
fb632ba226 Fix build on master. All hail XKB! 2009-01-26 20:48:00 +01:00
Alan Coopersmith
f62159e4df Remove xorgconfig & xorgcfg from See Also list in man page 2009-01-09 16:14:12 -08:00
Sascha Hlusiak
43e2f05268 Prepare for 1.4.0 release xf86-input-joystick-1.4.0 2008-12-28 18:57:36 +01:00
Sascha Hlusiak
fd80f1c2b5 Matched comments in joystick-properties.h with previous commit 2008-12-28 17:32:44 +01:00
Sascha Hlusiak
f81b9077d1 Export JSTK_* constants with joystick-properties.h 2008-12-28 17:28:50 +01:00
Sascha Hlusiak
79028fc80f Rename constants for better distinction
@jstk.h:
    TYPE_* -> JSTK_TYPE_*
    MAPPING_* -> JSTK_MAPPING_*
2008-12-28 17:24:08 +01:00
Peter Hutterer
38b4c9b3bd properties: handle checkonly flag in SetProperty.
If checkonly is TRUE, don't touch any values, just check vor validity of the
data.

Signed-off-by: Sascha Hlusiak <saschahlusiak@arcor.de>
2008-10-13 08:49:23 +02:00
Sascha Hlusiak
0da072fde4 Install joystick-properties.h and xorg-joystick.pc for clients.
Let's clients be aware of properties made available by the driver.
2008-10-01 23:14:22 +02:00
Sascha Hlusiak
3c2a323a3a Option for per-axis valuators. Defaults to off for all axes.
Old: Each axis had an extra valuator, starting with 2 (0 and 1 are pointer movement)
New: Add "valuator" to axis option to give it an extra valuator of range -32768 to 32768.
Default: Off for all axes, since rarely used (and broken anyway right now).
2008-10-01 21:43:49 +02:00
Sascha Hlusiak
432805db42 Remove XKB calls since we don't make use of it anyway.
No error messages because of missing xkb rules, yay.
2008-09-30 19:02:17 +02:00
Sascha Hlusiak
8a5b8e08aa Do not require randrproto 2008-09-30 18:35:27 +02:00
Sascha Hlusiak
ba8ea1799c Support for setting Button Number property
does not change the button map, which is assumed to be default. Buttons can still be
reordered using xmodmap.
2008-09-30 18:13:19 +02:00
Sascha Hlusiak
5c72d14686 Replace dynamic button map with static one
Saves some configuration efforts but caps logical button numbers to BUTTONMAP_SIZE=32.
Makes property support much easier.
2008-09-30 18:08:04 +02:00
Sascha Hlusiak
03175f968c Name all properties uppercase
Just looks better
2008-09-30 00:35:01 +02:00
Sascha Hlusiak
34ca7d2683 Do not accept fewer values anymore when setting properties
Supplied number of values have to match the numbers of axes/buttons exactly. Fewer values are not accepted
anymore, because the omitted information get lost. That way we ensure that the properties are always complete
when requested by clients.
2008-09-30 00:30:24 +02:00
Sascha Hlusiak
e1c3b5e304 Exporting num_axes values instead of MAXAXES
Only export the number of axes/buttons in properties that we actually have.
No need to export MAXAXES values, if we don't support them.
2008-09-30 00:17:41 +02:00
Sascha Hlusiak
ab79083b13 Save probed number of axes/buttons for joystick backend 2008-09-30 00:01:38 +02:00
Sascha Hlusiak
e8432b7f8e Probed number of buttons shall not exceed MAXBUTTONS
Same for axes.
2008-09-30 00:01:16 +02:00
Sascha Hlusiak
06c607ebc1 Compile fix on BSD 2008-09-29 23:47:53 +02:00
Sascha Hlusiak
f4be58b1ea Probe device once on INIT and re-use found information.
Makes reopening a device on vt-enter much smoother and throws less warnings.
Remember number of found axes and buttons.
2008-09-29 23:36:12 +02:00
Sascha Hlusiak
b56085c73d Export number of configurable buttons/axes as readonly properties.
This number does not need to match the number of valuators/buttons.
2008-09-29 22:56:29 +02:00
Sascha Hlusiak
ebf31b61b3 jstk_key.c: missing include
xf86optionListDup is defined in xf86Optrec.h
2008-09-28 16:41:17 +02:00
Peter Hutterer
3794afd978 Adjust joystick properties to new property API.
ConfigureProperty doesn't exist anymore, ChangeProperty has two parameters
less. SetProperty handler must return Status.
Mark all properties as non-deletable.
2008-09-26 17:21:16 +09:30
Sascha Hlusiak
6e635e394a Merge branch 'input-properties'
Conflicts:
	src/jstk.h
	src/jstk_key.c
2008-09-16 20:58:40 +02:00
Sascha Hlusiak
a1b87df15d Set type_name of slave keyboard device to XI_JOYSTICK as well. 2008-09-15 19:29:07 +02:00
Sascha Hlusiak
57d1201f58 Set type_name to XI_JOYSTICK. Let's not claim we are XI_MOUSE. 2008-09-15 19:27:52 +02:00
Sascha Hlusiak
f04e3c8222 Set type_name to XI_JOYSTICK. Let's not claim we are XI_MOUSE. 2008-09-15 19:24:40 +02:00
Christoph Brill
282fc3068e Make "less joystick.man" work 2008-09-07 11:11:50 +02:00
Sascha Hlusiak
838dfffe98 Initialize PtrFeedbackClassDeviceStruct for pointer device 2008-09-06 19:05:29 +02:00
Sascha Hlusiak
f691491bc9 Silence warning about implicit cast 2008-09-06 19:03:52 +02:00
Sascha Hlusiak
911986c4c7 Always add second input device for keys only
Having one device for both mouse and keyboard events breaks with MPX and custom keymaps, because the keymap is
copied to the core pointer instead of the core keyboard.

Easiest fix for that is to have two separate input devices. One single instance of the driver will now create
a second input device that has only keyboard capabilities. It shares all the config with the master and will
be removed when the master device is removed.

The creation of this second device is a little hack-ish. I hope things are done right.
2008-09-06 17:26:32 +02:00