D21561: [Notifier] Delay creating QNetworkConfigurationManager

2019-06-04 Thread Kai Uwe Broulik
This revision was automatically updated to reflect the committed changes. Closed by commit R134:89681ad47084: [Notifier] Delay creating QNetworkConfigurationManager (authored by broulik). REPOSITORY R134 Discover Software Store CHANGES SINCE LAST UPDATE https://phabricator.kde.org/D21561?vs=

D21561: [Notifier] Delay creating QNetworkConfigurationManager

2019-06-03 Thread Kai Uwe Broulik
broulik added a comment. As I feared, no matter if I disconnect, it's always `NetworkAccessible`, even with a stock QML app (i.e. without KIO AccessManager that KDeclarative injects). `QNetworkAccessManager` only checks the actual network session when the `QNetworkConfigurationManager::Netw

D21561: [Notifier] Delay creating QNetworkConfigurationManager

2019-06-03 Thread Kai Uwe Broulik
broulik added a comment. Sorry, misread you there. `networkAccessible` could work. It claims to reflect the actual device state and since the `QQmlEngine` already has its own `QNetworkAccessManager` we don't need to create one. I'll give it a go. REPOSITORY R134 Discover Software Store RE

D21561: [Notifier] Delay creating QNetworkConfigurationManager

2019-06-03 Thread Kai Uwe Broulik
broulik added a comment. In D21561#473937 , @davidedmundson wrote: > Is QNetworkAccessManager::networkAccessible any better? > > It has an unknown state which implies it might be async. It's the constructor that takes forever, doesn't

D21561: [Notifier] Delay creating QNetworkConfigurationManager

2019-06-03 Thread David Edmundson
davidedmundson added a comment. Is QNetworkAccessManager::networkAccessible any better? It has an unknown state which implies it might be async. REPOSITORY R134 Discover Software Store REVISION DETAIL https://phabricator.kde.org/D21561 To: broulik, #plasma, apol Cc: davidedmundson,

D21561: [Notifier] Delay creating QNetworkConfigurationManager

2019-06-03 Thread Aleix Pol Gonzalez
apol accepted this revision. apol added a comment. This revision is now accepted and ready to land. Yes, it's a big one. I was wondering if it would make sense to see if we can improve it on Qt level. INLINE COMMENTS > DiscoverNotifier.cpp:166 > { > +if (!m_manager) { > +m_

D21561: [Notifier] Delay creating QNetworkConfigurationManager

2019-06-03 Thread Kai Uwe Broulik
broulik created this revision. broulik added reviewers: Plasma, apol. Herald added a project: Plasma. Herald added a subscriber: plasma-devel. broulik requested review of this revision. REVISION SUMMARY Creating it is quite heavy (25ms here) as it has to query NetworkManager for information. R