diff --git a/gradle.properties b/gradle.properties index 6aaa6f656..b4a794492 100644 --- a/gradle.properties +++ b/gradle.properties @@ -21,13 +21,13 @@ # suppress inspection "UnusedProperty" for whole file kotlin.code.style=official -ideaVersion = 233-EAP-SNAPSHOT +ideaVersion = 233.9802.14-EAP-SNAPSHOT ideaVersionName = 2023.3 coreVersion = 1.6.10 downloadIdeaSources = true -pluginTomlVersion = 233.6745.297 +pluginTomlVersion = 233.9802.6 # Silences a build-time warning because we are bundling our own kotlin library kotlin.stdlib.default.dependency = false diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 5c7948adf..808c1fff3 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -18,8 +18,8 @@ jflex-skeleton = "org.jetbrains.idea:jflex:1.7.0-c1fdf11" grammarKit = "org.jetbrains.idea:grammar-kit:1.5.1" # Gradle Tooling -gradleToolingExtension = "com.jetbrains.intellij.gradle:gradle-tooling-extension:233-EAP-SNAPSHOT" -annotations = "org.jetbrains:annotations:23.0.0" +gradleToolingExtension = "com.jetbrains.intellij.gradle:gradle-tooling-extension:233.9802.14-EAP-SNAPSHOT" +annotations = "org.jetbrains:annotations:24.0.0" groovy = "org.codehaus.groovy:groovy-all:2.5.18" asm = { module = "org.ow2.asm:asm", version.ref = "asm" } diff --git a/src/main/kotlin/facet/MinecraftFacetEditorTab.kt b/src/main/kotlin/facet/MinecraftFacetEditorTab.kt index b26ac07d0..f72d48f62 100644 --- a/src/main/kotlin/facet/MinecraftFacetEditorTab.kt +++ b/src/main/kotlin/facet/MinecraftFacetEditorTab.kt @@ -24,7 +24,7 @@ import com.demonwav.mcdev.asset.MCDevBundle import com.demonwav.mcdev.asset.PlatformAssets import com.demonwav.mcdev.platform.PlatformType import com.intellij.facet.ui.FacetEditorTab -import com.intellij.util.ui.StartupUiUtil +import com.intellij.ui.JBColor import javax.swing.JCheckBox import javax.swing.JComponent import javax.swing.JLabel @@ -102,7 +102,7 @@ class MinecraftFacetEditorTab(private val configuration: MinecraftFacetConfigura } override fun createComponent(): JComponent { - if (StartupUiUtil.isDarkTheme) { + if (!JBColor.isBright()) { spongeIcon.icon = PlatformAssets.SPONGE_ICON_2X_DARK mcpIcon.icon = PlatformAssets.MCP_ICON_2X_DARK mixinIcon.icon = PlatformAssets.MIXIN_ICON_2X_DARK diff --git a/src/main/kotlin/facet/MinecraftFacetEditorTabV2.kt b/src/main/kotlin/facet/MinecraftFacetEditorTabV2.kt index 4ae6bfaae..5c3ef5eff 100644 --- a/src/main/kotlin/facet/MinecraftFacetEditorTabV2.kt +++ b/src/main/kotlin/facet/MinecraftFacetEditorTabV2.kt @@ -27,12 +27,12 @@ import com.intellij.facet.ui.FacetEditorTab import com.intellij.openapi.observable.properties.GraphProperty import com.intellij.openapi.observable.properties.PropertyGraph import com.intellij.openapi.observable.util.not +import com.intellij.ui.JBColor import com.intellij.ui.dsl.builder.Panel import com.intellij.ui.dsl.builder.Row import com.intellij.ui.dsl.builder.RowLayout import com.intellij.ui.dsl.builder.bindSelected import com.intellij.ui.dsl.builder.panel -import com.intellij.util.ui.StartupUiUtil import javax.swing.Icon import javax.swing.JComponent import javax.swing.JLabel @@ -84,7 +84,7 @@ class MinecraftFacetEditorTabV2(private val configuration: MinecraftFacetConfigu { afterChange { _ -> all(this, bukkit.auto, spigot.auto)(bukkit, spigot, paper) } }, ) - val isDarkMode = StartupUiUtil.isDarkTheme + val isDarkMode = !JBColor.isBright() val spongeIcon = if (isDarkMode) PlatformAssets.SPONGE_ICON_2X_DARK else PlatformAssets.SPONGE_ICON_2X createRow(sponge, "Sponge", spongeIcon) diff --git a/src/main/kotlin/insight/generation/ui/EventListenerWizard.kt b/src/main/kotlin/insight/generation/ui/EventListenerWizard.kt index 0cd281ffd..94843c41b 100644 --- a/src/main/kotlin/insight/generation/ui/EventListenerWizard.kt +++ b/src/main/kotlin/insight/generation/ui/EventListenerWizard.kt @@ -23,8 +23,8 @@ package com.demonwav.mcdev.insight.generation.ui import com.intellij.ide.highlighter.JavaHighlightingColors import com.intellij.openapi.editor.ex.util.EditorUtil import com.intellij.openapi.wm.ex.IdeFocusTraversalPolicy +import com.intellij.ui.JBColor import com.intellij.uiDesigner.core.GridConstraints -import com.intellij.util.ui.StartupUiUtil import javax.swing.JLabel import javax.swing.JPanel import javax.swing.JSeparator @@ -42,7 +42,7 @@ class EventListenerWizard(panel: JPanel?, className: String, defaultListenerName classNameTextField.font = EditorUtil.getEditorFont() listenerNameTextField.font = EditorUtil.getEditorFont() publicVoidLabel.font = EditorUtil.getEditorFont() - if (StartupUiUtil.isDarkTheme) { + if (!JBColor.isBright()) { publicVoidLabel.foreground = JavaHighlightingColors.KEYWORD.defaultAttributes.foregroundColor } else { publicVoidLabel.foreground = diff --git a/src/main/kotlin/platform/AbstractModuleType.kt b/src/main/kotlin/platform/AbstractModuleType.kt index d88258293..0e5693a10 100644 --- a/src/main/kotlin/platform/AbstractModuleType.kt +++ b/src/main/kotlin/platform/AbstractModuleType.kt @@ -32,7 +32,7 @@ import com.intellij.psi.PsiElement import com.intellij.psi.PsiFile import java.awt.Color import javax.swing.Icon -import org.apache.commons.lang.builder.ToStringBuilder +import org.apache.commons.lang3.builder.ToStringBuilder abstract class AbstractModuleType(val groupId: String, val artifactId: String) { @@ -61,7 +61,7 @@ abstract class AbstractModuleType(val groupId: String, v return } val manager = EntryPointsManager.getInstance(project) - val annotations = (manager as? EntryPointsManagerBase)?.ADDITIONAL_ANNOTATIONS as? MutableList ?: return + val annotations = (manager as? EntryPointsManagerBase)?.customAdditionalAnnotations ?: return ignoredAnnotations.asSequence() .filter { annotation -> !annotations.contains(annotation) } .forEach { annotations.add(it) } diff --git a/src/main/kotlin/platform/mcp/actions/SrgActionBase.kt b/src/main/kotlin/platform/mcp/actions/SrgActionBase.kt index 0a962e7ac..5d4482266 100644 --- a/src/main/kotlin/platform/mcp/actions/SrgActionBase.kt +++ b/src/main/kotlin/platform/mcp/actions/SrgActionBase.kt @@ -41,7 +41,7 @@ import com.intellij.ui.LightColors import com.intellij.ui.awt.RelativePoint import java.awt.Point import javax.swing.JComponent -import org.apache.commons.lang.StringEscapeUtils +import org.apache.commons.text.StringEscapeUtils abstract class SrgActionBase : AnAction() { @@ -119,7 +119,7 @@ abstract class SrgActionBase : AnAction() { } fun showSuccessBalloon(editor: Editor, element: PsiElement, text: String) { - val escapedText = StringEscapeUtils.escapeHtml(text) + val escapedText = StringEscapeUtils.escapeHtml4(text) val balloon = JBPopupFactory.getInstance() .createHtmlTextBalloonBuilder(escapedText, null, LightColors.SLIGHTLY_GREEN, null) .setHideOnAction(true)