Unnamed: 0 int64 0 305k | body stringlengths 7 52.9k | name stringlengths 1 185 |
|---|---|---|
247,100 | int (JTree tree, TreePath path) { if (path == null || !isValid(tree)) return -1; return super.getRowForPath(tree, path); } | getRowForPath |
247,101 | int (JTree tree) { if (!isValid(tree)) return 0; return super.getRowCount(tree); } | getRowCount |
247,102 | TreePath (JTree tree, int x, int y) { return isValid(tree) ? super.getClosestPathForLocation(tree, x, y) : null; } | getClosestPathForLocation |
247,103 | boolean (JTree tree) { return isValid(tree) && super.isEditing(tree); } | isEditing |
247,104 | boolean (JTree tree) { return isValid(tree) && super.stopEditing(tree); } | stopEditing |
247,105 | void (JTree tree) { if (!isValid(tree)) { return; } super.cancelEditing(tree); } | cancelEditing |
247,106 | void (JTree tree, TreePath path) { if (path == null || !isValid(tree)) { return; } super.startEditingAtPath(tree, path); } | startEditingAtPath |
247,107 | TreePath (JTree tree) { if (!isValid(tree)) { return null; } return super.getEditingPath(tree); } | getEditingPath |
247,108 | Component (@NotNull JTree tree, @Nullable Object value, boolean selected, boolean expanded, boolean leaf, int row, boolean focused) { Component component = super.getTreeCellRendererComponent(tree, value, selected, expanded, leaf, row, focused); if (!selected) setForeground(COLOR); setIcon(ICON); return component; } | getTreeCellRendererComponent |
247,109 | int (@NotNull Control control, int depth, boolean leaf) { if (depth < 0) return -1; // do not paint row if (depth == 0) return 0; int controlWidth = control.getWidth(); int left = getLeftIndent(controlWidth / 2); int right = getRightIndent(); int offset = getLeafIndent(leaf); if (offset < 0) offset = Math.max(controlWi... | getRendererOffset |
247,110 | int (@NotNull Control control, int depth, boolean leaf) { if (depth <= 0 || leaf) return -1; // do not paint control int controlWidth = control.getWidth(); int left = getLeftIndent(controlWidth / 2); int offset = left - controlWidth / 2; return depth > 1 ? (depth - 1) * (left + getRightIndent()) + offset : offset; } | getControlOffset |
247,111 | void (@NotNull Component c, @NotNull Graphics g, int x, int y, int width, int height, @NotNull Control control, int depth, boolean leaf, boolean expanded, boolean selected) { if (depth <= 0) return; // do not paint boolean paintLines = getPaintLines(); if (!paintLines && leaf) return; // nothing to paint int controlWid... | paint |
247,112 | boolean (@Nullable Boolean paintLines) { if (paintLines != null) return paintLines; if (UIManager.getBoolean("Tree.paintLines")) return true; UISettings settings = UISettings.getInstanceOrNull(); return settings != null && settings.getShowTreeIndentGuides(); } | getPaintLines |
247,113 | boolean () { return getPaintLines(myPaintLines); } | getPaintLines |
247,114 | int (int min) { return Math.max(min, myLeftIndent != null ? JBUIScale.scale(myLeftIndent) : UIManager.getInt("Tree.leftChildIndent")); } | getLeftIndent |
247,115 | int () { int old = myRightIndent == null ? Registry.intValue("ide.ui.tree.indent", -1) : -1; if (old >= 0) return JBUIScale.scale(old); return Math.max(0, myRightIndent != null ? JBUIScale.scale(myRightIndent) : UIManager.getInt("Tree.rightChildIndent")); } | getRightIndent |
247,116 | int (boolean leaf) { return !leaf || myLeafIndent == null ? -1 : JBUIScale.scale(myLeafIndent); } | getLeafIndent |
247,117 | void (@NotNull Graphics g, int x, int y, int width, int height) { if (g instanceof Graphics2D g2d) { double dx = x + width / 2.0 - PaintUtil.devPixel(g2d); LinePainter2D.paint(g2d, dx, y, dx, y + height, LinePainter2D.StrokeType.CENTERED, 1, RenderingHints.VALUE_ANTIALIAS_ON); } else { x += width / 2; g.drawLine(x, y, ... | paintLine |
247,118 | void (ActionEvent event) { Object source = event.getSource(); if (source instanceof JTree) action.accept((JTree)source); } | actionPerformed |
247,119 | void (@NotNull ActionMap map) { Object[] keys = map.keys(); if (keys != null && keys.length != 0) return; // actions are already installed for (TreeAction action : ACTIONS) map.put(action.name, action); } | installTo |
247,120 | void (@NotNull InputMap map) { Object[] keys = map.keys(); if (keys != null && keys.length != 0) return; // keys for actions are already installed for (TreeAction action : ACTIONS) for (KeyStroke key : action.keys) map.put(key, action.name); } | installTo |
247,121 | boolean (@NotNull MoveType type) { return type != MoveType.ExtendSelection && TreeUtil.isCyclicScrollingAllowed(); } | isCycleScrollingAllowed |
247,122 | boolean (@NotNull JTree tree, @NotNull TreePath path) { return tree.getModel().isLeaf(path.getLastPathComponent()); // TODO:malenkov: via DefaultTreeUI } | isLeaf |
247,123 | void (@NotNull MoveType type, @NotNull JTree tree) { TreePath lead = tree.getLeadSelectionPath(); int row = tree.getRowForPath(lead); if (lead == null || row < 0) { selectFirstExceptSeparator(type, tree); } else { row = findRowExceptSeparator(tree, row, false); // NB!: increase row before checking for cycle scrolling i... | lineDown |
247,124 | void (@NotNull MoveType type, @NotNull JTree tree) { TreePath lead = tree.getLeadSelectionPath(); int row = tree.getRowForPath(lead); if (lead == null || row < 0) { selectFirstExceptSeparator(type, tree); } else { if (row == 0 && isCycleScrollingAllowed(type)) row = tree.getRowCount(); row = findRowExceptSeparator(tree... | lineUp |
247,125 | int (@NotNull JTree tree, int row, boolean up) { TreePath curPath; int curRow = row; do { if (up) { curRow--; } else { curRow++; } curPath = tree.getPathForRow(curRow); } while (curPath != null && DefaultTreeUI.isSeparator(curPath)); return curRow; } | findRowExceptSeparator |
247,126 | void (@NotNull MoveType type, @NotNull JTree tree) { TreePath lead = tree.getLeadSelectionPath(); Rectangle bounds = tree.getPathBounds(lead); if (lead == null || bounds == null) { selectLast(type, tree); } else { int height = Math.max(tree.getVisibleRect().height - bounds.height * 4, 1); TreePath next = tree.getCloses... | pageDown |
247,127 | void (@NotNull MoveType type, @NotNull JTree tree) { TreePath lead = tree.getLeadSelectionPath(); Rectangle bounds = tree.getPathBounds(lead); if (lead == null || bounds == null) { selectFirst(type, tree); } else { int height = Math.max(tree.getVisibleRect().height - bounds.height * 4, 1); TreePath next = tree.getClose... | pageUp |
247,128 | void (@NotNull MoveType type, @NotNull JTree tree, int row) { select(type, tree, tree.getPathForRow(row), row); } | select |
247,129 | void (@NotNull MoveType type, @NotNull JTree tree, @NotNull TreePath path) { select(type, tree, path, tree.getRowForPath(path)); } | select |
247,130 | void (@NotNull MoveType type, @NotNull JTree tree, @Nullable TreePath path, int row) { if (path == null || row < 0) return; if (type == MoveType.ExtendSelection) { TreePath anchor = tree.getAnchorSelectionPath(); int anchorRow = anchor == null ? -1 : tree.getRowForPath(anchor); if (anchorRow < 0) { tree.setSelectionPat... | select |
247,131 | void (@NotNull MoveType type, @NotNull JTree tree) { TreePath lead = tree.getLeadSelectionPath(); int row = tree.getRowForPath(lead); if (lead == null || row < 0) { selectFirst(type, tree); } else if (tree.isExpanded(lead) || isLeaf(tree, lead)) { TreePath path = tree.getPathForRow(row + 1); if (!TreeUtil.isLoadingPath... | selectChild |
247,132 | void (@NotNull MoveType type, @NotNull JTree tree) { select(type, tree, 0); } | selectFirst |
247,133 | void (@NotNull MoveType type, @NotNull JTree tree) { selectExceptSeparator(type, tree, 0); } | selectFirstExceptSeparator |
247,134 | void (@NotNull MoveType type, @NotNull JTree tree, int row) { TreePath path = tree.getPathForRow(row); if (!DefaultTreeUI.isSeparator(path)) { select(type, tree, path, row); } } | selectExceptSeparator |
247,135 | void (@NotNull MoveType type, @NotNull JTree tree) { select(type, tree, tree.getRowCount() - 1); } | selectLast |
247,136 | void (@NotNull MoveType type, @NotNull JTree tree, boolean canCollapse) { TreePath lead = tree.getLeadSelectionPath(); int row = tree.getRowForPath(lead); if (lead == null || row < 0) { selectFirst(type, tree); } else if (canCollapse && tree.isExpanded(lead)) { tree.collapsePath(lead); } else { TreePath parent = lead.g... | selectParent |
247,137 | void (@NotNull JTree tree) { TreePath sibling = TreeUtil.nextVisibleSibling(tree, tree.getLeadSelectionPath()); if (sibling == null) return; // next sibling is not found tree.setSelectionPath(sibling); TreeUtil.scrollToVisible(tree, sibling, false); } | selectNextSibling |
247,138 | void (@NotNull JTree tree) { TreePath sibling = TreeUtil.previousVisibleSibling(tree, tree.getLeadSelectionPath()); if (sibling == null) return; // previous sibling is not found tree.setSelectionPath(sibling); TreeUtil.scrollToVisible(tree, sibling, false); } | selectPreviousSibling |
247,139 | void (@NotNull JTree tree) { } | addToSelection |
247,140 | void (@NotNull JTree tree) { } | cancel |
247,141 | void (@NotNull JTree tree) { } | clearSelection |
247,142 | void (@NotNull JTree tree) { } | collapse |
247,143 | void (@NotNull JTree tree) { } | expand |
247,144 | void (@NotNull JTree tree) { } | extendTo |
247,145 | void (@NotNull JTree tree) { } | moveSelectionTo |
247,146 | void (@NotNull JTree tree) { } | moveSelectionToParent |
247,147 | void (@NotNull JTree tree) { pageDown(MoveType.ChangeLead, tree); } | scrollDownChangeLead |
247,148 | void (@NotNull JTree tree) { pageDown(MoveType.ChangeSelection, tree); } | scrollDownChangeSelection |
247,149 | void (@NotNull JTree tree) { pageDown(MoveType.ExtendSelection, tree); } | scrollDownExtendSelection |
247,150 | void (@NotNull JTree tree) { } | scrollLeft |
247,151 | void (@NotNull JTree tree) { } | scrollLeftChangeLead |
247,152 | void (@NotNull JTree tree) { } | scrollLeftExtendSelection |
247,153 | void (@NotNull JTree tree) { } | scrollRight |
247,154 | void (@NotNull JTree tree) { } | scrollRightChangeLead |
247,155 | void (@NotNull JTree tree) { } | scrollRightExtendSelection |
247,156 | void (@NotNull JTree tree) { pageUp(MoveType.ChangeLead, tree); } | scrollUpChangeLead |
247,157 | void (@NotNull JTree tree) { pageUp(MoveType.ChangeSelection, tree); } | scrollUpChangeSelection |
247,158 | void (@NotNull JTree tree) { pageUp(MoveType.ExtendSelection, tree); } | scrollUpExtendSelection |
247,159 | void (@NotNull JTree tree) { } | selectAll |
247,160 | void (@NotNull JTree tree) { selectChild(MoveType.ChangeSelection, tree); } | selectChild |
247,161 | void (@NotNull JTree tree) { selectChild(MoveType.ChangeLead, tree); } | selectChildChangeLead |
247,162 | void (@NotNull JTree tree) { selectChild(MoveType.ExtendSelection, tree); } | selectChildExtendSelection |
247,163 | void (@NotNull JTree tree) { selectFirst(MoveType.ChangeSelection, tree); } | selectFirst |
247,164 | void (@NotNull JTree tree) { selectFirst(MoveType.ChangeLead, tree); } | selectFirstChangeLead |
247,165 | void (@NotNull JTree tree) { selectFirst(MoveType.ExtendSelection, tree); } | selectFirstExtendSelection |
247,166 | void (@NotNull JTree tree) { selectLast(MoveType.ChangeSelection, tree); } | selectLast |
247,167 | void (@NotNull JTree tree) { selectLast(MoveType.ChangeLead, tree); } | selectLastChangeLead |
247,168 | void (@NotNull JTree tree) { selectLast(MoveType.ExtendSelection, tree); } | selectLastExtendSelection |
247,169 | void (@NotNull JTree tree) { lineDown(MoveType.ChangeSelection, tree); } | selectNext |
247,170 | void (@NotNull JTree tree) { lineDown(MoveType.ChangeLead, tree); } | selectNextChangeLead |
247,171 | void (@NotNull JTree tree) { lineDown(MoveType.ExtendSelection, tree); } | selectNextExtendSelection |
247,172 | void (@NotNull JTree tree) { selectParent(MoveType.ChangeSelection, tree, true); } | selectParent |
247,173 | void (@NotNull JTree tree) { selectParent(MoveType.ChangeSelection, tree, false); } | selectParentNoCollapse |
247,174 | void (@NotNull JTree tree) { selectParent(MoveType.ChangeLead, tree, false); } | selectParentChangeLead |
247,175 | void (@NotNull JTree tree) { selectParent(MoveType.ExtendSelection, tree, false); } | selectParentExtendSelection |
247,176 | void (@NotNull JTree tree) { lineUp(MoveType.ChangeSelection, tree); } | selectPrevious |
247,177 | void (@NotNull JTree tree) { lineUp(MoveType.ChangeLead, tree); } | selectPreviousChangeLead |
247,178 | void (@NotNull JTree tree) { lineUp(MoveType.ExtendSelection, tree); } | selectPreviousExtendSelection |
247,179 | void (@NotNull JTree tree) { } | startEditing |
247,180 | void (@NotNull JTree tree) { } | toggle |
247,181 | void (@NotNull JTree tree) { } | toggleAndAnchor |
247,182 | int (@NotNull Control control, int depth, boolean leaf) { if (depth < 0) return -1; // do not paint row if (depth == 0) return 0; int left = getLeftIndent(); int offset = getLeafIndent(leaf); if (offset < 0) offset = left + control.getWidth() + getRightIndent(); return depth > 1 ? (depth - 1) * (left + JBUIScale.scale(... | getRendererOffset |
247,183 | int (@NotNull Control control, int depth, boolean leaf) { if (depth <= 0 || leaf) return -1; // do not paint control int left = getLeftIndent(); return depth > 1 ? (depth - 1) * (left + JBUIScale.scale(2)) + left : left; } | getControlOffset |
247,184 | void (@NotNull Component c, @NotNull Graphics g, int x, int y, int width, int height, @NotNull Control control, int depth, boolean leaf, boolean expanded, boolean selected) { if (depth <= 0) return; // do not paint boolean paintLines = getPaintLines(); if (!paintLines && leaf) return; // nothing to paint int controlWid... | paint |
247,185 | boolean () { return ClassicPainter.getPaintLines(myPaintLines); } | getPaintLines |
247,186 | int () { return myLeftIndent == null ? 0 : Math.max(0, JBUIScale.scale(myLeftIndent)); } | getLeftIndent |
247,187 | int () { return myRightIndent == null ? 0 : Math.max(0, JBUIScale.scale(myRightIndent)); } | getRightIndent |
247,188 | int (boolean leaf) { return !leaf || myLeafIndent == null ? -1 : JBUIScale.scale(myLeafIndent); } | getLeafIndent |
247,189 | boolean (@Nullable TreeModel model) { return this.model == model; } | isActualModel |
247,190 | CancellablePromise<NodeContent> () { return compute(obsolescent -> getRootContent(obsolescent)); } | promiseRootContent |
247,191 | CancellablePromise<NodeStructure> (@NotNull Object node) { return compute(obsolescent -> getNodeStructure(obsolescent, node)); } | promiseNodeStructure |
247,192 | List<NodeContent> (@NotNull Obsolescent obsolescent, int count, @NotNull IntFunction<?> function) { if (count < 0) LOG.warn("illegal child count: " + count); if (count <= 0) return emptyList(); List<NodeContent> list = new ArrayList<>(count); for (int index = 0; index < count; index++) { checkCanceled(); if (obsolescen... | getChildren |
247,193 | String () { return model.toString(); } | toString |
247,194 | Object () { return userNode; } | getUserNode |
247,195 | LeafState () { return leafState; } | getLeafState |
247,196 | boolean (Object object) { return object == this || object instanceof NodeContent && hasUserNodeFrom((NodeContent)object); } | equals |
247,197 | int () { return hashCode; } | hashCode |
247,198 | NodeContent () { return content; } | getContent |
247,199 | List<NodeContent> () { return children; } | getChildren |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.