|
|||||||||
| Home >> All >> org >> merlotxml >> [ merlot overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
org.merlotxml.merlot
Class GD_XMLEditorDocUI

java.lang.Objectjava.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.JPanel
org.merlotxml.merlot.XMLEditorDocUI
org.merlotxml.merlot.GD_XMLEditorDocUI
- All Implemented Interfaces:
- javax.accessibility.Accessible, javax.swing.event.ChangeListener, java.util.EventListener, GD_MerlotDOMNodeViewListener, java.awt.image.ImageObserver, java.awt.MenuContainer, MerlotConstants, java.awt.event.MouseListener, java.io.Serializable, StatusListener
- public class GD_XMLEditorDocUI
- extends XMLEditorDocUI
- implements MerlotConstants, javax.swing.event.ChangeListener, StatusListener, GD_MerlotDOMNodeViewListener
- extends XMLEditorDocUI
XML Document UI L&F code
- Version:
- $Id: GD_XMLEditorDocUI.java,v 1.39 2002/10/29 15:22:02 flament Exp $
| Nested Class Summary | |
(package private) class |
GD_XMLEditorDocUI.AsyncSelect
|
protected class |
GD_XMLEditorDocUI.AutoHideAttribute
|
protected class |
GD_XMLEditorDocUI.NodeAddActionListener
|
| Nested classes inherited from class javax.swing.JPanel |
javax.swing.JPanel.AccessibleJPanel |
| Nested classes inherited from class javax.swing.JComponent |
javax.swing.JComponent.AccessibleJComponent |
| Nested classes inherited from class java.awt.Container |
java.awt.Container.AccessibleAWTContainer |
| Nested classes inherited from class java.awt.Component |
java.awt.Component.AccessibleAWTComponent, java.awt.Component.BltBufferStrategy, java.awt.Component.FlipBufferStrategy |
| Field Summary | |
(package private) StateAction[] |
_actions
|
(package private) GD_XMLEditorDocUI.AutoHideAttribute |
_autoHideAttribute
|
(package private) java.util.Hashtable |
_views
|
(package private) MerlotDOMNode |
_wishNode
|
(package private) javax.swing.JSplitPane |
_workspace
|
| Fields inherited from class org.merlotxml.merlot.XMLEditorDocUI |
_doc, _menuBar, _mouseChangedTab, _openEditors, _openEditPanels, _openNodes, _splitPane, _status1, _status2, _status3, _statusPanel, _table, _treePanel, _treePasteMenu, _XMLmodel, STATUS_DISPLAY_TIME |
| Fields inherited from class javax.swing.JComponent |
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
| Fields inherited from class java.awt.Container |
|
| Fields inherited from class java.awt.Component |
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
| Fields inherited from interface org.merlotxml.merlot.MerlotConstants |
ACTION_MENU_ACCELERATOR, ACTION_MENU_ICON, ACTION_NAME, ACTION_SHORT_DESCRIPTION, ACTION_SMALL_ICON, AFTER, BEFORE, ERR, INTO, UI, XML |
| Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
| Constructor Summary | |
GD_XMLEditorDocUI(XMLEditorDoc doc)
|
|
| Method Summary | |
protected void |
addItemsToMenu(java.util.List menuItems,
javax.swing.MenuElement menu)
|
void |
asyncSelectNode(MerlotDOMNode node)
call syncSelectNode with SwingUtilities.invokeLater |
boolean |
beforeSelect(GD_MerlotDOMNodeViewer view,
MerlotDOMNode newNode)
Propagate beforeSelect to all view expect from "view" |
void |
deleteNode(MerlotDOMNode node)
call from GD_XMLEditorDoc to select another node when the deleted one |
protected void |
doPopup(java.awt.event.MouseEvent e)
|
protected javax.swing.JMenuItem |
DTDElementToJMenuItem(MerlotDOMEditor editor,
MerlotDOMNode node,
org.merlotxml.util.xml.DTDElement el,
boolean addShortCut,
java.lang.StringBuffer shortcuts)
|
void |
editNode(MerlotDOMNode node,
boolean brandSpankinNew)
call from GD_XMLEditorDoc |
protected void |
finalize()
Called on an object by the Virtual Machine at most once, at some point after the Object is determined unreachable but before it is destroyed. |
StateAction[] |
getActions()
return action define in dtd plugin for this document |
javax.swing.JEditorPane |
getEditorPane()
Get JEditorPane of styled view |
protected javax.swing.JMenu |
getNodeAddMenu(MerlotDOMNode node,
int where)
Creates the add-> menu popup for right-click actions on a particular node. |
protected java.util.List |
getNodeMenuItems(MerlotDOMNode node)
return context menu for "node" |
java.awt.print.Printable |
getPrintable()
|
MerlotDOMNode |
getSelectedNode()
return the current select node (use the first view) |
MerlotDOMNode[] |
getSelectedNodes()
return all nodes selected (for compatibilty : only one can selected) |
int |
getSelectedRow()
|
java.awt.datatransfer.Transferable |
getTransferable()
gets the transfer data for the current selection, or null if no selection exists |
java.awt.datatransfer.Transferable |
getTransferable(MerlotDOMNode node)
|
java.awt.datatransfer.Transferable |
getTransferableOfChilds(MerlotDOMNode node)
|
private MerlotDOMNode |
getWishNode()
return the node that GD_XMLEditorDoc want to show |
GD_XMLEditorDoc |
getXMLEditorDoc()
|
protected void |
hideAttributes()
|
(package private) boolean |
isThereElement(MerlotDOMNode[] nodes)
|
java.util.Collection |
organizeDTDElement(MerlotDOMNode node,
java.util.Collection elements)
Get list of DTDElement and organize it with groups define in plugin |
void |
refreshNode(MerlotDOMNode node,
boolean cancelOnly)
override default to do nothing |
void |
selected(GD_MerlotDOMNodeViewer view)
Select the node than the current node in "view" |
void |
selectNode(MerlotDOMNode node)
override default to do nothing |
protected void |
setupAutoHideAttribute()
|
protected void |
setupPanel()
This panel looks a little like Windows Explorer. |
protected void |
setupViews(MerlotDOMNode root)
create all view and add them this |
protected void |
showAttributes()
|
void |
showNode(MerlotDOMNode node)
override default to do nothing |
void |
stateChanged(javax.swing.event.ChangeEvent evt)
Called by an object to notify the listener that the object's state has changed. |
void |
statusChanged(StatusEvent evt)
|
protected boolean |
suppressToUser(MerlotDOMEditor editor,
MerlotDOMNode node,
org.merlotxml.util.xml.DTDElement el)
|
boolean |
sync()
Save the current node from view |
void |
syncSelectNode(MerlotDOMNode node)
select a node in fact select a node in first view then all view are synchronize |
void |
updateNodeMenu(javax.swing.JMenu menu)
updates the given node menu for the selected node |
void |
updateStyledView()
Update styled view from MerlotDOMDocument |
| Methods inherited from class org.merlotxml.merlot.XMLEditorDocUI |
createTreePasteMenu, editText, enablePasteItems, getMenuBar, getNodeAddSpecialMenu, getNodeForPath, getNodeForRow, getNodePopupMenu, getWorkspaceSize, mouseClicked, mouseEntered, mouseExited, mousePressed, mouseReleased, saveOpenEditors, setStatus, setStatus, setupTreeTable |
| Methods inherited from class javax.swing.JPanel |
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI |
| Methods inherited from class java.lang.Object |
clone, equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
_workspace
javax.swing.JSplitPane _workspace
_views
java.util.Hashtable _views
_actions
StateAction[] _actions
_wishNode
MerlotDOMNode _wishNode
_autoHideAttribute
GD_XMLEditorDocUI.AutoHideAttribute _autoHideAttribute
| Constructor Detail |
GD_XMLEditorDocUI
public GD_XMLEditorDocUI(XMLEditorDoc doc)
| Method Detail |
finalize
protected void finalize()
throws java.lang.Throwable
- Description copied from class:
java.lang.Object - Called on an object by the Virtual Machine at most once,
at some point after the Object is determined unreachable
but before it is destroyed. You would think that this
means it eventually is called on every Object, but this is
not necessarily the case. If execution terminates
abnormally, garbage collection does not always happen.
Thus you cannot rely on this method to always work.
For finer control over garbage collection, use references
from the
java.lang.refpackage.Virtual Machines are free to not call this method if they can determine that it does nothing important; for example, if your class extends Object and overrides finalize to do simply
super.finalize().finalize() will be called by a java.lang.Thread that has no locks on any Objects, and may be called concurrently. There are no guarantees on the order in which multiple objects are finalized. This means that finalize() is usually unsuited for performing actions that must be thread-safe, and that your implementation must be use defensive programming if it is to always work.
If an Exception is thrown from finalize() during garbage collection, it will be patently ignored and the Object will still be destroyed.
It is allowed, although not typical, for user code to call finalize() directly. User invocation does not affect whether automatic invocation will occur. It is also permitted, although not recommended, for a finalize() method to "revive" an object by making it reachable from normal code again.
Unlike constructors, finalize() does not get called for an object's superclass unless the implementation specifically calls
super.finalize().The default implementation does nothing.
getActions
public StateAction[] getActions()
- return action define in dtd plugin for this document
setupViews
protected void setupViews(MerlotDOMNode root)
- create all view and add them this
setupAutoHideAttribute
protected void setupAutoHideAttribute()
showAttributes
protected void showAttributes()
hideAttributes
protected void hideAttributes()
setupPanel
protected void setupPanel()
- This panel looks a little like Windows Explorer. It has a treetable at the left,
a JSplitPane slider in the middle, and then an editing workspace at the right.
- Overrides:
setupPanelin classXMLEditorDocUI
getXMLEditorDoc
public GD_XMLEditorDoc getXMLEditorDoc()
getEditorPane
public javax.swing.JEditorPane getEditorPane()
- Get JEditorPane of styled view
getPrintable
public java.awt.print.Printable getPrintable()
updateStyledView
public void updateStyledView()
- Update styled view from MerlotDOMDocument
sync
public boolean sync()
- Save the current node from view
beforeSelect
public boolean beforeSelect(GD_MerlotDOMNodeViewer view, MerlotDOMNode newNode)
- Propagate beforeSelect to all view expect from "view"
- Specified by:
beforeSelectin interfaceGD_MerlotDOMNodeViewListener
selected
public void selected(GD_MerlotDOMNodeViewer view)
- Select the node than the current node in "view"
- Specified by:
selectedin interfaceGD_MerlotDOMNodeViewListener
getWishNode
private MerlotDOMNode getWishNode()
- return the node that GD_XMLEditorDoc want to show
editNode
public void editNode(MerlotDOMNode node, boolean brandSpankinNew)
- call from GD_XMLEditorDoc
- Overrides:
editNodein classXMLEditorDocUI
selectNode
public void selectNode(MerlotDOMNode node)
- override default to do nothing
- Overrides:
selectNodein classXMLEditorDocUI
syncSelectNode
public void syncSelectNode(MerlotDOMNode node)
- select a node
in fact select a node in first view then all view are synchronize
asyncSelectNode
public void asyncSelectNode(MerlotDOMNode node)
- call syncSelectNode with SwingUtilities.invokeLater
refreshNode
public void refreshNode(MerlotDOMNode node, boolean cancelOnly)
- override default to do nothing
- Overrides:
refreshNodein classXMLEditorDocUI
showNode
public void showNode(MerlotDOMNode node)
- override default to do nothing
- Overrides:
showNodein classXMLEditorDocUI
deleteNode
public void deleteNode(MerlotDOMNode node)
- call from GD_XMLEditorDoc to select another node when the deleted one
- Overrides:
deleteNodein classXMLEditorDocUI
getSelectedNode
public MerlotDOMNode getSelectedNode()
- return the current select node (use the first view)
- Overrides:
getSelectedNodein classXMLEditorDocUI
getSelectedNodes
public MerlotDOMNode[] getSelectedNodes()
- return all nodes selected (for compatibilty : only one can selected)
- Overrides:
getSelectedNodesin classXMLEditorDocUI
getNodeMenuItems
protected java.util.List getNodeMenuItems(MerlotDOMNode node)
- return context menu for "node"
- Overrides:
getNodeMenuItemsin classXMLEditorDocUI
addItemsToMenu
protected void addItemsToMenu(java.util.List menuItems, javax.swing.MenuElement menu)
- Overrides:
addItemsToMenuin classXMLEditorDocUI
getNodeAddMenu
protected javax.swing.JMenu getNodeAddMenu(MerlotDOMNode node, int where)
- Creates the add-> menu popup for right-click actions on a particular node.
- Overrides:
getNodeAddMenuin classXMLEditorDocUI
organizeDTDElement
public java.util.Collection organizeDTDElement(MerlotDOMNode node, java.util.Collection elements)
- Get list of DTDElement and organize it with groups define in plugin
suppressToUser
protected boolean suppressToUser(MerlotDOMEditor editor, MerlotDOMNode node, org.merlotxml.util.xml.DTDElement el)
DTDElementToJMenuItem
protected javax.swing.JMenuItem DTDElementToJMenuItem(MerlotDOMEditor editor, MerlotDOMNode node, org.merlotxml.util.xml.DTDElement el, boolean addShortCut, java.lang.StringBuffer shortcuts)
doPopup
protected void doPopup(java.awt.event.MouseEvent e)
- Overrides:
doPopupin classXMLEditorDocUI
getTransferable
public java.awt.datatransfer.Transferable getTransferable()
- Description copied from class:
XMLEditorDocUI - gets the transfer data for the current selection, or null if no selection exists
- Overrides:
getTransferablein classXMLEditorDocUI
getSelectedRow
public int getSelectedRow()
- Overrides:
getSelectedRowin classXMLEditorDocUI
stateChanged
public void stateChanged(javax.swing.event.ChangeEvent evt)
- Description copied from interface:
javax.swing.event.ChangeListener - Called by an object to notify the listener that the object's state has
changed. The incoming
eventidentifies thesourceof the event, allowing the listener to differentiate when it is listening for changes in multiple sources.- Specified by:
stateChangedin interfacejavax.swing.event.ChangeListener- Overrides:
stateChangedin classXMLEditorDocUI
isThereElement
boolean isThereElement(MerlotDOMNode[] nodes)
statusChanged
public void statusChanged(StatusEvent evt)
- Specified by:
statusChangedin interfaceStatusListener- Overrides:
statusChangedin classXMLEditorDocUI
getTransferable
public java.awt.datatransfer.Transferable getTransferable(MerlotDOMNode node)
getTransferableOfChilds
public java.awt.datatransfer.Transferable getTransferableOfChilds(MerlotDOMNode node)
updateNodeMenu
public void updateNodeMenu(javax.swing.JMenu menu)
- Description copied from class:
XMLEditorDocUI - updates the given node menu for the selected node
- Overrides:
updateNodeMenuin classXMLEditorDocUI
|
|||||||||
| Home >> All >> org >> merlotxml >> [ merlot overview ] | PREV CLASS NEXT CLASS | ||||||||
SUMMARY: JAVADOC | SOURCE | DOWNLOAD | NESTED | FIELD | CONSTR | METHOD |
DETAIL: FIELD | CONSTR | METHOD | ||||||||
JAVADOC