Updating 7.0 plugin to 8.0

I am working to update our plugin to run on IDEA 8.0 and am not sure about some changes.

I have quite a lot of references in the code to com.intellij.openapi.Disposable which is now showing as red. Is this because 8.0 still needs an external plugin dev kit of some sort or do I need to change to something else?

Regards,

MArkee

6 comments
Comment actions Permalink

Hello mark,

I am working to update our plugin to run on IDEA 8.0 and am not sure
about some changes.

I have quite a lot of references in the code to
com.intellij.openapi.Disposable which is now showing as red. Is this
because 8.0 still needs an external plugin dev kit of some sort or do
I need to change to something else?


You need to add util.jar to the classpath of your IDEA SDK.

--
Dmitry Jemerov
Development Lead
JetBrains, Inc.
http://www.jetbrains.com/
"Develop with Pleasure!"


0
Comment actions Permalink

Dmitry,

Thanks. That seems to fix almost everything.

Can you recommend any documentation on replacing readExternal/writeExternal which no longer work. I am using them just to store a couple of strings for configuration settings so I can remember users preferred settings.

Regards,

MArkee

0
Comment actions Permalink

Hello mark,

Dmitry,

Thanks. That seems to fix almost everything.

Can you recommend any documentation on replacing
readExternal/writeExternal which no longer work. I am using them just
to store a couple of strings for configuration settings so I can
remember users preferred settings.


See another recent thread on this topic: http://www.jetbrains.net/devnet/message/5231641#5231641

--
Dmitry Jemerov
Development Lead
JetBrains, Inc.
http://www.jetbrains.com/
"Develop with Pleasure!"


0
Comment actions Permalink

Thanks for the link.

MArkee

0
Comment actions Permalink

I've got this all working except my loadState method never seems to be called so values are not ever loaded.

My class is


public class PDFFileTypeManagerImpl extends PDFFileTypeManager implements //ApplicationComponent, //JDOMExternalizable{
       PersistentStateComponent<PDFFileTypeManagerImpl> {



and it is defined in plugin.xml as

<!-- project components of the plugin-->
    <application-components>

        <!--registers the filetype and sets it up-->
        <component>
            <implementation-class>org.jpedal.pdf.plugins.idea.fileTypes.impl.PDFFileTypeManagerImpl</implementation-class>
            <interface-class>org.jpedal.pdf.plugins.idea.fileTypes.PDFFileTypeManager</interface-class>
        </component>



Does it need to be defined elsewhere now or in a different way?

Regards,

MArk


0
Comment actions Permalink

Hello mark,

Did you specify the @State annotation on the class specifying where the settings
should be saved?

Also note that loadState() will only be called if the user has changed some
settings from their default values. The default state should be initialized
in the class constructor.

I've got this all working except my loadState method never seems to be
called so values are not ever loaded.

My class is

public class PDFFileTypeManagerImpl extends PDFFileTypeManager
implements //ApplicationComponent, //JDOMExternalizable{
PersistentStateComponent<PDFFileTypeManagerImpl> {
and it is defined in plugin.xml as

<!-- project components of the plugin-->
<application-components>
<!registers the filetype and sets it up>
<component>

<implementation-class>org.jpedal.pdf.plugins.idea.fileTypes.impl.PDFFi
leTypeManagerImpl</implementation-class>

<interface-class>org.jpedal.pdf.plugins.idea.fileTypes.PDFFileTypeMana
ger</interface-class>
</component>
Does it need to be defined elsewhere now or in a different way?

Regards,

MArk

---
Original message URL:
http://www.jetbrains.net/devnet/message/5233578#5233578

--
Dmitry Jemerov
Development Lead
JetBrains, Inc.
http://www.jetbrains.com/
"Develop with Pleasure!"


0

Please sign in to leave a comment.