Don't start new components when activating the screen-shield in gdm
Previous code was activating the networkAgent and telepathyClient in the lock-screen, irrespective of the previous mode. Now it checks if the session mode is locked down, and if so it refuses to start new components. https://bugzilla.gnome.org/show_bug.cgi?id=683400
This commit is contained in:
parent
011c9d1beb
commit
f957ae71c3
@ -41,6 +41,9 @@ const ComponentManager = new Lang.Class({
|
|||||||
if (component)
|
if (component)
|
||||||
return component;
|
return component;
|
||||||
|
|
||||||
|
if (Main.sessionMode.isLocked)
|
||||||
|
return null;
|
||||||
|
|
||||||
let constructor = this._importComponent(name);
|
let constructor = this._importComponent(name);
|
||||||
component = new constructor();
|
component = new constructor();
|
||||||
this._allComponents[name] = component;
|
this._allComponents[name] = component;
|
||||||
@ -49,7 +52,8 @@ const ComponentManager = new Lang.Class({
|
|||||||
|
|
||||||
_enableComponent: function(name) {
|
_enableComponent: function(name) {
|
||||||
let component = this._ensureComponent(name);
|
let component = this._ensureComponent(name);
|
||||||
component.enable();
|
if (component)
|
||||||
|
component.enable();
|
||||||
},
|
},
|
||||||
|
|
||||||
_disableComponent: function(name) {
|
_disableComponent: function(name) {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user