~daker/ubuntu-html5-theme/fix.1232533

« back to all changes in this revision

Viewing changes to 0.1/ambiance/js/fast-buttons.js

  • Committer: Tarmac
  • Author(s): daker
  • Date: 2013-09-25 18:13:29 UTC
  • mfrom: (81.3.1 fix.1222881)
  • Revision ID: tarmac-20130925181329-4yhdynzsaiv3coq5
Made variable declaration locale. Fixes: https://bugs.launchpad.net/bugs/1222881.

Approved by PS Jenkins bot, Alexandre Abreu.

Show diffs side-by-side

added added

removed removed

Lines of Context:
5
5
 * This file is part of ubuntu-html5-theme.
6
6
 *
7
7
 * This package is free software; you can redistribute it and/or modify
8
 
 * it under the terms of the GNU Lesser General Public License as 
9
 
 * published by the Free Software Foundation; either version 3 of the 
 
8
 * it under the terms of the GNU Lesser General Public License as
 
9
 * published by the Free Software Foundation; either version 3 of the
10
10
 * License, or
11
11
 * (at your option) any later version.
12
 
 
 
12
 
13
13
 * This package is distributed in the hope that it will be useful,
14
14
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
15
15
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16
16
 * GNU General Public License for more details.
17
 
 
18
 
 * You should have received a copy of the GNU Lesser General Public 
19
 
 * License along with this program. If not, see 
 
17
 
 
18
 * You should have received a copy of the GNU Lesser General Public
 
19
 * License along with this program. If not, see
20
20
 * <http://www.gnu.org/licenses/>.
21
21
 */
22
22
 
68
68
 
69
69
    /* Remove event handling when no longer needed for this button */
70
70
    this.FastButton.prototype.destroy = function () {
71
 
        for (i = this.events.length - 1; i >= 0; i -= 1)
 
71
        for (var i = this.events.length - 1; i >= 0; i -= 1)
72
72
            this.events[i].destroy();
73
73
        this.events = this.touchEvents = this.element = this.handler = this.fastButton = null;
74
74
    };
121
121
    };
122
122
 
123
123
    this.FastButton.prototype.reset = function () {
124
 
        for (i = this.touchEvents.length - 1; i >= 0; i -= 1)
 
124
        for (var i = this.touchEvents.length - 1; i >= 0; i -= 1)
125
125
            this.touchEvents[i].destroy();
126
126
        this.touchEvents = [];
127
127
    };