[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[wtp-dev] Support for outline views..



Hi all,

I'm copying a msg I sent to the forums. This might be a more appropriate place.

For Virgo, we want to support an outline for the Server editor. First, I'm surprised that this isn't provided OOTB. Perhaps there is something we need to implement that we haven't? I also couldn't find any extension points to plug into the outline provider.

I was able to adapt generically for the server editor to our own outline page implementation, e.g.:

Code: [Select all] [Show/ hide]
<extension
        point="org.eclipse.core.runtime.adapters">
      <factory
            adaptableType="org.eclipse.wst.server.ui.internal.editor.ServerEditor"
            class="org.eclipse.virgo.ide.runtime.internal.ui.editor.VirgoEditorAdapterFactory">
         <adapter
               type="org.eclipse.ui.views.contentoutline.IContentOutlinePage">
         </adapter>
      </factory>
</extension>

But then when implementing the adapter itself, I discovered that there doesn't seem to be any easy way in API to determine what the server type is? Neutral So if I implement this, I'm going to really be providing an outline view for any server editors, which of course we shouldn't be doing.

What if anything is the pattern for this? Ideally, WTP would provide an outline with a parent node for each page and then perhaps allow page contributions to provide a content provider or something..

In fact, we could contribute such a thing to WTP proper, but a concern would be how quickly a patch might be able to get through the process, esp. given proximity to Juno.

cheers,

Miles
______________________________
Miles T. Parker
http://tasktop.com
Committer, Eclipse Mylyn and Virgo
Project Lead, Model Focussing Tools and AMP