diff options
Diffstat (limited to 'bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/internal/p2/ui/ProvUI.java')
-rw-r--r-- | bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/internal/p2/ui/ProvUI.java | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/internal/p2/ui/ProvUI.java b/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/internal/p2/ui/ProvUI.java index bd7ad9026..1d78b0c2f 100644 --- a/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/internal/p2/ui/ProvUI.java +++ b/bundles/org.eclipse.equinox.p2.ui/src/org/eclipse/equinox/internal/p2/ui/ProvUI.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2007, 2012 IBM Corporation and others. + * Copyright (c) 2007, 2015 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 @@ -8,6 +8,7 @@ * Contributors: * IBM Corporation - initial API and implementation * Ericsson AB (Hamdan Msheik) - Bug 396420 - Control Install dialog through preference customization + * Red Hat Inc. - Bug 460967 *******************************************************************************/ package org.eclipse.equinox.internal.p2.ui; @@ -167,18 +168,18 @@ public class ProvUI { } public static boolean isUpdateManagerInstallerPresent() { - ICommandService commandService = (ICommandService) PlatformUI.getWorkbench().getService(ICommandService.class); + ICommandService commandService = PlatformUI.getWorkbench().getService(ICommandService.class); Command command = commandService.getCommand(UPDATE_MANAGER_FIND_AND_INSTALL); return command.isDefined(); } private static void runCommand(String commandId, String errorMessage, Event event) { - ICommandService commandService = (ICommandService) PlatformUI.getWorkbench().getService(ICommandService.class); + ICommandService commandService = PlatformUI.getWorkbench().getService(ICommandService.class); Command command = commandService.getCommand(commandId); if (!command.isDefined()) { return; } - IHandlerService handlerService = (IHandlerService) PlatformUI.getWorkbench().getService(IHandlerService.class); + IHandlerService handlerService = PlatformUI.getWorkbench().getService(IHandlerService.class); try { handlerService.executeCommand(commandId, event); } catch (ExecutionException e) { |