Update Polymer and pull in iron-list
[chromium-blink-merge.git] / third_party / polymer / v1_0 / components-chromium / paper-dialog / paper-dialog-extracted.js
blob6e3705c7eb1576d4d492462b39a9693489e77f58
3 (function() {
5   Polymer({
7     is: 'paper-dialog',
9     behaviors: [
10       Polymer.PaperDialogBehavior,
11       Polymer.NeonAnimationRunnerBehavior
12     ],
14     listeners: {
15       'neon-animation-finish': '_onNeonAnimationFinish'
16     },
18     _renderOpened: function() {
19       if (this.withBackdrop) {
20         this.backdropElement.open();
21       }
22       this.playAnimation('entry');
23     },
25     _renderClosed: function() {
26       if (this.withBackdrop) {
27         this.backdropElement.close();
28       }
29       this.playAnimation('exit');
30     },
32     _onNeonAnimationFinish: function() {
33       if (this.opened) {
34         this._finishRenderOpened();
35       } else {
36         this._finishRenderClosed();
37       }
38     }
40   });
42 })();