cli: allow for new_fn_inversion call to fail
This commit is contained in:
parent
2f870fe0f7
commit
a7ddb3efdd
|
@ -196,9 +196,11 @@ def _print_device(dev, num=None):
|
||||||
if wheel_status:
|
if wheel_status:
|
||||||
print(' Wheel Reports: %s' % wheel_status)
|
print(' Wheel Reports: %s' % wheel_status)
|
||||||
elif feature == _hidpp20.FEATURE.NEW_FN_INVERSION:
|
elif feature == _hidpp20.FEATURE.NEW_FN_INVERSION:
|
||||||
inverted, default_inverted = _hidpp20.get_new_fn_inversion(dev)
|
inversion = _hidpp20.get_new_fn_inversion(dev)
|
||||||
print(' Fn-swap:', 'enabled' if inverted else 'disabled')
|
if inversion:
|
||||||
print(' Fn-swap default:', 'enabled' if default_inverted else 'disabled')
|
inverted, default_inverted = inversion
|
||||||
|
print(' Fn-swap:', 'enabled' if inverted else 'disabled')
|
||||||
|
print(' Fn-swap default:', 'enabled' if default_inverted else 'disabled')
|
||||||
elif feature == _hidpp20.FEATURE.HOSTS_INFO:
|
elif feature == _hidpp20.FEATURE.HOSTS_INFO:
|
||||||
host_names = _hidpp20.get_host_names(dev)
|
host_names = _hidpp20.get_host_names(dev)
|
||||||
for host, (paired, name) in host_names.items():
|
for host, (paired, name) in host_names.items():
|
||||||
|
|
Loading…
Reference in New Issue