Skip to content

Commit

Permalink
[desktop]: Fix inaccessible image after capture started
Browse files Browse the repository at this point in the history
  • Loading branch information
tiagohm committed Aug 10, 2024
1 parent bcb4b16 commit e3b1e5e
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions desktop/src/app/image/image.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -689,7 +689,11 @@ export class ImageComponent implements AfterViewInit, OnDestroy {
}

private async loadImageFromOpenImage(data: OpenImage) {
Object.assign(this.imageData, data)
if (data.camera) this.imageData.camera = data.camera
if (data.path) this.imageData.path = data.path
this.imageData.source = data.source
if (data.title) this.imageData.title = data.title
if (data.capture) this.imageData.capture = data.capture

// Not clicked on menu item.
if (this.calibration.source === 'CAMERA' && this.transformation.calibrationGroup !== data.capture?.calibrationGroup) {
Expand Down Expand Up @@ -1138,7 +1142,6 @@ export class ImageComponent implements AfterViewInit, OnDestroy {
const imageWrapper = image.parentElement

URL.revokeObjectURL(image.src)
console.log(image.src)

if (!this.zoom.panZoom && imageWrapper) {
const panZoom = createPanZoom(imageWrapper, {
Expand Down

0 comments on commit e3b1e5e

Please sign in to comment.