XMLMultipageEditorPart read only [message #1612869] |
Thu, 12 February 2015 08:56 |
Jakub Wegrzyn Messages: 4 Registered: October 2014 |
Junior Member |
|
|
Hi,
I want to make my XmlMultiPageEditor read-only in certain situations.
I have already tried three aproaches but none of them was satisfying.
1. Removing text input isteners from xmlEditor - that would mean rewriting a lot of wst.xml.ui.internal.tabletree package. I might be wrong here.
2. Using IStorageEditorInput - it didn't work for the design page, and i don't like that because i mainly use FileEditorInput in my application. Some features would not work anymore.
3. Setting IFile.setReadOnly(true). When I try to modify a document the editor asks if i want to make the document writable.
I tried to implement extension point:
<extension
point="org.eclipse.team.core.defaultFileModificationValidator ">
<validator
class=" org.eclipse.team.internal.ui.DefaultUIFileModificationValidator "/>
</extension>
But the application doesn't use my own Validator... it uses the default one.
My question is how can i make 3rd approach work? Something with extension point is not ok...
Thanks,
Jakub
|
|
|
Powered by
FUDForum. Page generated in 0.02808 seconds