use of com.intellij.notification.NotificationGroup in project google-cloud-intellij by GoogleCloudPlatform.
the class AppEngineStandardUnsupportedJavaVersionCheck method warnUser.
private void warnUser(Project project, List<Module> invalidModules) {
String message = new StringBuilder().append("<p>").append(GctBundle.message("appengine.support.java.version.alert.detail", "<a href=\"" + UPDATE_HREF + "\">", "</a>")).append("</p>").toString();
NotificationGroup notification = new NotificationGroup(GctBundle.message("appengine.support.java.version.alert.title"), NotificationDisplayType.BALLOON, true);
notification.createNotification(GctBundle.message("appengine.support.java.version.alert.title"), message, NotificationType.WARNING, new LanguageLevelLinkListener(invalidModules)).notify(project);
}
use of com.intellij.notification.NotificationGroup in project google-cloud-intellij by GoogleCloudPlatform.
the class ConflictingAppEnginePluginCheck method showNotification.
private void showNotification(@NotNull IdeaPluginDescriptor plugin) {
NotificationGroup notification = new NotificationGroup(GctBundle.message("plugin.conflict.error.title"), NotificationDisplayType.BALLOON, true);
String errorMessage = new StringBuilder().append("<p>").append(GctBundle.message("plugin.conflict.error.detail", plugin.getName())).append("</p>").append("<br />").append("<p>").append(GctBundle.message("plugin.conflict.error.action", "<a href=\"" + DEACTIVATE_LINK_HREF + "\">", "</a>")).append("</p>").toString();
notification.createNotification(GctBundle.message("plugin.conflict.error.title"), errorMessage, NotificationType.ERROR, new IdeaAppEnginePluginLinkListener(plugin)).notify(null);
UsageTrackerProvider.getInstance().trackEvent(GctTracking.APP_ENGINE_OLD_PLUGIN_NOTIFICATION).ping();
}
use of com.intellij.notification.NotificationGroup in project intellij-community by JetBrains.
the class CloudNotifier method showMessage.
public Notification showMessage(String message, MessageType messageType, @Nullable NotificationListener listener) {
NotificationGroup notificationGroup = findOrCreateBaloonGroup(myNotificationDisplayId);
Notification notification = notificationGroup.createNotification("", message, messageType.toNotificationType(), listener);
notification.notify(null);
return notification;
}
use of com.intellij.notification.NotificationGroup in project intellij-community by JetBrains.
the class NotificationParentGroup method findParent.
@Nullable
public static NotificationParentGroupBean findParent(@NotNull NotificationSettings setting) {
prepareInfo();
String groupId = setting.getGroupId();
NotificationGroup group = NotificationGroup.findRegisteredGroup(groupId);
NotificationParentGroupBean parent;
if (group == null) {
parent = myGroupToParent.get(groupId);
} else {
String parentId = group.getParentId();
if (parentId == null) {
parent = myGroupToParent.get(group.getDisplayId());
if (parent != null) {
group.setParentId(parent.id);
}
} else {
parent = myParents.get(parentId);
}
}
return parent;
}
use of com.intellij.notification.NotificationGroup in project intellij-community by JetBrains.
the class NotificationsConfigurationImpl method getAllSettings.
public synchronized NotificationSettings[] getAllSettings() {
Collection<NotificationSettings> settings = new THashSet<>(myIdToSettingsMap.values());
for (NotificationGroup group : NotificationGroup.getAllRegisteredGroups()) {
settings.add(getSettings(group.getDisplayId()));
}
NotificationSettings[] result = settings.toArray(new NotificationSettings[settings.size()]);
Arrays.sort(result, NOTIFICATION_SETTINGS_COMPARATOR);
return result;
}
Aggregations