Java Code Examples for java.awt.Container#invalidate()
The following examples show how to use
java.awt.Container#invalidate() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: MemorySamplerViewSupport.java From visualvm with GNU General Public License v2.0 | 6 votes |
private void activateSearch() { JComponent panel = getBottomPanel(); if (searchPanel == null) { searchPanel = SearchUtils.createSearchPanel(table); panel.add(searchPanel); Container parent = panel.getParent(); parent.invalidate(); parent.revalidate(); parent.repaint(); } panel.setVisible(true); searchPanel.setVisible(true); searchPanel.requestFocusInWindow(); }
Example 2
Source File: ThreadsCPUView.java From visualvm with GNU General Public License v2.0 | 6 votes |
private void activateFilter() { JComponent panel = getBottomPanel(); if (filterPanel == null) { filterPanel = FilterUtils.createFilterPanel(table, null); panel.add(filterPanel); Container parent = panel.getParent(); parent.invalidate(); parent.revalidate(); parent.repaint(); } panel.setVisible(true); filterPanel.setVisible(true); filterPanel.requestFocusInWindow(); }
Example 3
Source File: MemoryView.java From visualvm with GNU General Public License v2.0 | 6 votes |
private void activateSearch() { JComponent panel = getBottomPanel(); if (searchPanel == null) { searchPanel = SearchUtils.createSearchPanel(table); panel.add(searchPanel); Container parent = panel.getParent(); parent.invalidate(); parent.revalidate(); parent.repaint(); } panel.setVisible(true); searchPanel.setVisible(true); searchPanel.requestFocusInWindow(); }
Example 4
Source File: ThreadsCPUView.java From visualvm with GNU General Public License v2.0 | 6 votes |
private void activateSearch() { JComponent panel = getBottomPanel(); if (searchPanel == null) { searchPanel = SearchUtils.createSearchPanel(table); panel.add(searchPanel); Container parent = panel.getParent(); parent.invalidate(); parent.revalidate(); parent.repaint(); } panel.setVisible(true); searchPanel.setVisible(true); searchPanel.requestFocusInWindow(); }
Example 5
Source File: ThreadsMemoryView.java From visualvm with GNU General Public License v2.0 | 6 votes |
private void activateSearch() { JComponent panel = getBottomPanel(); if (searchPanel == null) { searchPanel = SearchUtils.createSearchPanel(table); panel.add(searchPanel); Container parent = panel.getParent(); parent.invalidate(); parent.revalidate(); parent.repaint(); } panel.setVisible(true); searchPanel.setVisible(true); searchPanel.requestFocusInWindow(); }
Example 6
Source File: ThreadsMemoryView.java From visualvm with GNU General Public License v2.0 | 6 votes |
private void activateFilter() { JComponent panel = getBottomPanel(); if (filterPanel == null) { filterPanel = FilterUtils.createFilterPanel(table, null); panel.add(filterPanel); Container parent = panel.getParent(); parent.invalidate(); parent.revalidate(); parent.repaint(); } panel.setVisible(true); filterPanel.setVisible(true); filterPanel.requestFocusInWindow(); }
Example 7
Source File: DataView.java From visualvm with GNU General Public License v2.0 | 6 votes |
public void activateSearch() { JComponent panel = getBottomPanel(); if (searchPanel == null) { SearchUtils.TreeHelper searchHelper = getSearchHelper(); if (searchHelper == null) searchPanel = SearchUtils.createSearchPanel(getResultsComponent(), getSearchOptions()); else searchPanel = SearchUtils.createSearchPanel((ProfilerTreeTable)getResultsComponent(), searchHelper, getSearchOptions()); panel.add(searchPanel); Container parent = panel.getParent(); parent.invalidate(); parent.revalidate(); parent.repaint(); } panel.setVisible(true); searchPanel.setVisible(true); searchPanel.requestFocusInWindow(); }
Example 8
Source File: DataView.java From visualvm with GNU General Public License v2.0 | 6 votes |
public void activateFilter() { JComponent panel = getBottomPanel(); if (filterPanel == null) { filterPanel = FilterUtils.createFilterPanel(getResultsComponent(), getExcludesFilter(), getFilterOptions()); panel.add(filterPanel); Container parent = panel.getParent(); parent.invalidate(); parent.revalidate(); parent.repaint(); } panel.setVisible(true); filterPanel.setVisible(true); filterPanel.requestFocusInWindow(); }
Example 9
Source File: TruffleSummaryView.java From visualvm with GNU General Public License v2.0 | 6 votes |
void setRealModel(TableModel model) { if (table == null) { BorderLayout bl = (BorderLayout)getLayout(); Component c = bl.getLayoutComponent(BorderLayout.CENTER); if (c != null) remove(c); table = createTable(model); add(table, BorderLayout.CENTER); Container parent = getParent(); if (parent != null) { parent.invalidate(); parent.revalidate(); parent.repaint(); } } else { table.setModel(model); } setupTable(table); enableTableEvents(table); link.setEnabled(true); }
Example 10
Source File: JCollapsiblePane.java From CodenameOne with GNU General Public License v2.0 | 6 votes |
void validate() { Container parent = SwingUtilities.getAncestorOfClass( JCollapsiblePaneContainer.class, JCollapsiblePane.this); if (parent != null) { parent = ((JCollapsiblePaneContainer)parent).getValidatingContainer(); } else { parent = getParent(); } if (parent != null) { if (parent instanceof JComponent) { ((JComponent)parent).revalidate(); } else { parent.invalidate(); } parent.doLayout(); parent.repaint(); } }
Example 11
Source File: JCollapsiblePane.java From orbit-image-analysis with GNU General Public License v3.0 | 6 votes |
void validate() { Container parent = SwingUtilities.getAncestorOfClass( JCollapsiblePaneContainer.class, JCollapsiblePane.this); if (parent != null) { parent = ((JCollapsiblePaneContainer)parent).getValidatingContainer(); } else { parent = getParent(); } if (parent != null) { if (parent instanceof JComponent) { ((JComponent)parent).revalidate(); } else { parent.invalidate(); } parent.doLayout(); parent.repaint(); } }
Example 12
Source File: GraphViewer.java From org.alloytools.alloy with Apache License 2.0 | 6 votes |
/** Repaint this component. */ public void alloyRepaint() { Container c = getParent(); while (c != null) { if (c instanceof JViewport) break; else c = c.getParent(); } setSize((int) (graph.getTotalWidth() * scale), (int) (graph.getTotalHeight() * scale)); if (c != null) { c.invalidate(); c.repaint(); c.validate(); } else { invalidate(); repaint(); validate(); } }
Example 13
Source File: DataView.java From netbeans with Apache License 2.0 | 6 votes |
public void activateSearch() { JComponent panel = getBottomPanel(); if (searchPanel == null) { SearchUtils.TreeHelper searchHelper = getSearchHelper(); if (searchHelper == null) searchPanel = SearchUtils.createSearchPanel(getResultsComponent(), getSearchOptions()); else searchPanel = SearchUtils.createSearchPanel((ProfilerTreeTable)getResultsComponent(), searchHelper, getSearchOptions()); panel.add(searchPanel); Container parent = panel.getParent(); parent.invalidate(); parent.revalidate(); parent.repaint(); } panel.setVisible(true); searchPanel.setVisible(true); searchPanel.requestFocusInWindow(); }
Example 14
Source File: DataView.java From netbeans with Apache License 2.0 | 6 votes |
public void activateFilter() { JComponent panel = getBottomPanel(); if (filterPanel == null) { filterPanel = FilterUtils.createFilterPanel(getResultsComponent(), getExcludesFilter(), getFilterOptions()); panel.add(filterPanel); Container parent = panel.getParent(); parent.invalidate(); parent.revalidate(); parent.repaint(); } panel.setVisible(true); filterPanel.setVisible(true); filterPanel.requestFocusInWindow(); }
Example 15
Source File: MemoryView.java From visualvm with GNU General Public License v2.0 | 6 votes |
private void activateFilter() { JComponent panel = getBottomPanel(); if (filterPanel == null) { filterPanel = FilterUtils.createFilterPanel(table, null); panel.add(filterPanel); Container parent = panel.getParent(); parent.invalidate(); parent.revalidate(); parent.repaint(); } panel.setVisible(true); filterPanel.setVisible(true); filterPanel.requestFocusInWindow(); }
Example 16
Source File: FormLayout.java From LGoodDatePicker with MIT License | 5 votes |
private static void invalidateAndRepaint(Container container) { if (container == null) { return; } if (container instanceof JComponent) { ((JComponent) container).revalidate(); } else { container.invalidate(); } container.repaint(); }
Example 17
Source File: GroupChatInvitationUI.java From Spark with Apache License 2.0 | 5 votes |
/** * Removes this interface from it's parent. */ private void removeUI() { final Container par = getParent(); if (par != null) { par.remove(this); par.invalidate(); par.validate(); par.repaint(); } }
Example 18
Source File: GridUtils.java From netbeans with Apache License 2.0 | 5 votes |
/** * Forces revalidation of the grid managed by the specified manager. * * @param manager manager of the grid that we want to revalidate. */ public static void revalidateGrid(GridManager manager) { Container cont = manager.getContainer(); Container parent = cont.getParent(); parent.invalidate(); parent.doLayout(); cont.invalidate(); cont.doLayout(); }
Example 19
Source File: HierarchicalControllerTopComponent.java From constellation with Apache License 2.0 | 5 votes |
private static void revalidateParents(Container container) { while (container != null) { container.invalidate(); container.validate(); container.repaint(); container = container.getParent(); } }
Example 20
Source File: InspectorRowPanel.java From pumpernickel with MIT License | 4 votes |
private void invalidateInspectorParent() { Container parent = getParent(); if (parent != null) parent.invalidate(); }