Skip to content

Commit

Permalink
ui: don't lock setting when an error occurs
Browse files Browse the repository at this point in the history
  • Loading branch information
pfps committed Feb 10, 2024
1 parent b3bc932 commit 4d7b6a0
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/solaar/ui/config_panel.py
Original file line number Diff line number Diff line change
Expand Up @@ -711,15 +711,15 @@ def _create_sbox(s, device):
def _update_setting_item(sbox, value, is_online=True, sensitive=True, nullOK=False):
# sbox._spinner.set_visible(False) # don't repack item box
sbox._spinner.stop()
sensitive = sbox._change_icon._allowed if sensitive is None else sensitive
if value is None and not nullOK:
sbox._control.set_sensitive(False)
_change_icon(False, sbox._change_icon)
sbox._control.set_sensitive(sensitive is True)
_change_icon(sensitive, sbox._change_icon)
sbox._failed.set_visible(is_online)
return
sbox._failed.set_visible(False)
sbox._control.set_sensitive(False)
sbox._control.set_value(value)
sensitive = sbox._change_icon._allowed if sensitive is None else sensitive
sbox._control.set_sensitive(sensitive is True)
_change_icon(sensitive, sbox._change_icon)

Expand Down

0 comments on commit 4d7b6a0

Please sign in to comment.