Skip to content

Commit

Permalink
Fix Annotation Overlay bug when Dialog was cancelled
Browse files Browse the repository at this point in the history
  • Loading branch information
tischi committed Oct 30, 2024
1 parent fdfed71 commit c202c89
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@

<groupId>org.embl.mobie</groupId>
<artifactId>mobie-viewer-fiji</artifactId>
<version>5.5.1</version>
<version>5.5.3</version>
<!-- mvn clean install -Dmaven.test.skip=true -Dscijava.app.directory=/Users/tischer/Desktop/Fiji/Fiji-MoBIE.app -->

<!-- ../scijava-scripts/release-version.sh - -skip-version-check - -skip-license-update -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,9 @@ public void close()
@Override
protected synchronized void draw( Graphics2D g )
{
if ( annotationColumn == null || annotations == null || annotations.isEmpty() )
return;

if ( viewerTransform != null )
{
start = System.currentTimeMillis();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ public void close()
@Override
protected synchronized void draw( Graphics2D g )
{
if ( annotations == null || annotations.size() == 0 )
if ( annotationColumn == null || annotations == null || annotations.size() == 0 )
return;

if ( viewerTransform != null )
Expand Down
3 changes: 3 additions & 0 deletions src/main/java/org/embl/mobie/lib/table/TableView.java
Original file line number Diff line number Diff line change
Expand Up @@ -497,6 +497,9 @@ private void overlayAnnotationDialog()
jTable,
"Annotation column" );

if ( annotationColumn == null )
return;

if ( annotationOverlay != null )
{
annotationOverlay.close();
Expand Down

0 comments on commit c202c89

Please sign in to comment.