Java Code Examples for org.openide.windows.TopComponent#revalidate()
The following examples show how to use
org.openide.windows.TopComponent#revalidate() .
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: SplitAction.java From netbeans with Apache License 2.0 | 5 votes |
static void splitWindow(TopComponent tc, int orientation, int splitLocation) { if (tc instanceof Splitable) { TopComponent split = ((Splitable) tc).splitComponent(orientation, splitLocation); split.open(); split.requestActive(); split.invalidate(); split.revalidate(); split.repaint(); split.requestFocusInWindow(); } }
Example 2
Source File: SplitAction.java From netbeans with Apache License 2.0 | 5 votes |
static void clearSplit(TopComponent tc, int elementToActivate) { if (tc instanceof Splitable) { TopComponent original = ((Splitable) tc).clearSplit(elementToActivate); original.open(); original.requestActive(); original.invalidate(); original.revalidate(); original.repaint(); original.requestFocusInWindow(); } }
Example 3
Source File: PagePanel.java From snap-desktop with GNU General Public License v3.0 | 5 votes |
protected void showAlternativeView() { final TopComponent parent = (TopComponent) this.getParent(); parent.remove(this); this.setVisible(false); parent.add(alternativeView, BorderLayout.CENTER); alternativeView.setVisible(true); parent.revalidate(); }
Example 4
Source File: MetadataPlotTopComponent.java From snap-desktop with GNU General Public License v3.0 | 5 votes |
@Override protected void showAlternativeView() { // this is overridden to avoid the clearance of the MetadataPlotPanel when // switching back from the MetadataTableViewPagePanel final TopComponent parent = (TopComponent) this.getParent(); parent.remove(this); this.setVisible(false); final PagePanel alternativeView = getAlternativeView(); alternativeView.handleLayerContentChanged(); parent.add(alternativeView, BorderLayout.CENTER); alternativeView.setVisible(true); parent.revalidate(); }