From c6d1ab452676dbbf376e40464e8fff539df1ec53 Mon Sep 17 00:00:00 2001 From: Daniel Pavel Date: Fri, 2 Nov 2012 22:07:35 +0200 Subject: [PATCH] fix for starting the application with no receiver connected --- app/receiver.py | 6 +++--- app/solaar.py | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/app/receiver.py b/app/receiver.py index ca3431af..1d816e38 100644 --- a/app/receiver.py +++ b/app/receiver.py @@ -120,8 +120,8 @@ class DeviceInfo(_api.PairedDevice): self.features = _FeaturesArray(self) # read them now, otherwise it it temporarily hang the UI - if status >= STATUS.CONNECTED: - n, k, s, f = self.name, self.kind, self.serial, self.firmware + # if status >= STATUS.CONNECTED: + # n, k, s, f = self.name, self.kind, self.serial, self.firmware @property def receiver(self): @@ -381,7 +381,7 @@ class ReceiverListener(_EventsListener): class _DUMMY_RECEIVER(object): __slots__ = ['name', 'max_devices', 'status', 'status_text', 'devices'] - name = _api.Receiver.name + name = kind = _api.Receiver.name max_devices = _api.Receiver.max_devices status = STATUS.UNAVAILABLE status_text = _RECEIVER_STATUS_NAME[STATUS.UNAVAILABLE] diff --git a/app/solaar.py b/app/solaar.py index acc231f2..4458c341 100644 --- a/app/solaar.py +++ b/app/solaar.py @@ -87,7 +87,7 @@ if __name__ == '__main__': if listener is None: pairing.state = None if notify_missing: - status_changed(DUMMY, True) + status_changed(DUMMY, None, True) notify_missing = False return retry