loleaflet: fixed js lint erros in src/map/handler/*

This commit is contained in:
Mihai Varga 2015-11-13 10:38:28 +02:00
parent feebb0d2a7
commit 81e773ac2a
5 changed files with 13 additions and 13 deletions

View file

@ -48,7 +48,6 @@ L.Map.FileInserter = L.Handler.extend({
_sendFile: function (name, file) {
var url = this._url;
console.log(url);
var xmlHttp = new XMLHttpRequest();
xmlHttp.onreadystatechange = function () {
if (xmlHttp.readyState === 4 && xmlHttp.status === 200) {

View file

@ -229,9 +229,10 @@ L.Map.Keyboard = L.Handler.extend({
this.modifier = shift | ctrl | alt;
if (ctrl) {
if (this._handleCtrlCommand(e))
if (this._handleCtrlCommand(e)) {
return;
}
}
// page up or page down, handled by this.dopagejump
// to jump back to the anchor from footnote/endnote by PgUp
@ -309,7 +310,7 @@ L.Map.Keyboard = L.Handler.extend({
if (e.type !== 'keydown' && e.originalEvent.key !== 'c' && e.originalEvent.key !== 'v') {
e.originalEvent.preventDefault();
return true;
};
}
if (e.originalEvent.keyCode !== 67 && e.originalEvent.keyCode !== 86 && e.originalEvent.key !== 'c' && e.originalEvent.key !== 'v') {
// not copy or paste

View file

@ -25,7 +25,7 @@ L.Map.Print = L.Handler.extend({
// object URL, because else we might have cross origin security problems
var xmlHttp = new XMLHttpRequest();
xmlHttp.onreadystatechange = L.bind(function () {
if (xmlHttp.readyState == 4 && xmlHttp.status == 200) {
if (xmlHttp.readyState === 4 && xmlHttp.status === 200) {
this._onInitPrint(xmlHttp);
}
}, this);

View file

@ -22,7 +22,7 @@ L.Map.SlideShow = L.Handler.extend({
this._map.off('slidedownloadready', this._onSlideDownloadReady, this);
},
_onFullScreen: function (e) {
_onFullScreen: function () {
this._slideShow = L.DomUtil.create('iframe', '', this._map._container);
if (this._slideShow.requestFullscreen) {
this._slideShow.requestFullscreen();
@ -37,14 +37,14 @@ L.Map.SlideShow = L.Handler.extend({
this._slideShow.webkitRequestFullscreen();
}
L.DomEvent['on'](document, 'fullscreenchange webkitfullscreenchange mozfullscreenchange msfullscreenchange',
L.DomEvent.on(document, 'fullscreenchange webkitfullscreenchange mozfullscreenchange msfullscreenchange',
this._onFullScreenChange, this);
this.fullscreen = true;
this._map.downloadAs('slideshow.svg', 'svg', null, 'slideshow');
},
_onFullScreenChange: function (e) {
_onFullScreenChange: function () {
this.fullscreen = document.fullscreen ||
document.webkitIsFullScreen ||