diff --git a/lib/logitech_receiver/settings_templates.py b/lib/logitech_receiver/settings_templates.py index daa0cc17..65fa2700 100644 --- a/lib/logitech_receiver/settings_templates.py +++ b/lib/logitech_receiver/settings_templates.py @@ -949,11 +949,7 @@ class Gesture2Params(_LongSettings): rw_options = {'read_fnid': 0x70, 'write_fnid': 0x80} choices_universe = None - class ParamWrapper: - def get(self, name, default=None): - return _GESTURE2_PARAMS_LABELS.get(name.param, default) - - _labels = ParamWrapper() + _labels = _GESTURE2_PARAMS_LABELS _labels_sub = _GESTURE2_PARAMS_LABELS_SUB class validator_class(_MultipleRangeV): diff --git a/lib/solaar/ui/config_panel.py b/lib/solaar/ui/config_panel.py index 61da9b26..0d7849cf 100644 --- a/lib/solaar/ui/config_panel.py +++ b/lib/solaar/ui/config_panel.py @@ -356,7 +356,7 @@ class MultipleRangeControl(Gtk.ListBox, MultipleControl): lbl_text = str(item) lbl_tooltip = None if hasattr(sbox.setting, '_labels'): - l1, l2 = sbox.setting._labels.get(item, (None, None)) + l1, l2 = sbox.setting._labels.get(int(item), (None, None)) lbl_text = l1 if l1 else lbl_text lbl_tooltip = l2 if l2 else lbl_tooltip item_lbl = Gtk.Label(lbl_text)