1
// -*- mode: js; js-indent-level: 4; indent-tabs-mode: nil -*-
3
const Lang = imports.lang;
5
const Lightbox = imports.ui.lightbox;
6
const Main = imports.ui.main;
7
const Tweener = imports.ui.tweener;
9
const FLASHSPOT_ANIMATION_TIME = 0.25; // seconds
11
const Flashspot = new Lang.Class({
13
Extends: Lightbox.Lightbox,
15
_init: function(area) {
16
this.parent(Main.uiGroup, { inhibitEvents: true,
18
height: area.height });
20
this.actor.style_class = 'flashspot';
21
this.actor.set_position(area.x, area.y);
25
this.actor.opacity = 0;
26
Tweener.addTween(this.actor,
28
time: FLASHSPOT_ANIMATION_TIME,
30
onComplete: Lang.bind(this, this._onFireShowComplete)
35
_onFireShowComplete: function() {
36
Tweener.addTween(this.actor,
38
time: FLASHSPOT_ANIMATION_TIME,
40
onComplete: Lang.bind(this, function() {