Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
SeleniumHQ
GitHub Repository: SeleniumHQ/Selenium
Path: blob/trunk/third_party/closure/goog/fx/transition.js
4164 views
1
/**
2
* @license
3
* Copyright The Closure Library Authors.
4
* SPDX-License-Identifier: Apache-2.0
5
*/
6
7
/**
8
* @fileoverview An interface for transition animation. This is a simple
9
* interface that allows for playing and stopping a transition. It adds
10
* a simple event model with BEGIN and END event.
11
*/
12
13
goog.provide('goog.fx.Transition');
14
goog.provide('goog.fx.Transition.EventType');
15
16
17
18
/**
19
* An interface for programmatic transition. Must extend
20
* `goog.events.EventTarget`.
21
* @interface
22
*/
23
goog.fx.Transition = function() {};
24
25
26
/**
27
* Transition event types.
28
* @enum {string}
29
*/
30
goog.fx.Transition.EventType = {
31
/** Dispatched when played for the first time OR when it is resumed. */
32
PLAY: 'play',
33
34
/** Dispatched only when the animation starts from the beginning. */
35
BEGIN: 'begin',
36
37
/** Dispatched only when animation is restarted after a pause. */
38
RESUME: 'resume',
39
40
/**
41
* Dispatched when animation comes to the end of its duration OR stop
42
* is called.
43
*/
44
END: 'end',
45
46
/** Dispatched only when stop is called. */
47
STOP: 'stop',
48
49
/** Dispatched only when animation comes to its end naturally. */
50
FINISH: 'finish',
51
52
/** Dispatched when an animation is paused. */
53
PAUSE: 'pause'
54
};
55
56
57
/**
58
* @type {function()}
59
* Plays the transition.
60
*/
61
goog.fx.Transition.prototype.play;
62
63
64
/**
65
* @type {function()}
66
* Stops the transition.
67
*/
68
goog.fx.Transition.prototype.stop;
69
70