Skip to content

Commit

Permalink
Restore compatibility with EAP 2024.2, the minimum version is now 202…
Browse files Browse the repository at this point in the history
…4.1 (#1636)
  • Loading branch information
ahus1 committed Jun 21, 2024
1 parent 6f0b781 commit 03c9ff8
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 172 deletions.
3 changes: 2 additions & 1 deletion CHANGELOG.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,10 @@ This document provides a high-level view of the changes introduced by release.
[[releasenotes]]
== Release notes

=== 0.41.16
=== 0.42.0

- Custom extensions loading in multimodule projects (thanks to @o-nix) (#1633)
- Restore compatibility with EAP 2024.2, the minimum version is now 2024.1 (#1636)

=== 0.41.15

Expand Down
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@
# See https://jb.gg/intellij-platform-builds-list for available build versions
# skipping IC-223.7571.182 do to disk space limitations on GHA runners
# Run for example RD-233.11799.49 which doesn't include java
pluginVerifierIdeVersions = IC-233.11361.10,IC-241.15989.150
pluginVerifierIdeVersions = IC-241.14494.240,IC-241.15989.150
Original file line number Diff line number Diff line change
Expand Up @@ -3,20 +3,17 @@
import com.intellij.openapi.application.ApplicationManager;
import com.intellij.openapi.fileEditor.FileEditor;
import com.intellij.openapi.fileEditor.FileEditorManager;
import com.intellij.openapi.fileEditor.TextEditor;
import com.intellij.openapi.fileEditor.impl.text.PsiAwareTextEditorProvider;
import com.intellij.openapi.fileEditor.TextEditorWithPreviewProvider;
import com.intellij.openapi.project.Project;
import com.intellij.openapi.project.ProjectManager;
import com.intellij.openapi.vfs.VirtualFile;
import com.intellij.psi.PsiFile;
import com.intellij.psi.PsiManager;
import org.asciidoc.intellij.AsciiDocLanguage;
import org.asciidoc.intellij.ui.SplitTextEditorProvider;
import org.jetbrains.annotations.NotNull;

public class AsciiDocSplitEditorProvider extends SplitTextEditorProvider {
public class AsciiDocSplitEditorProvider extends TextEditorWithPreviewProvider {
public AsciiDocSplitEditorProvider() {
super(new PsiAwareTextEditorProvider(), new AsciiDocPreviewEditorProvider());
super(new AsciiDocPreviewEditorProvider());

// when this plugin is installed at runtime, check if the existing editors as split editors.
// If not, close the editor and re-open the files
Expand Down Expand Up @@ -58,13 +55,4 @@ public AsciiDocSplitEditorProvider() {
});
}

@Override
protected FileEditor createSplitEditor(@NotNull final FileEditor firstEditor, @NotNull FileEditor secondEditor) {
if (!(firstEditor instanceof TextEditor) || !(secondEditor instanceof AsciiDocPreviewEditor asciiDocPreviewEditor)) {
throw new IllegalArgumentException("Main editor should be TextEditor");
}
asciiDocPreviewEditor.setEditor(((TextEditor) firstEditor).getEditor());
return new AsciiDocSplitEditor(((TextEditor) firstEditor), ((AsciiDocPreviewEditor) secondEditor));
}

}
154 changes: 0 additions & 154 deletions src/main/java/org/asciidoc/intellij/ui/SplitTextEditorProvider.java

This file was deleted.

2 changes: 1 addition & 1 deletion src/main/resources/META-INF/plugin.xml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@

<!-- please see http://confluence.jetbrains.net/display/IDEADEV/Plugin+Compatibility+with+IntelliJ+Platform+Products
on how to target different products -->
<idea-version since-build="233.11799.241"/> <!-- 2023.3 -->
<idea-version since-build="241.14494.240"/> <!-- 2024.1 -->
<!-- please see https://plugins.jetbrains.com/docs/intellij/build-number-ranges.html -->
<depends>com.intellij.modules.lang</depends>
<depends optional="true" config-file="org.asciidoctor.intellij.asciidoc-javafx.xml">com.intellij.javafx</depends>
Expand Down

0 comments on commit 03c9ff8

Please sign in to comment.