org.apache.batik.apps.svgbrowser
Class DOMViewer.Panel.NodeInsertionHandler
java.lang.Object
org.apache.batik.apps.svgbrowser.DOMViewer.Panel.NodeInsertionHandler
- All Implemented Interfaces:
- EventListener
- Enclosing class:
- DOMViewer.Panel
protected class DOMViewer.Panel.NodeInsertionHandler
- extends Object
- implements EventListener
Handles "DOMNodeInserted" event.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DOMViewer.Panel.NodeInsertionHandler
protected DOMViewer.Panel.NodeInsertionHandler()
handleEvent
public void handleEvent(Event evt)
- Description copied from interface:
EventListener
- This method is called whenever an event occurs of the event type for
which the
EventListener
interface was registered.
- Specified by:
handleEvent
in interface EventListener
- Parameters:
evt
- The Event
contains contextual information
about the event.
findIndexToInsert
protected int findIndexToInsert(DefaultMutableTreeNode parentNode,
DefaultMutableTreeNode newParentNode)
- Compares the children of the two tree nodes and returns the index
of the first difference.
- Parameters:
parentNode
- The old tree nodenewParentNode
- The new tree node
- Returns:
- first child that differs
Copyright © 2017 Apache Software Foundation. All Rights Reserved.