cleanup: Use milliseconds for animation times
The different units - seconds for Tweener and milliseconds for timeouts - are not a big issue currently, as there is little overlap. However this will change when we start using Clutter's own animation framework (which uses milliseconds as well), in particular where constants are shared between modules. In order to prepare for the transition, define all animation times as milliseconds and adjust them when passing them to Tweener. https://gitlab.gnome.org/GNOME/gnome-shell/merge_requests/663
This commit is contained in:
parent
31968ea53c
commit
476816732f
@ -12,10 +12,10 @@ const Tweener = imports.ui.tweener;
|
|||||||
const UserWidget = imports.ui.userWidget;
|
const UserWidget = imports.ui.userWidget;
|
||||||
|
|
||||||
var DEFAULT_BUTTON_WELL_ICON_SIZE = 16;
|
var DEFAULT_BUTTON_WELL_ICON_SIZE = 16;
|
||||||
var DEFAULT_BUTTON_WELL_ANIMATION_DELAY = 1.0;
|
var DEFAULT_BUTTON_WELL_ANIMATION_DELAY = 1000;
|
||||||
var DEFAULT_BUTTON_WELL_ANIMATION_TIME = 0.3;
|
var DEFAULT_BUTTON_WELL_ANIMATION_TIME = 300;
|
||||||
|
|
||||||
var MESSAGE_FADE_OUT_ANIMATION_TIME = 0.5;
|
var MESSAGE_FADE_OUT_ANIMATION_TIME = 500;
|
||||||
|
|
||||||
var AuthPromptMode = {
|
var AuthPromptMode = {
|
||||||
UNLOCK_ONLY: 0,
|
UNLOCK_ONLY: 0,
|
||||||
@ -292,8 +292,8 @@ var AuthPrompt = class {
|
|||||||
} else {
|
} else {
|
||||||
Tweener.addTween(oldActor,
|
Tweener.addTween(oldActor,
|
||||||
{ opacity: 0,
|
{ opacity: 0,
|
||||||
time: DEFAULT_BUTTON_WELL_ANIMATION_TIME,
|
time: DEFAULT_BUTTON_WELL_ANIMATION_TIME / 1000,
|
||||||
delay: DEFAULT_BUTTON_WELL_ANIMATION_DELAY,
|
delay: DEFAULT_BUTTON_WELL_ANIMATION_DELAY / 1000,
|
||||||
transition: 'linear',
|
transition: 'linear',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
if (wasSpinner) {
|
if (wasSpinner) {
|
||||||
@ -314,8 +314,8 @@ var AuthPrompt = class {
|
|||||||
else
|
else
|
||||||
Tweener.addTween(actor,
|
Tweener.addTween(actor,
|
||||||
{ opacity: 255,
|
{ opacity: 255,
|
||||||
time: DEFAULT_BUTTON_WELL_ANIMATION_TIME,
|
time: DEFAULT_BUTTON_WELL_ANIMATION_TIME / 1000,
|
||||||
delay: DEFAULT_BUTTON_WELL_ANIMATION_DELAY,
|
delay: DEFAULT_BUTTON_WELL_ANIMATION_DELAY / 1000,
|
||||||
transition: 'linear' });
|
transition: 'linear' });
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -368,7 +368,7 @@ var AuthPrompt = class {
|
|||||||
Tweener.removeTweens(this._message);
|
Tweener.removeTweens(this._message);
|
||||||
Tweener.addTween(this._message,
|
Tweener.addTween(this._message,
|
||||||
{ opacity: 0,
|
{ opacity: 0,
|
||||||
time: MESSAGE_FADE_OUT_ANIMATION_TIME,
|
time: MESSAGE_FADE_OUT_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad'
|
transition: 'easeOutQuad'
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -34,8 +34,8 @@ const Realmd = imports.gdm.realmd;
|
|||||||
const Tweener = imports.ui.tweener;
|
const Tweener = imports.ui.tweener;
|
||||||
const UserWidget = imports.ui.userWidget;
|
const UserWidget = imports.ui.userWidget;
|
||||||
|
|
||||||
const _FADE_ANIMATION_TIME = 0.25;
|
const _FADE_ANIMATION_TIME = 250;
|
||||||
const _SCROLL_ANIMATION_TIME = 0.5;
|
const _SCROLL_ANIMATION_TIME = 500;
|
||||||
const _TIMED_LOGIN_IDLE_THRESHOLD = 5.0;
|
const _TIMED_LOGIN_IDLE_THRESHOLD = 5.0;
|
||||||
const _LOGO_ICON_HEIGHT = 48;
|
const _LOGO_ICON_HEIGHT = 48;
|
||||||
const _MAX_BOTTOM_MENU_ITEMS = 5;
|
const _MAX_BOTTOM_MENU_ITEMS = 5;
|
||||||
@ -208,7 +208,7 @@ var UserList = class {
|
|||||||
Tweener.removeTweens(adjustment);
|
Tweener.removeTweens(adjustment);
|
||||||
Tweener.addTween (adjustment,
|
Tweener.addTween (adjustment,
|
||||||
{ value: value,
|
{ value: value,
|
||||||
time: _SCROLL_ANIMATION_TIME,
|
time: _SCROLL_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad' });
|
transition: 'easeOutQuad' });
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -761,7 +761,7 @@ var LoginDialog = GObject.registerClass({
|
|||||||
this._bannerView.show();
|
this._bannerView.show();
|
||||||
Tweener.addTween(this._bannerView,
|
Tweener.addTween(this._bannerView,
|
||||||
{ opacity: 255,
|
{ opacity: 255,
|
||||||
time: _FADE_ANIMATION_TIME,
|
time: _FADE_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad' });
|
transition: 'easeOutQuad' });
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -861,7 +861,7 @@ var LoginDialog = GObject.registerClass({
|
|||||||
this._authPrompt.actor.show();
|
this._authPrompt.actor.show();
|
||||||
Tweener.addTween(this._authPrompt.actor,
|
Tweener.addTween(this._authPrompt.actor,
|
||||||
{ opacity: 255,
|
{ opacity: 255,
|
||||||
time: _FADE_ANIMATION_TIME,
|
time: _FADE_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad' });
|
transition: 'easeOutQuad' });
|
||||||
this._fadeInBannerView();
|
this._fadeInBannerView();
|
||||||
}
|
}
|
||||||
@ -912,7 +912,7 @@ var LoginDialog = GObject.registerClass({
|
|||||||
|
|
||||||
Tweener.addTween(this,
|
Tweener.addTween(this,
|
||||||
{ opacity: 255,
|
{ opacity: 255,
|
||||||
time: _FADE_ANIMATION_TIME,
|
time: _FADE_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onUpdate: () => {
|
onUpdate: () => {
|
||||||
let children = Main.layoutManager.uiGroup.get_children();
|
let children = Main.layoutManager.uiGroup.get_children();
|
||||||
@ -940,7 +940,7 @@ var LoginDialog = GObject.registerClass({
|
|||||||
_startSession(serviceName) {
|
_startSession(serviceName) {
|
||||||
Tweener.addTween(this,
|
Tweener.addTween(this,
|
||||||
{ opacity: 0,
|
{ opacity: 0,
|
||||||
time: _FADE_ANIMATION_TIME,
|
time: _FADE_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onUpdate: () => {
|
onUpdate: () => {
|
||||||
let children = Main.layoutManager.uiGroup.get_children();
|
let children = Main.layoutManager.uiGroup.get_children();
|
||||||
|
@ -17,8 +17,8 @@ var PASSWORD_SERVICE_NAME = 'gdm-password';
|
|||||||
var FINGERPRINT_SERVICE_NAME = 'gdm-fingerprint';
|
var FINGERPRINT_SERVICE_NAME = 'gdm-fingerprint';
|
||||||
var SMARTCARD_SERVICE_NAME = 'gdm-smartcard';
|
var SMARTCARD_SERVICE_NAME = 'gdm-smartcard';
|
||||||
var OVIRT_SERVICE_NAME = 'gdm-ovirtcred';
|
var OVIRT_SERVICE_NAME = 'gdm-ovirtcred';
|
||||||
var FADE_ANIMATION_TIME = 0.16;
|
var FADE_ANIMATION_TIME = 160;
|
||||||
var CLONE_FADE_ANIMATION_TIME = 0.25;
|
var CLONE_FADE_ANIMATION_TIME = 250;
|
||||||
|
|
||||||
var LOGIN_SCREEN_SCHEMA = 'org.gnome.login-screen';
|
var LOGIN_SCREEN_SCHEMA = 'org.gnome.login-screen';
|
||||||
var PASSWORD_AUTHENTICATION_KEY = 'enable-password-authentication';
|
var PASSWORD_AUTHENTICATION_KEY = 'enable-password-authentication';
|
||||||
@ -54,7 +54,7 @@ function fadeInActor(actor) {
|
|||||||
Tweener.addTween(actor,
|
Tweener.addTween(actor,
|
||||||
{ opacity: 255,
|
{ opacity: 255,
|
||||||
height: naturalHeight,
|
height: naturalHeight,
|
||||||
time: FADE_ANIMATION_TIME,
|
time: FADE_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete() {
|
onComplete() {
|
||||||
this.set_height(-1);
|
this.set_height(-1);
|
||||||
@ -76,7 +76,7 @@ function fadeOutActor(actor) {
|
|||||||
Tweener.addTween(actor,
|
Tweener.addTween(actor,
|
||||||
{ opacity: 0,
|
{ opacity: 0,
|
||||||
height: 0,
|
height: 0,
|
||||||
time: FADE_ANIMATION_TIME,
|
time: FADE_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete() {
|
onComplete() {
|
||||||
this.hide();
|
this.hide();
|
||||||
@ -105,7 +105,7 @@ function cloneAndFadeOutActor(actor) {
|
|||||||
let hold = new Batch.Hold();
|
let hold = new Batch.Hold();
|
||||||
Tweener.addTween(clone,
|
Tweener.addTween(clone,
|
||||||
{ opacity: 0,
|
{ opacity: 0,
|
||||||
time: CLONE_FADE_ANIMATION_TIME,
|
time: CLONE_FADE_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete() {
|
onComplete() {
|
||||||
clone.destroy();
|
clone.destroy();
|
||||||
|
@ -12,7 +12,7 @@ const Main = imports.ui.main;
|
|||||||
const Tweener = imports.ui.tweener;
|
const Tweener = imports.ui.tweener;
|
||||||
const Params = imports.misc.params;
|
const Params = imports.misc.params;
|
||||||
|
|
||||||
var SCROLL_TIME = 0.1;
|
var SCROLL_TIME = 100;
|
||||||
|
|
||||||
// http://daringfireball.net/2010/07/improved_regex_for_matching_urls
|
// http://daringfireball.net/2010/07/improved_regex_for_matching_urls
|
||||||
const _balancedParens = '\\([^\\s()<>]+\\)';
|
const _balancedParens = '\\([^\\s()<>]+\\)';
|
||||||
@ -428,7 +428,7 @@ function ensureActorVisibleInScrollView(scrollView, actor) {
|
|||||||
|
|
||||||
Tweener.addTween(adjustment,
|
Tweener.addTween(adjustment,
|
||||||
{ value: value,
|
{ value: value,
|
||||||
time: SCROLL_TIME,
|
time: SCROLL_TIME / 1000,
|
||||||
transition: 'easeOutQuad' });
|
transition: 'easeOutQuad' });
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -13,7 +13,7 @@ var APP_ICON_HOVER_TIMEOUT = 200; // milliseconds
|
|||||||
|
|
||||||
var THUMBNAIL_DEFAULT_SIZE = 256;
|
var THUMBNAIL_DEFAULT_SIZE = 256;
|
||||||
var THUMBNAIL_POPUP_TIME = 500; // milliseconds
|
var THUMBNAIL_POPUP_TIME = 500; // milliseconds
|
||||||
var THUMBNAIL_FADE_TIME = 0.1; // seconds
|
var THUMBNAIL_FADE_TIME = 100; // milliseconds
|
||||||
|
|
||||||
var WINDOW_PREVIEW_SIZE = 128;
|
var WINDOW_PREVIEW_SIZE = 128;
|
||||||
var APP_ICON_SIZE = 96;
|
var APP_ICON_SIZE = 96;
|
||||||
@ -364,7 +364,7 @@ class AppSwitcherPopup extends SwitcherPopup.SwitcherPopup {
|
|||||||
let thumbnailsActor = this._thumbnails;
|
let thumbnailsActor = this._thumbnails;
|
||||||
Tweener.addTween(thumbnailsActor,
|
Tweener.addTween(thumbnailsActor,
|
||||||
{ opacity: 0,
|
{ opacity: 0,
|
||||||
time: THUMBNAIL_FADE_TIME,
|
time: THUMBNAIL_FADE_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
thumbnailsActor.destroy();
|
thumbnailsActor.destroy();
|
||||||
@ -395,7 +395,7 @@ class AppSwitcherPopup extends SwitcherPopup.SwitcherPopup {
|
|||||||
this._thumbnails.opacity = 0;
|
this._thumbnails.opacity = 0;
|
||||||
Tweener.addTween(this._thumbnails,
|
Tweener.addTween(this._thumbnails,
|
||||||
{ opacity: 255,
|
{ opacity: 255,
|
||||||
time: THUMBNAIL_FADE_TIME,
|
time: THUMBNAIL_FADE_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => this.thumbnailsVisible = true
|
onComplete: () => this.thumbnailsVisible = true
|
||||||
});
|
});
|
||||||
|
@ -7,8 +7,8 @@ const Mainloop = imports.mainloop;
|
|||||||
const Tweener = imports.ui.tweener;
|
const Tweener = imports.ui.tweener;
|
||||||
|
|
||||||
var ANIMATED_ICON_UPDATE_TIMEOUT = 16;
|
var ANIMATED_ICON_UPDATE_TIMEOUT = 16;
|
||||||
var SPINNER_ANIMATION_TIME = 0.3;
|
var SPINNER_ANIMATION_TIME = 300;
|
||||||
var SPINNER_ANIMATION_DELAY = 1.0;
|
var SPINNER_ANIMATION_DELAY = 1000;
|
||||||
|
|
||||||
var Animation = class {
|
var Animation = class {
|
||||||
constructor(file, width, height, speed) {
|
constructor(file, width, height, speed) {
|
||||||
@ -144,8 +144,8 @@ var Spinner = class extends AnimatedIcon {
|
|||||||
super.play();
|
super.play();
|
||||||
Tweener.addTween(this.actor, {
|
Tweener.addTween(this.actor, {
|
||||||
opacity: 255,
|
opacity: 255,
|
||||||
delay: SPINNER_ANIMATION_DELAY,
|
delay: SPINNER_ANIMATION_DELAY / 1000,
|
||||||
time: SPINNER_ANIMATION_TIME,
|
time: SPINNER_ANIMATION_TIME / 1000,
|
||||||
transition: 'linear'
|
transition: 'linear'
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
@ -160,7 +160,7 @@ var Spinner = class extends AnimatedIcon {
|
|||||||
if (this._animate) {
|
if (this._animate) {
|
||||||
Tweener.addTween(this.actor, {
|
Tweener.addTween(this.actor, {
|
||||||
opacity: 0,
|
opacity: 0,
|
||||||
time: SPINNER_ANIMATION_TIME,
|
time: SPINNER_ANIMATION_TIME / 1000,
|
||||||
transition: 'linear',
|
transition: 'linear',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
super.stop();
|
super.stop();
|
||||||
|
@ -29,15 +29,15 @@ var MIN_ROWS = 4;
|
|||||||
var INACTIVE_GRID_OPACITY = 77;
|
var INACTIVE_GRID_OPACITY = 77;
|
||||||
// This time needs to be less than IconGrid.EXTRA_SPACE_ANIMATION_TIME
|
// This time needs to be less than IconGrid.EXTRA_SPACE_ANIMATION_TIME
|
||||||
// to not clash with other animations
|
// to not clash with other animations
|
||||||
var INACTIVE_GRID_OPACITY_ANIMATION_TIME = 0.24;
|
var INACTIVE_GRID_OPACITY_ANIMATION_TIME = 240;
|
||||||
var FOLDER_SUBICON_FRACTION = .4;
|
var FOLDER_SUBICON_FRACTION = .4;
|
||||||
|
|
||||||
var MIN_FREQUENT_APPS_COUNT = 3;
|
var MIN_FREQUENT_APPS_COUNT = 3;
|
||||||
|
|
||||||
var VIEWS_SWITCH_TIME = 0.4;
|
var VIEWS_SWITCH_TIME = 400;
|
||||||
var VIEWS_SWITCH_ANIMATION_DELAY = 0.1;
|
var VIEWS_SWITCH_ANIMATION_DELAY = 100;
|
||||||
|
|
||||||
var PAGE_SWITCH_TIME = 0.3;
|
var PAGE_SWITCH_TIME = 300;
|
||||||
|
|
||||||
const SWITCHEROO_BUS_NAME = 'net.hadess.SwitcherooControl';
|
const SWITCHEROO_BUS_NAME = 'net.hadess.SwitcherooControl';
|
||||||
const SWITCHEROO_OBJECT_PATH = '/net/hadess/SwitcherooControl';
|
const SWITCHEROO_OBJECT_PATH = '/net/hadess/SwitcherooControl';
|
||||||
@ -208,12 +208,12 @@ class BaseAppView {
|
|||||||
Tweener.removeTweens(this.actor);
|
Tweener.removeTweens(this.actor);
|
||||||
Tweener.removeTweens(this._grid);
|
Tweener.removeTweens(this._grid);
|
||||||
|
|
||||||
let params = { time: VIEWS_SWITCH_TIME,
|
let params = { time: VIEWS_SWITCH_TIME / 1000,
|
||||||
transition: 'easeOutQuad' };
|
transition: 'easeOutQuad' };
|
||||||
if (animationDirection == IconGrid.AnimationDirection.IN) {
|
if (animationDirection == IconGrid.AnimationDirection.IN) {
|
||||||
this.actor.show();
|
this.actor.show();
|
||||||
params.opacity = 255;
|
params.opacity = 255;
|
||||||
params.delay = VIEWS_SWITCH_ANIMATION_DELAY;
|
params.delay = VIEWS_SWITCH_ANIMATION_DELAY / 1000;
|
||||||
} else {
|
} else {
|
||||||
params.opacity = 0;
|
params.opacity = 0;
|
||||||
params.delay = 0;
|
params.delay = 0;
|
||||||
@ -451,7 +451,7 @@ var AllView = class AllView extends BaseAppView {
|
|||||||
if (this._currentPopup && this._displayingPopup &&
|
if (this._currentPopup && this._displayingPopup &&
|
||||||
animationDirection == IconGrid.AnimationDirection.OUT)
|
animationDirection == IconGrid.AnimationDirection.OUT)
|
||||||
Tweener.addTween(this._currentPopup.actor,
|
Tweener.addTween(this._currentPopup.actor,
|
||||||
{ time: VIEWS_SWITCH_TIME,
|
{ time: VIEWS_SWITCH_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
opacity: 0,
|
opacity: 0,
|
||||||
onComplete() {
|
onComplete() {
|
||||||
@ -490,9 +490,9 @@ var AllView = class AllView extends BaseAppView {
|
|||||||
// Only take the velocity into account on page changes, otherwise
|
// Only take the velocity into account on page changes, otherwise
|
||||||
// return smoothly to the current page using the default velocity
|
// return smoothly to the current page using the default velocity
|
||||||
if (this._grid.currentPage != pageNumber) {
|
if (this._grid.currentPage != pageNumber) {
|
||||||
let minVelocity = totalHeight / (PAGE_SWITCH_TIME * 1000);
|
let minVelocity = totalHeight / PAGE_SWITCH_TIME;
|
||||||
velocity = Math.max(minVelocity, velocity);
|
velocity = Math.max(minVelocity, velocity);
|
||||||
time = (diffToPage / velocity) / 1000;
|
time = diffToPage / velocity;
|
||||||
} else {
|
} else {
|
||||||
time = PAGE_SWITCH_TIME * diffToPage / totalHeight;
|
time = PAGE_SWITCH_TIME * diffToPage / totalHeight;
|
||||||
}
|
}
|
||||||
@ -503,7 +503,7 @@ var AllView = class AllView extends BaseAppView {
|
|||||||
this._grid.currentPage = pageNumber;
|
this._grid.currentPage = pageNumber;
|
||||||
Tweener.addTween(this._adjustment,
|
Tweener.addTween(this._adjustment,
|
||||||
{ value: this._grid.getPageY(this._grid.currentPage),
|
{ value: this._grid.getPageY(this._grid.currentPage),
|
||||||
time: time,
|
time: time / 1000,
|
||||||
transition: 'easeOutQuad' });
|
transition: 'easeOutQuad' });
|
||||||
this._pageIndicators.setCurrentPage(pageNumber);
|
this._pageIndicators.setCurrentPage(pageNumber);
|
||||||
}
|
}
|
||||||
@ -626,7 +626,7 @@ var AllView = class AllView extends BaseAppView {
|
|||||||
else
|
else
|
||||||
opacity = 255;
|
opacity = 255;
|
||||||
params = { opacity: opacity,
|
params = { opacity: opacity,
|
||||||
time: INACTIVE_GRID_OPACITY_ANIMATION_TIME,
|
time: INACTIVE_GRID_OPACITY_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad' };
|
transition: 'easeOutQuad' };
|
||||||
Tweener.addTween(this._items[id].actor, params);
|
Tweener.addTween(this._items[id].actor, params);
|
||||||
}
|
}
|
||||||
|
@ -110,7 +110,7 @@ const COLOR_SHADING_TYPE_KEY = 'color-shading-type';
|
|||||||
const BACKGROUND_STYLE_KEY = 'picture-options';
|
const BACKGROUND_STYLE_KEY = 'picture-options';
|
||||||
const PICTURE_URI_KEY = 'picture-uri';
|
const PICTURE_URI_KEY = 'picture-uri';
|
||||||
|
|
||||||
var FADE_ANIMATION_TIME = 1.0;
|
var FADE_ANIMATION_TIME = 1000;
|
||||||
|
|
||||||
// These parameters affect how often we redraw.
|
// These parameters affect how often we redraw.
|
||||||
// The first is how different (percent crossfaded) the slide show
|
// The first is how different (percent crossfaded) the slide show
|
||||||
@ -712,7 +712,7 @@ var BackgroundManager = class BackgroundManager {
|
|||||||
|
|
||||||
Tweener.addTween(oldBackgroundActor,
|
Tweener.addTween(oldBackgroundActor,
|
||||||
{ opacity: 0,
|
{ opacity: 0,
|
||||||
time: FADE_ANIMATION_TIME,
|
time: FADE_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete() {
|
onComplete() {
|
||||||
oldBackgroundActor.destroy();
|
oldBackgroundActor.destroy();
|
||||||
|
@ -13,7 +13,7 @@ var PopupAnimation = {
|
|||||||
FULL: ~0,
|
FULL: ~0,
|
||||||
};
|
};
|
||||||
|
|
||||||
var POPUP_ANIMATION_TIME = 0.15;
|
var POPUP_ANIMATION_TIME = 150;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* BoxPointer:
|
* BoxPointer:
|
||||||
@ -115,7 +115,7 @@ var BoxPointer = GObject.registerClass({
|
|||||||
if (onComplete)
|
if (onComplete)
|
||||||
onComplete();
|
onComplete();
|
||||||
},
|
},
|
||||||
time: animationTime });
|
time: animationTime / 1000 });
|
||||||
}
|
}
|
||||||
|
|
||||||
close(animate, onComplete) {
|
close(animate, onComplete) {
|
||||||
@ -153,7 +153,7 @@ var BoxPointer = GObject.registerClass({
|
|||||||
translation_x: translationX,
|
translation_x: translationX,
|
||||||
translation_y: translationY,
|
translation_y: translationY,
|
||||||
transition: 'linear',
|
transition: 'linear',
|
||||||
time: animationTime,
|
time: animationTime / 1000,
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
this.hide();
|
this.hide();
|
||||||
this.opacity = 0;
|
this.opacity = 0;
|
||||||
|
@ -8,7 +8,7 @@ const Main = imports.ui.main;
|
|||||||
const Tweener = imports.ui.tweener;
|
const Tweener = imports.ui.tweener;
|
||||||
|
|
||||||
var FROZEN_WINDOW_BRIGHTNESS = -0.3;
|
var FROZEN_WINDOW_BRIGHTNESS = -0.3;
|
||||||
var DIALOG_TRANSITION_TIME = 0.15;
|
var DIALOG_TRANSITION_TIME = 150;
|
||||||
var ALIVE_TIMEOUT = 5000;
|
var ALIVE_TIMEOUT = 5000;
|
||||||
|
|
||||||
var CloseDialog = GObject.registerClass({
|
var CloseDialog = GObject.registerClass({
|
||||||
@ -152,7 +152,7 @@ var CloseDialog = GObject.registerClass({
|
|||||||
Tweener.addTween(this._dialog,
|
Tweener.addTween(this._dialog,
|
||||||
{ scale_y: 1,
|
{ scale_y: 1,
|
||||||
transition: 'linear',
|
transition: 'linear',
|
||||||
time: DIALOG_TRANSITION_TIME,
|
time: DIALOG_TRANSITION_TIME / 1000,
|
||||||
onComplete: this._onFocusChanged.bind(this)
|
onComplete: this._onFocusChanged.bind(this)
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@ -179,7 +179,7 @@ var CloseDialog = GObject.registerClass({
|
|||||||
Tweener.addTween(dialog,
|
Tweener.addTween(dialog,
|
||||||
{ scale_y: 0,
|
{ scale_y: 0,
|
||||||
transition: 'linear',
|
transition: 'linear',
|
||||||
time: DIALOG_TRANSITION_TIME,
|
time: DIALOG_TRANSITION_TIME / 1000,
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
dialog.destroy();
|
dialog.destroy();
|
||||||
}
|
}
|
||||||
|
@ -12,9 +12,9 @@ const IconGrid = imports.ui.iconGrid;
|
|||||||
const Main = imports.ui.main;
|
const Main = imports.ui.main;
|
||||||
const Tweener = imports.ui.tweener;
|
const Tweener = imports.ui.tweener;
|
||||||
|
|
||||||
var DASH_ANIMATION_TIME = 0.2;
|
var DASH_ANIMATION_TIME = 200;
|
||||||
var DASH_ITEM_LABEL_SHOW_TIME = 0.15;
|
var DASH_ITEM_LABEL_SHOW_TIME = 150;
|
||||||
var DASH_ITEM_LABEL_HIDE_TIME = 0.1;
|
var DASH_ITEM_LABEL_HIDE_TIME = 100;
|
||||||
var DASH_ITEM_HOVER_TIMEOUT = 300;
|
var DASH_ITEM_HOVER_TIMEOUT = 300;
|
||||||
|
|
||||||
function getAppFromSource(source) {
|
function getAppFromSource(source) {
|
||||||
@ -98,7 +98,7 @@ class DashItemContainer extends St.Widget {
|
|||||||
this.label.set_position(x, y);
|
this.label.set_position(x, y);
|
||||||
Tweener.addTween(this.label,
|
Tweener.addTween(this.label,
|
||||||
{ opacity: 255,
|
{ opacity: 255,
|
||||||
time: DASH_ITEM_LABEL_SHOW_TIME,
|
time: DASH_ITEM_LABEL_SHOW_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@ -111,7 +111,7 @@ class DashItemContainer extends St.Widget {
|
|||||||
hideLabel() {
|
hideLabel() {
|
||||||
Tweener.addTween(this.label,
|
Tweener.addTween(this.label,
|
||||||
{ opacity: 0,
|
{ opacity: 0,
|
||||||
time: DASH_ITEM_LABEL_HIDE_TIME,
|
time: DASH_ITEM_LABEL_HIDE_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
this.label.hide();
|
this.label.hide();
|
||||||
@ -140,7 +140,7 @@ class DashItemContainer extends St.Widget {
|
|||||||
Tweener.addTween(this,
|
Tweener.addTween(this,
|
||||||
{ childScale: 1.0,
|
{ childScale: 1.0,
|
||||||
childOpacity: 255,
|
childOpacity: 255,
|
||||||
time: time,
|
time: time / 1000,
|
||||||
transition: 'easeOutQuad'
|
transition: 'easeOutQuad'
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@ -157,7 +157,7 @@ class DashItemContainer extends St.Widget {
|
|||||||
Tweener.addTween(this,
|
Tweener.addTween(this,
|
||||||
{ childScale: 0.0,
|
{ childScale: 0.0,
|
||||||
childOpacity: 0,
|
childOpacity: 0,
|
||||||
time: DASH_ANIMATION_TIME,
|
time: DASH_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
this.destroy();
|
this.destroy();
|
||||||
@ -637,7 +637,7 @@ var Dash = class Dash {
|
|||||||
Tweener.addTween(icon.icon,
|
Tweener.addTween(icon.icon,
|
||||||
{ width: targetWidth,
|
{ width: targetWidth,
|
||||||
height: targetHeight,
|
height: targetHeight,
|
||||||
time: DASH_ANIMATION_TIME,
|
time: DASH_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
12
js/ui/dnd.js
12
js/ui/dnd.js
@ -9,11 +9,11 @@ const Params = imports.misc.params;
|
|||||||
const Tweener = imports.ui.tweener;
|
const Tweener = imports.ui.tweener;
|
||||||
|
|
||||||
// Time to scale down to maxDragActorSize
|
// Time to scale down to maxDragActorSize
|
||||||
var SCALE_ANIMATION_TIME = 0.25;
|
var SCALE_ANIMATION_TIME = 250;
|
||||||
// Time to animate to original position on cancel
|
// Time to animate to original position on cancel
|
||||||
var SNAP_BACK_ANIMATION_TIME = 0.25;
|
var SNAP_BACK_ANIMATION_TIME = 250;
|
||||||
// Time to animate to original position on success
|
// Time to animate to original position on success
|
||||||
var REVERT_ANIMATION_TIME = 0.75;
|
var REVERT_ANIMATION_TIME = 750;
|
||||||
|
|
||||||
var DragMotionResult = {
|
var DragMotionResult = {
|
||||||
NO_DROP: 0,
|
NO_DROP: 0,
|
||||||
@ -433,7 +433,7 @@ var _Draggable = class _Draggable {
|
|||||||
Tweener.addTween(this._dragActor,
|
Tweener.addTween(this._dragActor,
|
||||||
{ scale_x: scale * origScale,
|
{ scale_x: scale * origScale,
|
||||||
scale_y: scale * origScale,
|
scale_y: scale * origScale,
|
||||||
time: SCALE_ANIMATION_TIME,
|
time: SCALE_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onUpdate: () => {
|
onUpdate: () => {
|
||||||
let currentScale = this._dragActor.scale_x / origScale;
|
let currentScale = this._dragActor.scale_x / origScale;
|
||||||
@ -663,7 +663,7 @@ var _Draggable = class _Draggable {
|
|||||||
y: snapBackY,
|
y: snapBackY,
|
||||||
scale_x: snapBackScale,
|
scale_x: snapBackScale,
|
||||||
scale_y: snapBackScale,
|
scale_y: snapBackScale,
|
||||||
time: SNAP_BACK_ANIMATION_TIME,
|
time: SNAP_BACK_ANIMATION_TIME / 1000,
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -677,7 +677,7 @@ var _Draggable = class _Draggable {
|
|||||||
this._dragActor.opacity = 0;
|
this._dragActor.opacity = 0;
|
||||||
|
|
||||||
this._animateDragEnd(eventTime,
|
this._animateDragEnd(eventTime,
|
||||||
{ time: REVERT_ANIMATION_TIME });
|
{ time: REVERT_ANIMATION_TIME / 1000 });
|
||||||
}
|
}
|
||||||
|
|
||||||
_animateDragEnd(eventTime, params) {
|
_animateDragEnd(eventTime, params) {
|
||||||
|
@ -10,9 +10,9 @@ const Main = imports.ui.main;
|
|||||||
var ICON_SIZE = 96;
|
var ICON_SIZE = 96;
|
||||||
var MIN_ICON_SIZE = 16;
|
var MIN_ICON_SIZE = 16;
|
||||||
|
|
||||||
var EXTRA_SPACE_ANIMATION_TIME = 0.25;
|
var EXTRA_SPACE_ANIMATION_TIME = 250;
|
||||||
|
|
||||||
var ANIMATION_TIME_IN = 0.350;
|
var ANIMATION_TIME_IN = 350;
|
||||||
var ANIMATION_TIME_OUT = 1 / 2 * ANIMATION_TIME_IN;
|
var ANIMATION_TIME_OUT = 1 / 2 * ANIMATION_TIME_IN;
|
||||||
var ANIMATION_MAX_DELAY_FOR_ITEM = 2 / 3 * ANIMATION_TIME_IN;
|
var ANIMATION_MAX_DELAY_FOR_ITEM = 2 / 3 * ANIMATION_TIME_IN;
|
||||||
var ANIMATION_BASE_DELAY_FOR_ITEM = 1 / 4 * ANIMATION_MAX_DELAY_FOR_ITEM;
|
var ANIMATION_BASE_DELAY_FOR_ITEM = 1 / 4 * ANIMATION_MAX_DELAY_FOR_ITEM;
|
||||||
@ -27,7 +27,7 @@ var AnimationDirection = {
|
|||||||
};
|
};
|
||||||
|
|
||||||
var APPICON_ANIMATION_OUT_SCALE = 3;
|
var APPICON_ANIMATION_OUT_SCALE = 3;
|
||||||
var APPICON_ANIMATION_OUT_TIME = 0.25;
|
var APPICON_ANIMATION_OUT_TIME = 250;
|
||||||
|
|
||||||
var BaseIcon = GObject.registerClass(
|
var BaseIcon = GObject.registerClass(
|
||||||
class BaseIcon extends St.Bin {
|
class BaseIcon extends St.Bin {
|
||||||
@ -170,7 +170,7 @@ function zoomOutActor(actor) {
|
|||||||
let containedY = clamp(scaledY, monitor.y, monitor.y + monitor.height - scaledHeight);
|
let containedY = clamp(scaledY, monitor.y, monitor.y + monitor.height - scaledHeight);
|
||||||
|
|
||||||
Tweener.addTween(actorClone,
|
Tweener.addTween(actorClone,
|
||||||
{ time: APPICON_ANIMATION_OUT_TIME,
|
{ time: APPICON_ANIMATION_OUT_TIME / 1000,
|
||||||
scale_x: APPICON_ANIMATION_OUT_SCALE,
|
scale_x: APPICON_ANIMATION_OUT_SCALE,
|
||||||
scale_y: APPICON_ANIMATION_OUT_SCALE,
|
scale_y: APPICON_ANIMATION_OUT_SCALE,
|
||||||
translation_x: containedX - scaledX,
|
translation_x: containedX - scaledX,
|
||||||
@ -460,14 +460,14 @@ var IconGrid = GObject.registerClass({
|
|||||||
let bounceUpTime = ANIMATION_TIME_IN / 4;
|
let bounceUpTime = ANIMATION_TIME_IN / 4;
|
||||||
let isLastItem = index == actors.length - 1;
|
let isLastItem = index == actors.length - 1;
|
||||||
Tweener.addTween(actor,
|
Tweener.addTween(actor,
|
||||||
{ time: bounceUpTime,
|
{ time: bounceUpTime / 1000,
|
||||||
transition: 'easeInOutQuad',
|
transition: 'easeInOutQuad',
|
||||||
delay: delay,
|
delay: delay / 1000,
|
||||||
scale_x: ANIMATION_BOUNCE_ICON_SCALE,
|
scale_x: ANIMATION_BOUNCE_ICON_SCALE,
|
||||||
scale_y: ANIMATION_BOUNCE_ICON_SCALE,
|
scale_y: ANIMATION_BOUNCE_ICON_SCALE,
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
Tweener.addTween(actor,
|
Tweener.addTween(actor,
|
||||||
{ time: ANIMATION_TIME_IN - bounceUpTime,
|
{ time: (ANIMATION_TIME_IN - bounceUpTime) / 1000,
|
||||||
transition: 'easeInOutQuad',
|
transition: 'easeInOutQuad',
|
||||||
scale_x: 1,
|
scale_x: 1,
|
||||||
scale_y: 1,
|
scale_y: 1,
|
||||||
@ -536,9 +536,9 @@ var IconGrid = GObject.registerClass({
|
|||||||
|
|
||||||
let delay = (1 - (actor._distance - minDist) / normalization) * ANIMATION_MAX_DELAY_FOR_ITEM;
|
let delay = (1 - (actor._distance - minDist) / normalization) * ANIMATION_MAX_DELAY_FOR_ITEM;
|
||||||
let [finalX, finalY] = actor._transformedPosition;
|
let [finalX, finalY] = actor._transformedPosition;
|
||||||
movementParams = { time: ANIMATION_TIME_IN,
|
movementParams = { time: ANIMATION_TIME_IN / 1000,
|
||||||
transition: 'easeInOutQuad',
|
transition: 'easeInOutQuad',
|
||||||
delay: delay,
|
delay: delay / 1000,
|
||||||
x: finalX,
|
x: finalX,
|
||||||
y: finalY,
|
y: finalY,
|
||||||
scale_x: 1,
|
scale_x: 1,
|
||||||
@ -547,9 +547,9 @@ var IconGrid = GObject.registerClass({
|
|||||||
if (isLastItem)
|
if (isLastItem)
|
||||||
this._animationDone();
|
this._animationDone();
|
||||||
} };
|
} };
|
||||||
fadeParams = { time: ANIMATION_FADE_IN_TIME_FOR_ITEM,
|
fadeParams = { time: ANIMATION_FADE_IN_TIME_FOR_ITEM / 1000,
|
||||||
transition: 'easeInOutQuad',
|
transition: 'easeInOutQuad',
|
||||||
delay: delay,
|
delay: delay / 1000,
|
||||||
opacity: 255 };
|
opacity: 255 };
|
||||||
} else {
|
} else {
|
||||||
let isLastItem = actor._distance == maxDist;
|
let isLastItem = actor._distance == maxDist;
|
||||||
@ -558,9 +558,9 @@ var IconGrid = GObject.registerClass({
|
|||||||
actorClone.set_position(startX, startY);
|
actorClone.set_position(startX, startY);
|
||||||
|
|
||||||
let delay = (actor._distance - minDist) / normalization * ANIMATION_MAX_DELAY_OUT_FOR_ITEM;
|
let delay = (actor._distance - minDist) / normalization * ANIMATION_MAX_DELAY_OUT_FOR_ITEM;
|
||||||
movementParams = { time: ANIMATION_TIME_OUT,
|
movementParams = { time: ANIMATION_TIME_OUT / 1000,
|
||||||
transition: 'easeInOutQuad',
|
transition: 'easeInOutQuad',
|
||||||
delay: delay,
|
delay: delay / 1000,
|
||||||
x: adjustedSourcePositionX,
|
x: adjustedSourcePositionX,
|
||||||
y: adjustedSourcePositionY,
|
y: adjustedSourcePositionY,
|
||||||
scale_x: scaleX,
|
scale_x: scaleX,
|
||||||
@ -569,9 +569,9 @@ var IconGrid = GObject.registerClass({
|
|||||||
if (isLastItem)
|
if (isLastItem)
|
||||||
this._animationDone();
|
this._animationDone();
|
||||||
} };
|
} };
|
||||||
fadeParams = { time: ANIMATION_FADE_IN_TIME_FOR_ITEM,
|
fadeParams = { time: ANIMATION_FADE_IN_TIME_FOR_ITEM / 1000,
|
||||||
transition: 'easeInOutQuad',
|
transition: 'easeInOutQuad',
|
||||||
delay: ANIMATION_TIME_OUT + delay - ANIMATION_FADE_IN_TIME_FOR_ITEM,
|
delay: (ANIMATION_TIME_OUT + delay - ANIMATION_FADE_IN_TIME_FOR_ITEM) / 1000,
|
||||||
opacity: 0 };
|
opacity: 0 };
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -983,7 +983,7 @@ var PaginatedIconGrid = GObject.registerClass({
|
|||||||
for (let i = 0; i < children.length; i++) {
|
for (let i = 0; i < children.length; i++) {
|
||||||
children[i].translation_y = 0;
|
children[i].translation_y = 0;
|
||||||
let params = { translation_y: translationY,
|
let params = { translation_y: translationY,
|
||||||
time: EXTRA_SPACE_ANIMATION_TIME,
|
time: EXTRA_SPACE_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeInOutQuad'
|
transition: 'easeInOutQuad'
|
||||||
};
|
};
|
||||||
if (i == (children.length - 1))
|
if (i == (children.length - 1))
|
||||||
@ -1003,7 +1003,7 @@ var PaginatedIconGrid = GObject.registerClass({
|
|||||||
continue;
|
continue;
|
||||||
Tweener.addTween(this._translatedChildren[i],
|
Tweener.addTween(this._translatedChildren[i],
|
||||||
{ translation_y: 0,
|
{ translation_y: 0,
|
||||||
time: EXTRA_SPACE_ANIMATION_TIME,
|
time: EXTRA_SPACE_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeInOutQuad',
|
transition: 'easeInOutQuad',
|
||||||
onComplete: () => this.emit('space-closed')
|
onComplete: () => this.emit('space-closed')
|
||||||
});
|
});
|
||||||
|
@ -13,9 +13,9 @@ const PageIndicators = imports.ui.pageIndicators;
|
|||||||
const PopupMenu = imports.ui.popupMenu;
|
const PopupMenu = imports.ui.popupMenu;
|
||||||
const Tweener = imports.ui.tweener;
|
const Tweener = imports.ui.tweener;
|
||||||
|
|
||||||
var KEYBOARD_REST_TIME = Layout.KEYBOARD_ANIMATION_TIME * 2 * 1000;
|
var KEYBOARD_REST_TIME = Layout.KEYBOARD_ANIMATION_TIME * 2;
|
||||||
var KEY_LONG_PRESS_TIME = 250;
|
var KEY_LONG_PRESS_TIME = 250;
|
||||||
var PANEL_SWITCH_ANIMATION_TIME = 0.5;
|
var PANEL_SWITCH_ANIMATION_TIME = 500;
|
||||||
var PANEL_SWITCH_RELATIVE_DISTANCE = 1 / 3; /* A third of the actor width */
|
var PANEL_SWITCH_RELATIVE_DISTANCE = 1 / 3; /* A third of the actor width */
|
||||||
|
|
||||||
const A11Y_APPLICATIONS_SCHEMA = 'org.gnome.desktop.a11y.applications';
|
const A11Y_APPLICATIONS_SCHEMA = 'org.gnome.desktop.a11y.applications';
|
||||||
@ -695,7 +695,7 @@ var EmojiPager = class EmojiPager {
|
|||||||
Tweener.removeTweens(this);
|
Tweener.removeTweens(this);
|
||||||
Tweener.addTween(this,
|
Tweener.addTween(this,
|
||||||
{ delta: value,
|
{ delta: value,
|
||||||
time: time,
|
time: time / 1000,
|
||||||
transition: 'easeInOutQuad',
|
transition: 'easeInOutQuad',
|
||||||
onComplete() {
|
onComplete() {
|
||||||
this.setCurrentPage(this.getFollowingPage());
|
this.setCurrentPage(this.getFollowingPage());
|
||||||
@ -711,7 +711,7 @@ var EmojiPager = class EmojiPager {
|
|||||||
Tweener.removeTweens(this);
|
Tweener.removeTweens(this);
|
||||||
Tweener.addTween(this,
|
Tweener.addTween(this,
|
||||||
{ delta: 0,
|
{ delta: 0,
|
||||||
time: time,
|
time: time / 1000,
|
||||||
transition: 'easeInOutQuad',
|
transition: 'easeInOutQuad',
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@ -1656,14 +1656,14 @@ var Keyboard = class Keyboard {
|
|||||||
if (show) {
|
if (show) {
|
||||||
Tweener.addTween(windowActor,
|
Tweener.addTween(windowActor,
|
||||||
{ y: windowActor.y - deltaY,
|
{ y: windowActor.y - deltaY,
|
||||||
time: Layout.KEYBOARD_ANIMATION_TIME,
|
time: Layout.KEYBOARD_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: this._windowSlideAnimationComplete,
|
onComplete: this._windowSlideAnimationComplete,
|
||||||
onCompleteParams: [window, -deltaY] });
|
onCompleteParams: [window, -deltaY] });
|
||||||
} else {
|
} else {
|
||||||
Tweener.addTween(windowActor,
|
Tweener.addTween(windowActor,
|
||||||
{ y: windowActor.y + deltaY,
|
{ y: windowActor.y + deltaY,
|
||||||
time: Layout.KEYBOARD_ANIMATION_TIME,
|
time: Layout.KEYBOARD_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeInQuad',
|
transition: 'easeInQuad',
|
||||||
onComplete: this._windowSlideAnimationComplete,
|
onComplete: this._windowSlideAnimationComplete,
|
||||||
onCompleteParams: [window, deltaY] });
|
onCompleteParams: [window, deltaY] });
|
||||||
|
@ -14,9 +14,9 @@ const Params = imports.misc.params;
|
|||||||
const Tweener = imports.ui.tweener;
|
const Tweener = imports.ui.tweener;
|
||||||
const Ripples = imports.ui.ripples;
|
const Ripples = imports.ui.ripples;
|
||||||
|
|
||||||
var STARTUP_ANIMATION_TIME = 0.5;
|
var STARTUP_ANIMATION_TIME = 500;
|
||||||
var KEYBOARD_ANIMATION_TIME = 0.15;
|
var KEYBOARD_ANIMATION_TIME = 150;
|
||||||
var BACKGROUND_FADE_ANIMATION_TIME = 1.0;
|
var BACKGROUND_FADE_ANIMATION_TIME = 1000;
|
||||||
|
|
||||||
var HOT_CORNER_PRESSURE_THRESHOLD = 100; // pixels
|
var HOT_CORNER_PRESSURE_THRESHOLD = 100; // pixels
|
||||||
var HOT_CORNER_PRESSURE_TIMEOUT = 1000; // ms
|
var HOT_CORNER_PRESSURE_TIMEOUT = 1000; // ms
|
||||||
@ -466,7 +466,7 @@ var LayoutManager = GObject.registerClass({
|
|||||||
backgroundActor.opacity = 0;
|
backgroundActor.opacity = 0;
|
||||||
Tweener.addTween(backgroundActor,
|
Tweener.addTween(backgroundActor,
|
||||||
{ opacity: 255,
|
{ opacity: 255,
|
||||||
time: BACKGROUND_FADE_ANIMATION_TIME,
|
time: BACKGROUND_FADE_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad' });
|
transition: 'easeOutQuad' });
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -700,7 +700,7 @@ var LayoutManager = GObject.registerClass({
|
|||||||
_startupAnimationGreeter() {
|
_startupAnimationGreeter() {
|
||||||
Tweener.addTween(this.panelBox,
|
Tweener.addTween(this.panelBox,
|
||||||
{ translation_y: 0,
|
{ translation_y: 0,
|
||||||
time: STARTUP_ANIMATION_TIME,
|
time: STARTUP_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: this._startupAnimationComplete,
|
onComplete: this._startupAnimationComplete,
|
||||||
onCompleteScope: this });
|
onCompleteScope: this });
|
||||||
@ -711,7 +711,7 @@ var LayoutManager = GObject.registerClass({
|
|||||||
{ scale_x: 1,
|
{ scale_x: 1,
|
||||||
scale_y: 1,
|
scale_y: 1,
|
||||||
opacity: 255,
|
opacity: 255,
|
||||||
time: STARTUP_ANIMATION_TIME,
|
time: STARTUP_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: this._startupAnimationComplete,
|
onComplete: this._startupAnimationComplete,
|
||||||
onCompleteScope: this });
|
onCompleteScope: this });
|
||||||
@ -743,7 +743,7 @@ var LayoutManager = GObject.registerClass({
|
|||||||
Tweener.addTween(this.keyboardBox,
|
Tweener.addTween(this.keyboardBox,
|
||||||
{ anchor_y: this.keyboardBox.height,
|
{ anchor_y: this.keyboardBox.height,
|
||||||
opacity: 255,
|
opacity: 255,
|
||||||
time: KEYBOARD_ANIMATION_TIME,
|
time: KEYBOARD_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: this._showKeyboardComplete,
|
onComplete: this._showKeyboardComplete,
|
||||||
onCompleteScope: this
|
onCompleteScope: this
|
||||||
@ -769,7 +769,7 @@ var LayoutManager = GObject.registerClass({
|
|||||||
Tweener.addTween(this.keyboardBox,
|
Tweener.addTween(this.keyboardBox,
|
||||||
{ anchor_y: 0,
|
{ anchor_y: 0,
|
||||||
opacity: 0,
|
opacity: 0,
|
||||||
time: immediate ? 0 : KEYBOARD_ANIMATION_TIME,
|
time: immediate ? 0 : KEYBOARD_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeInQuad',
|
transition: 'easeInQuad',
|
||||||
onComplete: this._hideKeyboardComplete,
|
onComplete: this._hideKeyboardComplete,
|
||||||
onCompleteScope: this
|
onCompleteScope: this
|
||||||
|
@ -69,8 +69,8 @@ class RadialShaderEffect extends Shell.GLSLEffect {
|
|||||||
* - inhibitEvents: whether to inhibit events for @container
|
* - inhibitEvents: whether to inhibit events for @container
|
||||||
* - width: shade actor width
|
* - width: shade actor width
|
||||||
* - height: shade actor height
|
* - height: shade actor height
|
||||||
* - fadeInTime: seconds used to fade in
|
* - fadeInTime: milliseconds used to fade in
|
||||||
* - fadeOutTime: seconds used to fade out
|
* - fadeOutTime: milliseconds used to fade out
|
||||||
*
|
*
|
||||||
* Lightbox creates a dark translucent "shade" actor to hide the
|
* Lightbox creates a dark translucent "shade" actor to hide the
|
||||||
* contents of @container, and allows you to specify particular actors
|
* contents of @container, and allows you to specify particular actors
|
||||||
@ -160,7 +160,7 @@ var Lightbox = class Lightbox {
|
|||||||
Tweener.addTween(effect,
|
Tweener.addTween(effect,
|
||||||
{ brightness: VIGNETTE_BRIGHTNESS,
|
{ brightness: VIGNETTE_BRIGHTNESS,
|
||||||
vignetteSharpness: VIGNETTE_SHARPNESS,
|
vignetteSharpness: VIGNETTE_SHARPNESS,
|
||||||
time: fadeInTime,
|
time: fadeInTime / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
this.shown = true;
|
this.shown = true;
|
||||||
@ -171,7 +171,7 @@ var Lightbox = class Lightbox {
|
|||||||
Tweener.removeTweens(this.actor);
|
Tweener.removeTweens(this.actor);
|
||||||
Tweener.addTween(this.actor,
|
Tweener.addTween(this.actor,
|
||||||
{ opacity: 255 * this._fadeFactor,
|
{ opacity: 255 * this._fadeFactor,
|
||||||
time: fadeInTime,
|
time: fadeInTime / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
this.shown = true;
|
this.shown = true;
|
||||||
@ -195,7 +195,7 @@ var Lightbox = class Lightbox {
|
|||||||
{ brightness: 1.0,
|
{ brightness: 1.0,
|
||||||
vignetteSharpness: 0.0,
|
vignetteSharpness: 0.0,
|
||||||
opacity: 0,
|
opacity: 0,
|
||||||
time: fadeOutTime,
|
time: fadeOutTime / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
this.actor.hide();
|
this.actor.hide();
|
||||||
@ -205,7 +205,7 @@ var Lightbox = class Lightbox {
|
|||||||
Tweener.removeTweens(this.actor);
|
Tweener.removeTweens(this.actor);
|
||||||
Tweener.addTween(this.actor,
|
Tweener.addTween(this.actor,
|
||||||
{ opacity: 0,
|
{ opacity: 0,
|
||||||
time: fadeOutTime,
|
time: fadeOutTime / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
this.actor.hide();
|
this.actor.hide();
|
||||||
|
@ -34,7 +34,7 @@ var commandHeader = 'const { Clutter, Gio, GLib, GObject, Meta, Shell, St } = im
|
|||||||
const HISTORY_KEY = 'looking-glass-history';
|
const HISTORY_KEY = 'looking-glass-history';
|
||||||
// Time between tabs for them to count as a double-tab event
|
// Time between tabs for them to count as a double-tab event
|
||||||
var AUTO_COMPLETE_DOUBLE_TAB_DELAY = 500;
|
var AUTO_COMPLETE_DOUBLE_TAB_DELAY = 500;
|
||||||
var AUTO_COMPLETE_SHOW_COMPLETION_ANIMATION_DURATION = 0.2;
|
var AUTO_COMPLETE_SHOW_COMPLETION_ANIMATION_DURATION = 200;
|
||||||
var AUTO_COMPLETE_GLOBAL_KEYWORDS = _getAutoCompleteGlobalKeywords();
|
var AUTO_COMPLETE_GLOBAL_KEYWORDS = _getAutoCompleteGlobalKeywords();
|
||||||
|
|
||||||
function _getAutoCompleteGlobalKeywords() {
|
function _getAutoCompleteGlobalKeywords() {
|
||||||
@ -952,7 +952,7 @@ var LookingGlass = class LookingGlass {
|
|||||||
let settings = St.Settings.get();
|
let settings = St.Settings.get();
|
||||||
this._completionActor.show();
|
this._completionActor.show();
|
||||||
Tweener.removeTweens(this._completionActor);
|
Tweener.removeTweens(this._completionActor);
|
||||||
Tweener.addTween(this._completionActor, { time: AUTO_COMPLETE_SHOW_COMPLETION_ANIMATION_DURATION / settings.slow_down_factor,
|
Tweener.addTween(this._completionActor, { time: AUTO_COMPLETE_SHOW_COMPLETION_ANIMATION_DURATION / (1000 * settings.slow_down_factor),
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
height: naturalHeight,
|
height: naturalHeight,
|
||||||
opacity: 255
|
opacity: 255
|
||||||
@ -964,7 +964,7 @@ var LookingGlass = class LookingGlass {
|
|||||||
if (this._completionActor) {
|
if (this._completionActor) {
|
||||||
let settings = St.Settings.get();
|
let settings = St.Settings.get();
|
||||||
Tweener.removeTweens(this._completionActor);
|
Tweener.removeTweens(this._completionActor);
|
||||||
Tweener.addTween(this._completionActor, { time: AUTO_COMPLETE_SHOW_COMPLETION_ANIMATION_DURATION / settings.slow_down_factor,
|
Tweener.addTween(this._completionActor, { time: AUTO_COMPLETE_SHOW_COMPLETION_ANIMATION_DURATION / (1000 * settings.slow_down_factor),
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
height: 0,
|
height: 0,
|
||||||
opacity: 0,
|
opacity: 0,
|
||||||
|
@ -7,7 +7,7 @@ const Calendar = imports.ui.calendar;
|
|||||||
const Tweener = imports.ui.tweener;
|
const Tweener = imports.ui.tweener;
|
||||||
const Util = imports.misc.util;
|
const Util = imports.misc.util;
|
||||||
|
|
||||||
var MESSAGE_ANIMATION_TIME = 0.1;
|
var MESSAGE_ANIMATION_TIME = 100;
|
||||||
|
|
||||||
var DEFAULT_EXPAND_LINES = 6;
|
var DEFAULT_EXPAND_LINES = 6;
|
||||||
|
|
||||||
@ -442,12 +442,12 @@ var Message = class Message {
|
|||||||
if (animate) {
|
if (animate) {
|
||||||
Tweener.addTween(this._bodyStack.layout_manager,
|
Tweener.addTween(this._bodyStack.layout_manager,
|
||||||
{ expansion: 1,
|
{ expansion: 1,
|
||||||
time: MessageTray.ANIMATION_TIME,
|
time: MessageTray.ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad' });
|
transition: 'easeOutQuad' });
|
||||||
this._actionBin.scale_y = 0;
|
this._actionBin.scale_y = 0;
|
||||||
Tweener.addTween(this._actionBin,
|
Tweener.addTween(this._actionBin,
|
||||||
{ scale_y: 1,
|
{ scale_y: 1,
|
||||||
time: MessageTray.ANIMATION_TIME,
|
time: MessageTray.ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad' });
|
transition: 'easeOutQuad' });
|
||||||
} else {
|
} else {
|
||||||
this._bodyStack.layout_manager.expansion = 1;
|
this._bodyStack.layout_manager.expansion = 1;
|
||||||
@ -461,11 +461,11 @@ var Message = class Message {
|
|||||||
if (animate) {
|
if (animate) {
|
||||||
Tweener.addTween(this._bodyStack.layout_manager,
|
Tweener.addTween(this._bodyStack.layout_manager,
|
||||||
{ expansion: 0,
|
{ expansion: 0,
|
||||||
time: MessageTray.ANIMATION_TIME,
|
time: MessageTray.ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad' });
|
transition: 'easeOutQuad' });
|
||||||
Tweener.addTween(this._actionBin,
|
Tweener.addTween(this._actionBin,
|
||||||
{ scale_y: 0,
|
{ scale_y: 0,
|
||||||
time: MessageTray.ANIMATION_TIME,
|
time: MessageTray.ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
this._actionBin.hide();
|
this._actionBin.hide();
|
||||||
@ -583,7 +583,7 @@ var MessageListSection = class MessageListSection {
|
|||||||
if (animate)
|
if (animate)
|
||||||
Tweener.addTween(obj.container, { scale_x: 1,
|
Tweener.addTween(obj.container, { scale_x: 1,
|
||||||
scale_y: 1,
|
scale_y: 1,
|
||||||
time: MESSAGE_ANIMATION_TIME,
|
time: MESSAGE_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad' });
|
transition: 'easeOutQuad' });
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -599,12 +599,12 @@ var MessageListSection = class MessageListSection {
|
|||||||
this._list.set_child_at_index(obj.container, index);
|
this._list.set_child_at_index(obj.container, index);
|
||||||
Tweener.addTween(obj.container, { scale_x: 1,
|
Tweener.addTween(obj.container, { scale_x: 1,
|
||||||
scale_y: 1,
|
scale_y: 1,
|
||||||
time: MESSAGE_ANIMATION_TIME,
|
time: MESSAGE_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad' });
|
transition: 'easeOutQuad' });
|
||||||
};
|
};
|
||||||
Tweener.addTween(obj.container, { scale_x: 0,
|
Tweener.addTween(obj.container, { scale_x: 0,
|
||||||
scale_y: 0,
|
scale_y: 0,
|
||||||
time: MESSAGE_ANIMATION_TIME,
|
time: MESSAGE_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: onComplete });
|
onComplete: onComplete });
|
||||||
}
|
}
|
||||||
@ -620,7 +620,7 @@ var MessageListSection = class MessageListSection {
|
|||||||
|
|
||||||
if (animate) {
|
if (animate) {
|
||||||
Tweener.addTween(obj.container, { scale_x: 0, scale_y: 0,
|
Tweener.addTween(obj.container, { scale_x: 0, scale_y: 0,
|
||||||
time: MESSAGE_ANIMATION_TIME,
|
time: MESSAGE_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete() {
|
onComplete() {
|
||||||
obj.container.destroy();
|
obj.container.destroy();
|
||||||
@ -650,8 +650,8 @@ var MessageListSection = class MessageListSection {
|
|||||||
Tweener.addTween(obj.container,
|
Tweener.addTween(obj.container,
|
||||||
{ anchor_x: this._list.width,
|
{ anchor_x: this._list.width,
|
||||||
opacity: 0,
|
opacity: 0,
|
||||||
time: MESSAGE_ANIMATION_TIME,
|
time: MESSAGE_ANIMATION_TIME / 1000,
|
||||||
delay: i * delay,
|
delay: i * delay / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete() {
|
onComplete() {
|
||||||
message.close();
|
message.close();
|
||||||
|
@ -16,11 +16,11 @@ const Tweener = imports.ui.tweener;
|
|||||||
|
|
||||||
const SHELL_KEYBINDINGS_SCHEMA = 'org.gnome.shell.keybindings';
|
const SHELL_KEYBINDINGS_SCHEMA = 'org.gnome.shell.keybindings';
|
||||||
|
|
||||||
var ANIMATION_TIME = 0.2;
|
var ANIMATION_TIME = 200;
|
||||||
var NOTIFICATION_TIMEOUT = 4;
|
var NOTIFICATION_TIMEOUT = 4000;
|
||||||
|
|
||||||
var HIDE_TIMEOUT = 0.2;
|
var HIDE_TIMEOUT = 200;
|
||||||
var LONGER_HIDE_TIMEOUT = 0.6;
|
var LONGER_HIDE_TIMEOUT = 600;
|
||||||
|
|
||||||
var MAX_NOTIFICATIONS_IN_QUEUE = 3;
|
var MAX_NOTIFICATIONS_IN_QUEUE = 3;
|
||||||
var MAX_NOTIFICATIONS_PER_SOURCE = 3;
|
var MAX_NOTIFICATIONS_PER_SOURCE = 3;
|
||||||
@ -1137,7 +1137,7 @@ var MessageTray = class MessageTray {
|
|||||||
// We wait just a little before hiding the message tray in case the user quickly moves the mouse back into it.
|
// We wait just a little before hiding the message tray in case the user quickly moves the mouse back into it.
|
||||||
// We wait for a longer period if the notification popped up where the mouse pointer was already positioned.
|
// We wait for a longer period if the notification popped up where the mouse pointer was already positioned.
|
||||||
// That gives the user more time to mouse away from the notification and mouse back in in order to expand it.
|
// That gives the user more time to mouse away from the notification and mouse back in in order to expand it.
|
||||||
let timeout = this._useLongerNotificationLeftTimeout ? LONGER_HIDE_TIMEOUT * 1000 : HIDE_TIMEOUT * 1000;
|
let timeout = this._useLongerNotificationLeftTimeout ? LONGER_HIDE_TIMEOUT : HIDE_TIMEOUT;
|
||||||
this._notificationLeftTimeoutId = Mainloop.timeout_add(timeout, this._onNotificationLeftTimeout.bind(this));
|
this._notificationLeftTimeoutId = Mainloop.timeout_add(timeout, this._onNotificationLeftTimeout.bind(this));
|
||||||
GLib.Source.set_name_by_id(this._notificationLeftTimeoutId, '[gnome-shell] this._onNotificationLeftTimeout');
|
GLib.Source.set_name_by_id(this._notificationLeftTimeoutId, '[gnome-shell] this._onNotificationLeftTimeout');
|
||||||
}
|
}
|
||||||
@ -1167,7 +1167,7 @@ var MessageTray = class MessageTray {
|
|||||||
x < this._notificationLeftMouseX + MOUSE_LEFT_ACTOR_THRESHOLD &&
|
x < this._notificationLeftMouseX + MOUSE_LEFT_ACTOR_THRESHOLD &&
|
||||||
x > this._notificationLeftMouseX - MOUSE_LEFT_ACTOR_THRESHOLD) {
|
x > this._notificationLeftMouseX - MOUSE_LEFT_ACTOR_THRESHOLD) {
|
||||||
this._notificationLeftMouseX = -1;
|
this._notificationLeftMouseX = -1;
|
||||||
this._notificationLeftTimeoutId = Mainloop.timeout_add(LONGER_HIDE_TIMEOUT * 1000,
|
this._notificationLeftTimeoutId = Mainloop.timeout_add(LONGER_HIDE_TIMEOUT,
|
||||||
this._onNotificationLeftTimeout.bind(this));
|
this._onNotificationLeftTimeout.bind(this));
|
||||||
GLib.Source.set_name_by_id(this._notificationLeftTimeoutId, '[gnome-shell] this._onNotificationLeftTimeout');
|
GLib.Source.set_name_by_id(this._notificationLeftTimeoutId, '[gnome-shell] this._onNotificationLeftTimeout');
|
||||||
} else {
|
} else {
|
||||||
@ -1351,7 +1351,7 @@ var MessageTray = class MessageTray {
|
|||||||
|
|
||||||
let tweenParams = { y: 0,
|
let tweenParams = { y: 0,
|
||||||
_opacity: 255,
|
_opacity: 255,
|
||||||
time: ANIMATION_TIME,
|
time: ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutBack',
|
transition: 'easeOutBack',
|
||||||
onUpdate: this._clampOpacity,
|
onUpdate: this._clampOpacity,
|
||||||
onUpdateScope: this,
|
onUpdateScope: this,
|
||||||
@ -1364,7 +1364,7 @@ var MessageTray = class MessageTray {
|
|||||||
|
|
||||||
_showNotificationCompleted() {
|
_showNotificationCompleted() {
|
||||||
if (this._notification.urgency != Urgency.CRITICAL)
|
if (this._notification.urgency != Urgency.CRITICAL)
|
||||||
this._updateNotificationTimeout(NOTIFICATION_TIMEOUT * 1000);
|
this._updateNotificationTimeout(NOTIFICATION_TIMEOUT);
|
||||||
}
|
}
|
||||||
|
|
||||||
_updateNotificationTimeout(timeout) {
|
_updateNotificationTimeout(timeout) {
|
||||||
@ -1422,7 +1422,7 @@ var MessageTray = class MessageTray {
|
|||||||
this._tween(this._bannerBin, '_notificationState', State.HIDDEN,
|
this._tween(this._bannerBin, '_notificationState', State.HIDDEN,
|
||||||
{ y: -this._bannerBin.height,
|
{ y: -this._bannerBin.height,
|
||||||
_opacity: 0,
|
_opacity: 0,
|
||||||
time: ANIMATION_TIME,
|
time: ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutBack',
|
transition: 'easeOutBack',
|
||||||
onUpdate: this._clampOpacity,
|
onUpdate: this._clampOpacity,
|
||||||
onUpdateScope: this,
|
onUpdateScope: this,
|
||||||
|
@ -10,8 +10,8 @@ const Main = imports.ui.main;
|
|||||||
const Params = imports.misc.params;
|
const Params = imports.misc.params;
|
||||||
const Tweener = imports.ui.tweener;
|
const Tweener = imports.ui.tweener;
|
||||||
|
|
||||||
var OPEN_AND_CLOSE_TIME = 0.1;
|
var OPEN_AND_CLOSE_TIME = 100;
|
||||||
var FADE_OUT_DIALOG_TIME = 1.0;
|
var FADE_OUT_DIALOG_TIME = 1000;
|
||||||
|
|
||||||
var State = {
|
var State = {
|
||||||
OPENED: 0,
|
OPENED: 0,
|
||||||
@ -127,7 +127,7 @@ var ModalDialog = GObject.registerClass({
|
|||||||
this.show();
|
this.show();
|
||||||
Tweener.addTween(this,
|
Tweener.addTween(this,
|
||||||
{ opacity: 255,
|
{ opacity: 255,
|
||||||
time: this._shouldFadeIn ? OPEN_AND_CLOSE_TIME : 0,
|
time: this._shouldFadeIn ? OPEN_AND_CLOSE_TIME / 1000 : 0,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
this._setState(State.OPENED);
|
this._setState(State.OPENED);
|
||||||
@ -179,7 +179,7 @@ var ModalDialog = GObject.registerClass({
|
|||||||
if (this._shouldFadeOut)
|
if (this._shouldFadeOut)
|
||||||
Tweener.addTween(this,
|
Tweener.addTween(this,
|
||||||
{ opacity: 0,
|
{ opacity: 0,
|
||||||
time: OPEN_AND_CLOSE_TIME,
|
time: OPEN_AND_CLOSE_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: this._closeComplete.bind(this)
|
onComplete: this._closeComplete.bind(this)
|
||||||
});
|
});
|
||||||
@ -251,7 +251,7 @@ var ModalDialog = GObject.registerClass({
|
|||||||
this.popModal(timestamp);
|
this.popModal(timestamp);
|
||||||
Tweener.addTween(this.dialogLayout,
|
Tweener.addTween(this.dialogLayout,
|
||||||
{ opacity: 0,
|
{ opacity: 0,
|
||||||
time: FADE_OUT_DIALOG_TIME,
|
time: FADE_OUT_DIALOG_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
this._setState(State.FADED_OUT);
|
this._setState(State.FADED_OUT);
|
||||||
|
@ -10,8 +10,8 @@ const Main = imports.ui.main;
|
|||||||
const Tweener = imports.ui.tweener;
|
const Tweener = imports.ui.tweener;
|
||||||
|
|
||||||
var HIDE_TIMEOUT = 1500;
|
var HIDE_TIMEOUT = 1500;
|
||||||
var FADE_TIME = 0.1;
|
var FADE_TIME = 100;
|
||||||
var LEVEL_ANIMATION_TIME = 0.1;
|
var LEVEL_ANIMATION_TIME = 100;
|
||||||
|
|
||||||
var OsdWindowConstraint = GObject.registerClass(
|
var OsdWindowConstraint = GObject.registerClass(
|
||||||
class OsdWindowConstraint extends Clutter.Constraint {
|
class OsdWindowConstraint extends Clutter.Constraint {
|
||||||
@ -112,7 +112,7 @@ var OsdWindow = class {
|
|||||||
if (this.actor.visible)
|
if (this.actor.visible)
|
||||||
Tweener.addTween(this._level,
|
Tweener.addTween(this._level,
|
||||||
{ value: value,
|
{ value: value,
|
||||||
time: LEVEL_ANIMATION_TIME,
|
time: LEVEL_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad' });
|
transition: 'easeOutQuad' });
|
||||||
else
|
else
|
||||||
this._level.value = value;
|
this._level.value = value;
|
||||||
@ -135,7 +135,7 @@ var OsdWindow = class {
|
|||||||
|
|
||||||
Tweener.addTween(this.actor,
|
Tweener.addTween(this.actor,
|
||||||
{ opacity: 255,
|
{ opacity: 255,
|
||||||
time: FADE_TIME,
|
time: FADE_TIME / 1000,
|
||||||
transition: 'easeOutQuad' });
|
transition: 'easeOutQuad' });
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -158,7 +158,7 @@ var OsdWindow = class {
|
|||||||
this._hideTimeoutId = 0;
|
this._hideTimeoutId = 0;
|
||||||
Tweener.addTween(this.actor,
|
Tweener.addTween(this.actor,
|
||||||
{ opacity: 0,
|
{ opacity: 0,
|
||||||
time: FADE_TIME,
|
time: FADE_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
this._reset();
|
this._reset();
|
||||||
|
@ -17,12 +17,12 @@ const Tweener = imports.ui.tweener;
|
|||||||
const WorkspaceThumbnail = imports.ui.workspaceThumbnail;
|
const WorkspaceThumbnail = imports.ui.workspaceThumbnail;
|
||||||
|
|
||||||
// Time for initial animation going into Overview mode
|
// Time for initial animation going into Overview mode
|
||||||
var ANIMATION_TIME = 0.25;
|
var ANIMATION_TIME = 250;
|
||||||
|
|
||||||
// Must be less than ANIMATION_TIME, since we switch to
|
// Must be less than ANIMATION_TIME, since we switch to
|
||||||
// or from the overview completely after ANIMATION_TIME,
|
// or from the overview completely after ANIMATION_TIME,
|
||||||
// and don't want the shading animation to get cut off
|
// and don't want the shading animation to get cut off
|
||||||
var SHADE_ANIMATION_TIME = .20;
|
var SHADE_ANIMATION_TIME = 200;
|
||||||
|
|
||||||
var DND_WINDOW_SWITCH_TIMEOUT = 750;
|
var DND_WINDOW_SWITCH_TIMEOUT = 750;
|
||||||
|
|
||||||
@ -177,7 +177,7 @@ var Overview = class {
|
|||||||
Tweener.addTween(backgrounds[i],
|
Tweener.addTween(backgrounds[i],
|
||||||
{ brightness: 1.0,
|
{ brightness: 1.0,
|
||||||
vignette_sharpness: 0.0,
|
vignette_sharpness: 0.0,
|
||||||
time: SHADE_ANIMATION_TIME,
|
time: SHADE_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad'
|
transition: 'easeOutQuad'
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@ -189,7 +189,7 @@ var Overview = class {
|
|||||||
Tweener.addTween(backgrounds[i],
|
Tweener.addTween(backgrounds[i],
|
||||||
{ brightness: Lightbox.VIGNETTE_BRIGHTNESS,
|
{ brightness: Lightbox.VIGNETTE_BRIGHTNESS,
|
||||||
vignette_sharpness: Lightbox.VIGNETTE_SHARPNESS,
|
vignette_sharpness: Lightbox.VIGNETTE_SHARPNESS,
|
||||||
time: SHADE_ANIMATION_TIME,
|
time: SHADE_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad'
|
transition: 'easeOutQuad'
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@ -429,7 +429,7 @@ var Overview = class {
|
|||||||
this._desktopFade.show();
|
this._desktopFade.show();
|
||||||
Tweener.addTween(this._desktopFade,
|
Tweener.addTween(this._desktopFade,
|
||||||
{ opacity: 255,
|
{ opacity: 255,
|
||||||
time: ANIMATION_TIME,
|
time: ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad' });
|
transition: 'easeOutQuad' });
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -446,7 +446,7 @@ var Overview = class {
|
|||||||
this._desktopFade.show();
|
this._desktopFade.show();
|
||||||
Tweener.addTween(this._desktopFade,
|
Tweener.addTween(this._desktopFade,
|
||||||
{ opacity: 0,
|
{ opacity: 0,
|
||||||
time: ANIMATION_TIME,
|
time: ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad'
|
transition: 'easeOutQuad'
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@ -531,7 +531,7 @@ var Overview = class {
|
|||||||
Tweener.addTween(this._overview,
|
Tweener.addTween(this._overview,
|
||||||
{ opacity: 255,
|
{ opacity: 255,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
time: ANIMATION_TIME,
|
time: ANIMATION_TIME / 1000,
|
||||||
onComplete: this._showDone,
|
onComplete: this._showDone,
|
||||||
onCompleteScope: this
|
onCompleteScope: this
|
||||||
});
|
});
|
||||||
@ -595,7 +595,7 @@ var Overview = class {
|
|||||||
Tweener.addTween(this._overview,
|
Tweener.addTween(this._overview,
|
||||||
{ opacity: 0,
|
{ opacity: 0,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
time: ANIMATION_TIME,
|
time: ANIMATION_TIME / 1000,
|
||||||
onComplete: this._hideDone,
|
onComplete: this._hideDone,
|
||||||
onCompleteScope: this
|
onCompleteScope: this
|
||||||
});
|
});
|
||||||
|
@ -10,7 +10,7 @@ const Tweener = imports.ui.tweener;
|
|||||||
const ViewSelector = imports.ui.viewSelector;
|
const ViewSelector = imports.ui.viewSelector;
|
||||||
const WorkspaceThumbnail = imports.ui.workspaceThumbnail;
|
const WorkspaceThumbnail = imports.ui.workspaceThumbnail;
|
||||||
|
|
||||||
var SIDE_CONTROLS_ANIMATION_TIME = 0.16;
|
var SIDE_CONTROLS_ANIMATION_TIME = 160;
|
||||||
|
|
||||||
function getRtlSlideDirection(direction, actor) {
|
function getRtlSlideDirection(direction, actor) {
|
||||||
let rtl = (actor.text_direction == Clutter.TextDirection.RTL);
|
let rtl = (actor.text_direction == Clutter.TextDirection.RTL);
|
||||||
@ -128,7 +128,7 @@ var SlidingControl = class {
|
|||||||
|
|
||||||
_updateSlide() {
|
_updateSlide() {
|
||||||
Tweener.addTween(this.layout, { slideX: this._getSlide(),
|
Tweener.addTween(this.layout, { slideX: this._getSlide(),
|
||||||
time: SIDE_CONTROLS_ANIMATION_TIME,
|
time: SIDE_CONTROLS_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad' });
|
transition: 'easeOutQuad' });
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -166,7 +166,7 @@ var SlidingControl = class {
|
|||||||
|
|
||||||
this.layout.translationX = translationStart;
|
this.layout.translationX = translationStart;
|
||||||
Tweener.addTween(this.layout, { translationX: translationEnd,
|
Tweener.addTween(this.layout, { translationX: translationEnd,
|
||||||
time: SIDE_CONTROLS_ANIMATION_TIME,
|
time: SIDE_CONTROLS_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad' });
|
transition: 'easeOutQuad' });
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -197,14 +197,14 @@ var SlidingControl = class {
|
|||||||
|
|
||||||
fadeIn() {
|
fadeIn() {
|
||||||
Tweener.addTween(this.actor, { opacity: 255,
|
Tweener.addTween(this.actor, { opacity: 255,
|
||||||
time: SIDE_CONTROLS_ANIMATION_TIME / 2,
|
time: SIDE_CONTROLS_ANIMATION_TIME / (2 * 1000),
|
||||||
transition: 'easeInQuad'
|
transition: 'easeInQuad'
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
fadeHalf() {
|
fadeHalf() {
|
||||||
Tweener.addTween(this.actor, { opacity: 128,
|
Tweener.addTween(this.actor, { opacity: 128,
|
||||||
time: SIDE_CONTROLS_ANIMATION_TIME / 2,
|
time: SIDE_CONTROLS_ANIMATION_TIME / (2 * 1000),
|
||||||
transition: 'easeOutQuad'
|
transition: 'easeOutQuad'
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -6,17 +6,17 @@ const { Clutter, GObject, St } = imports.gi;
|
|||||||
const Tweener = imports.ui.tweener;
|
const Tweener = imports.ui.tweener;
|
||||||
const { ANIMATION_TIME_OUT, ANIMATION_MAX_DELAY_OUT_FOR_ITEM, AnimationDirection } = imports.ui.iconGrid;
|
const { ANIMATION_TIME_OUT, ANIMATION_MAX_DELAY_OUT_FOR_ITEM, AnimationDirection } = imports.ui.iconGrid;
|
||||||
|
|
||||||
var INDICATORS_BASE_TIME = 0.25;
|
var INDICATORS_BASE_TIME = 250;
|
||||||
var INDICATORS_BASE_TIME_OUT = 0.125;
|
var INDICATORS_BASE_TIME_OUT = 125;
|
||||||
var INDICATORS_ANIMATION_DELAY = 0.125;
|
var INDICATORS_ANIMATION_DELAY = 125;
|
||||||
var INDICATORS_ANIMATION_DELAY_OUT = 0.0625;
|
var INDICATORS_ANIMATION_DELAY_OUT = 62.5;
|
||||||
var INDICATORS_ANIMATION_MAX_TIME = 0.75;
|
var INDICATORS_ANIMATION_MAX_TIME = 750;
|
||||||
var SWITCH_TIME = 0.4;
|
var SWITCH_TIME = 400;
|
||||||
var INDICATORS_ANIMATION_MAX_TIME_OUT =
|
var INDICATORS_ANIMATION_MAX_TIME_OUT =
|
||||||
Math.min (SWITCH_TIME,
|
Math.min (SWITCH_TIME,
|
||||||
ANIMATION_TIME_OUT + ANIMATION_MAX_DELAY_OUT_FOR_ITEM);
|
ANIMATION_TIME_OUT + ANIMATION_MAX_DELAY_OUT_FOR_ITEM);
|
||||||
|
|
||||||
var ANIMATION_DELAY = 0.1;
|
var ANIMATION_DELAY = 100;
|
||||||
|
|
||||||
var PageIndicators = GObject.registerClass({
|
var PageIndicators = GObject.registerClass({
|
||||||
Signals: { 'page-activated': { param_types: [GObject.TYPE_INT] } }
|
Signals: { 'page-activated': { param_types: [GObject.TYPE_INT] } }
|
||||||
@ -132,9 +132,9 @@ class AnimatedPageIndicators extends PageIndicators {
|
|||||||
children[i].translation_x = isAnimationIn ? offset : 0;
|
children[i].translation_x = isAnimationIn ? offset : 0;
|
||||||
Tweener.addTween(children[i], {
|
Tweener.addTween(children[i], {
|
||||||
translation_x: isAnimationIn ? 0 : offset,
|
translation_x: isAnimationIn ? 0 : offset,
|
||||||
time: baseTime + delay * i,
|
time: (baseTime + delay * i) / 1000,
|
||||||
transition: 'easeInOutQuad',
|
transition: 'easeInOutQuad',
|
||||||
delay: isAnimationIn ? ANIMATION_DELAY : 0
|
delay: isAnimationIn ? ANIMATION_DELAY / 1000 : 0
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -265,7 +265,7 @@ var AppMenuButton = GObject.registerClass({
|
|||||||
Tweener.removeTweens(this);
|
Tweener.removeTweens(this);
|
||||||
Tweener.addTween(this,
|
Tweener.addTween(this,
|
||||||
{ opacity: 255,
|
{ opacity: 255,
|
||||||
time: Overview.ANIMATION_TIME,
|
time: Overview.ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad' });
|
transition: 'easeOutQuad' });
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -278,7 +278,7 @@ var AppMenuButton = GObject.registerClass({
|
|||||||
Tweener.removeTweens(this);
|
Tweener.removeTweens(this);
|
||||||
Tweener.addTween(this,
|
Tweener.addTween(this,
|
||||||
{ opacity: 0,
|
{ opacity: 0,
|
||||||
time: Overview.ANIMATION_TIME,
|
time: Overview.ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
this.hide();
|
this.hide();
|
||||||
|
@ -19,7 +19,7 @@ const TERMINAL_SCHEMA = 'org.gnome.desktop.default-applications.terminal';
|
|||||||
const EXEC_KEY = 'exec';
|
const EXEC_KEY = 'exec';
|
||||||
const EXEC_ARG_KEY = 'exec-arg';
|
const EXEC_ARG_KEY = 'exec-arg';
|
||||||
|
|
||||||
var DIALOG_GROW_TIME = 0.1;
|
var DIALOG_GROW_TIME = 100;
|
||||||
|
|
||||||
var RunDialog = GObject.registerClass(
|
var RunDialog = GObject.registerClass(
|
||||||
class RunDialog extends ModalDialog.ModalDialog {
|
class RunDialog extends ModalDialog.ModalDialog {
|
||||||
@ -245,7 +245,7 @@ class RunDialog extends ModalDialog.ModalDialog {
|
|||||||
let parentActor = this._errorBox.get_parent();
|
let parentActor = this._errorBox.get_parent();
|
||||||
Tweener.addTween(parentActor,
|
Tweener.addTween(parentActor,
|
||||||
{ height: parentActor.height + errorBoxNaturalHeight,
|
{ height: parentActor.height + errorBoxNaturalHeight,
|
||||||
time: DIALOG_GROW_TIME,
|
time: DIALOG_GROW_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
parentActor.set_height(-1);
|
parentActor.set_height(-1);
|
||||||
|
@ -34,7 +34,7 @@ var ARROW_DRAG_THRESHOLD = 0.1;
|
|||||||
|
|
||||||
// Parameters for the arrow animation
|
// Parameters for the arrow animation
|
||||||
var N_ARROWS = 3;
|
var N_ARROWS = 3;
|
||||||
var ARROW_ANIMATION_TIME = 0.6;
|
var ARROW_ANIMATION_TIME = 600;
|
||||||
var ARROW_ANIMATION_PEAK_OPACITY = 0.4;
|
var ARROW_ANIMATION_PEAK_OPACITY = 0.4;
|
||||||
var ARROW_IDLE_TIME = 30000; // ms
|
var ARROW_IDLE_TIME = 30000; // ms
|
||||||
|
|
||||||
@ -45,9 +45,9 @@ var SUMMARY_ICON_SIZE = 48;
|
|||||||
// - MANUAL_FADE_TIME is used for lowering the shield when asked by the user,
|
// - MANUAL_FADE_TIME is used for lowering the shield when asked by the user,
|
||||||
// or when cancelling the dialog
|
// or when cancelling the dialog
|
||||||
// - CURTAIN_SLIDE_TIME is used when raising the shield before unlocking
|
// - CURTAIN_SLIDE_TIME is used when raising the shield before unlocking
|
||||||
var STANDARD_FADE_TIME = 10;
|
var STANDARD_FADE_TIME = 10000;
|
||||||
var MANUAL_FADE_TIME = 0.3;
|
var MANUAL_FADE_TIME = 300;
|
||||||
var CURTAIN_SLIDE_TIME = 0.3;
|
var CURTAIN_SLIDE_TIME = 300;
|
||||||
|
|
||||||
var Clock = class {
|
var Clock = class {
|
||||||
constructor() {
|
constructor() {
|
||||||
@ -737,8 +737,8 @@ var ScreenShield = class {
|
|||||||
arrows[i].opacity = 0;
|
arrows[i].opacity = 0;
|
||||||
Tweener.addTween(arrows[i],
|
Tweener.addTween(arrows[i],
|
||||||
{ opacity: 0,
|
{ opacity: 0,
|
||||||
delay: unitaryDelay * (N_ARROWS - (i + 1)),
|
delay: (unitaryDelay * (N_ARROWS - (i + 1))) / 1000,
|
||||||
time: ARROW_ANIMATION_TIME,
|
time: ARROW_ANIMATION_TIME / 1000,
|
||||||
transition(t, b, c, d) {
|
transition(t, b, c, d) {
|
||||||
if (t < d / 2)
|
if (t < d / 2)
|
||||||
return TweenerEquations.easeOutQuad(t, 0, maxOpacity, d / 2);
|
return TweenerEquations.easeOutQuad(t, 0, maxOpacity, d / 2);
|
||||||
@ -788,7 +788,7 @@ var ScreenShield = class {
|
|||||||
Tweener.removeTweens(this._lockScreenGroup);
|
Tweener.removeTweens(this._lockScreenGroup);
|
||||||
Tweener.addTween(this._lockScreenGroup,
|
Tweener.addTween(this._lockScreenGroup,
|
||||||
{ y: 0,
|
{ y: 0,
|
||||||
time: time,
|
time: time / 1000,
|
||||||
transition: 'easeInQuad',
|
transition: 'easeInQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
this._lockScreenGroup.fixed_position_set = false;
|
this._lockScreenGroup.fixed_position_set = false;
|
||||||
@ -830,8 +830,10 @@ var ScreenShield = class {
|
|||||||
let shouldLock = this._settings.get_boolean(LOCK_ENABLED_KEY) && !this._isLocked;
|
let shouldLock = this._settings.get_boolean(LOCK_ENABLED_KEY) && !this._isLocked;
|
||||||
|
|
||||||
if (shouldLock) {
|
if (shouldLock) {
|
||||||
let lockTimeout = Math.max(STANDARD_FADE_TIME, this._settings.get_uint(LOCK_DELAY_KEY));
|
let lockTimeout = Math.max(
|
||||||
this._lockTimeoutId = Mainloop.timeout_add(lockTimeout * 1000,
|
STANDARD_FADE_TIME,
|
||||||
|
this._settings.get_uint(LOCK_DELAY_KEY) * 1000);
|
||||||
|
this._lockTimeoutId = Mainloop.timeout_add(lockTimeout,
|
||||||
() => {
|
() => {
|
||||||
this._lockTimeoutId = 0;
|
this._lockTimeoutId = 0;
|
||||||
this.lock(false);
|
this.lock(false);
|
||||||
@ -931,14 +933,14 @@ var ScreenShield = class {
|
|||||||
// if velocity is specified, it's in pixels per milliseconds
|
// if velocity is specified, it's in pixels per milliseconds
|
||||||
let h = global.stage.height;
|
let h = global.stage.height;
|
||||||
let delta = (h + this._lockScreenGroup.y);
|
let delta = (h + this._lockScreenGroup.y);
|
||||||
let minVelocity = global.stage.height / (CURTAIN_SLIDE_TIME * 1000);
|
let minVelocity = global.stage.height / CURTAIN_SLIDE_TIME;
|
||||||
|
|
||||||
velocity = Math.max(minVelocity, velocity);
|
velocity = Math.max(minVelocity, velocity);
|
||||||
let time = (delta / velocity) / 1000;
|
let time = delta / velocity;
|
||||||
|
|
||||||
Tweener.addTween(this._lockScreenGroup,
|
Tweener.addTween(this._lockScreenGroup,
|
||||||
{ y: -h,
|
{ y: -h,
|
||||||
time: time,
|
time: time / 1000,
|
||||||
transition: 'easeInQuad',
|
transition: 'easeInQuad',
|
||||||
onComplete: this._hideLockScreenComplete.bind(this),
|
onComplete: this._hideLockScreenComplete.bind(this),
|
||||||
});
|
});
|
||||||
@ -1004,7 +1006,7 @@ var ScreenShield = class {
|
|||||||
Tweener.removeTweens(this._lockScreenGroup);
|
Tweener.removeTweens(this._lockScreenGroup);
|
||||||
Tweener.addTween(this._lockScreenGroup,
|
Tweener.addTween(this._lockScreenGroup,
|
||||||
{ y: 0,
|
{ y: 0,
|
||||||
time: MANUAL_FADE_TIME,
|
time: MANUAL_FADE_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
this._lockScreenShown({ fadeToBlack: fadeToBlack,
|
this._lockScreenShown({ fadeToBlack: fadeToBlack,
|
||||||
@ -1096,7 +1098,7 @@ var ScreenShield = class {
|
|||||||
if (params.fadeToBlack && params.animateFade) {
|
if (params.fadeToBlack && params.animateFade) {
|
||||||
// Take a beat
|
// Take a beat
|
||||||
|
|
||||||
let id = Mainloop.timeout_add(1000 * MANUAL_FADE_TIME, () => {
|
let id = Mainloop.timeout_add(MANUAL_FADE_TIME, () => {
|
||||||
this._activateFade(this._shortLightbox, MANUAL_FADE_TIME);
|
this._activateFade(this._shortLightbox, MANUAL_FADE_TIME);
|
||||||
return GLib.SOURCE_REMOVE;
|
return GLib.SOURCE_REMOVE;
|
||||||
});
|
});
|
||||||
@ -1217,7 +1219,7 @@ var ScreenShield = class {
|
|||||||
Tweener.addTween(this._lockDialogGroup, {
|
Tweener.addTween(this._lockDialogGroup, {
|
||||||
scale_x: 0,
|
scale_x: 0,
|
||||||
scale_y: 0,
|
scale_y: 0,
|
||||||
time: animate ? Overview.ANIMATION_TIME : 0,
|
time: animate ? Overview.ANIMATION_TIME / 1000 : 0,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: this._completeDeactivate.bind(this),
|
onComplete: this._completeDeactivate.bind(this),
|
||||||
onCompleteScope: this
|
onCompleteScope: this
|
||||||
|
@ -367,7 +367,7 @@ var PickPixel = class {
|
|||||||
};
|
};
|
||||||
Signals.addSignalMethods(PickPixel.prototype);
|
Signals.addSignalMethods(PickPixel.prototype);
|
||||||
|
|
||||||
var FLASHSPOT_ANIMATION_OUT_TIME = 0.5; // seconds
|
var FLASHSPOT_ANIMATION_OUT_TIME = 500; // milliseconds
|
||||||
|
|
||||||
var Flashspot = class extends Lightbox.Lightbox {
|
var Flashspot = class extends Lightbox.Lightbox {
|
||||||
constructor(area) {
|
constructor(area) {
|
||||||
@ -384,7 +384,7 @@ var Flashspot = class extends Lightbox.Lightbox {
|
|||||||
this.actor.opacity = 255;
|
this.actor.opacity = 255;
|
||||||
Tweener.addTween(this.actor,
|
Tweener.addTween(this.actor,
|
||||||
{ opacity: 0,
|
{ opacity: 0,
|
||||||
time: FLASHSPOT_ANIMATION_OUT_TIME,
|
time: FLASHSPOT_ANIMATION_OUT_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
if (doneCallback)
|
if (doneCallback)
|
||||||
|
@ -9,8 +9,8 @@ const Tweener = imports.ui.tweener;
|
|||||||
|
|
||||||
var POPUP_DELAY_TIMEOUT = 150; // milliseconds
|
var POPUP_DELAY_TIMEOUT = 150; // milliseconds
|
||||||
|
|
||||||
var POPUP_SCROLL_TIME = 0.10; // seconds
|
var POPUP_SCROLL_TIME = 100; // milliseconds
|
||||||
var POPUP_FADE_OUT_TIME = 0.1; // seconds
|
var POPUP_FADE_OUT_TIME = 100; // milliseconds
|
||||||
|
|
||||||
var DISABLE_HOVER_TIMEOUT = 500; // milliseconds
|
var DISABLE_HOVER_TIMEOUT = 500; // milliseconds
|
||||||
var NO_MODS_TIMEOUT = 1500; // milliseconds
|
var NO_MODS_TIMEOUT = 1500; // milliseconds
|
||||||
@ -286,7 +286,7 @@ var SwitcherPopup = GObject.registerClass({
|
|||||||
if (this.visible) {
|
if (this.visible) {
|
||||||
Tweener.addTween(this,
|
Tweener.addTween(this,
|
||||||
{ opacity: 0,
|
{ opacity: 0,
|
||||||
time: POPUP_FADE_OUT_TIME,
|
time: POPUP_FADE_OUT_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
this.destroy();
|
this.destroy();
|
||||||
@ -463,7 +463,7 @@ var SwitcherList = GObject.registerClass({
|
|||||||
this._scrollableRight = true;
|
this._scrollableRight = true;
|
||||||
Tweener.addTween(adjustment,
|
Tweener.addTween(adjustment,
|
||||||
{ value: value,
|
{ value: value,
|
||||||
time: POPUP_SCROLL_TIME,
|
time: POPUP_SCROLL_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
if (this._highlighted == 0)
|
if (this._highlighted == 0)
|
||||||
@ -487,7 +487,7 @@ var SwitcherList = GObject.registerClass({
|
|||||||
this._scrollableLeft = true;
|
this._scrollableLeft = true;
|
||||||
Tweener.addTween(adjustment,
|
Tweener.addTween(adjustment,
|
||||||
{ value: value,
|
{ value: value,
|
||||||
time: POPUP_SCROLL_TIME,
|
time: POPUP_SCROLL_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
if (this._highlighted == this._items.length - 1)
|
if (this._highlighted == this._items.length - 1)
|
||||||
|
@ -324,7 +324,7 @@ var ViewSelector = class {
|
|||||||
_fadePageIn() {
|
_fadePageIn() {
|
||||||
Tweener.addTween(this._activePage,
|
Tweener.addTween(this._activePage,
|
||||||
{ opacity: 255,
|
{ opacity: 255,
|
||||||
time: OverviewControls.SIDE_CONTROLS_ANIMATION_TIME,
|
time: OverviewControls.SIDE_CONTROLS_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad'
|
transition: 'easeOutQuad'
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@ -333,7 +333,7 @@ var ViewSelector = class {
|
|||||||
let oldPage = page;
|
let oldPage = page;
|
||||||
Tweener.addTween(page,
|
Tweener.addTween(page,
|
||||||
{ opacity: 0,
|
{ opacity: 0,
|
||||||
time: OverviewControls.SIDE_CONTROLS_ANIMATION_TIME,
|
time: OverviewControls.SIDE_CONTROLS_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
this._animateIn(oldPage);
|
this._animateIn(oldPage);
|
||||||
@ -606,7 +606,7 @@ var ViewSelector = class {
|
|||||||
fadeIn() {
|
fadeIn() {
|
||||||
let actor = this._activePage;
|
let actor = this._activePage;
|
||||||
Tweener.addTween(actor, { opacity: 255,
|
Tweener.addTween(actor, { opacity: 255,
|
||||||
time: OverviewControls.SIDE_CONTROLS_ANIMATION_TIME / 2,
|
time: OverviewControls.SIDE_CONTROLS_ANIMATION_TIME / (2 * 1000),
|
||||||
transition: 'easeInQuad'
|
transition: 'easeInQuad'
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@ -614,7 +614,7 @@ var ViewSelector = class {
|
|||||||
fadeHalf() {
|
fadeHalf() {
|
||||||
let actor = this._activePage;
|
let actor = this._activePage;
|
||||||
Tweener.addTween(actor, { opacity: 128,
|
Tweener.addTween(actor, { opacity: 128,
|
||||||
time: OverviewControls.SIDE_CONTROLS_ANIMATION_TIME / 2,
|
time: OverviewControls.SIDE_CONTROLS_ANIMATION_TIME / (2 * 1000),
|
||||||
transition: 'easeOutQuad'
|
transition: 'easeOutQuad'
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -22,15 +22,15 @@ const SwitchMonitor = imports.ui.switchMonitor;
|
|||||||
const { loadInterfaceXML } = imports.misc.fileUtils;
|
const { loadInterfaceXML } = imports.misc.fileUtils;
|
||||||
|
|
||||||
var SHELL_KEYBINDINGS_SCHEMA = 'org.gnome.shell.keybindings';
|
var SHELL_KEYBINDINGS_SCHEMA = 'org.gnome.shell.keybindings';
|
||||||
var MINIMIZE_WINDOW_ANIMATION_TIME = 0.2;
|
var MINIMIZE_WINDOW_ANIMATION_TIME = 200;
|
||||||
var SHOW_WINDOW_ANIMATION_TIME = 0.15;
|
var SHOW_WINDOW_ANIMATION_TIME = 150;
|
||||||
var DIALOG_SHOW_WINDOW_ANIMATION_TIME = 0.1;
|
var DIALOG_SHOW_WINDOW_ANIMATION_TIME = 100;
|
||||||
var DESTROY_WINDOW_ANIMATION_TIME = 0.15;
|
var DESTROY_WINDOW_ANIMATION_TIME = 150;
|
||||||
var DIALOG_DESTROY_WINDOW_ANIMATION_TIME = 0.1;
|
var DIALOG_DESTROY_WINDOW_ANIMATION_TIME = 100;
|
||||||
var WINDOW_ANIMATION_TIME = 0.25;
|
var WINDOW_ANIMATION_TIME = 250;
|
||||||
var DIM_BRIGHTNESS = -0.3;
|
var DIM_BRIGHTNESS = -0.3;
|
||||||
var DIM_TIME = 0.500;
|
var DIM_TIME = 500;
|
||||||
var UNDIM_TIME = 0.250;
|
var UNDIM_TIME = 250;
|
||||||
var MOTION_THRESHOLD = 100;
|
var MOTION_THRESHOLD = 100;
|
||||||
|
|
||||||
var ONE_SECOND = 1000; // in ms
|
var ONE_SECOND = 1000; // in ms
|
||||||
@ -419,7 +419,7 @@ var TilePreview = class {
|
|||||||
width: tileRect.width,
|
width: tileRect.width,
|
||||||
height: tileRect.height,
|
height: tileRect.height,
|
||||||
opacity: 255,
|
opacity: 255,
|
||||||
time: WINDOW_ANIMATION_TIME,
|
time: WINDOW_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad'
|
transition: 'easeOutQuad'
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@ -431,7 +431,7 @@ var TilePreview = class {
|
|||||||
this._showing = false;
|
this._showing = false;
|
||||||
Tweener.addTween(this.actor,
|
Tweener.addTween(this.actor,
|
||||||
{ opacity: 0,
|
{ opacity: 0,
|
||||||
time: WINDOW_ANIMATION_TIME,
|
time: WINDOW_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: this._reset.bind(this)
|
onComplete: this._reset.bind(this)
|
||||||
});
|
});
|
||||||
@ -1139,7 +1139,7 @@ var WindowManager = class {
|
|||||||
Tweener.addTween(switchData.container,
|
Tweener.addTween(switchData.container,
|
||||||
{ x: 0,
|
{ x: 0,
|
||||||
y: 0,
|
y: 0,
|
||||||
time: WINDOW_ANIMATION_TIME,
|
time: WINDOW_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: this._finishWorkspaceSwitch,
|
onComplete: this._finishWorkspaceSwitch,
|
||||||
onCompleteScope: this,
|
onCompleteScope: this,
|
||||||
@ -1284,7 +1284,7 @@ var WindowManager = class {
|
|||||||
if (actor.meta_window.is_monitor_sized()) {
|
if (actor.meta_window.is_monitor_sized()) {
|
||||||
Tweener.addTween(actor,
|
Tweener.addTween(actor,
|
||||||
{ opacity: 0,
|
{ opacity: 0,
|
||||||
time: MINIMIZE_WINDOW_ANIMATION_TIME,
|
time: MINIMIZE_WINDOW_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: this._minimizeWindowDone,
|
onComplete: this._minimizeWindowDone,
|
||||||
onCompleteScope: this,
|
onCompleteScope: this,
|
||||||
@ -1320,7 +1320,7 @@ var WindowManager = class {
|
|||||||
scale_y: yScale,
|
scale_y: yScale,
|
||||||
x: xDest,
|
x: xDest,
|
||||||
y: yDest,
|
y: yDest,
|
||||||
time: MINIMIZE_WINDOW_ANIMATION_TIME,
|
time: MINIMIZE_WINDOW_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeInExpo',
|
transition: 'easeInExpo',
|
||||||
onComplete: this._minimizeWindowDone,
|
onComplete: this._minimizeWindowDone,
|
||||||
onCompleteScope: this,
|
onCompleteScope: this,
|
||||||
@ -1365,7 +1365,7 @@ var WindowManager = class {
|
|||||||
actor.set_scale(1.0, 1.0);
|
actor.set_scale(1.0, 1.0);
|
||||||
Tweener.addTween(actor,
|
Tweener.addTween(actor,
|
||||||
{ opacity: 255,
|
{ opacity: 255,
|
||||||
time: MINIMIZE_WINDOW_ANIMATION_TIME,
|
time: MINIMIZE_WINDOW_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: this._unminimizeWindowDone,
|
onComplete: this._unminimizeWindowDone,
|
||||||
onCompleteScope: this,
|
onCompleteScope: this,
|
||||||
@ -1402,7 +1402,7 @@ var WindowManager = class {
|
|||||||
scale_y: 1.0,
|
scale_y: 1.0,
|
||||||
x: xDest,
|
x: xDest,
|
||||||
y: yDest,
|
y: yDest,
|
||||||
time: MINIMIZE_WINDOW_ANIMATION_TIME,
|
time: MINIMIZE_WINDOW_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeInExpo',
|
transition: 'easeInExpo',
|
||||||
onComplete: this._unminimizeWindowDone,
|
onComplete: this._unminimizeWindowDone,
|
||||||
onCompleteScope: this,
|
onCompleteScope: this,
|
||||||
@ -1488,7 +1488,7 @@ var WindowManager = class {
|
|||||||
scale_x: scaleX,
|
scale_x: scaleX,
|
||||||
scale_y: scaleY,
|
scale_y: scaleY,
|
||||||
opacity: 0,
|
opacity: 0,
|
||||||
time: WINDOW_ANIMATION_TIME,
|
time: WINDOW_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad'
|
transition: 'easeOutQuad'
|
||||||
});
|
});
|
||||||
|
|
||||||
@ -1505,7 +1505,7 @@ var WindowManager = class {
|
|||||||
scale_y: 1.0,
|
scale_y: 1.0,
|
||||||
translation_x: 0,
|
translation_x: 0,
|
||||||
translation_y: 0,
|
translation_y: 0,
|
||||||
time: WINDOW_ANIMATION_TIME,
|
time: WINDOW_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: this._sizeChangeWindowDone,
|
onComplete: this._sizeChangeWindowDone,
|
||||||
onCompleteScope: this,
|
onCompleteScope: this,
|
||||||
@ -1586,7 +1586,7 @@ var WindowManager = class {
|
|||||||
if (this._shouldAnimate())
|
if (this._shouldAnimate())
|
||||||
Tweener.addTween(dimmer,
|
Tweener.addTween(dimmer,
|
||||||
{ dimFactor: 1.0,
|
{ dimFactor: 1.0,
|
||||||
time: DIM_TIME,
|
time: DIM_TIME / 1000,
|
||||||
transition: 'linear'
|
transition: 'linear'
|
||||||
});
|
});
|
||||||
else
|
else
|
||||||
@ -1603,7 +1603,7 @@ var WindowManager = class {
|
|||||||
if (this._shouldAnimate())
|
if (this._shouldAnimate())
|
||||||
Tweener.addTween(dimmer,
|
Tweener.addTween(dimmer,
|
||||||
{ dimFactor: 0.0,
|
{ dimFactor: 0.0,
|
||||||
time: UNDIM_TIME,
|
time: UNDIM_TIME / 1000,
|
||||||
transition: 'linear' });
|
transition: 'linear' });
|
||||||
else
|
else
|
||||||
dimmer.dimFactor = 0.0;
|
dimmer.dimFactor = 0.0;
|
||||||
@ -1655,7 +1655,7 @@ var WindowManager = class {
|
|||||||
{ opacity: 255,
|
{ opacity: 255,
|
||||||
scale_x: 1,
|
scale_x: 1,
|
||||||
scale_y: 1,
|
scale_y: 1,
|
||||||
time: SHOW_WINDOW_ANIMATION_TIME,
|
time: SHOW_WINDOW_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutExpo',
|
transition: 'easeOutExpo',
|
||||||
onComplete: this._mapWindowDone,
|
onComplete: this._mapWindowDone,
|
||||||
onCompleteScope: this,
|
onCompleteScope: this,
|
||||||
@ -1677,7 +1677,7 @@ var WindowManager = class {
|
|||||||
{ opacity: 255,
|
{ opacity: 255,
|
||||||
scale_x: 1,
|
scale_x: 1,
|
||||||
scale_y: 1,
|
scale_y: 1,
|
||||||
time: DIALOG_SHOW_WINDOW_ANIMATION_TIME,
|
time: DIALOG_SHOW_WINDOW_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: this._mapWindowDone,
|
onComplete: this._mapWindowDone,
|
||||||
onCompleteScope: this,
|
onCompleteScope: this,
|
||||||
@ -1743,7 +1743,7 @@ var WindowManager = class {
|
|||||||
{ opacity: 0,
|
{ opacity: 0,
|
||||||
scale_x: 0.8,
|
scale_x: 0.8,
|
||||||
scale_y: 0.8,
|
scale_y: 0.8,
|
||||||
time: DESTROY_WINDOW_ANIMATION_TIME,
|
time: DESTROY_WINDOW_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: this._destroyWindowDone,
|
onComplete: this._destroyWindowDone,
|
||||||
onCompleteScope: this,
|
onCompleteScope: this,
|
||||||
@ -1768,7 +1768,7 @@ var WindowManager = class {
|
|||||||
|
|
||||||
Tweener.addTween(actor,
|
Tweener.addTween(actor,
|
||||||
{ scale_y: 0,
|
{ scale_y: 0,
|
||||||
time: DIALOG_DESTROY_WINDOW_ANIMATION_TIME,
|
time: DIALOG_DESTROY_WINDOW_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: this._destroyWindowDone,
|
onComplete: this._destroyWindowDone,
|
||||||
onCompleteScope: this,
|
onCompleteScope: this,
|
||||||
@ -2017,7 +2017,7 @@ var WindowManager = class {
|
|||||||
Tweener.addTween(this._switchData.container,
|
Tweener.addTween(this._switchData.container,
|
||||||
{ x: xDest,
|
{ x: xDest,
|
||||||
y: yDest,
|
y: yDest,
|
||||||
time: WINDOW_ANIMATION_TIME,
|
time: WINDOW_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: this._switchWorkspaceDone,
|
onComplete: this._switchWorkspaceDone,
|
||||||
onCompleteScope: this,
|
onCompleteScope: this,
|
||||||
|
@ -613,7 +613,7 @@ var WindowOverlay = class {
|
|||||||
let params = { x: x,
|
let params = { x: x,
|
||||||
y: y,
|
y: y,
|
||||||
width: width,
|
width: width,
|
||||||
time: Overview.ANIMATION_TIME,
|
time: Overview.ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad' };
|
transition: 'easeOutQuad' };
|
||||||
|
|
||||||
if (height !== undefined)
|
if (height !== undefined)
|
||||||
@ -650,7 +650,7 @@ var WindowOverlay = class {
|
|||||||
a.opacity = 0;
|
a.opacity = 0;
|
||||||
Tweener.addTween(a,
|
Tweener.addTween(a,
|
||||||
{ opacity: 255,
|
{ opacity: 255,
|
||||||
time: WINDOW_OVERLAY_FADE_TIME,
|
time: WINDOW_OVERLAY_FADE_TIME / 1000,
|
||||||
transition: 'easeOutQuad' });
|
transition: 'easeOutQuad' });
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@ -660,7 +660,7 @@ var WindowOverlay = class {
|
|||||||
a.opacity = 255;
|
a.opacity = 255;
|
||||||
Tweener.addTween(a,
|
Tweener.addTween(a,
|
||||||
{ opacity: 0,
|
{ opacity: 0,
|
||||||
time: WINDOW_OVERLAY_FADE_TIME,
|
time: WINDOW_OVERLAY_FADE_TIME / 1000,
|
||||||
transition: 'easeInQuad' });
|
transition: 'easeInQuad' });
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@ -1346,7 +1346,7 @@ var Workspace = class {
|
|||||||
|
|
||||||
Tweener.addTween(clone,
|
Tweener.addTween(clone,
|
||||||
{ opacity: 255,
|
{ opacity: 255,
|
||||||
time: Overview.ANIMATION_TIME,
|
time: Overview.ANIMATION_TIME / 1000,
|
||||||
transition: 'easeInQuad'
|
transition: 'easeInQuad'
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@ -1389,7 +1389,7 @@ var Workspace = class {
|
|||||||
y: y,
|
y: y,
|
||||||
scale_x: scale,
|
scale_x: scale,
|
||||||
scale_y: scale,
|
scale_y: scale,
|
||||||
time: Overview.ANIMATION_TIME,
|
time: Overview.ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
this._showWindowOverlay(clone, overlay);
|
this._showWindowOverlay(clone, overlay);
|
||||||
@ -1695,7 +1695,7 @@ var Workspace = class {
|
|||||||
clone.x = origX;
|
clone.x = origX;
|
||||||
clone.y = origY;
|
clone.y = origY;
|
||||||
Tweener.addTween(clone,
|
Tweener.addTween(clone,
|
||||||
{ time: time,
|
{ time: time / 1000,
|
||||||
opacity: opacity,
|
opacity: opacity,
|
||||||
transition: 'easeOutQuad'
|
transition: 'easeOutQuad'
|
||||||
});
|
});
|
||||||
@ -1749,7 +1749,7 @@ var Workspace = class {
|
|||||||
y: origY,
|
y: origY,
|
||||||
scale_x: 1.0,
|
scale_x: 1.0,
|
||||||
scale_y: 1.0,
|
scale_y: 1.0,
|
||||||
time: Overview.ANIMATION_TIME,
|
time: Overview.ANIMATION_TIME / 1000,
|
||||||
opacity: 255,
|
opacity: 255,
|
||||||
transition: 'easeOutQuad'
|
transition: 'easeOutQuad'
|
||||||
});
|
});
|
||||||
@ -1759,7 +1759,7 @@ var Workspace = class {
|
|||||||
{ scale_x: 0,
|
{ scale_x: 0,
|
||||||
scale_y: 0,
|
scale_y: 0,
|
||||||
opacity: 0,
|
opacity: 0,
|
||||||
time: Overview.ANIMATION_TIME,
|
time: Overview.ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad'
|
transition: 'easeOutQuad'
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
@ -7,7 +7,7 @@ const Mainloop = imports.mainloop;
|
|||||||
const Main = imports.ui.main;
|
const Main = imports.ui.main;
|
||||||
const Tweener = imports.ui.tweener;
|
const Tweener = imports.ui.tweener;
|
||||||
|
|
||||||
var ANIMATION_TIME = 0.1;
|
var ANIMATION_TIME = 100;
|
||||||
var DISPLAY_TIMEOUT = 600;
|
var DISPLAY_TIMEOUT = 600;
|
||||||
|
|
||||||
var WorkspaceSwitcherPopupList = GObject.registerClass(
|
var WorkspaceSwitcherPopupList = GObject.registerClass(
|
||||||
@ -183,7 +183,7 @@ class WorkspaceSwitcherPopup extends St.Widget {
|
|||||||
|
|
||||||
_show() {
|
_show() {
|
||||||
Tweener.addTween(this._container, { opacity: 255,
|
Tweener.addTween(this._container, { opacity: 255,
|
||||||
time: ANIMATION_TIME,
|
time: ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad'
|
transition: 'easeOutQuad'
|
||||||
});
|
});
|
||||||
this.show();
|
this.show();
|
||||||
@ -205,7 +205,7 @@ class WorkspaceSwitcherPopup extends St.Widget {
|
|||||||
Mainloop.source_remove(this._timeoutId);
|
Mainloop.source_remove(this._timeoutId);
|
||||||
this._timeoutId = 0;
|
this._timeoutId = 0;
|
||||||
Tweener.addTween(this._container, { opacity: 0.0,
|
Tweener.addTween(this._container, { opacity: 0.0,
|
||||||
time: ANIMATION_TIME,
|
time: ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => this.destroy()
|
onComplete: () => this.destroy()
|
||||||
});
|
});
|
||||||
|
@ -15,8 +15,8 @@ const WorkspacesView = imports.ui.workspacesView;
|
|||||||
// The maximum size of a thumbnail is 1/10 the width and height of the screen
|
// The maximum size of a thumbnail is 1/10 the width and height of the screen
|
||||||
let MAX_THUMBNAIL_SCALE = 1 / 10.;
|
let MAX_THUMBNAIL_SCALE = 1 / 10.;
|
||||||
|
|
||||||
var RESCALE_ANIMATION_TIME = 0.2;
|
var RESCALE_ANIMATION_TIME = 200;
|
||||||
var SLIDE_ANIMATION_TIME = 0.2;
|
var SLIDE_ANIMATION_TIME = 200;
|
||||||
|
|
||||||
// When we create workspaces by dragging, we add a "cut" into the top and
|
// When we create workspaces by dragging, we add a "cut" into the top and
|
||||||
// bottom of each workspace so that the user doesn't have to hit the
|
// bottom of each workspace so that the user doesn't have to hit the
|
||||||
@ -1039,7 +1039,7 @@ class ThumbnailsBox extends St.Widget {
|
|||||||
_tweenScale() {
|
_tweenScale() {
|
||||||
Tweener.addTween(this,
|
Tweener.addTween(this,
|
||||||
{ scale: this._targetScale,
|
{ scale: this._targetScale,
|
||||||
time: RESCALE_ANIMATION_TIME,
|
time: RESCALE_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: this._queueUpdateStates,
|
onComplete: this._queueUpdateStates,
|
||||||
onCompleteScope: this });
|
onCompleteScope: this });
|
||||||
@ -1058,7 +1058,7 @@ class ThumbnailsBox extends St.Widget {
|
|||||||
|
|
||||||
Tweener.addTween(thumbnail,
|
Tweener.addTween(thumbnail,
|
||||||
{ slidePosition: 1,
|
{ slidePosition: 1,
|
||||||
time: SLIDE_ANIMATION_TIME,
|
time: SLIDE_ANIMATION_TIME / 1000,
|
||||||
transition: 'linear',
|
transition: 'linear',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
this._setThumbnailState(thumbnail, ThumbnailState.ANIMATED_OUT);
|
this._setThumbnailState(thumbnail, ThumbnailState.ANIMATED_OUT);
|
||||||
@ -1076,7 +1076,7 @@ class ThumbnailsBox extends St.Widget {
|
|||||||
this._setThumbnailState(thumbnail, ThumbnailState.COLLAPSING);
|
this._setThumbnailState(thumbnail, ThumbnailState.COLLAPSING);
|
||||||
Tweener.addTween(thumbnail,
|
Tweener.addTween(thumbnail,
|
||||||
{ collapseFraction: 1,
|
{ collapseFraction: 1,
|
||||||
time: RESCALE_ANIMATION_TIME,
|
time: RESCALE_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
this._stateCounts[thumbnail.state]--;
|
this._stateCounts[thumbnail.state]--;
|
||||||
@ -1105,7 +1105,7 @@ class ThumbnailsBox extends St.Widget {
|
|||||||
this._setThumbnailState(thumbnail, ThumbnailState.ANIMATING_IN);
|
this._setThumbnailState(thumbnail, ThumbnailState.ANIMATING_IN);
|
||||||
Tweener.addTween(thumbnail,
|
Tweener.addTween(thumbnail,
|
||||||
{ slidePosition: 0,
|
{ slidePosition: 0,
|
||||||
time: SLIDE_ANIMATION_TIME,
|
time: SLIDE_ANIMATION_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
this._setThumbnailState(thumbnail, ThumbnailState.NORMAL);
|
this._setThumbnailState(thumbnail, ThumbnailState.NORMAL);
|
||||||
@ -1329,7 +1329,7 @@ class ThumbnailsBox extends St.Widget {
|
|||||||
this.indicatorY = this._indicator.allocation.y1 + indicatorTopFullBorder;
|
this.indicatorY = this._indicator.allocation.y1 + indicatorTopFullBorder;
|
||||||
Tweener.addTween(this,
|
Tweener.addTween(this,
|
||||||
{ indicatorY: thumbnail.actor.allocation.y1,
|
{ indicatorY: thumbnail.actor.allocation.y1,
|
||||||
time: WorkspacesView.WORKSPACE_SWITCH_TIME,
|
time: WorkspacesView.WORKSPACE_SWITCH_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
this._animatingIndicator = false;
|
this._animatingIndicator = false;
|
||||||
|
@ -9,7 +9,7 @@ const Tweener = imports.ui.tweener;
|
|||||||
const WindowManager = imports.ui.windowManager;
|
const WindowManager = imports.ui.windowManager;
|
||||||
const Workspace = imports.ui.workspace;
|
const Workspace = imports.ui.workspace;
|
||||||
|
|
||||||
var WORKSPACE_SWITCH_TIME = 0.25;
|
var WORKSPACE_SWITCH_TIME = 250;
|
||||||
|
|
||||||
var AnimationType = {
|
var AnimationType = {
|
||||||
ZOOM: 0,
|
ZOOM: 0,
|
||||||
@ -200,7 +200,7 @@ var WorkspacesView = class extends WorkspacesViewBase {
|
|||||||
|
|
||||||
if (showAnimation) {
|
if (showAnimation) {
|
||||||
let tweenParams = Object.assign(params, {
|
let tweenParams = Object.assign(params, {
|
||||||
time: WORKSPACE_SWITCH_TIME,
|
time: WORKSPACE_SWITCH_TIME / 1000,
|
||||||
transition: 'easeOutQuad'
|
transition: 'easeOutQuad'
|
||||||
});
|
});
|
||||||
// we have to call _updateVisibility() once before the
|
// we have to call _updateVisibility() once before the
|
||||||
@ -247,7 +247,7 @@ var WorkspacesView = class extends WorkspacesViewBase {
|
|||||||
|
|
||||||
Tweener.addTween(this.scrollAdjustment, {
|
Tweener.addTween(this.scrollAdjustment, {
|
||||||
value: index,
|
value: index,
|
||||||
time: WORKSPACE_SWITCH_TIME,
|
time: WORKSPACE_SWITCH_TIME / 1000,
|
||||||
transition: 'easeOutQuad',
|
transition: 'easeOutQuad',
|
||||||
onComplete: () => {
|
onComplete: () => {
|
||||||
this._animatingScroll = false;
|
this._animatingScroll = false;
|
||||||
|
Loading…
Reference in New Issue
Block a user