diff --git a/README.md b/README.md
index 242a844..7cd1e12 100644
--- a/README.md
+++ b/README.md
@@ -6,21 +6,14 @@ English Notes:
Show javadoc comments at the Project view Tree structure.
Show javadoc comments at the end-of-line.
Show javadoc comments at "xx ClassNameOrSimpleName.json".
-One of the above features can be turned off in
- settings -> Tools -> Show Comment Global
-Font color of end-of-line comments can be modified in
- settings -> Tools -> Show Comment Global
-Class name prefix filter of end-of-line comment can be modified in
- settings -> Tools -> Show Comment Project
+Config: settings -> Tools -> Show Comment Global/Project
Chinese Notes:
- 在结构树显示 文档注释。
- 在行末尾显示 文档注释。
- 支持 "xx 类全名或简名.json"。
-
- 可以在设置中 关闭 上面其中一个功能。
-
- 可以在设置中 修改 行末注释 的字体颜色。
-
- 可以在设置中 修改 行末注释 的类名前缀过滤。
+
- 修改配置:设置 -> 工具 -> Show Comment Global/Project
English Change Notes:
diff --git a/src/main/java/io/github/linwancen/plugin/show/doc/JsonDocUtils.java b/src/main/java/io/github/linwancen/plugin/show/doc/JsonDocUtils.java
index a2c4377..cf7acbc 100644
--- a/src/main/java/io/github/linwancen/plugin/show/doc/JsonDocUtils.java
+++ b/src/main/java/io/github/linwancen/plugin/show/doc/JsonDocUtils.java
@@ -46,13 +46,17 @@ public class JsonDocUtils {
continue;
}
if (level == 0) {
- return DocUtils.srcOrByteCodeDoc(psiField);
- }
- String classFullName = toClassFullName(psiField);
- PsiClass[] classes = PsiClassUtils.fullNameToClass(classFullName, project);
- PsiDocComment docComment = doc(classes, project, jsonPath, level - 1);
- if (docComment != null) {
- return docComment;
+ PsiDocComment docComment = DocUtils.srcOrByteCodeDoc(psiField);
+ if (docComment != null) {
+ return docComment;
+ }
+ } else {
+ String classFullName = toClassFullName(psiField);
+ PsiClass[] classes = PsiClassUtils.fullNameToClass(classFullName, project);
+ PsiDocComment docComment = doc(classes, project, jsonPath, level - 1);
+ if (docComment != null) {
+ return docComment;
+ }
}
}
return null;
diff --git a/src/main/resources/META-INF/plugin.xml b/src/main/resources/META-INF/plugin.xml
index 7c169a7..d8af239 100644
--- a/src/main/resources/META-INF/plugin.xml
+++ b/src/main/resources/META-INF/plugin.xml
@@ -9,21 +9,14 @@ English Notes:
Show javadoc comments at the Project view Tree structure.
Show javadoc comments at the end-of-line.
Show javadoc comments at "xx ClassNameOrSimpleName.json".
-One of the above features can be turned off in
- settings -> Tools -> Show Comment Global
-Font color of end-of-line comments can be modified in
- settings -> Tools -> Show Comment Global
-Class name prefix filter of end-of-line comment can be modified in
- settings -> Tools -> Show Comment Project
+Config: settings -> Tools -> Show Comment Global/Project
Chinese Notes:
- 在结构树显示 文档注释。
- 在行末尾显示 文档注释。
- 支持 "xx 类全名或简名.json"。
-
- 可以在设置中 关闭 上面其中一个功能。
-
- 可以在设置中 修改 行末注释 的字体颜色。
-
- 可以在设置中 修改 行末注释 的类名前缀过滤。
+
- 修改配置:设置 -> 工具 -> Show Comment Global/Project
]]>
diff --git a/src/test/java/io/github/linwancen/plugin/show/demo/spi/io.github.linwancen.plugin.show.demo.method.Face b/src/test/java/io/github/linwancen/plugin/show/demo/spi/io.github.linwancen.plugin.show.demo.java.obj.Face
similarity index 100%
rename from src/test/java/io/github/linwancen/plugin/show/demo/spi/io.github.linwancen.plugin.show.demo.method.Face
rename to src/test/java/io/github/linwancen/plugin/show/demo/spi/io.github.linwancen.plugin.show.demo.java.obj.Face