networkAgent: Support NM versions without :capabilities
Commit 926de53c0cbd7ae5 bumped the requirement for NetworkManager, which is problematic on a stable branch; optionally fall back to the previous code. https://bugzilla.gnome.org/show_bug.cgi?id=738485
This commit is contained in:
parent
1e7b2ef51f
commit
e21e90c5e6
@ -604,9 +604,15 @@ const NetworkAgent = new Lang.Class({
|
||||
Name: 'NetworkAgent',
|
||||
|
||||
_init: function() {
|
||||
this._native = new Shell.NetworkAgent({ identifier: 'org.gnome.Shell.NetworkAgent',
|
||||
capabilities: NMClient.SecretAgentCapabilities.VPN_HINTS
|
||||
});
|
||||
try {
|
||||
this._native = new Shell.NetworkAgent({ identifier: 'org.gnome.Shell.NetworkAgent',
|
||||
capabilities: NMClient.SecretAgentCapabilities.VPN_HINTS
|
||||
});
|
||||
} catch(e) {
|
||||
// Support older versions without NetworkAgent:capabilities
|
||||
this._native = new Shell.NetworkAgent({ identifier: 'org.gnome.Shell.NetworkAgent'
|
||||
});
|
||||
}
|
||||
|
||||
this._dialogs = { };
|
||||
this._vpnRequests = { };
|
||||
|
Loading…
x
Reference in New Issue
Block a user