[geary/wip/17-noisy-problem-reports: 8/12] Don't consider service state unknown to be offline
- From: Michael Gratton <mjog src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [geary/wip/17-noisy-problem-reports: 8/12] Don't consider service state unknown to be offline
- Date: Tue, 1 Jan 2019 11:30:24 +0000 (UTC)
commit 0e9f18c45bec3e4c1e8e780d5c7a63085ae81c87
Author: Michael Gratton <mike vee net>
Date: Tue Jan 1 21:28:16 2019 +1100
Don't consider service state unknown to be offline
This prevents the offline info bar showing up on first start or when
restarting services.
src/engine/api/geary-account.vala | 8 ++++++--
1 file changed, 6 insertions(+), 2 deletions(-)
---
diff --git a/src/engine/api/geary-account.vala b/src/engine/api/geary-account.vala
index cbce1282..8a9aaeb7 100644
--- a/src/engine/api/geary-account.vala
+++ b/src/engine/api/geary-account.vala
@@ -538,8 +538,12 @@ public abstract class Geary.Account : BaseObject {
private void on_service_status_notify() {
Status new_status = 0;
- if (incoming.current_status != UNKNOWN &&
- incoming.current_status != UNREACHABLE) {
+ // Don't consider service status UNKNOWN to indicate being
+ // offline, since clients will indicate offline status, but
+ // not indicate online status. So when at startup, or when
+ // restarting services, we don't want to cause them to
+ // spuriously indicate being offline.
+ if (incoming.current_status != UNREACHABLE) {
new_status |= ONLINE;
}
if (incoming.current_status.is_error() ||
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]