From c211eb133e1ff30ac71fd82332400b8dd26be20b Mon Sep 17 00:00:00 2001 From: A Samuel Pottinger Date: Sat, 10 Dec 2022 17:31:38 +0000 Subject: [PATCH] Fix #619 --- .../mode/java/preproc/PdeParseTreeListener.java | 2 +- java/test/resources/staticannotations.expected | 8 ++++---- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/java/src/processing/mode/java/preproc/PdeParseTreeListener.java b/java/src/processing/mode/java/preproc/PdeParseTreeListener.java index d774b6e92..8e10e1c33 100644 --- a/java/src/processing/mode/java/preproc/PdeParseTreeListener.java +++ b/java/src/processing/mode/java/preproc/PdeParseTreeListener.java @@ -591,7 +591,7 @@ public class PdeParseTreeListener extends ProcessingBaseListener { if (annoationPoint == null) { insertBefore(possibleModifiers.getStart(), "public "); } else { - insertAfter(annoationPoint.getStop(), "public "); + insertAfter(annoationPoint.getStop(), " public "); } } diff --git a/java/test/resources/staticannotations.expected b/java/test/resources/staticannotations.expected index b56a8584b..2b651f2b4 100644 --- a/java/test/resources/staticannotations.expected +++ b/java/test/resources/staticannotations.expected @@ -26,16 +26,16 @@ class Button { this.radius = radius; } - boolean over() { + public boolean over() { return dist(mouseX, mouseY, this.x, this.y) < this.radius; } - void draw() { + public void draw() { ellipse(this.x, this.y, this.radius * 2, this.radius * 2); } @Deprecated - void old() { + public void old() { ellipse(this.x, this.y, this.radius, this.radius); } @@ -45,7 +45,7 @@ class Button { class ButtonOther extends Button { @Override - boolean over() { + public boolean over() { return dist(mouseX, mouseY, this.x, this.y) < this.radius / 2; }