Skip to content

Commit ff825b8

Browse files
author
zhaokai
committed
还原时间轴方法
1 parent 71e14db commit ff825b8

File tree

2 files changed

+23
-17
lines changed

2 files changed

+23
-17
lines changed

src/service/3DPlot/PlotLayer3D.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ class PlotLayer3D extends Observable {
132132
if (!plotLayer) {
133133
return undefined;
134134
}
135-
135+
136136
let index = this._getPlotIndexById(id, plotLayer);
137137
const {_primitives} = plotLayer;
138138
if (index !== undefined) {

src/service/PlotBase/Animation/TimeLine/TimeLine.js

Lines changed: 22 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
* @Author: zk
44
* @Date: 2022-03-23 11:53:45
55
* @LastEditors: zk
6-
* @LastEditTime: 2022-06-17 15:46:41
6+
* @LastEditTime: 2022-06-17 19:58:03
77
*/
88

99
import { AnimationReg } from '../AnimationTypes';
@@ -199,21 +199,27 @@ export default class TimeLine {
199199
return this._animationArr.filter((v) => v.isInAnimation(id));
200200
}
201201

202-
/**
203-
* @function: Module:TimeLine.prototype.addAnimationObject
204-
* @description: 添加动画对象
205-
* @param {*} plotObjects
206-
* @param {*} item
207-
* @return {*}
208-
*/
209-
addAnimationObject(plotObjects,item) {
210-
if(!plotObjects || plotObjects.length===0) return;
211-
const animationOptions= Object.assign({},item)
212-
const keyString= plotObjects.map((s)=>{
213-
return s.getElement().getFeatureId()
214-
}).toString()
215-
animationOptions.featureIds=keyString
216-
const addAnimation = this.createAnimationObject(animationOptions);
202+
// /**
203+
// * @function: Module:TimeLine.prototype.addAnimationObject
204+
// * @description: 添加动画对象
205+
// * @param {*} plotObjects
206+
// * @param {*} item
207+
// * @return {*}
208+
// */
209+
// addAnimationObject(plotObjects,item) {
210+
// if(!plotObjects || plotObjects.length===0) return;
211+
// const animationOptions= Object.assign({},item)
212+
// const keyString= plotObjects.map((s)=>{
213+
// return s.getElement().getFeatureId()
214+
// }).toString()
215+
// animationOptions.featureIds=keyString
216+
// const addAnimation = this.createAnimationObject(animationOptions);
217+
// this._animationArr.push(addAnimation);
218+
// return addAnimation;
219+
// }
220+
221+
addAnimationObject(item) {
222+
const addAnimation = this.createAnimationObject(item);
217223
this._animationArr.push(addAnimation);
218224
return addAnimation;
219225
}

0 commit comments

Comments
 (0)