List of usage examples for org.eclipse.jface.dialogs IDialogConstants FINISH_ID
int FINISH_ID
To view the source code for org.eclipse.jface.dialogs IDialogConstants FINISH_ID.
Click Source Link
From source file:com.nokia.carbide.internal.bugreport.ui.wizards.BugReporterWizardDialog.java
License:Open Source License
@Override public void create() { super.create(); getButton(IDialogConstants.FINISH_ID).setText(Messages.getString("BugReporterWizardDialog.SendReport")); //$NON-NLS-1$ }
From source file:com.nokia.cdt.internal.debug.launch.newwizard.AbstractLaunchWizard.java
License:Open Source License
/** * @param buttonBar//from w w w .j a v a 2s . c o m * @return */ private Button findFinishButton(Composite parent) { for (Control kid : parent.getChildren()) { if (kid instanceof Button) { if (kid.getData() instanceof Integer && (Integer) kid.getData() == IDialogConstants.FINISH_ID) { return (Button) kid; } } else if (kid instanceof Composite) { Button button = findFinishButton((Composite) kid); if (button != null) return button; } } return null; }
From source file:com.nokia.s60ct.gui.actions.ImportVatiantDataAction.java
License:Open Source License
public void run(IAction action) { VariantDataImportWizard wizard = new VariantDataImportWizard(rootConf, action.getId()); WizardDialog wizardDialog = new WizardDialog(getWindow().getShell(), wizard) { @Override/*from w ww . j av a 2 s . co m*/ protected Button createButton(Composite parent, int id, String label, boolean defaultButton) { if (id == IDialogConstants.FINISH_ID) { Button finish = super.createButton(parent, id, label, defaultButton); finish.setVisible(false); return finish; } else return super.createButton(parent, id, label, defaultButton); } @Override protected void createButtonsForButtonBar(Composite parent) { super.createButtonsForButtonBar(parent); Button cancel = this.getButton(IDialogConstants.CANCEL_ID); cancel.setText("Done"); } }; wizardDialog.open(); }
From source file:de.fu_berlin.inf.dpp.ui.wizards.JoinSessionWizard.java
License:Open Source License
@Override public void createPageControls(Composite pageContainer) { descriptionPage.createControl(pageContainer); if (getContainer() instanceof WizardDialogAccessable) { ((WizardDialogAccessable) getContainer()).setWizardButtonLabel(IDialogConstants.FINISH_ID, Messages.JoinSessionWizard_accept); }/* www .jav a 2 s . c o m*/ isn.addCancelListener(cancelListener); if (isn.isCanceled()) { /* * FIXME error message is only available after negotiation * termination, but in most cases it should be null at this point * anyway */ handleCanceledAsync(isn.isLocalCancellation() ? CancelLocation.LOCAL : CancelLocation.REMOTE, null); } }
From source file:dynamicrefactoring.interfaz.wizard.CustomWizardDialog.java
License:Open Source License
/** * Crea los botones del dilogo en que se muestra un asistente. * /*from w ww .jav a2 s . c o m*/ * @param parent el componente padre que contendr los botones. */ @Override protected void createButtonsForButtonBar(Composite parent) { super.createButtonsForButtonBar(parent); if (super.getButton(IDialogConstants.FINISH_ID) != null) super.getButton(IDialogConstants.FINISH_ID).setText(ButtonTextProvider.getFinishText()); if (super.getButton(IDialogConstants.CANCEL_ID) != null) super.getButton(IDialogConstants.CANCEL_ID).setText(ButtonTextProvider.getCancelText()); if (super.getButton(IDialogConstants.BACK_ID) != null) super.getButton(IDialogConstants.BACK_ID).setText(ButtonTextProvider.getBackText()); if (super.getButton(IDialogConstants.NEXT_ID) != null) super.getButton(IDialogConstants.NEXT_ID).setText(ButtonTextProvider.getNextText()); }
From source file:eu.abc4trust.ri.ui.user.wizard.IssueWizardDialog.java
License:Open Source License
@Override protected void createButtonsForButtonBar(Composite parent) { super.createButtonsForButtonBar(parent); Button ok = getButton(IDialogConstants.NEXT_ID); ok.setText("Get credential!"); setButtonLayoutData(ok);/*ww w . j a va 2 s. c o m*/ ok.addMouseListener(new MouseListener() { private static final long serialVersionUID = 6732595815149773092L; @Override public void mouseDoubleClick(MouseEvent arg0) { } @Override public void mouseDown(MouseEvent arg0) { ProtocolHandler.doProtocol(wizard); } @Override public void mouseUp(MouseEvent arg0) { } }); Button finish = getButton(IDialogConstants.FINISH_ID); finish.setText("Thanks!"); setButtonLayoutData(finish); Button cancel = getButton(IDialogConstants.CANCEL_ID); cancel.setText("I changed my mind"); setButtonLayoutData(cancel); }
From source file:eu.aniketos.wp1.ststool.report.handlers.GenerateReportHandler.java
License:Open Source License
@Override public Object execute(ExecutionEvent event) throws ExecutionException { try {//from w w w. j a va 2 s . c o m final IWorkbenchWindow window; if (event != null) window = HandlerUtil.getActiveWorkbenchWindowChecked(event); else window = PlatformUI.getWorkbench().getActiveWorkbenchWindow(); if (!(window.getActivePage().getActiveEditor() instanceof StsToolDiagramEditor)) return null; GenerateReportWizard wizard = new GenerateReportWizard( (StsToolDiagramEditor) window.getActivePage().getActiveEditor()); WizardDialog dialog = new WizardDialog(window.getShell(), wizard) { @Override public void updateButtons() { super.updateButtons(); boolean canFlipToNextPage = false; if (getButton(IDialogConstants.NEXT_ID) != null) { canFlipToNextPage = getCurrentPage().canFlipToNextPage(); } if (canFlipToNextPage) { getShell().setDefaultButton(getButton(IDialogConstants.NEXT_ID)); } else { getShell().setDefaultButton(getButton(IDialogConstants.FINISH_ID)); } } }; dialog.create(); dialog.setBlockOnOpen(true); dialog.open(); } catch (Exception e) { e.printStackTrace(); } return null; }
From source file:fr.imag.adele.cadse.si.workspace.uiplatform.swt.ui.DetailWizardDialog.java
License:Apache License
@Override protected void createButtonsForButtonBar(Composite parent) { finishButtonOverWrite = createButton(parent, IDialogConstants.FINISH_ID, IDialogConstants.CLOSE_LABEL, true); }
From source file:fr.imag.adele.cadse.si.workspace.uiplatform.swt.ui.DetailWizardDialog.java
License:Apache License
@Override protected void buttonPressed(int buttonId) { if (buttonId == IDialogConstants.FINISH_ID) { finishPressed();/* www. j a v a 2 s . c om*/ } super.buttonPressed(buttonId); }
From source file:net.geoprism.shapefile.LocalizedWizardDialog.java
License:Open Source License
/** * Creates the buttons for this dialog's button bar. * <p>/*from ww w . j a va 2 s. c om*/ * The <code>WizardDialog</code> implementation of this framework method * prevents the parent composite's columns from being made equal width in * order to remove the margin between the Back and Next buttons. * </p> * * @param parent * the parent composite to contain the buttons */ protected void createButtonsForButtonBar(Composite parent) { ((GridLayout) parent.getLayout()).makeColumnsEqualWidth = false; if (wizard.isHelpAvailable()) { helpButton = createButton(parent, IDialogConstants.HELP_ID, Localizer.getMessage("HELP"), false); } if (wizard.needsPreviousAndNextButtons()) { createPreviousAndNextButtons(parent); } finishButton = createButton(parent, IDialogConstants.FINISH_ID, Localizer.getMessage("FINISH"), true); cancelButton = createCancelButton(parent); if (parent.getDisplay().getDismissalAlignment() == SWT.RIGHT) { // Make the default button the right-most button. // See also special code in // org.eclipse.jface.dialogs.Dialog#initializeBounds() finishButton.moveBelow(null); } }