var Battery = function()

in www/battery.js [32:44]


var Battery = function () {
    this._level = null;
    this._isPlugged = null;
    // Create new event handlers on the window (returns a channel instance)
    this.channels = {
        batterystatus: cordova.addWindowEventHandler('batterystatus'),
        batterylow: cordova.addWindowEventHandler('batterylow'),
        batterycritical: cordova.addWindowEventHandler('batterycritical')
    };
    for (var key in this.channels) {
        this.channels[key].onHasSubscribersChange = Battery.onHasSubscribersChange;
    }
};