# HG changeset patch # User Marco Filippi iz3gme.marco@gmail.com # Date 1398244915 -7200 # mer apr 23 11:21:55 2014 +0200 # Node ID 9ce1da058a19da9107127f351a52f8f8cf4f9ef7 # Parent e51624d6ad4b7cb72a3554356d71f26cfe503adb [BF-888] Fix BCL and Scramble editing
BCL and Scramble was always enabled on edited memories because setting.values is of <type 'instance'> so not setting.values as well as not(bool(setting.values)) always return false, coerce to int instead pickup the value of the instance so not(int(setting.values)) do the job
Fix #1549
diff --git a/chirp/h777.py b/chirp/h777.py --- a/chirp/h777.py +++ b/chirp/h777.py @@ -379,7 +379,7 @@
for setting in mem.extra: # NOTE: Only two settings right now, both are inverted - setattr(_mem, setting.get_name(), not setting.value) + setattr(_mem, setting.get_name(), not int(setting.value))
def get_settings(self): _settings = self._memobj.settings