/** * Entry point for hit handle detection called from processMouse. * Does nothing if isHitDetectionFromProcessMouse is false. * * @return true if the mouseEvent triggered an expand/collapse in * the renderer, false otherwise. * * @see #isHitDetectionFromProcessMouse() */ public boolean hitHandleDetectionFromProcessMouse(MouseEvent e) { if (!isHitDetectionFromProcessMouse()) return false; int col = columnAtPoint(e.getPoint()); return ((col >= 0) && expandOrCollapseNode(columnAtPoint(e .getPoint()), e)); }
/** * Overridden to enable hit handle detection a mouseEvent which triggered * a expand/collapse. */ @Override protected void processMouseEvent(MouseEvent e) { // BasicTableUI selects on released if the pressed had been // consumed. So we try to fish for the accompanying released // here and consume it as wll. if ((e.getID() == MouseEvent.MOUSE_RELEASED) && consumedOnPress) { consumedOnPress = false; e.consume(); return; } if (getTreeTableHacker().hitHandleDetectionFromProcessMouse(e)) { // Issue #332-swing: hacking around selection loss. // prevent the // _table_ selection by consuming the mouseEvent // if it resulted in a expand/collapse consumedOnPress = true; e.consume(); return; } consumedOnPress = false; super.processMouseEvent(e); }
if (!isHierarchical(column)) return false; if (!mightBeExpansionTrigger(e)) return false; boolean changedExpansion = false;
if (!isHierarchical(column)) return false; if (!mightBeExpansionTrigger(e)) return false; boolean changedExpansion = false;
if (!isHierarchical(column)) return false; if (!mightBeExpansionTrigger(e)) return false; boolean changedExpansion = false;
if (!isHierarchical(column)) return false; if (!mightBeExpansionTrigger(e)) return false; boolean changedExpansion = false;
if (!isHierarchical(column)) return false; if (!mightBeExpansionTrigger(e)) return false; boolean changedExpansion = false;
/** * Overridden to enable hit handle detection a mouseEvent which triggered * a expand/collapse. */ @Override protected void processMouseEvent(MouseEvent e) { // BasicTableUI selects on released if the pressed had been // consumed. So we try to fish for the accompanying released // here and consume it as wll. if ((e.getID() == MouseEvent.MOUSE_RELEASED) && consumedOnPress) { consumedOnPress = false; e.consume(); return; } if (getTreeTableHacker().hitHandleDetectionFromProcessMouse(e)) { // Issue #332-swing: hacking around selection loss. // prevent the // _table_ selection by consuming the mouseEvent // if it resulted in a expand/collapse consumedOnPress = true; e.consume(); return; } consumedOnPress = false; super.processMouseEvent(e); }
/** * Overridden to enable hit handle detection a mouseEvent which triggered * a expand/collapse. */ @Override protected void processMouseEvent(MouseEvent e) { // BasicTableUI selects on released if the pressed had been // consumed. So we try to fish for the accompanying released // here and consume it as wll. if ((e.getID() == MouseEvent.MOUSE_RELEASED) && consumedOnPress) { consumedOnPress = false; e.consume(); return; } if (getTreeTableHacker().hitHandleDetectionFromProcessMouse(e)) { // Issue #332-swing: hacking around selection loss. // prevent the // _table_ selection by consuming the mouseEvent // if it resulted in a expand/collapse consumedOnPress = true; e.consume(); return; } consumedOnPress = false; super.processMouseEvent(e); }
/** * Overridden to enable hit handle detection a mouseEvent which triggered * a expand/collapse. */ @Override protected void processMouseEvent(MouseEvent e) { // BasicTableUI selects on released if the pressed had been // consumed. So we try to fish for the accompanying released // here and consume it as wll. if ((e.getID() == MouseEvent.MOUSE_RELEASED) && consumedOnPress) { consumedOnPress = false; e.consume(); return; } if (getTreeTableHacker().hitHandleDetectionFromProcessMouse(e)) { // Issue #332-swing: hacking around selection loss. // prevent the // _table_ selection by consuming the mouseEvent // if it resulted in a expand/collapse consumedOnPress = true; e.consume(); return; } consumedOnPress = false; super.processMouseEvent(e); }
/** * Overridden to enable hit handle detection a mouseEvent which triggered * a expand/collapse. */ @Override protected void processMouseEvent(MouseEvent e) { // BasicTableUI selects on released if the pressed had been // consumed. So we try to fish for the accompanying released // here and consume it as wll. if ((e.getID() == MouseEvent.MOUSE_RELEASED) && consumedOnPress) { consumedOnPress = false; e.consume(); return; } if (getTreeTableHacker().hitHandleDetectionFromProcessMouse(e)) { // Issue #332-swing: hacking around selection loss. // prevent the // _table_ selection by consuming the mouseEvent // if it resulted in a expand/collapse consumedOnPress = true; e.consume(); return; } consumedOnPress = false; super.processMouseEvent(e); }
/** * Overriden to invoke repaint for the particular location if * the column contains the tree. This is done as the tree editor does * not fill the bounds of the cell, we need the renderer to paint * the tree in the background, and then draw the editor over it. * You should not need to call this method directly. <p> * * Additionally, there is tricksery involved to expand/collapse * the nodes. * * {@inheritDoc} */ @Override public boolean editCellAt(int row, int column, EventObject e) { getTreeTableHacker().hitHandleDetectionFromEditCell(column, e); // RG: Fix Issue 49! boolean canEdit = super.editCellAt(row, column, e); if (canEdit && isHierarchical(column)) { repaint(getCellRect(row, column, false)); } return canEdit; }
/** * Overriden to invoke repaint for the particular location if * the column contains the tree. This is done as the tree editor does * not fill the bounds of the cell, we need the renderer to paint * the tree in the background, and then draw the editor over it. * You should not need to call this method directly. <p> * * Additionally, there is tricksery involved to expand/collapse * the nodes. * * {@inheritDoc} */ @Override public boolean editCellAt(int row, int column, EventObject e) { getTreeTableHacker().hitHandleDetectionFromEditCell(column, e); // RG: Fix Issue 49! boolean canEdit = super.editCellAt(row, column, e); if (canEdit && isHierarchical(column)) { repaint(getCellRect(row, column, false)); } return canEdit; }
/** * Overriden to invoke repaint for the particular location if * the column contains the tree. This is done as the tree editor does * not fill the bounds of the cell, we need the renderer to paint * the tree in the background, and then draw the editor over it. * You should not need to call this method directly. <p> * * Additionally, there is tricksery involved to expand/collapse * the nodes. * * {@inheritDoc} */ @Override public boolean editCellAt(int row, int column, EventObject e) { getTreeTableHacker().hitHandleDetectionFromEditCell(column, e); // RG: Fix Issue 49! boolean canEdit = super.editCellAt(row, column, e); if (canEdit && isHierarchical(column)) { repaint(getCellRect(row, column, false)); } return canEdit; }
/** * Overriden to invoke repaint for the particular location if * the column contains the tree. This is done as the tree editor does * not fill the bounds of the cell, we need the renderer to paint * the tree in the background, and then draw the editor over it. * You should not need to call this method directly. <p> * * Additionally, there is tricksery involved to expand/collapse * the nodes. * * {@inheritDoc} */ @Override public boolean editCellAt(int row, int column, EventObject e) { getTreeTableHacker().hitHandleDetectionFromEditCell(column, e); // RG: Fix Issue 49! boolean canEdit = super.editCellAt(row, column, e); if (canEdit && isHierarchical(column)) { repaint(getCellRect(row, column, false)); } return canEdit; }
/** * Overriden to invoke repaint for the particular location if * the column contains the tree. This is done as the tree editor does * not fill the bounds of the cell, we need the renderer to paint * the tree in the background, and then draw the editor over it. * You should not need to call this method directly. <p> * * Additionally, there is tricksery involved to expand/collapse * the nodes. * * {@inheritDoc} */ @Override public boolean editCellAt(int row, int column, EventObject e) { getTreeTableHacker().hitHandleDetectionFromEditCell(column, e); // RG: Fix Issue 49! boolean canEdit = super.editCellAt(row, column, e); if (canEdit && isHierarchical(column)) { repaint(getCellRect(row, column, false)); } return canEdit; }
/** * Entry point for hit handle detection called from processMouse. * Does nothing if isHitDetectionFromProcessMouse is false. * * @return true if the mouseEvent triggered an expand/collapse in * the renderer, false otherwise. * * @see #isHitDetectionFromProcessMouse() */ public boolean hitHandleDetectionFromProcessMouse(MouseEvent e) { if (!isHitDetectionFromProcessMouse()) return false; int col = columnAtPoint(e.getPoint()); return ((col >= 0) && expandOrCollapseNode(columnAtPoint(e .getPoint()), e)); }
/** * Entry point for hit handle detection called from processMouse. * Does nothing if isHitDetectionFromProcessMouse is false. * * @return true if the mouseEvent triggered an expand/collapse in * the renderer, false otherwise. * * @see #isHitDetectionFromProcessMouse() */ public boolean hitHandleDetectionFromProcessMouse(MouseEvent e) { if (!isHitDetectionFromProcessMouse()) return false; int col = columnAtPoint(e.getPoint()); return ((col >= 0) && expandOrCollapseNode(columnAtPoint(e .getPoint()), e)); }
/** * Entry point for hit handle detection called from processMouse. * Does nothing if isHitDetectionFromProcessMouse is false. * * @return true if the mouseEvent triggered an expand/collapse in * the renderer, false otherwise. * * @see #isHitDetectionFromProcessMouse() */ public boolean hitHandleDetectionFromProcessMouse(MouseEvent e) { if (!isHitDetectionFromProcessMouse()) return false; int col = columnAtPoint(e.getPoint()); return ((col >= 0) && expandOrCollapseNode(columnAtPoint(e .getPoint()), e)); }
/** * Entry point for hit handle detection called from processMouse. * Does nothing if isHitDetectionFromProcessMouse is false. * * @return true if the mouseEvent triggered an expand/collapse in * the renderer, false otherwise. * * @see #isHitDetectionFromProcessMouse() */ public boolean hitHandleDetectionFromProcessMouse(MouseEvent e) { if (!isHitDetectionFromProcessMouse()) return false; int col = columnAtPoint(e.getPoint()); return ((col >= 0) && expandOrCollapseNode(columnAtPoint(e .getPoint()), e)); }