diff --git a/plugins/spellchecker/src/com/intellij/spellchecker/quickfixes/AcceptWordAsCorrect.java b/plugins/spellchecker/src/com/intellij/spellchecker/quickfixes/AcceptWordAsCorrect.java index 18a93ed00d80..2d93575065e4 100644 --- a/plugins/spellchecker/src/com/intellij/spellchecker/quickfixes/AcceptWordAsCorrect.java +++ b/plugins/spellchecker/src/com/intellij/spellchecker/quickfixes/AcceptWordAsCorrect.java @@ -23,6 +23,8 @@ import com.intellij.spellchecker.SpellCheckerManager; import com.intellij.spellchecker.util.SpellCheckerBundle; import org.jetbrains.annotations.NotNull; +import javax.swing.*; + public class AcceptWordAsCorrect implements SpellCheckerQuickFix { private String word; @@ -51,4 +53,7 @@ public class AcceptWordAsCorrect implements SpellCheckerQuickFix { spellCheckerManager.acceptWordAsCorrect(word); } + public Icon getIcon(int flags) { + return new ImageIcon(ShowSuggestions.class.getResource("spellcheck.png")); + } } diff --git a/plugins/spellchecker/src/com/intellij/spellchecker/quickfixes/ShowSuggestions.java b/plugins/spellchecker/src/com/intellij/spellchecker/quickfixes/ShowSuggestions.java index d41972672461..8c9fe5f5ceb8 100644 --- a/plugins/spellchecker/src/com/intellij/spellchecker/quickfixes/ShowSuggestions.java +++ b/plugins/spellchecker/src/com/intellij/spellchecker/quickfixes/ShowSuggestions.java @@ -17,14 +17,16 @@ package com.intellij.spellchecker.quickfixes; import com.intellij.codeInspection.LocalQuickFix; import com.intellij.openapi.project.Project; +import com.intellij.openapi.util.Iconable; import com.intellij.openapi.util.TextRange; import com.intellij.spellchecker.SpellCheckerManager; import org.jetbrains.annotations.NotNull; +import javax.swing.*; import java.util.List; -public abstract class ShowSuggestions implements LocalQuickFix { +public abstract class ShowSuggestions implements LocalQuickFix, Iconable { protected TextRange textRange; protected String word; @@ -55,4 +57,8 @@ public abstract class ShowSuggestions implements LocalQuickFix { suggestions = manager.getSuggestions(word); } + public Icon getIcon(int flags) { + return new ImageIcon(ShowSuggestions.class.getResource("spellcheck.png")); + } + } diff --git a/plugins/spellchecker/src/com/intellij/spellchecker/quickfixes/SpellCheckerQuickFix.java b/plugins/spellchecker/src/com/intellij/spellchecker/quickfixes/SpellCheckerQuickFix.java index 9bb123f549fd..d9b4d9fc2536 100644 --- a/plugins/spellchecker/src/com/intellij/spellchecker/quickfixes/SpellCheckerQuickFix.java +++ b/plugins/spellchecker/src/com/intellij/spellchecker/quickfixes/SpellCheckerQuickFix.java @@ -17,9 +17,10 @@ package com.intellij.spellchecker.quickfixes; import com.intellij.codeInspection.LocalQuickFix; import com.intellij.openapi.actionSystem.Anchor; +import com.intellij.openapi.util.Iconable; import org.jetbrains.annotations.NotNull; -public interface SpellCheckerQuickFix extends LocalQuickFix { +public interface SpellCheckerQuickFix extends LocalQuickFix, Iconable { @NotNull Anchor getPopupActionAnchor(); diff --git a/plugins/spellchecker/src/com/intellij/spellchecker/quickfixes/spellcheck.png b/plugins/spellchecker/src/com/intellij/spellchecker/quickfixes/spellcheck.png new file mode 100644 index 000000000000..308e4a0cd95f Binary files /dev/null and b/plugins/spellchecker/src/com/intellij/spellchecker/quickfixes/spellcheck.png differ