Unnamed: 0 int64 0 305k | body stringlengths 7 52.9k | name stringlengths 1 185 |
|---|---|---|
44,900 | void () { super.fireSelectionChanged(); myLayeredPane.revalidate(); myLayeredPane.repaint(); } | fireSelectionChanged |
44,901 | void () { List<RadComponent> selection = getSelection(); if (selection.size() == 1) { Rectangle bounds = selection.get(0).getBounds(myLayeredPane); if (bounds != null) { myLayeredPane.scrollRectToVisible(bounds); } } } | scrollToSelection |
44,902 | RadComponent (int x, int y, @Nullable ComponentTargetFilter filter) { return DesignerEditorPanel.this.findTarget(x, y, filter); } | findTarget |
44,903 | InputTool (int x, int y) { return myDecorationLayer.findTargetTool(x, y); } | findTargetTool |
44,904 | void (boolean value) { myDecorationLayer.showSelection(value); } | showSelection |
44,905 | ComponentDecorator () { return DesignerEditorPanel.this.getRootSelectionDecorator(); } | getRootSelectionDecorator |
44,906 | FeedbackLayer () { return myFeedbackLayer; } | getFeedbackLayer |
44,907 | RadComponent () { return myRootComponent; } | getRootComponent |
44,908 | ActionGroup () { return myActionPanel.getPopupActions(this); } | getPopupActions |
44,909 | String () { return ActionPlaces.GUI_DESIGNER_EDITOR_POPUP; } | getPopupPlace |
44,910 | void () { setActiveTool(createDefaultTool()); } | loadDefaultTool |
44,911 | void (InputTool tool) { if (getActiveTool() instanceof CreationTool && !(tool instanceof CreationTool)) { getPaletteToolWindow().clearActiveItem(); } if (!(tool instanceof SelectionTool)) { hideInspections(); } super.setActiveTool(tool); } | setActiveTool |
44,912 | boolean (final ThrowableRunnable<Exception> operation, String command, final boolean updateProperties) { myLastExecuteCommand = command; final Ref<Boolean> result = Ref.create(Boolean.TRUE); CommandProcessor.getInstance().executeCommand(getProject(), () -> result.set(DesignerEditorPanel.this.execute(operation, updatePr... | execute |
44,913 | void (final ThrowableRunnable<Exception> operation, String command) { myLastExecuteCommand = command; CommandProcessor.getInstance().executeCommand(getProject(), () -> DesignerEditorPanel.this.executeWithReparse(operation), command, null); } | executeWithReparse |
44,914 | void (final List<EditOperation> operations, String command) { myLastExecuteCommand = command; CommandProcessor.getInstance().executeCommand(getProject(), () -> DesignerEditorPanel.this.execute(operations), command, null); } | execute |
44,915 | void (@Nullable InplaceContext inplaceContext) { myInplaceEditingLayer.startEditing(inplaceContext); } | startInplaceEditing |
44,916 | void () { myQuickFixManager.hideHint(); } | hideInspections |
44,917 | void (@Nls String message, Throwable e) { DesignerEditorPanel.this.showError(message, e); } | showError |
44,918 | boolean () { return DesignerEditorPanel.this.isZoomSupported(); } | isZoomSupported |
44,919 | void (@NotNull ZoomType type) { DesignerEditorPanel.this.zoom(type); } | zoom |
44,920 | void (double zoom) { DesignerEditorPanel.this.setZoom(zoom); } | setZoom |
44,921 | double () { return DesignerEditorPanel.this.getZoom(); } | getZoom |
44,922 | Dimension () { return getPreferredSize(); } | getMinimumSize |
44,923 | Dimension () { Rectangle bounds = myScrollPane.getViewport().getBounds(); Dimension size = getSceneSize(this); size.width = Math.max(size.width, bounds.width); size.height = Math.max(size.height, bounds.height); return size; } | getPreferredSize |
44,924 | Dimension () { return getPreferredSize(); } | getPreferredScrollableViewportSize |
44,925 | int (Rectangle visibleRect, int orientation, int direction) { return 10; } | getScrollableUnitIncrement |
44,926 | int (Rectangle visibleRect, int orientation, int direction) { if (orientation == SwingConstants.HORIZONTAL) { return visibleRect.width - 10; } return visibleRect.height - 10; } | getScrollableBlockIncrement |
44,927 | boolean () { return false; } | getScrollableTracksViewportWidth |
44,928 | boolean () { return false; } | getScrollableTracksViewportHeight |
44,929 | void (List<FixableMessageInfo> messages) { if (!myIsAdded) { myTitle = Integer.toString(messages.size()); setItems(messages, null); myActionGroup.add(this); myActionPanel.update(); myIsAdded = true; } } | show |
44,930 | void () { if (myIsAdded) { myActionGroup.remove(this); myActionPanel.update(); myIsAdded = false; } } | hide |
44,931 | DefaultActionGroup (@NotNull JComponent button, @NotNull DataContext context) { DefaultActionGroup actionGroup = new DefaultActionGroup(); for (final FixableMessageInfo message : myItems) { AnAction action; if ((message.myQuickFix != null && (message.myLinkText.length() > 0 || message.myAfterLinkText.length() > 0)) || ... | createPopupActionGroup |
44,932 | void (@NotNull AnActionEvent e) { defaultAction[0].actionPerformed(e); } | actionPerformed |
44,933 | void (@NotNull AnActionEvent e) { message.myQuickFix.run(); } | actionPerformed |
44,934 | void (@NotNull AnActionEvent e) { pair.second.run(); } | actionPerformed |
44,935 | void (FixableMessageInfo item, Presentation presentation, boolean popup) { if (popup) { presentation.setText(cleanText(item.myBeforeLinkText)); } else { presentation.setText(myTitle); } } | update |
44,936 | boolean (FixableMessageInfo item) { return false; } | selectionChanged |
44,937 | InputTool (DecorationLayer layer, RadComponent component, int x, int y) { return null; } | findTargetTool |
44,938 | void (DecorationLayer layer, Graphics2D host, RadComponent component) { } | decorate |
44,939 | void (DecorationLayer layer, Graphics2D g, RadComponent component) { } | paint |
44,940 | void (boolean selectBackground) { mySelectBackground = selectBackground; } | setSelectBackground |
44,941 | void (int button) { if (button == MouseEvent.BUTTON1 || button == MouseEvent.BUTTON2) { if (myState == STATE_INIT) { myState = STATE_DRAG; if (myInputEvent.isControlDown()) { mySelectionMode = TOGGLE_MODE; } else if (myInputEvent.isShiftDown()) { mySelectionMode = APPEND_MODE; } } } else { myState = STATE_INVALID; eras... | handleButtonDown |
44,942 | void (int button) { if (myState == STATE_DRAG_IN_PROGRESS) { myState = STATE_NONE; eraseFeedback(); performMarqueeSelect(); } else if (mySelectBackground) { performMarqueeSelect(); } } | handleButtonUp |
44,943 | void () { if (myState == STATE_DRAG) { myState = STATE_DRAG_IN_PROGRESS; refreshCursor(); } if (myState == STATE_DRAG_IN_PROGRESS) { showFeedback(); } } | handleDragInProgress |
44,944 | void () { if (myState == STATE_DRAG_IN_PROGRESS) { eraseFeedback(); } super.deactivate(); } | deactivate |
44,945 | Cursor () { if (myState == STATE_DRAG_IN_PROGRESS) { return getDefaultCursor(); } if (myState == STATE_INVALID) { return getDisabledCursor(); } return null; } | calculateCursor |
44,946 | void () { FeedbackLayer layer = myArea.getFeedbackLayer(); if (myFeedback == null) { myFeedback = new AlphaFeedback(myColor); layer.add(myFeedback); } myFeedback.setBounds(getSelectionRectangle()); if (ApplicationManager.getApplication().isInternal()) { Dimension size = myFeedback.getSize(); myArea.setDescription(Desig... | showFeedback |
44,947 | void () { if (myFeedback != null) { FeedbackLayer layer = myArea.getFeedbackLayer(); layer.remove(myFeedback); layer.repaint(); myFeedback = null; } } | eraseFeedback |
44,948 | Rectangle () { if (isAltOptionPressed()) { // Alt/Option: Center selection around starting point int deltaX = Math.abs(myStartScreenX - myCurrentScreenX); int deltaY = Math.abs(myStartScreenY - myCurrentScreenY); return new Rectangle(myStartScreenX - deltaX, myStartScreenY - deltaY, 2 * deltaX, 2 * deltaY); } // Select... | getSelectionRectangle |
44,949 | void () { final Rectangle selectionRectangle = getSelectionRectangle(); final List<RadComponent> newSelection = new ArrayList<>(); RadComponent rootComponent = myArea.getRootComponent(); if (rootComponent != null) { rootComponent.accept(new RadComponentVisitor() { @Override public void endVisit(RadComponent component) ... | performMarqueeSelect |
44,950 | void (RadComponent component) { if (selectionRectangle.contains(component.getBounds(myArea.getNativeComponent())) && !component.isBackground()) { newSelection.add(component); } } | endVisit |
44,951 | void (RadComponent component) { // Only select the bottom-most background if (newSelection.isEmpty() && component.getBounds(myArea.getNativeComponent()).contains(selectionRectangle.x, selectionRectangle.y) && component.isBackground()) { newSelection.add(component); } } | endVisit |
44,952 | void (int button) { if (myState == STATE_DRAG) { myState = STATE_NONE; eraseFeedback(); performSelection(); } else { super.handleButtonUp(button); } } | handleButtonUp |
44,953 | void () { if (mySelected || myArea.isTree()) { return; } mySelected = true; SelectionTracker.performSelection(this, myComponent); } | performSelection |
44,954 | void (int button) { if (button == MouseEvent.BUTTON1) { if (myState == STATE_INIT) { myState = STATE_DRAG; } } else { myState = STATE_INVALID; handleInvalidInput(); } } | handleButtonDown |
44,955 | void (int button) { if (myState == STATE_DRAG || myState == STATE_DRAG_IN_PROGRESS) { eraseFeedback(); executeCommand(); selectAddedObjects(); } myState = STATE_NONE; handleFinished(); } | handleButtonUp |
44,956 | void () { updateContext(); updateTargetUnderMouse(); showFeedback(); updateCommand(); } | handleMove |
44,957 | void () { if (myState == STATE_DRAG_IN_PROGRESS) { updateContext(); showFeedback(); updateCommand(); } } | handleDragInProgress |
44,958 | void () { if (myExecuteEnabled) { myArea.setSelection(myContext.getComponents()); } } | selectAddedObjects |
44,959 | void () { // hack: update cursor if (myCanUnload || myArea == null) { super.resetState(); } } | resetState |
44,960 | void () { if (myCanUnload) { myToolProvider.loadDefaultTool(); } else { deactivate(); activate(); // hack: update cursor if (myArea != null) { handleMove(); } } } | handleFinished |
44,961 | void () { ContainerTargetFilter filter = new ContainerTargetFilter(); RadComponent target = myArea.findTarget(myCurrentScreenX, myCurrentScreenY, filter); setTarget(target, filter); if (target != null) { updateTarget(); } } | updateTargetUnderMouse |
44,962 | void () { super.updateContext(); if (myState == STATE_DRAG_IN_PROGRESS) { myContext.setSizeDelta(new Dimension(moveDeltaWidth(), moveDeltaHeight())); } myContext.setLocation(getLocation()); } | updateContext |
44,963 | void () { } | handleKeyEvent |
44,964 | void () { myCanPastThreshold = false; resetState(); myState = STATE_INIT; myActive = true; } | activate |
44,965 | void () { myActive = false; setExecuteEnabled(false); } | deactivate |
44,966 | void () { myCurrentScreenX = 0; myCurrentScreenY = 0; myInputEvent = null; myButton = 0; myStartScreenX = 0; myStartScreenY = 0; } | resetState |
44,967 | void (ToolProvider provider) { myToolProvider = provider; } | setToolProvider |
44,968 | void (@Nullable EditableArea area) { if (myArea != area) { setCursor(null); myArea = area; if (myArea != null) { Point mouseLocation = MouseInfo.getPointerInfo().getLocation(); SwingUtilities.convertPointFromScreen(mouseLocation, myArea.getNativeComponent()); myCurrentScreenX = mouseLocation.x; myCurrentScreenY = mouse... | setArea |
44,969 | void (boolean enabled) { myExecuteEnabled = enabled; refreshCursor(); } | setExecuteEnabled |
44,970 | void (@Nullable Cursor cursor) { if (myArea != null) { myArea.setCursor(cursor); } } | setCursor |
44,971 | void () { if (myActive) { setCursor(calculateCursor()); } } | refreshCursor |
44,972 | Cursor () { if (myState == STATE_NONE) { return null; } return myExecuteEnabled ? getDefaultCursor() : getDisabledCursor(); } | calculateCursor |
44,973 | Cursor () { return myDefaultCursor; } | getDefaultCursor |
44,974 | void (@Nullable Cursor cursor) { if (myDefaultCursor != cursor) { myDefaultCursor = cursor; refreshCursor(); } } | setDefaultCursor |
44,975 | Cursor () { return myDisabledCursor == null ? getDefaultCursor() : myDisabledCursor; } | getDisabledCursor |
44,976 | void (@Nullable Cursor cursor) { if (myDisabledCursor != cursor) { myDisabledCursor = cursor; refreshCursor(); } } | setDisabledCursor |
44,977 | void (KeyEvent event) { myInputEvent = event; myModifiers = event.getModifiers(); } | setEvent |
44,978 | boolean () { return (myModifiers & InputEvent.SHIFT_MASK) != 0; } | isShiftPressed |
44,979 | boolean () { return (myModifiers & InputEvent.ALT_MASK) != 0; } | isAltOptionPressed |
44,980 | boolean () { return (myModifiers & (InputEvent.CTRL_MASK | InputEvent.META_DOWN_MASK)) != 0; } | isCtrlCmdPressed |
44,981 | void (MouseEvent event) { myCurrentScreenX = event.getX(); myCurrentScreenY = event.getY(); myModifiers = event.getModifiers(); myButton = event.getButton(); myInputEvent = event; myToolProvider.setEvent(event); } | setEvent |
44,982 | boolean () { if (!myCanPastThreshold) { myCanPastThreshold = Math.abs(moveDeltaWidth()) > DRAG_THRESHOLD || Math.abs(moveDeltaHeight()) > DRAG_THRESHOLD; } return myCanPastThreshold; } | movedPastThreshold |
44,983 | int () { return myCurrentScreenX - myStartScreenX; } | moveDeltaWidth |
44,984 | int () { return myCurrentScreenY - myStartScreenY; } | moveDeltaHeight |
44,985 | Point () { return new Point(myCurrentScreenX, myCurrentScreenY); } | getLocation |
44,986 | void (int button) { } | handleButtonDown |
44,987 | void (int button) { } | handleButtonUp |
44,988 | void () { } | handleMove |
44,989 | void () { } | handleDrag |
44,990 | void () { } | handleDragStarted |
44,991 | void () { } | handleDragInProgress |
44,992 | void () { } | handlePopup |
44,993 | void (int button) { } | handleDoubleClick |
44,994 | void () { } | handleAreaExited |
44,995 | ComponentCreationFactory () { return myFactory; } | getFactory |
44,996 | void () { super.activate(); myContext.setType(OperationContext.CREATE); try { myContext.setComponents(Collections.singletonList(myFactory.create())); } catch (Throwable e) { myToolProvider.loadDefaultTool(); } } | activate |
44,997 | void () { myTargetOperation.setComponent(myContext.getComponents().get(0)); } | updateTarget |
44,998 | void (KeyEvent event, EditableArea area) { if (myTool != null) { try { switch (event.getID()) { case KeyEvent.KEY_PRESSED -> myTool.keyPressed(event, area); case KeyEvent.KEY_TYPED -> myTool.keyTyped(event, area); case KeyEvent.KEY_RELEASED -> myTool.keyReleased(event, area); } } catch (Throwable e) { showError(Designe... | processKeyEvent |
44,999 | void (MouseEvent event, EditableArea area) { if (myTool != null) { try { switch (event.getID()) { case MouseEvent.MOUSE_PRESSED -> { myTool.mouseDown(event, area); if (event.isPopupTrigger()) { myTool.mousePopup(event, area); } } case MouseEvent.MOUSE_RELEASED -> { myTool.mouseUp(event, area); if (event.isPopupTrigger(... | processMouseEvent |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.