Yaroslav Chvanov
fe73bb34ef
sinowealth: add support for button actions in macros
2022-12-23 02:52:00 +03:00
Yaroslav Chvanov
0bdd0e71ba
sinowealth: improve error handling
...
- No more arbitrary error codes, use POSIX error codes.
- Bubble errors up.
- Add strerror() wherever errno is printed.
2022-12-23 02:52:00 +03:00
Yaroslav Chvanov
46711b3624
sinowealth: refactor sinowealth_update_macro_from_action()
...
Reading it was giving me head-ache. This still doesn't feel perfect but
it's already better.
2022-12-23 02:52:00 +03:00
Yaroslav Chvanov
c48320134e
sinowealth: fix a missing new line in logging
2022-12-23 02:52:00 +03:00
Yaroslav Chvanov
0da7cc10b0
sinowealth: add support for reading 2 profiles (if a macro is set)
...
For what it's worth, all of this may not even belong in libratbag - this
is never going to be shipped to end users, only if someone modifies the
source code. In other words all of this is basically dead code, it's
just me trying to figure out the internal of SinoWealth devices.
2022-12-23 02:52:00 +03:00
Yaroslav Chvanov
4621e1016a
sinowealth: deduplicate the code of reading configuration data
2022-12-23 02:52:00 +03:00
Yaroslav Chvanov
da92117973
sinowealth: fix a typo
2022-12-23 02:52:00 +03:00
Yaroslav Chvanov
36af0009bd
sinowealth: assert instead of silently ignoring an error
2022-12-23 02:51:59 +03:00
Yaroslav Chvanov
f23f2bfbfb
sinowealth: simply return a bool instead of 0 or 1
2022-12-23 02:51:59 +03:00
Yaroslav Chvanov
007fa34c87
sinowealth: make all casts explicit
2022-12-23 02:51:59 +03:00
Yaroslav Chvanov
a018207728
sinowealth: fix some variable types
2022-12-23 02:51:59 +03:00
Yaroslav Chvanov
e18baf6f36
sinowealth: use non-GNU-specific empty array initializer
2022-12-23 02:51:59 +03:00
Yaroslav Chvanov
991cf92594
sinowealth: print a warning if there are too much events in a macro
2022-12-23 02:51:47 +03:00
Yaroslav Chvanov
a493575daa
test: add device data tests for the steelseries driver
2022-12-22 03:38:31 +03:00
Yaroslav Chvanov
c7e2e13ee0
test: add device data tests for the asus driver
2022-12-22 03:38:25 +03:00
Yaroslav Chvanov
d6b6b0d12c
test: make check_section_driver() a bit more diff-friendly
2022-12-22 03:38:09 +03:00
Yaroslav Chvanov
9450ce18e1
test: increase max DPI in check_dpi_range_str() to 36000
...
o_O
2022-12-22 03:38:06 +03:00
Yaroslav Chvanov
10f03eaf0e
test: fix incorrect character escaping in data-parse-test
2022-12-22 03:04:01 +03:00
Yaroslav Chvanov
8e798c74c9
test: data-parse-test: check all files even if there is an error
2022-12-22 03:03:59 +03:00
Yaroslav Chvanov
c6005b2cb8
test: fix formatting
2022-12-22 02:49:10 +03:00
Yaroslav Chvanov
e2ee8185c2
build: fix data tests not running
...
This will also help with out-of-tree builds.
2022-12-22 02:22:59 +03:00
Yaroslav Chvanov
be79267f9d
test: work-around unsupported Driver section of the sinowealth driver
2022-12-22 02:22:59 +03:00
Yaroslav Chvanov
38d10977b6
test: add wheel to the list of permitted LED types
2022-12-22 02:22:59 +03:00
Yaroslav Chvanov
8a7474b1bd
data: fix missing Driver field
2022-12-22 02:22:29 +03:00
Yaroslav Chvanov
1e4c1d73b8
test: add type hints to data-parse-test
...
This will help us prevent errors like in
41c655090ce9f709db4f7069777741a6b5384d24 in the future.
2022-12-22 02:18:42 +03:00
Yaroslav Chvanov
99bbbfb0b5
test: fix incorrect type of file paths in data-parse-test
...
Seems like the API of pathlib changed at some point.
2022-12-22 02:18:41 +03:00
Yaroslav Chvanov
0b8f4a25b1
tools: put the list of possible button action types into a const
2022-12-22 00:52:05 +03:00
Yaroslav Chvanov
72c1a29f28
ratbagd: fix formatting
2022-12-22 00:52:05 +03:00
Yaroslav Chvanov
9485ab6c1f
ratbagd: use NULL instead of 0 for pointers
2022-12-22 00:52:05 +03:00
Yaroslav Chvanov
3b0ac12cc7
ratbagctl: add an error message if the key supplied to macro is wrong
2022-12-22 00:52:05 +03:00
Kyoken
39b6178d92
fix typo in macro bindings
2022-12-22 00:52:05 +03:00
Kyoken
49b9ad5647
use key name instead of code for binding
2022-12-22 00:52:05 +03:00
Kyoken
434b0537b5
fix ratbag-command key bindings
2022-12-22 00:52:05 +03:00
Kyoken
2eeacc354f
implement key bindings feature
2022-12-22 00:51:59 +03:00
Yaroslav Chvanov
8bacfe9ee6
build: bump ratbagd DBus API version
2022-12-22 00:46:03 +03:00
Yaroslav Chvanov
0f39b0f1e9
asus: use ARRAY_FOR_EACH
2022-12-20 04:44:04 +03:00
Yaroslav Chvanov
8c528b2ec0
asus: make pointer variables const wherever possible
...
Also fixes `ASUS_BUTTON_MAPPING` being duplicated between different
source files if I understand C right.
2022-12-20 04:44:04 +03:00
Yaroslav Chvanov
0656d7896c
libratbag-data: fix formatting
2022-12-20 04:44:03 +03:00
Peter Oliver
4319466aed
Adjust offered resolutions for SteelSeries Kinzu V3
...
Fixes #1386 .
2022-12-19 20:02:29 +00:00
TCH
d3c62a0d67
data: add Logitech MX Master 3S
2022-12-12 08:40:27 +10:00
Kyoken
67ab803657
asus: pugio button mapping
2022-12-09 10:01:21 +03:00
Kyoken
4187aa4123
asus: allow empty cells in bindings table and fix pugio button bindings
2022-12-07 23:32:03 +03:00
lennie420
919cde2b15
Logitech G303 Shroud Edition device file
...
Adds basic support for Logitech G303 Shroud Edition
2022-11-26 00:55:05 +03:00
Kyoken
f9286536f8
asus: fix button mapping type
2022-11-26 00:46:37 +03:00
Kyoken
0cf97d40af
asus: handle undefined buttons
2022-11-26 00:46:37 +03:00
Kyoken
b93900bd91
asus: rename params
2022-11-26 00:46:37 +03:00
Red_M
6476cd000a
Fix spatha x device file.
2022-11-26 00:46:37 +03:00
Kyoken
e628b50abf
asus: add spatha x
2022-11-26 00:46:37 +03:00
Kyoken
3e5ac899ae
asus: fix building errors
2022-11-26 00:46:37 +03:00
Kyoken
041a8023b8
asus: button mapping reworked
2022-11-26 00:46:32 +03:00