appDisplay: Remove redundant checks for pageNumber
We already do these at the beginning of the function. https://bugzilla.gnome.org/show_bug.cgi?id=729064
This commit is contained in:
parent
1c8036b863
commit
551e57406d
@ -472,14 +472,12 @@ const AllView = new Lang.Class({
|
||||
// longer than PAGE_SWITCH_TIME
|
||||
time = Math.min(time, PAGE_SWITCH_TIME);
|
||||
|
||||
if (pageNumber < this._grid.nPages() && pageNumber >= 0) {
|
||||
this._currentPage = pageNumber;
|
||||
Tweener.addTween(this._adjustment,
|
||||
{ value: this._grid.getPageY(this._currentPage),
|
||||
time: time,
|
||||
transition: 'easeOutQuad' });
|
||||
this._pageIndicators.setCurrentPage(pageNumber);
|
||||
}
|
||||
this._currentPage = pageNumber;
|
||||
Tweener.addTween(this._adjustment,
|
||||
{ value: this._grid.getPageY(this._currentPage),
|
||||
time: time,
|
||||
transition: 'easeOutQuad' });
|
||||
this._pageIndicators.setCurrentPage(pageNumber);
|
||||
},
|
||||
|
||||
_diffToPage: function (pageNumber) {
|
||||
|
Loading…
Reference in New Issue
Block a user