private class DirectoryChooserUI.DirectoryHandler extends MouseAdapter implements TreeSelectionListener, CellEditorListener, ActionListener, FocusListener, Runnable
| Modifier and Type | Field and Description |
|---|---|
private WeakReference<TreePath> |
curSelPath
current selection holder
|
private JFileChooser |
fileChooser |
private TreePath |
pathToRename
path to rename for slow click to rename feature
|
private Timer |
renameTimer
timer for slow click to rename feature
|
| Constructor and Description |
|---|
DirectoryChooserUI.DirectoryHandler(JFileChooser fileChooser) |
| Modifier and Type | Method and Description |
|---|---|
void |
actionPerformed(ActionEvent e)
ActionListener impl, slow-double-click rename
|
private void |
cancelRename() |
private void |
changeTreeDirectory(File dir) |
void |
editingCanceled(ChangeEvent e) |
void |
editingStopped(ChangeEvent e)
Refresh filename text field after rename
|
void |
focusGained(FocusEvent e)
implementation of focus listener, for slow click rename cancelling
|
void |
focusLost(FocusEvent e) |
private File[] |
getSelectedNodes(TreePath[] paths) |
private void |
handlePopupMenu(MouseEvent e) |
private boolean |
isSelectionKept(TreePath selPath) |
void |
mouseClicked(MouseEvent e)
impl of MouseListener
|
void |
mousePressed(MouseEvent e) |
void |
mouseReleased(MouseEvent e) |
(package private) void |
preprocessMouseEvent(MouseEvent e) |
void |
run() |
void |
valueChanged(TreeSelectionEvent e)
imple of TreeSelectionListener
|
mouseDragged, mouseEntered, mouseExited, mouseMoved, mouseWheelMovedprivate JFileChooser fileChooser
private WeakReference<TreePath> curSelPath
private Timer renameTimer
private TreePath pathToRename
public DirectoryChooserUI.DirectoryHandler(JFileChooser fileChooser)
public void valueChanged(TreeSelectionEvent e)
valueChanged in interface TreeSelectionListenerpublic void mouseClicked(MouseEvent e)
mouseClicked in interface MouseListenermouseClicked in class MouseAdapterpublic void mousePressed(MouseEvent e)
mousePressed in interface MouseListenermousePressed in class MouseAdapterpublic void mouseReleased(MouseEvent e)
mouseReleased in interface MouseListenermouseReleased in class MouseAdapterprivate void handlePopupMenu(MouseEvent e)
private void changeTreeDirectory(File dir)
public void editingStopped(ChangeEvent e)
editingStopped in interface CellEditorListenerpublic void editingCanceled(ChangeEvent e)
editingCanceled in interface CellEditorListenerpublic void actionPerformed(ActionEvent e)
actionPerformed in interface ActionListenervoid preprocessMouseEvent(MouseEvent e)
private boolean isSelectionKept(TreePath selPath)
private void cancelRename()
public void focusGained(FocusEvent e)
focusGained in interface FocusListenerpublic void focusLost(FocusEvent e)
focusLost in interface FocusListenerCopyright © 2007–2016 Gephi Consortium. All rights reserved.