Skip to content
This repository has been archived by the owner on Mar 8, 2023. It is now read-only.

Commit

Permalink
MINOR: Re-enable no-unused-variable tslint option
Browse files Browse the repository at this point in the history
Signed-off-by: Nino Kettlitz <1396039+ninok@users.noreply.github.com>
  • Loading branch information
ninok committed Apr 25, 2019
1 parent c62b680 commit ebd9bd0
Show file tree
Hide file tree
Showing 15 changed files with 8 additions and 60 deletions.
7 changes: 0 additions & 7 deletions @here/harp-datasource-protocol/lib/Extruder.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,6 @@
* SPDX-License-Identifier: Apache-2.0
*/

import * as THREE from "three";

const currEdgeStart = new THREE.Vector2();
const currEdgeGoal = new THREE.Vector2();
const prevEdgeStart = new THREE.Vector2();
const prevEdgeGoal = new THREE.Vector2();

/**
* Fills an index buffer with the indices for the extruded walls for a polygon contour.
*
Expand Down
2 changes: 1 addition & 1 deletion @here/harp-geojson-datasource/lib/GeoJsonTile.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ import {
Tile,
TileObject
} from "@here/harp-mapview";
import { ContextualArabicConverter, FontUnit } from "@here/harp-text-canvas";
import { ContextualArabicConverter } from "@here/harp-text-canvas";
import * as THREE from "three";
import {
GeoJsonPoiGeometry,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,6 @@ import * as THREE from "three";

import * as geo from "@here/harp-geoutils";

import * as fs from "fs";

describe("SphericalGeometrySubdivisionModifier", function() {
it("SubdivideTileBounds", function() {
const geoPoint = new geo.GeoCoordinates(53.3, 13.4);
Expand Down
3 changes: 0 additions & 3 deletions @here/harp-mapview-decoder/lib/WorkerServiceManager.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,8 @@
*/

import { WorkerServiceProtocol } from "@here/harp-datasource-protocol";
import { LoggerManager } from "@here/harp-utils";
import { WorkerService, WorkerServiceResponse } from "./WorkerService";

const logger = LoggerManager.instance.create("WorkerServiceManager");

/**
* Factory function that creates [[WorkerService]].
*/
Expand Down
1 change: 0 additions & 1 deletion @here/harp-mapview/lib/MapView.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@ import { IMapAntialiasSettings, IMapRenderingManager, MapRenderingManager } from
import { ConcurrentDecoderFacade } from "./ConcurrentDecoderFacade";
import { CopyrightInfo } from "./CopyrightInfo";
import { DataSource } from "./DataSource";
import { ElevationRangeSource } from "./ElevationRangeSource";
import { MapViewImageCache } from "./image/MapViewImageCache";
import { MapViewFog } from "./MapViewFog";
import { PickHandler, PickResult } from "./PickHandler";
Expand Down
28 changes: 0 additions & 28 deletions @here/harp-mapview/lib/Tile.ts
Original file line number Diff line number Diff line change
Expand Up @@ -1032,18 +1032,6 @@ export class Tile implements CachedResource {
* @param decodedTile The [[DecodedTile]].
*/
createTextElements(decodedTile: DecodedTile) {
// gather the sum of [[TextElement]]s (upper boundary), to compute the priority, such that
// the text elements that come first get the highest priority, so they get placed first.
let numTextElements = 0;
let numTextElementsCreated = 0;

if (decodedTile.textPathGeometries !== undefined) {
numTextElements += decodedTile.textPathGeometries.length;
}
if (decodedTile.textGeometries !== undefined) {
numTextElements += decodedTile.textGeometries.length;
}

const displayZoomLevel = Math.floor(this.mapView.zoomLevel);
if (decodedTile.textPathGeometries !== undefined) {
this.m_preparedTextPaths = this.prepareTextPaths(decodedTile.textPathGeometries);
Expand Down Expand Up @@ -1109,7 +1097,6 @@ export class Tile implements CachedResource {
textElement.reserveSpace = technique.reserveSpace !== false;

this.addTextElement(textElement);
numTextElementsCreated++;
}
}

Expand Down Expand Up @@ -1176,7 +1163,6 @@ export class Tile implements CachedResource {
textElement.fadeFar = getPropertyValue(technique.fadeFar, displayZoomLevel);

this.addTextElement(textElement);
numTextElementsCreated++;
}
}
}
Expand Down Expand Up @@ -1942,20 +1928,6 @@ export class Tile implements CachedResource {
};
}

private getMaterialsCount() {
let num = 0;
this.objects.forEach((rootObject: TileObject & DisposableObject) => {
if (rootObject.material) {
if (Array.isArray(rootObject.material)) {
num += rootObject.material.length;
} else {
num += 1;
}
}
});
return num;
}

