修改当同时播放两个效果时的连续闪烁问题

This commit is contained in:
冯少康 2026-08-06 14:50:59 +08:00
parent 4b24e87192
commit 37a088d6ac
4 changed files with 15 additions and 7 deletions

View File

@ -204,7 +204,7 @@ const palyDateEvent: any = {
// 添加天气运算接口 animationType: 0 回放 1预览 // 添加天气运算接口 animationType: 0 回放 1预览
addyctqjsGis(map: any, eventOpt?: any) { addyctqjsGis(map: any, eventOpt?: any) {
// 清理UI // 清理UI
if (gisImgOpt.weatherType === 3) { if (eventOpt.weatherType === 3) {
removeWindLayer(map); removeWindLayer(map);
addWindLayer(map, windDataHandle(eventOpt.data)); addWindLayer(map, windDataHandle(eventOpt.data));

View File

@ -308,18 +308,20 @@ function updateTimeLabel(ctime: any) {
EventBusTool.getEventBus().publish("playData", { EventBusTool.getEventBus().publish("playData", {
key: "addyctqjsGis", key: "addyctqjsGis",
data: res.result, data: res.result,
weatherType:params.weatherType
}); });
}); });
// // //
if (weathFlag[3] === true&&gisImgOpt.weatherType!=3) { if (weathFlag[3] === true&&gisImgOpt.weatherType!=3) {
const params = { ...gisImgOpt, weatherType: 3, startTime: dataRequestOpt.value[currentHourDiff],hour:currentHourDiff }; const params1 = { ...params, weatherType: 3 };
delete params.key; delete params1.key;
delete params.endTime; delete params1.endTime;
playbackSearchData(params, true, (res) => { playbackSearchData(params1, true, (res) => {
// //
EventBusTool.getEventBus().publish('playData', { EventBusTool.getEventBus().publish('playData', {
key: 'addyctqjsGis', key: 'addyctqjsGis',
data: res.result, data: res.result,
weatherType:3
}); });
}); });
} }

View File

@ -99,14 +99,19 @@ function handleIconClick(item: meteorologyItem) {
key: "addyctqjsGis", key: "addyctqjsGis",
data: res.result, data: res.result,
animationType: 1, animationType: 1,
weatherType:gisImgOpt.weatherType
}); });
}); });
} else { } else {
playbackSearchData(gisImgOpt, false, (res) => { const params = { ...gisImgOpt };
delete params.key;
delete params.endTime;
playbackSearchData(params, false, (res) => {
// //
EventBusTool.getEventBus().publish("playData", { EventBusTool.getEventBus().publish("playData", {
key: "addyctqjsGis", key: "addyctqjsGis",
data: res.result, data: res.result,
weatherType:gisImgOpt.weatherType
}); });
}); });
} }

View File

@ -62,6 +62,7 @@ function weatherPreviewHandle(params: any) {
key: 'addyctqjsGis', key: 'addyctqjsGis',
data: res.result, data: res.result,
animationType: 1, animationType: 1,
weatherType:gisImgOpt.weatherType
}); });
dialogVisible.value = false; dialogVisible.value = false;
}); });