[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
Re: [jdt-ui-dev] Extending ClassFileEditor..
|
The ClassFileDocumentProvider uses IClassFile.getSource() to access the
source of a class file. In order to associate source with a
jar file you create a class path entry using
JCore.newLibraryEntry and update the class path of the containing
project. To change how the source path works this would be an appropriate
starting point for your investigation. The UI elements such as the
SourceAttachmentDialog must then be adapted to the new story.
In order to edit read-only files you should look into the following
issues:
- the result of ITextEditor.isEditable is used to the set the editable
state of the editor's SourceViewer (see
AbstractTextEditor.validateState)
- source manipulating actions such as Paste enable/disable themselves
based on ITextEditorExtension2#validateEditorInputState() (based on
this method files that are under version control can be checked out prior
to the first modification)
- Save should redirect to Save As for modified read-only files
Kai
At 12:40 PM 5/28/2003 +0530, you wrote:
Hi,
I am trying to extend ClassFileEditor so that I can associate
more than one source-paths to one .jar file in "Java Build Path
-> Libraries", where the source-paths will be separated by
";". Also I would like to edit the java source files if they
have write-permission(can it be done by just overwriting in which
isEditable() will return true).
Something similar to JBuilder-Libraries... ;)
Any pointer is greatly appreciated. Thanks in advance...
prasen
_______________________________________________
jdt-ui-dev mailing list
jdt-ui-dev@xxxxxxxxxxx
http://dev.eclipse.org/mailman/listinfo/jdt-ui-dev