Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
肾齐团队
Hosts
提交
95ec173a
Hosts
项目概览
肾齐团队
/
Hosts
通知
17
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
Hosts
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
Pages
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
提交
Issue看板
前往新版Gitcode,体验更适合开发者的 AI 搜索 >>
提交
95ec173a
编写于
5月 12, 2022
作者:
C
chenjianqiang
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
1.增加刷新
2.修复工作空间问题 3.窗体icon
上级
3eadd030
变更
4
隐藏空白更改
内联
并排
Showing
4 changed file
with
15 addition
and
3 deletion
+15
-3
src/main/java/com/lishihe/hosts/frame/HostsFrame.java
src/main/java/com/lishihe/hosts/frame/HostsFrame.java
+7
-0
src/main/java/com/lishihe/hosts/utils/FileUtils.java
src/main/java/com/lishihe/hosts/utils/FileUtils.java
+1
-1
src/main/resources/META-INF/plugin.xml
src/main/resources/META-INF/plugin.xml
+7
-2
src/main/resources/static/reload.png
src/main/resources/static/reload.png
+0
-0
未找到文件。
src/main/java/com/lishihe/hosts/frame/HostsFrame.java
浏览文件 @
95ec173a
...
...
@@ -176,6 +176,13 @@ public class HostsFrame {
clip
.
setContents
(
new
StringSelection
(
fileNameAndPathMap
.
get
(
name
)),
null
);
});
nameListMenu
.
add
(
itemCopyPath
);
//6 刷新
JMenuItem
itemReload
=
new
JMenuItem
(
"刷新"
,
getMenuIcon
(
"reload"
));
itemReload
.
addActionListener
(
itemE
->
{
//重新拉取列表
parseHostList
();
});
nameListMenu
.
add
(
itemReload
);
}
/**
...
...
src/main/java/com/lishihe/hosts/utils/FileUtils.java
浏览文件 @
95ec173a
...
...
@@ -181,7 +181,7 @@ public class FileUtils {
* @param file 文件夹对象
*/
public
static
void
checkDirectory
(
File
file
)
{
if
(!
file
.
exists
()
&&
file
.
isDirectory
()
)
{
if
(!
file
.
exists
())
{
try
{
boolean
newFile
=
file
.
mkdirs
();
}
catch
(
Exception
e
)
{
...
...
src/main/resources/META-INF/plugin.xml
浏览文件 @
95ec173a
...
...
@@ -11,7 +11,12 @@
]]>
</description>
<depends>
com.intellij.modules.platform
</depends>
<extensions
defaultExtensionNs=
"com.intellij"
>
<toolWindow
id=
"Hosts"
anchor=
"bottom"
factoryClass=
"com.lishihe.hosts.factory.ToolWindowsFactory"
secondary=
"true"
canCloseContents=
"false"
/>
<toolWindow
id=
"Hosts"
anchor=
"bottom"
factoryClass=
"com.lishihe.hosts.factory.ToolWindowsFactory"
secondary=
"true"
canCloseContents=
"false"
icon=
"AllIcons.Actions.Annotate"
/>
</extensions>
</idea-plugin>
\ No newline at end of file
src/main/resources/static/reload.png
0 → 100644
浏览文件 @
95ec173a
1.7 KB
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录