<!ELEMENT extension (weavingPanel)>
<!ATTLIST extension
point CDATA #REQUIRED
id CDATA #IMPLIED>
<!ELEMENT weavingPanel EMPTY>
<!ATTLIST weavingPanel
class CDATA #REQUIRED
name CDATA #IMPLIED>
The weaving panel configuration element
<extension point=
"org.eclipse.gmt.weaver.weavingPanelID"
id=
"DefaultWeavingPanelExtension"
>
<weavingPanel name=
"Base weaving panel extension"
class=
"org.eclipse.gmt.weaver.extension.panel.DefaultWeavingPanel"
/>
</extension>
public interface IWeavingPanel extends IMenuListener, IPropertyListener, Listener, IWeaverMenuAdapter {
/**
* Initialize the panel with the reference of the Global Editor
* @param editor
*/
public void init(GlobalWeaverEditor editor);
/**
* Create the viewer
* @param parent
*/
public Viewer createViewer(Composite parent);
/**
* Create the control
* @param parent
*/
public void createControl(Composite parent);
/**
* Get the viewer
* @return
*/
public Viewer getViewer();
/**
* Sets the ressource set input
* @param input the ressource set
*/
public void setInput(ResourceSet input);
/**
* Sets the panel title for ContentViewer
* @param object
*/
public void setTitle(Object object);
/**
* Set the panel title
* @param title
* @param image
*/
public void setTitle(String title, Image image);
/**
* Dispose the panel
*/
public void dispose();
/**
* adds a new selection listener.
* @param listener
*/
public void addWeaverSelectionChangedListener(IWSelectionChangedListener listener);
/**
* removes the selection listener
* @param listener
*/
public void removeWeaverSelectionChangedListener(IWSelectionChangedListener listener);
}
-----------------------------------------------------------------------------------------------
Overview of other implemented interfaces
--> IMenuListener
- public void menuAboutToShow(IMenuManager manager);
To populate pop up menus with previous defined elements (see IWeaverMenuAdapter)
--> IPropertyListener
- public void propertyChanged(Object source, int propId);
To change/refresh property values
--> Listener
- void handleEvent (Event event);
Listen to other windows events (like drag and drop)
--> IWeaverMenuAdapter
used to create the pop up menu objects. It wraps the MenuContributor.
- public void createActions(EObject eObj);
creates a list with sub menu actions associated with this eObj
- public void populateMenuAboutToShow(IMenuManager parentMenu);
populates the menu with the private actions into the parent menu specified