Skip to content

Commit

Permalink
fix #176 Clicking 'Go to Extra Icons settings' from the notification …
Browse files Browse the repository at this point in the history
…just throws an error
  • Loading branch information
jonathanlermitage committed Jan 5, 2024
1 parent daf4dac commit 532d61c
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGELOG.md
Expand Up @@ -2,6 +2,7 @@

## 2024.1.2 (WIP)
* optimize icons size by ~3% with SVGO 3.2.0.
* fix [#176](https://github.com/jonathanlermitage/intellij-extra-icons-plugin/issues/176): clicking 'Go to Extra Icons settings' from the notification just throws an error.

## 2024.1.1 (2024/01/02)
* **INFO**: JetBrains will introduce a new business model for paid/freemium plugins. This model will offer a perpetual license, **allowing users to make a one-time payment for the plugin and use it for a lifetime**. [Get more information here](https://github.com/jonathanlermitage/intellij-extra-icons-plugin/blob/master/docs/LICENSE_FAQ.md#how-to-get-a-lifetime-license). There is no ETA yet.
Expand Down
Expand Up @@ -2,12 +2,12 @@

package lermitage.intellij.extra.icons.activity;

import com.intellij.ide.BrowserUtil;
import com.intellij.notification.Notification;
import com.intellij.notification.NotificationAction;
import com.intellij.notification.NotificationType;
import com.intellij.notification.Notifications;
import com.intellij.openapi.actionSystem.AnActionEvent;
import com.intellij.openapi.diagnostic.Logger;
import com.intellij.openapi.options.ShowSettingsUtil;
import com.intellij.openapi.project.Project;
import com.intellij.openapi.startup.ProjectActivity;
Expand All @@ -20,6 +20,8 @@
import lermitage.intellij.extra.icons.messaging.RefreshIconsNotifierService;
import lermitage.intellij.extra.icons.utils.I18nUtils;
import lermitage.intellij.extra.icons.utils.IJUtils;
import lermitage.intellij.extra.icons.utils.ProjectUtils;
import org.jetbrains.annotations.NonNls;
import org.jetbrains.annotations.NotNull;
import org.jetbrains.annotations.Nullable;

Expand All @@ -31,11 +33,17 @@
*/
public class HintNotificationsProjectActivity implements ProjectActivity {

private static final @NonNls Logger LOGGER = Logger.getInstance(HintNotificationsProjectActivity.class);

private static final ResourceBundle i18n = I18nUtils.getResourceBundle();

@Nullable
@Override
public Object execute(@NotNull Project project, @NotNull Continuation<? super Unit> continuation) {
if (!ProjectUtils.isProjectAlive(project)) {
LOGGER.info(this.getClass().getName() + " started before project is ready. Will not show startup notifications this time");
return null;
}
SettingsIDEService settingsIDEService = SettingsIDEService.getInstance();

boolean alwaysShowNotifications = System.getProperty("extra-icons.always.show.notifications", "false").equals("true"); //NON-NLS
Expand Down

0 comments on commit 532d61c

Please sign in to comment.