mirror of
https://github.com/zhigang1992/DefinitelyTyped.git
synced 2026-04-24 05:06:02 +08:00
Add callback to olx.view.FitOptions. (#23199)
* Add `callback` to `olx.view.FitOptions`. See http://openlayers.org/en/latest/apidoc//ol.View.html#fit * Use existing AnimateCallback type
This commit is contained in:
1
types/openlayers/index.d.ts
vendored
1
types/openlayers/index.d.ts
vendored
@@ -14618,6 +14618,7 @@ declare module olx {
|
||||
maxZoom?: number;
|
||||
duration?: number;
|
||||
easing?: ((t: number) => number);
|
||||
callback?: olx.animation.AnimateCallback;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -399,6 +399,10 @@ let view: ol.View = new ol.View({
|
||||
|
||||
voidValue = view.setMaxZoom(numberValue);
|
||||
voidValue = view.setMinZoom(numberValue);
|
||||
voidValue = view.fit(simpleGeometry);
|
||||
voidValue = view.fit(extent);
|
||||
voidValue = view.fit(extent, {callback: () => {}});
|
||||
voidValue = view.fit(extent, {callback: (animationCompleted: boolean) => {}});
|
||||
|
||||
//
|
||||
// ol.layer.Base
|
||||
|
||||
Reference in New Issue
Block a user