private void displayResult(JComponent tableView) { resultTreePanel.invalidate(); resultTreePanel.removeAll(); resultTreePanel.add(new JBScrollPane(tableView)); resultTreePanel.validate(); }
void initCombo(final ComboBox combobox, final JPanel parentPanel) { combobox.setModel(new DefaultComboBoxModel<>(JsonDataType.values())); combobox.setRenderer(new ColoredListCellRenderer() { @Override protected void customizeCellRenderer(JList jList, Object o, int i, boolean b, boolean b2) { append(((JsonDataType) o).type); } }); combobox.setSelectedItem(null); combobox.addItemListener(itemEvent -> { JsonDataType selectedType = (JsonDataType) combobox.getSelectedItem(); currentEditor = UI_COMPONENT_BY_JSON_DATATYPE.get(selectedType); currentEditor.reset(); parentPanel.invalidate(); parentPanel.removeAll(); parentPanel.add(currentEditor.getComponent(), BorderLayout.CENTER); parentPanel.validate(); }); combobox.setSelectedItem(JsonDataType.STRING); }
@Override public void run(@NotNull ProgressIndicator indicator) { try { UIUtil.invokeLaterIfNeeded(() -> loadingDecorator.startLoading(false)); final MongoQueryOptions queryOptions = wayPoint.getQueryOptions(); if (!useCachedResults) { currentResults = mongoManager.findMongoDocuments( configuration, wayPoint.getCollection(), queryOptions); } UIUtil.invokeLaterIfNeeded(() -> { resultPanel.updateResultView(currentResults, pagination); rowCountLabel.setText(String.format("%s documents", currentResults.getDocuments().size())); initActions(resultPanel.resultTreeTableView); }); } catch (final Exception ex) { UIUtil.invokeLaterIfNeeded(() -> { errorPanel.invalidate(); errorPanel.removeAll(); errorPanel.add(new ErrorPanel(ex), BorderLayout.CENTER); errorPanel.validate(); errorPanel.setVisible(true); }); } finally { UIUtil.invokeLaterIfNeeded(loadingDecorator::stopLoading); } } });
/** * Triggers a full repaint, since the component is not valid anymore (size * change, iconized, ...) */ public void invalidate() { super.invalidate(); repaint = true; }
public void actionPerformed(ActionEvent e) { map.invalidate(); map.repaint(); } });
public void updateAddData() { saveBagAsExecutor.setEnabled(true); bagButtonPanel.invalidate(); topButtonPanel.invalidate(); }
public void addCommandBar(JComponent component) { component.setBorder(new BasicBorders.MenuBarBorder(Color.GRAY, Color.GRAY)); component.setAlignmentX(Component.BOTTOM_ALIGNMENT); commandBarPanel.add(component); commandBarPanel.invalidate(); }
/** End of initial startup. */ public synchronized void endInit() { if (win == null) return; progressText.setText("Starting framework..."); progressBar.setMinimum(0); progressBar.setMaximum(10050); progressBar.setValue(50); bottom.invalidate(); }
private void refreshGraphPreview() { parent.getGraphPanelChart().invalidateCache(); jPanelGraphPreview.invalidate(); jPanelGraphPreview.repaint(); }
public void refreshPreview() { parent.getGraphObject().invalidateCache(); jPanelGraphPreview.invalidate(); jPanelGraphPreview.repaint(); }
private void refreshGraphPreview() { parent.getGraphPanelChart().invalidateCache(); jPanelGraphPreview.invalidate(); jPanelGraphPreview.repaint(); }
@Override public void invalidate() { if ((getInvokeCondition() & INVOKE_ON_VALIDATE) != 0) { initialize(); } super.invalidate(); }
@Override public void invalidate() { super.invalidate(); if (!optionsGrid.isLoaded()) { optionsGrid.reload(); } }
@Override public void invalidate() { super.invalidate(); if (!grid.isLoaded()) { grid.reload(); } }
private void initializeReportView() { JPanel basePanel = m_svgView.getBasePanel(); if ( basePanel.getComponentCount() > 0) { if ( basePanel.getComponent(0) == m_panel) { return; } else { basePanel.removeAll(); } } basePanel.add( m_panel, BorderLayout.CENTER); basePanel.invalidate(); }
private void outputToggleActionPerformed(java.awt.event.ActionEvent evt) {//GEN-FIRST:event_outputToggleActionPerformed if (outputToggle.isSelected()) { detailsPanel.add(detailsScrollPane, java.awt.BorderLayout.CENTER); } else { detailsPanel.remove(detailsScrollPane); } detailsPanel.invalidate(); invalidate(); revalidate(); validate(); repaint(); }//GEN-LAST:event_outputToggleActionPerformed
@Override public void run() { progress.setVisible(false); outlineView.setVisible(true); progress.invalidate(); outlineView.invalidate(); validate(); }
/** * Redo the layout. */ public void relayout () { mMainPanel.invalidate (); mMainScroller.invalidate (); mMainScroller.validate (); mMainScroller.repaint (); }
private void revalidateDetailsPanel() { detailsPanel.invalidate(); repaint(); if (detailsPanel.getParent() != null) { detailsPanel.getParent().validate(); } else { detailsPanel.validate(); } }
private void revalidateDetailsPanel() { detailsPanel.invalidate(); repaint(); if (detailsPanel.getParent() != null) { detailsPanel.getParent().validate(); } else { detailsPanel.validate(); } }