User of my plugin has specified files that will be opened in my external utility.I need to override the double-click action for that.
You'll need to provide an implementation of com.intellij.openapi.fileEditor.FileEditorProvider interface, and open your external utility from its createEditor() method. There are lots of places in IntelliJ IDEA from where files can be opened, and double-click in project view is just one of them. Providing a FileEditorProvider implementation will cover them all.
-- Dmitry Jemerov Software Developer JetBrains, Inc. http://www.jetbrains.com/ "Develop with Pleasure!"
The Interface FileEditorProvider forces me to return a non-null FileEditor. I called my external tool in the createEditor method that return null. But I don't create FileEditor object from the createEditor method. How doing in this cause?
Hello r321e,
What are you actually trying to do? Most likely you don't need to override
the double-click action.
--
Dmitry Jemerov
Software Developer
JetBrains, Inc.
http://www.jetbrains.com/
"Develop with Pleasure!"
User of my plugin has specified files that will be opened in my external utility.I need to override the double-click action for that.
Hello r321e,
You'll need to provide an implementation of com.intellij.openapi.fileEditor.FileEditorProvider
interface, and open your external utility from its createEditor() method.
There are lots of places in IntelliJ IDEA from where files can be opened,
and double-click in project view is just one of them. Providing a FileEditorProvider
implementation will cover them all.
--
Dmitry Jemerov
Software Developer
JetBrains, Inc.
http://www.jetbrains.com/
"Develop with Pleasure!"
Thank you very much!:)
I have some problem.
The Interface FileEditorProvider forces me to return a non-null FileEditor.
I called my external tool in the createEditor method that return null. But I don't create FileEditor object from the createEditor method.
How doing in this cause?
Did u get this to work ?
If so, how ?
I have exactly same question for this.....
I want to run external binary when double clicking on a file with a specific extension, so i tried this...
But it cannot be null, cause an error....
Please share a solution for this..