windowManager: Handle missing overrides settings
shell_global_get_overrides_settings() may return %NULL in case of custom shell modes (i.e. not the default and classic ones); while this is not officially encouraged, we should still handle it rather than throw an error. https://bugzilla.gnome.org/show_bug.cgi?id=751921
This commit is contained in:
parent
ef7541291b
commit
dfc4cc4aaf
@ -217,7 +217,8 @@ const WorkspaceTracker = new Lang.Class({
|
||||
|
||||
_getWorkspaceSettings: function() {
|
||||
let settings = global.get_overrides_settings();
|
||||
if (settings.settings_schema.list_keys().indexOf('dynamic-workspaces') > -1)
|
||||
if (settings &&
|
||||
settings.settings_schema.list_keys().indexOf('dynamic-workspaces') > -1)
|
||||
return settings;
|
||||
return new Gio.Settings({ schema_id: 'org.gnome.mutter' });
|
||||
},
|
||||
|
Loading…
Reference in New Issue
Block a user