Explorar el Código

improve the s3m lib

tags/2.12.0
Caven Chen hace 3 años
padre
commit
c3c54e6d47
Se han modificado 2 ficheros con 3 adiciones y 3 borrados
  1. 1
    1
      libs/s3m/S3MTiles/S3MTile.js
  2. 2
    2
      libs/s3m/S3MTiles/S3MTilesLayer.js

+ 1
- 1
libs/s3m/S3MTiles/S3MTile.js Ver fichero

} }


this.contentState = ContentState.LOADING this.contentState = ContentState.LOADING
this.contentReadyPromise = Cesium.when.defer()
this.contentReadyPromise = new Promise()
let contentFailedFunction = getContentFailedFunction(this) let contentFailedFunction = getContentFailedFunction(this)


promise promise

+ 2
- 2
libs/s3m/S3MTiles/S3MTilesLayer.js Ver fichero

distance: Number.MAX_VALUE, distance: Number.MAX_VALUE,
pixel: Number.MAX_VALUE pixel: Number.MAX_VALUE
} }
this._readyPromise = Cesium.when.defer()
this._readyPromise = new Promise()


this.loadConfig(options.url) this.loadConfig(options.url)
} }


S3MTilesLayer.prototype.loadConfig = function(url) { S3MTilesLayer.prototype.loadConfig = function(url) {
let that = this let that = this
Cesium.when(url)
Promise.resolve(url)
.then(function(url) { .then(function(url) {
let basePath let basePath
let resource = Cesium.Resource.createIfNeeded(url) let resource = Cesium.Resource.createIfNeeded(url)

Cargando…
Cancelar
Guardar