Unnamed: 0 int64 0 305k | body stringlengths 7 52.9k | name stringlengths 1 185 |
|---|---|---|
286,100 | Icon () { int index = getCurrentIndex(); return getFrames()[index].getIcon(); } | getUpdatedIcon |
286,101 | int () { long current = System.currentTimeMillis(); Frame frame = getFrames()[index]; if (frame.getDelay() <= (current - time)) updateFrameAt(current); return index; } | getCurrentIndex |
286,102 | void (@Nullable Component c) { if (c == null || requested.contains(c) || !canRefresh(c)) { return; } Frame frame = getFrames()[index]; int delay = frame.getDelay(); if (delay > 0) { requested.add(c); EdtScheduledExecutorService.getInstance().schedule(() -> { requested.remove(c); if (canRefresh(c)) { doRefresh(c); } }, delay, TimeUnit.MILLISECONDS); } else { doRefresh(c); } } | requestRefresh |
286,103 | void (Component c, Graphics g, int x, int y) { Icon icon = getUpdatedIcon(); if (EventQueue.isDispatchThread()) { CellRendererPane pane = ComponentUtil.getParentOfType(CellRendererPane.class, c); requestRefresh(pane == null ? c : getRendererOwner(pane.getParent())); } else if (LOG.isDebugEnabled()) { LOG.debug(new IllegalStateException("Unexpected thread " + Thread.currentThread().getName())); } icon.paintIcon(c, g, x, y); } | paintIcon |
286,104 | int () { return getUpdatedIcon().getIconWidth(); } | getIconWidth |
286,105 | int () { return getUpdatedIcon().getIconHeight(); } | getIconHeight |
286,106 | boolean (@NotNull Component component) { return component.isShowing(); } | canRefresh |
286,107 | void (@NotNull Component component) { Runnable delegate = component instanceof JComponent ? (Runnable)((JComponent)component).getClientProperty(REFRESH_DELEGATE) : null; if (delegate == null) { component.repaint(); } else { delegate.run(); } } | doRefresh |
286,108 | void (@NotNull DocumentEvent event) { fireUIChanged(); } | textChanged |
286,109 | void (@NotNull final com.intellij.openapi.editor.event.DocumentEvent e) { fireUIChanged(); } | documentChanged |
286,110 | void (TableModelEvent e) { fireUIChanged(); } | tableChanged |
286,111 | void (PropertyChangeEvent evt) { TableModel oldModel = (TableModel)evt.getOldValue(); if (oldModel != null) { oldModel.removeTableModelListener(myTableModelListener); } TableModel newModel = (TableModel)evt.getNewValue(); if (newModel != null) { newModel.addTableModelListener(myTableModelListener); } if (oldModel != null) { fireUIChanged(); } } | propertyChange |
286,112 | void (final ChangeEvent e) { fireUIChanged(); } | stateChanged |
286,113 | void (PropertyChangeEvent e) { if (e.getOldValue() != null && e.getNewValue() == null) fireUIChanged(); } | propertyChange |
286,114 | void (UserActivityListener listener) { myListeners.addListener(listener); } | addUserActivityListener |
286,115 | void (UserActivityListener listener, Disposable parentDisposable) { myListeners.addListener(listener, parentDisposable); } | addUserActivityListener |
286,116 | void (UserActivityListener listener) { myListeners.removeListener(listener); } | removeUserActivityListener |
286,117 | boolean (Object object) { if (Boolean.TRUE.equals(UIUtil.getClientProperty(object, DO_NOT_WATCH))) return true; return super.shouldBeIgnored(object); } | shouldBeIgnored |
286,118 | void () { myIsModified = true; myListeners.getMulticaster().stateChanged(); } | fireUIChanged |
286,119 | void (ItemEvent e) { fireUIChanged(); } | itemStateChanged |
286,120 | void (ListDataEvent e) { fireUIChanged(); } | intervalAdded |
286,121 | void (ListDataEvent e) { fireUIChanged(); } | intervalRemoved |
286,122 | void (ListDataEvent e) { fireUIChanged(); } | contentsChanged |
286,123 | void (ListSelectionEvent e) { fireUIChanged(); } | valueChanged |
286,124 | void (final TreeModelEvent e) { fireUIChanged(); } | treeNodesChanged |
286,125 | void (final TreeModelEvent e) { fireUIChanged(); } | treeNodesInserted |
286,126 | void (final TreeModelEvent e) { fireUIChanged(); } | treeNodesRemoved |
286,127 | void (final TreeModelEvent e) { fireUIChanged(); } | treeStructureChanged |
286,128 | boolean (Container container) { return !(container instanceof JTable); } | processChildren |
286,129 | void (final Component parentComponent) { if (parentComponent instanceof JTextComponent) { ((JTextComponent)parentComponent).getDocument().addDocumentListener(myDocumentListener); } else if (parentComponent instanceof EditorTextComponent) { ((EditorTextComponent)parentComponent).addDocumentListener(myIdeaDocumentListener); } else if (parentComponent instanceof ItemSelectable) { ((ItemSelectable)parentComponent).addItemListener(myItemListener); } else if (parentComponent instanceof JList) { ((JList)parentComponent).getModel().addListDataListener(myListDataListener); if (trackListSelection()) ((JList<?>)parentComponent).addListSelectionListener(myListSelectionListener); } else if (parentComponent instanceof JTree) { ((JTree)parentComponent).getModel().addTreeModelListener(myTreeModelListener); } if (parentComponent instanceof JComboBox) { ComboBoxEditor editor = ((JComboBox<?>)parentComponent).getEditor(); if (editor != null) { register(editor.getEditorComponent()); } } if (parentComponent instanceof JTable table) { table.addPropertyChangeListener("model", myTableListener); TableModel model = table.getModel(); if (model != null) { model.addTableModelListener(myTableModelListener); } table.addPropertyChangeListener(TABLE_CELL_EDITOR_PROPERTY, myCellEditorChangeListener); } if (parentComponent instanceof JSlider) { ((JSlider)parentComponent).addChangeListener(myChangeListener); } UserActivityProviderComponent provider = getActivityProviderComponent(parentComponent); if (provider != null) { provider.addChangeListener(myChangeListener); } } | processComponent |
286,130 | boolean () { return true; } | trackListSelection |
286,131 | void (final Component component) { if (component instanceof JTextComponent) { ((JTextComponent)component).getDocument().removeDocumentListener(myDocumentListener); } else if (component instanceof EditorTextComponent) { ((EditorTextComponent)component).removeDocumentListener(myIdeaDocumentListener); } else if (component instanceof ItemSelectable) { ((ItemSelectable)component).removeItemListener(myItemListener); } else if (component instanceof JTree) { ((JTree)component).getModel().removeTreeModelListener(myTreeModelListener); } if (component instanceof JTable) { component.removePropertyChangeListener(myTableListener); TableModel model = ((JTable)component).getModel(); if (model != null) { model.removeTableModelListener(myTableModelListener); } component.removePropertyChangeListener(myCellEditorChangeListener); } if (component instanceof JSlider){ ((JSlider)component).removeChangeListener(myChangeListener); } UserActivityProviderComponent provider = getActivityProviderComponent(component); if (provider != null) { provider.removeChangeListener(myChangeListener); } } | unprocessComponent |
286,132 | UserActivityProviderComponent (Component component) { return component instanceof UserActivityProviderComponent ? (UserActivityProviderComponent)component : UIUtil.getClientProperty(component, UserActivityProviderComponent.class); } | getActivityProviderComponent |
286,133 | boolean () { return myIsModified; } | isModified |
286,134 | void () { myIsModified = false; } | commit |
286,135 | void (@NotNull ChangeListener changeListener) { myDispatcher.addListener(changeListener); } | addChangeListener |
286,136 | void (@NotNull ChangeListener changeListener) { myDispatcher.removeListener(changeListener); } | removeChangeListener |
286,137 | void (ChangeEvent e) { myDispatcher.getMulticaster().stateChanged(e); } | stateChanged |
286,138 | void (Object source) { stateChanged(new ChangeEvent(source)); } | stateChanged |
286,139 | UserActivityProvider (JComponent component) { UserActivityProvider provider = new UserActivityProvider(); component.putClientProperty(UserActivityProviderComponent.class, provider); return provider; } | create |
286,140 | void (ContainerEvent e) { register(e.getChild()); } | componentAdded |
286,141 | void (ContainerEvent e) { unregister(e.getChild()); } | componentRemoved |
286,142 | boolean (Object object) { if (object instanceof CellRendererPane) return true; if (object == null) { return true; } for (Class aClass : myControlsToIgnore) { if (ReflectionUtil.isAssignable(aClass, object.getClass())) { return true; } } return false; } | shouldBeIgnored |
286,143 | void (Component parentComponent) { if (shouldBeIgnored(parentComponent)) { return; } if (parentComponent instanceof Container container && processChildren((Container)parentComponent)) { for (int i = 0; i < container.getComponentCount(); i++) { register(container.getComponent(i)); } container.addContainerListener(myContainerListener); } processComponent(parentComponent); } | register |
286,144 | boolean (Container container) { return true; } | processChildren |
286,145 | void (Component component) { if (component instanceof Container container && processChildren((Container)component)) { for (int i = 0; i < container.getComponentCount(); i++) { unregister(container.getComponent(i)); } container.removeContainerListener(myContainerListener); } unprocessComponent(component); } | unregister |
286,146 | Content () { return myContent; } | getContent |
286,147 | int () { return myIndex; } | getIndex |
286,148 | boolean () { return myConsumed; } | isConsumed |
286,149 | void () { myConsumed = true; } | consume |
286,150 | ContentOperation () { return myOperation; } | getOperation |
286,151 | Icon () { return myIcon; } | getIcon |
286,152 | int () { return myVShift; } | getVShift |
286,153 | int () { return myHShift; } | getHShift |
286,154 | void (final Component c, final Graphics g, final int x, final int y) { myIcon.paintIcon(c, g, x + myHShift, y + myVShift); } | paintIcon |
286,155 | int () { return myIcon.getIconWidth(); } | getIconWidth |
286,156 | int () { return myIcon.getIconHeight(); } | getIconHeight |
286,157 | Icon () { return myIcon; } | retrieveIcon |
286,158 | AlertIcon (@NotNull IconReplacer replacer) { return new AlertIcon(replacer.replaceIcon(myIcon), myVShift, myHShift); } | replaceBy |
286,159 | ContentFactory () { return ApplicationManager.getApplication().getService(ContentFactory.class); } | getInstance |
286,160 | ContentFactory () { return ContentFactory.getInstance(); } | getInstance |
286,161 | MacMessages () { return INSTANCE; } | getInstance |
286,162 | int (@NotNull String title, String message, String @NotNull [] buttons, boolean errorStyle, @Nullable Window window, int defaultOptionIndex, int focusedOptionIndex, @Nullable DoNotAskOption doNotAskDialogOption) { Icon icon = errorStyle ? UIUtil.getErrorIcon() : UIUtil.getInformationIcon(); return MessagesService.getInstance().showMessageDialog( null, window, message, title, buttons, defaultOptionIndex, focusedOptionIndex, icon, doNotAskDialogOption, false, null); } | showMessageDialog |
286,163 | void (@NotNull String title, String message, @NotNull String okText, @Nullable Window window) { MessagesService.getInstance().showMessageDialog( null, window, message, title, new String[]{okText}, 0, -1, UIUtil.getInformationIcon(), null, false, null); } | showOkMessageDialog |
286,164 | void (@NotNull String title, String message, @NotNull String okButton, @Nullable Window window) { MessagesService.getInstance().showMessageDialog( null, window, message, title, new String[]{okButton}, 0, -1, UIUtil.getErrorIcon(), null, false, null); } | showErrorDialog |
286,165 | String () { return myDisplayName; } | getDisplayName |
286,166 | NotificationsManager () { return ApplicationManager.getApplication().getService(NotificationsManager.class); } | getNotificationsManager |
286,167 | void (@NotNull Notification notification, @NotNull HyperlinkEvent event) { if (event.getEventType() == HyperlinkEvent.EventType.ACTIVATED) { hyperlinkActivated(notification, event); } } | hyperlinkUpdate |
286,168 | void (@NotNull Notification notification, @NotNull HyperlinkEvent event) { URL url = event.getURL(); if (url != null) { IdeUiService.getInstance().browse(url); } else { IdeUiService.getInstance().browse(event.getDescription()); } if (myExpireNotification) { notification.expire(); } } | hyperlinkActivated |
286,169 | void (@NotNull AnActionEvent e) { actionPerformed(e, Notification.get(e)); } | actionPerformed |
286,170 | NotificationAction (@NotNull @NotificationContent String text, @NotNull BiConsumer<? super AnActionEvent, ? super Notification> action) { return new Simple(text, action, false, action); } | create |
286,171 | NotificationAction (@NotNull Supplier<@NotificationContent String> dynamicText, @NotNull BiConsumer<? super AnActionEvent, ? super Notification> action) { return new Simple(dynamicText, action, false, action); } | create |
286,172 | NotificationAction (@NotNull @NotificationContent String text, @NotNull BiConsumer<? super AnActionEvent, ? super Notification> action) { return new Simple(text, action, true, action); } | createExpiring |
286,173 | NotificationAction (@NotNull @NotificationContent String text, @NotNull Runnable action) { return new Simple(text, (event, notification) -> action.run(), false, action); } | createSimple |
286,174 | NotificationAction (@NotNull Supplier<@NotificationContent String> dynamicText, @NotNull Runnable action) { return new Simple(dynamicText, (event, notification) -> action.run(), false, action); } | createSimple |
286,175 | NotificationAction (@NotNull @NotificationContent String text, @NotNull Runnable action) { return new Simple(text, (event, notification) -> action.run(), true, action); } | createSimpleExpiring |
286,176 | void (@NotNull AnActionEvent e, @NotNull Notification notification) { if (myExpire) { notification.expire(); } myAction.accept(e, notification); } | actionPerformed |
286,177 | Object () { return myActionInstance; } | getDelegate |
286,178 | void (@NotNull String groupId, @NotNull NotificationDisplayType defaultDisplayType) { if (ApplicationManager.getApplication().isUnitTestMode()) return; SwingUtilities.invokeLater(() -> { Application app = ApplicationManager.getApplication(); if (!app.isDisposed()) { app.getMessageBus().syncPublisher(TOPIC).register(groupId, defaultDisplayType); } }); } | register |
286,179 | void (@NotNull Notification notification) { notify(notification, null); } | notify |
286,180 | void (@NotNull Notification notification, @Nullable Project project) { notification.assertHasTitleOrContent(); Application app = ApplicationManager.getApplication(); if (app.isUnitTestMode() || app.isDispatchThread()) { doNotify(notification, project); } else if (project == null) { app.invokeLater(() -> doNotify(notification, null)); } else { app.invokeLater(() -> doNotify(notification, project), project.getDisposed()); } } | notify |
286,181 | void (Notification notification, @Nullable Project project) { if (project != null && !project.isDisposed() && !project.isDefault()) { project.getMessageBus().syncPublisher(TOPIC).notify(notification); Disposable notificationDisposable = () -> notification.expire(); Disposer.register(project, notificationDisposable); notification.whenExpired(() -> Disposer.dispose(notificationDisposable)); } else { Application app = ApplicationManager.getApplication(); if (!app.isDisposed()) { app.getMessageBus().syncPublisher(TOPIC).notify(notification); } } } | doNotify |
286,182 | void (@NotNull Notification notification, @Nullable Project project) { notify(notification); AppExecutorUtil.getAppScheduledExecutorService().schedule(() -> notification.expire(), 5, TimeUnit.SECONDS); } | notifyAndHide |
286,183 | NotificationGroupManager () { return ApplicationManager.getApplication().getService(NotificationGroupManager.class); } | getInstance |
286,184 | void (@NotNull AnActionEvent e, @NotNull Notification notification) { IdeUiService.getInstance().browse(myUrl); } | actionPerformed |
286,185 | NotificationsConfiguration () { return ApplicationManager.getApplication().getService(NotificationsConfiguration.class); } | getNotificationsConfiguration |
286,186 | boolean () { return mySuggestionType; } | isSuggestionType |
286,187 | Notification (boolean suggestionType) { mySuggestionType = suggestionType; return this; } | setSuggestionType |
286,188 | boolean () { return myImportantSuggestion; } | isImportantSuggestion |
286,189 | Notification (boolean importantSuggestion) { myImportantSuggestion = importantSuggestion; return this; } | setImportantSuggestion |
286,190 | long () { return myTimestamp; } | getTimestamp |
286,191 | Notification (@NotNull String displayId) { myDisplayId = displayId; return this; } | setDisplayId |
286,192 | Notification (@Nullable Icon icon) { myIcon = icon; return this; } | setIcon |
286,193 | String () { return myGroupId; } | getGroupId |
286,194 | void (@NotNull String id, @NotNull @Nls String displayName) { myDoNotAskId = id; myDoNotAskDisplayName = displayName; } | configureDoNotAskOption |
286,195 | boolean (@Nullable Project project) { if (myDoNotAskId == null) { @NlsSafe String title = NotificationGroup.getGroupTitle(myGroupId); if (title == null) { title = myGroupId; } myDoNotAskDisplayName = title; myDoNotAskId = myGroupId; } String id = "Notification.DoNotAsk-" + myDoNotAskId; boolean doNotAsk = PropertiesComponent.getInstance().getBoolean(id, false); if (doNotAsk) { return false; } if (project != null) { return !PropertiesComponent.getInstance(project).getBoolean(id, false); } return true; } | canShowFor |
286,196 | Notification (@Nullable Project project) { PropertiesComponent manager = project == null ? PropertiesComponent.getInstance() : PropertiesComponent.getInstance(project); manager.setValue("Notification.DoNotAsk-" + myDoNotAskId, true); manager.setValue("Notification.DisplayName-DoNotAsk-" + myDoNotAskId, myDoNotAskDisplayName); return this; } | setDoNotAskFor |
286,197 | void (boolean isShowingPopupSuppressed) { myIsShowingPopupSuppressed = isShowingPopupSuppressed; } | setSuppressShowingPopup |
286,198 | boolean () { return myIsShowingPopupSuppressed; } | isShowingPopupSuppressed |
286,199 | Notification (@NotNull String remindLaterHandlerId) { myRemindLaterHandlerId = remindLaterHandlerId; return this; } | setRemindLaterHandlerId |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.