diff options
Diffstat (limited to 'bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/wizards')
4 files changed, 9 insertions, 15 deletions
diff --git a/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/wizards/ConfigureProjectWizardMainPage.java b/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/wizards/ConfigureProjectWizardMainPage.java index 74c820758..ee65cf432 100644 --- a/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/wizards/ConfigureProjectWizardMainPage.java +++ b/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/wizards/ConfigureProjectWizardMainPage.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2000, 2017 IBM Corporation and others. + * Copyright (c) 2000, 2018 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -207,7 +207,7 @@ public class ConfigureProjectWizardMainPage extends WizardPage { @Override public IWizardPage getNextPage() { if (selectedWizard == null) return null; - if(! WorkbenchActivityHelper.allowUseOf(getTriggerPoint(), ((IStructuredSelection)viewer.getSelection()).getFirstElement())) return null; + if(! WorkbenchActivityHelper.allowUseOf(getTriggerPoint(), viewer.getStructuredSelection().getFirstElement())) return null; return selectedWizard.getStartingPage(); } diff --git a/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/wizards/ExportProjectSetLocationPage.java b/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/wizards/ExportProjectSetLocationPage.java index 1165f337f..260b79743 100644 --- a/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/wizards/ExportProjectSetLocationPage.java +++ b/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/wizards/ExportProjectSetLocationPage.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2006, 2017 IBM Corporation and others. + * Copyright (c) 2006, 2018 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -314,7 +314,7 @@ public class ExportProjectSetLocationPage extends TeamWizardPage { } private void getSelectedContainer() { - Object obj = ((IStructuredSelection) wsTreeViewer.getSelection()).getFirstElement(); + Object obj = wsTreeViewer.getStructuredSelection().getFirstElement(); if (obj instanceof IContainer) wsContainer = (IContainer) obj; @@ -339,7 +339,7 @@ public class ExportProjectSetLocationPage extends TeamWizardPage { void setupListeners() { wsTreeViewer.addSelectionChangedListener(event -> { - IStructuredSelection s = (IStructuredSelection) event.getSelection(); + IStructuredSelection s = event.getStructuredSelection(); Object obj = s.getFirstElement(); if (obj != null) { diff --git a/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/wizards/GlobalRefreshWizardSelectionPage.java b/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/wizards/GlobalRefreshWizardSelectionPage.java index 15f61a3d7..97651b3ea 100644 --- a/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/wizards/GlobalRefreshWizardSelectionPage.java +++ b/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/wizards/GlobalRefreshWizardSelectionPage.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2000, 2010 IBM Corporation and others. + * Copyright (c) 2000, 2018 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -90,9 +90,6 @@ public class GlobalRefreshWizardSelectionPage extends WizardPage implements IDou setTitle(TeamUIMessages.GlobalRefreshParticipantSelectionPage_2); } - /* (non-Javadoc) - * @see org.eclipse.jface.dialogs.IDialogPage#dispose() - */ @Override public void dispose() { if (createdImages != null) { @@ -110,16 +107,13 @@ public class GlobalRefreshWizardSelectionPage extends WizardPage implements IDou if (fViewer.getControl().isDisposed()) return; - final IStructuredSelection selection= (IStructuredSelection)fViewer.getSelection(); + final IStructuredSelection selection= fViewer.getStructuredSelection(); final Object selected= selection.getFirstElement(); if (!(selected instanceof SynchronizeWizardDescription)) return; getDialogSettings().put(DEFAULT_SELECTION, ((SynchronizeWizardDescription)selected).getId()); } - /* (non-Javadoc) - * @see org.eclipse.jface.dialogs.IDialogPage#createControl(org.eclipse.swt.widgets.Composite) - */ @Override public void createControl(Composite parent2) { Composite top = new Composite(parent2, SWT.NULL); diff --git a/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/wizards/WorkingSetsDialog.java b/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/wizards/WorkingSetsDialog.java index 276e97b74..b7e712905 100644 --- a/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/wizards/WorkingSetsDialog.java +++ b/bundles/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/wizards/WorkingSetsDialog.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2006, 2017 IBM Corporation and others. + * Copyright (c) 2006, 2018 IBM Corporation and others. * All rights reserved. This program and the accompanying materials * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at @@ -111,7 +111,7 @@ public class WorkingSetsDialog extends TitleAreaDialog { void setupListeners() { wsTableViewer.addSelectionChangedListener(event -> { - IStructuredSelection s = (IStructuredSelection) event.getSelection(); + IStructuredSelection s = event.getStructuredSelection(); Object obj = s.getFirstElement(); if (obj instanceof IWorkingSet) wsNameText.setText(((IWorkingSet) obj).getName()); |