/**
* Pass the feature data on to the object, so it can be used in picking
* `MapView.intersectMapObjects()`. Do not pass the feature data if the technique is a
Expand Down
2 changes: 1 addition & 1 deletion @here/harp-mapview/lib/VisibleTileSet.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { LRUCache } from "@here/harp-lrucache";
import * as THREE from "three";

import { DataSource } from "./DataSource";
import { CalculationStatus, ElevationRange, ElevationRangeSource } from "./ElevationRangeSource";
import { CalculationStatus, ElevationRangeSource } from "./ElevationRangeSource";
import { MapTileCuller } from "./MapTileCuller";
import { Tile } from "./Tile";

Expand Down
1 change: 1 addition & 0 deletions @here/harp-mapview/lib/text/TextElementsRenderer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -776,6 +776,7 @@ export class TextElementsRenderer {
this.createTextElementStyle(element, element.name!)
);
});
// tslint:disable-next-line:no-unused-variable
for (const [name, style] of this.m_textStyles) {
if (style.textCanvas === undefined) {
if (style.fontCatalog !== undefined) {
Expand Down
5 changes: 0 additions & 5 deletions @here/harp-mapview/lib/text/TextStyleCache.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,6 @@ import {
} from "@here/harp-text-canvas";
import { ColorCache } from "../ColorCache";

/**
* Maximum zoom level possible considered in [[computeStyleCacheId]].
*/
const MAX_ZOOM_LEVEL = 100;

/**
* [[TextStyle]] id for the default value inside a [[TextRenderStyleCache]] or a
* [[TextLayoutStyleCache]].
Expand Down
6 changes: 1 addition & 5 deletions @here/harp-mapview/test/ConcurrentWorkerSetTest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,7 @@
* Licensed under Apache 2.0, see full license in LICENSE
* SPDX-License-Identifier: Apache-2.0
*/
import {
RequestController,
WorkerDecoderProtocol,
WorkerServiceProtocol
} from "@here/harp-datasource-protocol";
import { WorkerDecoderProtocol, WorkerServiceProtocol } from "@here/harp-datasource-protocol";
import { stubGlobalConstructor, willEventually } from "@here/harp-test-utils";
import { Logger, LogLevel, WorkerChannel, WORKERCHANNEL_MSG_TYPE } from "@here/harp-utils";
import { assert } from "chai";
Expand Down
2 changes: 0 additions & 2 deletions @here/harp-omv-datasource/lib/OmvDebugLabelsTile.ts
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,6 @@ export class OmvDebugLabelsTile extends OmvTile {
super.createTextElements(decodedTile);

const colorMap = new Map<number, THREE.Color>();
// black color for point numbers
const black = new THREE.Color(0);

// activate in the browser with:
// window.__debugContext.setValue("DEBUG_TEXT_PATHS", true)
Expand Down
6 changes: 3 additions & 3 deletions @here/harp-omv-datasource/lib/OmvDecoder.ts
Original file line number Diff line number Diff line change
Expand Up @@ -182,7 +182,7 @@ export class OmvDecoder implements IGeometryProcessor {
private readonly m_projection: Projection,
private readonly m_styleSetEvaluator: StyleSetEvaluator,
private readonly m_showMissingTechniques: boolean,
private readonly m_dataFilter?: OmvFeatureFilter,
dataFilter?: OmvFeatureFilter,
private readonly m_featureModifier?: OmvFeatureModifier,
private readonly m_gatherFeatureIds = true,
private readonly m_createTileInfo = false,
Expand All @@ -192,8 +192,8 @@ export class OmvDecoder implements IGeometryProcessor {
private readonly m_languages?: string[]
) {
// Register the default adapters.
this.m_dataAdapters.push(new OmvProtobufDataAdapter(this, m_dataFilter, logger));
this.m_dataAdapters.push(new VTJsonDataAdapter(this, m_dataFilter, logger));
this.m_dataAdapters.push(new OmvProtobufDataAdapter(this, dataFilter, logger));
this.m_dataAdapters.push(new VTJsonDataAdapter(this, dataFilter, logger));
}

/**
Expand Down
1 change: 0 additions & 1 deletion @here/harp-omv-datasource/test/OmvTest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@ import {
OmvFilterString,
OmvGeometryType
} from "../index";
import { com } from "../lib/proto/vector_tile";

import { assert } from "chai";

Expand Down
1 change: 0 additions & 1 deletion test/ImportTest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ import * as glob from "glob";
import * as path from "path";

import { assert } from "chai";
import { stringify } from "querystring";

// tslint:disable:only-arrow-functions
// tslint:disable:forin
Expand Down
1 change: 1 addition & 0 deletions tslint.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@
}
],
"no-unused-expression": true,
"no-unused-variable": true,
"no-duplicate-variable": true,
"no-implicit-dependencies": false,
"no-namespace": false,
Expand Down

0 comments on commit ebd9bd0

Please sign in to comment.