/** * Returns the page change provider that is the source of this event. * * @return the originating page change provider */ public IPageChangeProvider getPageChangeProvider() { return (IPageChangeProvider) getSource(); } }
public void pageChanged(PageChangedEvent event) { pageChangeProvider = event.getPageChangeProvider(); pageChanged(event.getSelectedPage()); }
protected void updatePageSelection() { TabItem[] items = tabFolder.getSelection(); if (items.length == 1) { currentPage = pageMap.get(items[0]); updateMessage(); } firePageChanged(new PageChangedEvent(this, currentPage)); }
public void pageChanged(PageChangedEvent event) { if (event.getSelectedPage() instanceof ConnectionProfileDetailsPage || event.getSelectedPage() instanceof ProfileDetailsPropertyPage) { PropertyPage page = (PropertyPage) event.getSelectedPage(); if (page.getControl() instanceof Composite) { Composite composite = (Composite) page.getControl(); if (inReadOnlyRepository) disableControls(composite, !inReadOnlyRepository, true); } } else if (event.getSelectedPage() instanceof PropertyPage) { PropertyPage page = (PropertyPage) event.getSelectedPage(); if (page.getControl() instanceof Composite) { Composite composite = (Composite) page.getControl(); if (inReadOnlyRepository) disableControls(composite, !inReadOnlyRepository); } } } }
private void notifyPageChanged() { if (fPageChangeListeners != null && !fPageChangeListeners.isEmpty()) { // Fires the page change event final PageChangedEvent event= new PageChangedEvent(this, getSelectedPage()); for (IPageChangedListener l : fPageChangeListeners) { SafeRunner.run(new SafeRunnable() { @Override public void run() { l.pageChanged(event); } }); } } } }
/** * Called whenever the dialog we're inside has changed pages. This updates * the context help page if it is visible. * * @param event the page change event */ public void pageChanged(PageChangedEvent event) { Object page = event.getSelectedPage(); Control c = null; if (page instanceof IDialogPage) { c = ((IDialogPage) page).getControl(); } else { c = shell.getDisplay().getFocusControl(); if (c instanceof TabFolder) { TabFolder folder = (TabFolder) c; TabItem[] selection = folder.getSelection(); if (selection.length == 1) { c = selection[0].getControl(); } } } helpPart.update(null, null, c); }
private void notifyPageChanged() { if (fPageChangeListeners != null && !fPageChangeListeners.isEmpty()) { // Fires the page change event final PageChangedEvent event= new PageChangedEvent(this, getSelectedPage()); Object[] listeners= fPageChangeListeners.getListeners(); for (int i= 0; i < listeners.length; ++i) { final IPageChangedListener l= (IPageChangedListener) listeners[i]; SafeRunner.run(new SafeRunnable() { public void run() { l.pageChanged(event); } }); } } } }
/** * Returns the page change provider that is the source of this event. * * @return the originating page change provider */ public IPageChangeProvider getPageChangeProvider() { return (IPageChangeProvider) getSource(); } }
/** * Updates this dialog's controls to reflect the current page. */ protected void update() { // Update the window title updateWindowTitle(); // Update the title bar updateTitleBar(); // Update the buttons updateButtons(); // Fires the page change event firePageChanged(new PageChangedEvent(this, getCurrentPage())); }
/** * Returns the page change provider that is the source of this event. * * @return the originating page change provider */ public IPageChangeProvider getPageChangeProvider() { return (IPageChangeProvider) getSource(); } }
/** * Updates this dialog's controls to reflect the current page. */ protected void update() { // Update the window title updateWindowTitle(); // Update the title bar updateTitleBar(); // Update the buttons updateButtons(); // Fires the page change event firePageChanged(new PageChangedEvent(this, getCurrentPage())); }
/** * Updates this dialog's controls to reflect the current page. */ protected void update() { // Update the window title updateWindowTitle(); // Update the title bar updateTitleBar(); // Update the buttons updateButtons(); // Fires the page change event firePageChanged(new PageChangedEvent(this, getCurrentPage())); }
/** * Updates this dialog's controls to reflect the current page. */ protected void update() { // Update the title bar updateTitle(); // Update the message line updateMessage(); // Update the buttons updateButtons(); //Saved the selected node in the preferences setSelectedNode(); firePageChanged(new PageChangedEvent(this, getCurrentPage())); }
/** * Updates this dialog's controls to reflect the current page. */ protected void update() { // Update the title bar updateTitle(); // Update the message line updateMessage(); // Update the buttons updateButtons(); //Saved the selected node in the preferences setSelectedNode(); firePageChanged(new PageChangedEvent(this, getCurrentPage())); }
/** * Updates this dialog's controls to reflect the current page. */ protected void update() { // Update the title bar updateTitle(); // Update the message line updateMessage(); // Update the buttons updateButtons(); //Saved the selected node in the preferences setSelectedNode(); firePageChanged(new PageChangedEvent(this, getCurrentPage())); }
Object selectedPage = getSelectedPage(); if (selectedPage != null) { firePageChanged(new PageChangedEvent(this, selectedPage));