Skip to content

Commit

Permalink
1.1.4: Fixed issue#8: IllegalArgumentException in CycledPsiFile
Browse files Browse the repository at this point in the history
  • Loading branch information
Cybr0sis committed Jan 30, 2020
1 parent 424d591 commit 86e1074
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
import com.android.tools.idea.logcat.AndroidLogcatService;
import com.android.tools.idea.logcat.AndroidLogcatView;
import com.android.tools.idea.logcat.LogcatConsoleActionsPostProcessor;
import com.cybrosis.catdea.files.CatdeaFileType;
import com.cybrosis.catdea.highlighting.syntax.CatdeaSyntaxHighlighter;
import com.cybrosis.catdea.lang.CatdeaLanguage;
import com.cybrosis.catdea.lang.psi.PsiCatdeaEntry;
Expand Down Expand Up @@ -131,10 +132,10 @@ public void actionPerformed(@NotNull AnActionEvent e) {
this.deviceContext = deviceContext;

// Use PSI to support references and navigation to source code from log entry
final PsiFile dummy = PsiFileFactory.getInstance(project).createFileFromText(CatdeaLanguage.INSTANCE, "");
final PsiFile dummy = PsiFileFactory.getInstance(project).createFileFromText("_dummy_", CatdeaFileType.INSTANCE, "");
psiFile = new CycledPsiFile(dummy);

final Document document = PsiDocumentManager.getInstance(project).getDocument(psiFile);
final Document document = dummy.getViewProvider().getDocument();
assert document != null;

UndoUtil.disableUndoFor(document);
Expand Down
3 changes: 2 additions & 1 deletion src/main/resources/META-INF/plugin.xml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<idea-plugin>
<id>com.cybrosis.catdea</id>
<name>Catdea</name>
<version>1.1.3</version>
<version>1.1.4</version>
<vendor email="[email protected]" url="https://github.com/Cybr0sis/Catdea">Cybrosis</vendor>

<description><![CDATA[
Expand All @@ -26,6 +26,7 @@
]]></description>

<change-notes><![CDATA[
<p>1.1.4: Fixed issue#8: IllegalArgumentException in CycledPsiFile</p>
<p>1.1.3: Compatible with IntelliJ IDEA 2019.3</p>
<p>1.1.2: Fixed icons and minor refactoring</p>
<p>1.1.1: Fixed issue#4: NPE occurred in CatdeaServiceImpl.projectJdkChanged</p>
Expand Down

0 comments on commit 86e1074

Please sign in to comment.