loleaflet: eslint 4.0.0 conformance

Change-Id: I54a21b60fde707c8a193e520c60e3523c1f770bb
This commit is contained in:
bugrakurt 2020-10-17 21:20:39 +00:00 committed by Muhammet Kara
parent c6486d472e
commit e9252a2581
5 changed files with 17 additions and 17 deletions

View file

@ -597,13 +597,13 @@ L.Control.Header = L.Control.extend({
canvas.width = Math.floor(value * scale);
if (!isCorner)
this._canvasWidth = value;
// console.log('Header._setCanvasSizeImpl: _canvasWidth' + this._canvasWidth);
// console.log('Header._setCanvasSizeImpl: _canvasWidth' + this._canvasWidth);
}
else if (property === 'height') {
canvas.height = Math.floor(value * scale);
if (!isCorner)
this._canvasHeight = value;
// console.log('Header._setCanvasSizeImpl: _canvasHeight' + this._canvasHeight);
// console.log('Header._setCanvasSizeImpl: _canvasHeight' + this._canvasHeight);
}
},

View file

@ -1620,7 +1620,7 @@ L.Control.LokDialog = L.Control.extend({
// set the canvas to have the actual size, while
// the image is rendered with the HiDPI scale.
this._setCanvasWidthHeight(canvas, this._dialogs[parentId].childwidth,
this._dialogs[parentId].childheight);
this._dialogs[parentId].childheight);
var ctx = canvas.getContext('2d');
var img = new Image();

View file

@ -275,9 +275,9 @@ L.Control.TopToolbar = L.Control.extend({
case 'spreadsheet':
if (toolbarUp) {
toolbarUp.show('textalign', 'wraptext', 'breakspacing', 'insertannotation', 'conditionalformaticonset',
'numberformatcurrency', 'numberformatpercent',
'numberformatincdecimals', 'numberformatdecdecimals', 'break-number', 'togglemergecells', 'breakmergecells',
'setborderstyle', 'sortascending', 'sortdescending', 'breaksorting', 'backgroundcolor', 'breaksidebar', 'sidebar');
'numberformatcurrency', 'numberformatpercent',
'numberformatincdecimals', 'numberformatdecdecimals', 'break-number', 'togglemergecells', 'breakmergecells',
'setborderstyle', 'sortascending', 'sortdescending', 'breaksorting', 'backgroundcolor', 'breaksidebar', 'sidebar');
toolbarUp.remove('styles');
}
@ -292,8 +292,8 @@ L.Control.TopToolbar = L.Control.extend({
case 'text':
if (toolbarUp)
toolbarUp.show('leftpara', 'centerpara', 'rightpara', 'justifypara', 'breakpara', 'linespacing',
'breakspacing', 'defaultbullet', 'defaultnumbering', 'breakbullet', 'incrementindent', 'decrementindent',
'breakindent', 'inserttable', 'insertannotation', 'backcolor', 'breaksidebar', 'sidebar');
'breakspacing', 'defaultbullet', 'defaultnumbering', 'breakbullet', 'incrementindent', 'decrementindent',
'breakindent', 'inserttable', 'insertannotation', 'backcolor', 'breaksidebar', 'sidebar');
break;
case 'presentation':
@ -322,8 +322,8 @@ L.Control.TopToolbar = L.Control.extend({
case 'drawing':
if (toolbarUp)
toolbarUp.show('leftpara', 'centerpara', 'rightpara', 'justifypara', 'breakpara', 'linespacing',
'breakspacing', 'defaultbullet', 'defaultnumbering', 'breakbullet', 'inserttextbox', 'inserttable', 'backcolor',
'breaksidebar', 'modifypage', 'slidechangewindow', 'customanimation', 'masterslidespanel');
'breakspacing', 'defaultbullet', 'defaultnumbering', 'breakbullet', 'inserttextbox', 'inserttable', 'backcolor',
'breaksidebar', 'modifypage', 'slidechangewindow', 'customanimation', 'masterslidespanel');
break;
}
@ -517,7 +517,7 @@ L.Control.TopToolbar = L.Control.extend({
// we need to add the size
$('.styles-select')
.append($('<option></option>')
.text(state));
.text(state));
}
this.options.stylesSelectValue = state;
@ -535,7 +535,7 @@ L.Control.TopToolbar = L.Control.extend({
// we need to add the size
$('.fonts-select')
.append($('<option></option>')
.text(state));
.text(state));
}
this.options.fontsSelectValue = state;
$('.fonts-select').val(state).trigger('change');
@ -554,7 +554,7 @@ L.Control.TopToolbar = L.Control.extend({
// we need to add the size
$('.fontsizes-select')
.append($('<option>')
.text(state).val(state));
.text(state).val(state));
}
$('.fontsizes-select').val(state).trigger('change');
}

View file

@ -201,8 +201,8 @@ L.Map.include({
// we can scroll to the desired page without having a LOK instance
var pageBounds = docLayer._partPageRectanglesPixels[docLayer._currentPage];
var pos = new L.Point(
pageBounds.min.x + (pageBounds.max.x - pageBounds.min.x) / 2,
pageBounds.min.y);
pageBounds.min.x + (pageBounds.max.x - pageBounds.min.x) / 2,
pageBounds.min.y);
pos.y -= this.getSize().y / 4; // offset by a quater of the viewing area so that the previous page is visible
this.scrollTop(pos.y, {update: true});
this.scrollLeft(pos.x, {update: true});

View file

@ -40,8 +40,8 @@ L.Map.include({
var viewTopLeftpx = this.project(this.getBounds().getNorthWest());
var docBoundsTopLeft = this.project(this.options.maxBounds.getNorthWest());
var topLeft = this.unproject(new L.Point(
Math.max(viewTopLeftpx.x, docBoundsTopLeft.x),
Math.max(viewTopLeftpx.y, docBoundsTopLeft.y)));
Math.max(viewTopLeftpx.x, docBoundsTopLeft.x),
Math.max(viewTopLeftpx.y, docBoundsTopLeft.y)));
var topLeftTwips = this._docLayer._latLngToTwips(topLeft);
var searchStartPointX = topLeftTwips.x;