Make "global" global.

Rather than doing "let global = Shell.Global.get()" everywhere we
need it, just create a global variable called "global".

http://bugzilla.gnome.org/show_bug.cgi?id=594546
This commit is contained in:
Dan Winship
2009-09-08 16:12:50 -04:00
parent 0882da0a71
commit d0d79c5b3e
13 changed files with 4 additions and 82 deletions

View File

@ -82,8 +82,6 @@ Overview.prototype = {
_init : function() {
let me = this;
let global = Shell.Global.get();
this._group = new Clutter.Group();
this._group._delegate = this;
@ -131,8 +129,6 @@ Overview.prototype = {
},
_recalculateGridSizes: function () {
let global = Shell.Global.get();
wideScreen = (global.screen_width/global.screen_height > WIDE_SCREEN_CUT_OFF_RATIO);
// We divide the screen into an imaginary grid which helps us determine the layout of
@ -147,8 +143,6 @@ Overview.prototype = {
},
relayout: function () {
let global = Shell.Global.get();
let screenHeight = global.screen_height;
let screenWidth = global.screen_width;
@ -277,8 +271,6 @@ Overview.prototype = {
this.visible = true;
this.animationInProgress = true;
let global = Shell.Global.get();
this._dash.show();
/* TODO: make this stuff dynamic */
@ -334,8 +326,6 @@ Overview.prototype = {
if (!this.visible || this._hideInProgress)
return;
let global = Shell.Global.get();
this.animationInProgress = true;
this._hideInProgress = true;
if (this._activeDisplayPane != null)
@ -425,8 +415,6 @@ Overview.prototype = {
},
_hideDone: function() {
let global = Shell.Global.get();
global.window_group.show();
this._workspaces.destroy();