public class ValidatorDialog extends ToggleDialog implements SelectionChangedListener, MainLayerManager.ActiveLayerChangeListener
| Modifier and Type | Class and Description |
|---|---|
(package private) class |
ValidatorDialog.FixTask
Task for fixing a collection of
TestErrors. |
(package private) class |
ValidatorDialog.MouseEventHandler
Watches for double clicks and launches the popup menu.
|
class |
ValidatorDialog.SelectionWatch
Watches for tree selection.
|
static class |
ValidatorDialog.ValidatorBoundingXYVisitor |
ToggleDialog.ButtonHidingType, ToggleDialog.TitleBar, ToggleDialog.ToggleDialogActionjavax.swing.JPanel.AccessibleJPaneljavax.swing.JComponent.AccessibleJComponent| Modifier and Type | Field and Description |
|---|---|
private SideButton |
fixButton
The fix button
|
private SideButton |
ignoreButton
The ignore button
|
private javax.swing.tree.DefaultMutableTreeNode |
lastSelectedNode
Last selected element
|
private OsmDataLayer |
linkedLayer |
private SideButton |
lookupButton
The lookup button
|
private javax.swing.JPopupMenu |
popupMenu |
private PopupMenuHandler |
popupMenuHandler |
private SideButton |
selectButton
The select button
|
ValidatorTreePanel |
tree
The display tree
|
button, buttonHiding, detachedDialog, dialogsPanel, isCollapsed, isDocked, isShowing, name, preferenceClass, preferencePrefix, PROP_DYNAMIC_BUTTONS, titleBar, toggleAction, windowMenuItemlistenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW| Constructor and Description |
|---|
ValidatorDialog()
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
void |
activeOrEditLayerChanged(MainLayerManager.ActiveLayerChangeEvent e)
Called whenever the active or edit layer changed.
|
void |
addTreeSelectionListener(javax.swing.event.TreeSelectionListener listener)
Add a tree selection listener to the validator tree.
|
private void |
fixErrors()
Fix selected errors
|
PopupMenuHandler |
getPopupMenuHandler()
Replies the popup menu handler.
|
TestError |
getSelectedError()
Replies the currently selected error, or
null. |
void |
hideNotify()
Called when toggle dialog is hidden (collapsed, removed, MapFrame is removed, ...).
|
private void |
ignoreErrors()
Set selected errors to ignore state
|
void |
removeTreeSelectionListener(javax.swing.event.TreeSelectionListener listener)
Remove the given tree selection listener from the validator tree.
|
void |
selectionChanged(java.util.Collection<? extends OsmPrimitive> newSelection)
Informs the listener that the selection in the dataset has changed.
|
private void |
setSelectedItems()
Sets the selection of the map to the current selected items.
|
private boolean |
setSelection(java.util.Collection<OsmPrimitive> sel,
boolean addSelected)
Checks for fixes in selected element and, if needed, adds to the sel
parameter all selected elements
|
void |
setVisible(boolean v) |
void |
showNotify()
Called when toggle dialog is shown (after it was created or expanded).
|
void |
updateSelection(java.util.Collection<? extends OsmPrimitive> newSelection) |
buttonHidden, buttonShown, closeDetachedDialog, collapse, createLayout, createLayout, destroy, detach, dock, dockWhenClosingDetachedDlg, eventDispatched, expand, getButton, getDefaultDetachedSize, getName, getPreferencePrefix, getPreferredHeight, getToggleAction, helpTopic, hideDialog, isDialogInCollapsedView, isDialogInDefaultView, isDialogShowing, preferenceChanged, registerInWindowMenu, setButton, setContentVisible, setDialogsPanel, setIsButtonHiding, setIsCollapsed, setIsDocked, setIsShowing, setTitle, showDialog, stateChanged, toggleButtonHook, toString, unfurlDialoggetAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUIaddAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, hide, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingOrigin, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, unregisterKeyboardAction, updateadd, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusDownCycle, validate, validateTreeaction, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, transferFocus, transferFocusBackward, transferFocusUpCyclepublic ValidatorTreePanel tree
private final SideButton fixButton
private final SideButton ignoreButton
private final SideButton selectButton
private final SideButton lookupButton
private final javax.swing.JPopupMenu popupMenu
private final transient PopupMenuHandler popupMenuHandler
private javax.swing.tree.DefaultMutableTreeNode lastSelectedNode
private transient OsmDataLayer linkedLayer
public ValidatorDialog()
public void showNotify()
ToggleDialogshowNotify in class ToggleDialogpublic void hideNotify()
ToggleDialoghideNotify in class ToggleDialogpublic void setVisible(boolean v)
setVisible in class javax.swing.JComponentprivate void fixErrors()
private void ignoreErrors()
private void setSelectedItems()
private boolean setSelection(java.util.Collection<OsmPrimitive> sel, boolean addSelected)
sel - The collection where to add all selected elementsaddSelected - if true, add all selected elements to collectionpublic void activeOrEditLayerChanged(MainLayerManager.ActiveLayerChangeEvent e)
MainLayerManager.ActiveLayerChangeListenerYou can be sure that this layer is still contained in this set.
Listeners are called in the EDT thread and you can manipulate the layer manager in the current thread.
activeOrEditLayerChanged in interface MainLayerManager.ActiveLayerChangeListenere - The change event.public void addTreeSelectionListener(javax.swing.event.TreeSelectionListener listener)
listener - the TreeSelectionListenerpublic void removeTreeSelectionListener(javax.swing.event.TreeSelectionListener listener)
listener - the TreeSelectionListenerpublic PopupMenuHandler getPopupMenuHandler()
public TestError getSelectedError()
null.public void updateSelection(java.util.Collection<? extends OsmPrimitive> newSelection)
public void selectionChanged(java.util.Collection<? extends OsmPrimitive> newSelection)
SelectionChangedListenerselectionChanged in interface SelectionChangedListenernewSelection - The new selection.