fix: don't delete imagery size, update related telemetry on focusedImage change

This commit is contained in:
Jesse Mazzella 2023-02-10 10:34:16 -08:00
parent 622e6044a4
commit 55b8a4142c
2 changed files with 5 additions and 4 deletions

View File

@ -588,7 +588,6 @@ export default {
focusedImageIndex() { focusedImageIndex() {
this.trackDuration(); this.trackDuration();
this.resetAgeCSS(); this.resetAgeCSS();
this.updateRelatedTelemetryForFocusedImage();
this.getImageNaturalDimensions(); this.getImageNaturalDimensions();
}, },
bounds() { bounds() {
@ -774,6 +773,10 @@ export default {
this.layers = layersMetadata; this.layers = layersMetadata;
if (this.domainObject.configuration) { if (this.domainObject.configuration) {
const persistedLayers = this.domainObject.configuration.layers; const persistedLayers = this.domainObject.configuration.layers;
if (!persistedLayers) {
return;
}
layersMetadata.forEach((layer) => { layersMetadata.forEach((layer) => {
const persistedLayer = persistedLayers.find(object => object.name === layer.name); const persistedLayer = persistedLayers.find(object => object.name === layer.name);
if (persistedLayer) { if (persistedLayer) {
@ -960,6 +963,7 @@ export default {
} }
this.focusedImageIndex = index; this.focusedImageIndex = index;
this.updateRelatedTelemetryForFocusedImage();
}, },
trackDuration() { trackDuration() {
if (this.canTrackDuration) { if (this.canTrackDuration) {

View File

@ -153,9 +153,6 @@ export default {
return; return;
} }
// forcibly reset the imageContainer size to prevent an aspect ratio distortion
delete this.imageContainerWidth;
delete this.imageContainerHeight;
this.bounds = bounds; // setting bounds for ImageryView watcher this.bounds = bounds; // setting bounds for ImageryView watcher
}, },
timeSystemChange() { timeSystemChange() {