1 | var __extends = (this && this.__extends) || (function () {
|
2 | var extendStatics = Object.setPrototypeOf ||
|
3 | ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
4 | function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
|
5 | return function (d, b) {
|
6 | extendStatics(d, b);
|
7 | function __() { this.constructor = d; }
|
8 | d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
9 | };
|
10 | })();
|
11 | import { Animation } from '../animations/animation';
|
12 | import { Transition } from './transition';
|
13 |
|
14 |
|
15 |
|
16 | var PageTransition = (function (_super) {
|
17 | __extends(PageTransition, _super);
|
18 | function PageTransition() {
|
19 | return _super !== null && _super.apply(this, arguments) || this;
|
20 | }
|
21 | PageTransition.prototype.init = function () {
|
22 | var _this = this;
|
23 | if (this.enteringView) {
|
24 | this.enteringPage = new Animation(this.plt, this.enteringView.pageRef());
|
25 | this.add(this.enteringPage.beforeAddClass('show-page'));
|
26 |
|
27 | this.beforeAddRead(function () {
|
28 | _this.enteringView.readReady.emit();
|
29 | });
|
30 | this.beforeAddWrite(function () {
|
31 | _this.enteringView.writeReady.emit();
|
32 | });
|
33 | }
|
34 | };
|
35 | PageTransition.prototype.destroy = function () {
|
36 | _super.prototype.destroy.call(this);
|
37 | this.enteringPage && this.enteringPage.destroy();
|
38 | this.enteringPage = null;
|
39 | };
|
40 | return PageTransition;
|
41 | }(Transition));
|
42 | export { PageTransition };
|
43 |
|
\ | No newline at end of file |