From 3f0251476f4115202a0b4c043d8fa5851dc8a2ab Mon Sep 17 00:00:00 2001 From: Jumper Chen Date: Wed, 1 Dec 2021 12:13:25 +0800 Subject: [PATCH] 1. Fix #30 No compatible with v2021.3 2. Bump version 0.1.14 for Intellij v2021.3 --- build.gradle | 12 +++++------- .../org/zkoss/zkidea/newsNotification/ZKNews.java | 6 +++--- src/main/resources/META-INF/plugin.xml | 5 +++++ 3 files changed, 13 insertions(+), 10 deletions(-) diff --git a/build.gradle b/build.gradle index a1982be..0c9bda9 100644 --- a/build.gradle +++ b/build.gradle @@ -1,18 +1,16 @@ plugins { - id 'org.jetbrains.intellij' version '1.1.4' + id 'org.jetbrains.intellij' version '1.3.0' id 'java' } group 'org.zkoss.zkidea' -version '0.1.13' +version '0.1.14' repositories { mavenCentral() + maven { url 'https://www.jetbrains.com/intellij-repository/releases' } - maven { - url 'https://dl.bintray.com/jetbrains/intellij-plugin-service' - } - + maven { url "https://cache-redirector.jetbrains.com/intellij-dependencies" } } dependencies { @@ -20,7 +18,7 @@ dependencies { } intellij { - version = '2021.2' + version = '2021.3' plugins = ['maven', 'com.intellij.java'] } patchPluginXml { diff --git a/src/main/java/org/zkoss/zkidea/newsNotification/ZKNews.java b/src/main/java/org/zkoss/zkidea/newsNotification/ZKNews.java index 5b3c607..d828bce 100644 --- a/src/main/java/org/zkoss/zkidea/newsNotification/ZKNews.java +++ b/src/main/java/org/zkoss/zkidea/newsNotification/ZKNews.java @@ -26,7 +26,7 @@ import java.io.IOException; public class ZKNews implements StartupActivity { - public static final String ZK_WEBSITE_URL = "http://www.zkoss.org"; + public static final String ZK_WEBSITE_URL = "http://www.zkoss.org?ide=in"; @Override public void runActivity(@NotNull Project project) { @@ -43,12 +43,12 @@ private void newsNotificationPopup(Project project) throws IOException { File zkNewsFile = new File(ZKPathManager.getPluginTempPath() + File.separator + "zkNews.txt"); if (!zkNewsFile.exists()) zkNewsFile.createNewFile(); - String news = newsLoader(ZK_WEBSITE_URL); + String news = newsLoader(ZK_WEBSITE_URL + "&fetch=true"); String newsCache = FileUtil.loadFile(zkNewsFile); if(!news.equals(newsCache)) { FileUtil.writeToFile(zkNewsFile, news); NotificationGroupManager.getInstance().getNotificationGroup("news notification") - .createNotification(news + " Visit zkoss.org for detail.", NotificationType.INFORMATION) + .createNotification(news + " Visit zkoss.org for detail.", NotificationType.INFORMATION) .setListener(new NotificationListener.UrlOpeningListener(true)) .notify(project); } diff --git a/src/main/resources/META-INF/plugin.xml b/src/main/resources/META-INF/plugin.xml index 4f65a94..9d29682 100644 --- a/src/main/resources/META-INF/plugin.xml +++ b/src/main/resources/META-INF/plugin.xml @@ -11,6 +11,11 @@ ]]> 0.1.14

+ +

0.1.13