Skip to content

Commit ce80489

Browse files
don't mark constructors when only marking declarations
1 parent 4c20c66 commit ce80489

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

enigma-swing/src/main/java/org/quiltmc/enigma/gui/panel/EditorPanel.java

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@
99
import org.quiltmc.enigma.api.source.DecompiledClassSource;
1010
import org.quiltmc.enigma.api.source.TokenStore;
1111
import org.quiltmc.enigma.api.source.TokenType;
12+
import org.quiltmc.enigma.api.translation.representation.entry.MethodEntry;
1213
import org.quiltmc.enigma.gui.Gui;
1314
import org.quiltmc.enigma.gui.config.Config;
1415
import org.quiltmc.enigma.gui.config.EntryMarkersSection;
@@ -554,6 +555,10 @@ void tryMarking(Token token, TokenType type, TokenStore tokenStore) {
554555
EditorPanel.this.getReference(token);
555556

556557
if (reference != null) {
558+
if (reference.entry instanceof MethodEntry method && method.isConstructor()) {
559+
return;
560+
}
561+
557562
final Entry<?> resolved = EditorPanel.this.resolveReference(reference);
558563
final EntryReference<Entry<?>, Entry<?>> declaration = EntryReference
559564
.declaration(resolved, resolved.getName());

0 commit comments

Comments
 (0)