[gnome-shell] overviewControls: Make visible and inDrag private
- From: Jasper St. Pierre <jstpierre src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-shell] overviewControls: Make visible and inDrag private
- Date: Wed, 30 Oct 2013 17:17:51 +0000 (UTC)
commit f3186bd501872bb743bf6f72cc38833db6be4688
Author: Jasper St. Pierre <jstpierre mecheye net>
Date: Wed Sep 18 19:06:56 2013 -0400
overviewControls: Make visible and inDrag private
These don't need to be accessed from outside SlidingControl,
so don't let them be.
js/ui/overviewControls.js | 22 +++++++++++-----------
1 files changed, 11 insertions(+), 11 deletions(-)
---
diff --git a/js/ui/overviewControls.js b/js/ui/overviewControls.js
index e499ecd..d388340 100644
--- a/js/ui/overviewControls.js
+++ b/js/ui/overviewControls.js
@@ -99,8 +99,8 @@ const SlidingControl = new Lang.Class({
_init: function(params) {
params = Params.parse(params, { slideDirection: SlideDirection.LEFT });
- this.visible = true;
- this.inDrag = false;
+ this._visible = true;
+ this._inDrag = false;
this.layout = new SlideLayout();
this.layout.slideDirection = params.slideDirection;
@@ -152,7 +152,7 @@ const SlidingControl = new Lang.Class({
let translationEnd = 0;
let translation = this._getTranslation();
- if (this.visible) {
+ if (this._visible) {
translationStart = translation;
} else {
translationEnd = translation;
@@ -169,7 +169,7 @@ const SlidingControl = new Lang.Class({
},
_onOverviewShowing: function() {
- this.visible = true;
+ this._visible = true;
this.layout.slideX = this.getSlide();
this.actor.translation_x = this._getTranslation();
this.slideIn();
@@ -188,13 +188,13 @@ const SlidingControl = new Lang.Class({
},
_onDragBegin: function() {
- this.inDrag = true;
+ this._inDrag = true;
this.actor.translation_x = 0;
this.updateSlide();
},
_onDragEnd: function() {
- this.inDrag = false;
+ this._inDrag = false;
this.updateSlide();
},
@@ -213,13 +213,13 @@ const SlidingControl = new Lang.Class({
},
slideIn: function() {
- this.visible = true;
+ this._visible = true;
this._updateTranslation();
// we will update slideX and the translation from pageEmpty
},
slideOut: function() {
- this.visible = false;
+ this._visible = false;
this._updateTranslation();
// we will update slideX from pageEmpty
},
@@ -256,7 +256,7 @@ const ThumbnailsSlider = new Lang.Class({
_getAlwaysZoomOut: function() {
// Always show the pager when hover, during a drag, or if workspaces are
// actually used, e.g. there are windows on more than one
- let alwaysZoomOut = this.actor.hover || this.inDrag || !Meta.prefs_get_dynamic_workspaces() ||
global.screen.n_workspaces > 2;
+ let alwaysZoomOut = this.actor.hover || this._inDrag || !Meta.prefs_get_dynamic_workspaces() ||
global.screen.n_workspaces > 2;
if (!alwaysZoomOut) {
let monitors = Main.layoutManager.monitors;
@@ -282,7 +282,7 @@ const ThumbnailsSlider = new Lang.Class({
},
getSlide: function() {
- if (!this.visible)
+ if (!this._visible)
return 0;
let alwaysZoomOut = this._getAlwaysZoomOut();
@@ -329,7 +329,7 @@ const DashSlider = new Lang.Class({
},
getSlide: function() {
- if (this.visible || this.inDrag)
+ if (this._visible || this._inDrag)
return 1;
else
return 0;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]