implement property deletion handling; activate scheduler deletion

This commit is contained in:
Jakob Ketterl
2021-02-26 01:12:03 +01:00
parent 91c4d6f568
commit 412e0a51c7
8 changed files with 102 additions and 25 deletions

View File

@ -9,7 +9,7 @@ from owrx.version import openwebrx_version
from owrx.bands import Bandplan
from owrx.bookmarks import Bookmarks
from owrx.map import Map
from owrx.property import PropertyStack
from owrx.property import PropertyStack, PropertyDeleted
from owrx.modes import Modes, DigitalMode
from owrx.config import Config
from owrx.waterfall import WaterfallOptions
@ -176,7 +176,8 @@ class OpenWebRxReceiverClient(OpenWebRxClient, SdrSourceEventClient):
if changes is None:
config = configProps.__dict__()
else:
config = changes
# transform deletions into Nones
config = {k: v if v is not PropertyDeleted else None for k, v in changes.items()}
if (
(changes is None or "start_freq" in changes or "center_freq" in changes)
and "start_freq" in configProps