Postfix templates: allow to provide helpId for template editors

This commit is contained in:
Alexander Zolotov
2018-03-23 16:57:58 +03:00
parent b24d9f67ae
commit f9ab8cb01f
3 changed files with 15 additions and 0 deletions
@@ -133,6 +133,11 @@ public class JavaPostfixTemplateEditor implements PostfixTemplateEditor {
return myPanel;
}
@Override
public String getHelpId() {
return "reference.custom.postfix.templates";
}
private static Document createDocument(@Nullable Project project) {
if (project == null) {
return EditorFactory.getInstance().createDocument("");
@@ -62,4 +62,10 @@ public class PostfixEditTemplateDialog extends DialogWrapper {
.addComponentFillVertically(myEditor.getComponent(), 0)
.getPanel();
}
@Nullable
@Override
protected String getHelpId() {
return myEditor.getHelpId();
}
}
@@ -19,4 +19,8 @@ public interface PostfixTemplateEditor extends Disposable {
@NotNull
JComponent getComponent();
default String getHelpId() {
return null;
}
}