Skip to content

Commit

Permalink
511219: Provide Marketplace / Favorites commands for Quick Access
Browse files Browse the repository at this point in the history
Command to show installed plug-ins in MPC

Bug: 511219
Task-Url: https://bugs.eclipse.org/bugs/show_bug.cgi?id=511219
  • Loading branch information
creckord committed Mar 30, 2017
1 parent 97fdb85 commit b0adc02
Show file tree
Hide file tree
Showing 3 changed files with 40 additions and 0 deletions.
2 changes: 2 additions & 0 deletions org.eclipse.epp.mpc.ui/OSGI-INF/l10n/bundle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ command.open.label = Eclipse &Marketplace...
command.open.tooltip = Open the Eclipse Marketplace wizard
command.importFavorites.description = Import another user's Marketplace Favorites List
command.importFavorites.name = Import Marketplace Favorites
command.installed.description = Update or uninstall plug-ins installed from the Marketplace
command.installed.name = Manage installed plug-ins
command.favorites.description = Open Marketplace Favorites
command.favorites.name = Eclipse Marketplace Favorites
command.favorites.label = Eclipse Marketplace &Favorites...
Expand Down
9 changes: 9 additions & 0 deletions org.eclipse.epp.mpc.ui/plugin.xml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,10 @@
class="org.eclipse.epp.internal.mpc.ui.commands.ShowFavoritesCommand"
commandId="org.eclipse.epp.mpc.ui.command.showFavorites">
</handler>
<handler
class="org.eclipse.epp.internal.mpc.ui.commands.ShowInstalledSolutionsCommand"
commandId="org.eclipse.epp.mpc.ui.command.showInstalled">
</handler>
</extension>
<extension
point="org.eclipse.ui.commands">
Expand All @@ -50,6 +54,11 @@
id="org.eclipse.epp.mpc.ui.command.showFavorites"
name="%command.favorites.name">
</command>
<command
description="%command.installed.description"
id="org.eclipse.epp.mpc.ui.command.showInstalled"
name="%command.installed.name">
</command>
</extension>
<extension
point="org.eclipse.ui.menus">
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
/*******************************************************************************
* Copyright (c) 2010 The Eclipse Foundation 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
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* The Eclipse Foundation - initial API and implementation
*******************************************************************************/
package org.eclipse.epp.internal.mpc.ui.commands;

import org.eclipse.core.commands.AbstractHandler;
import org.eclipse.core.commands.ExecutionEvent;
import org.eclipse.core.commands.ExecutionException;
import org.eclipse.epp.mpc.ui.IMarketplaceClientConfiguration;
import org.eclipse.epp.mpc.ui.IMarketplaceClientService;
import org.eclipse.epp.mpc.ui.MarketplaceClient;

public class ShowInstalledSolutionsCommand extends AbstractHandler {

public Object execute(ExecutionEvent event) throws ExecutionException {
IMarketplaceClientService marketplaceClientService = MarketplaceClient.getMarketplaceClientService();
IMarketplaceClientConfiguration config = marketplaceClientService.newConfiguration();
marketplaceClientService.openInstalled(config);
return null;
}

}

0 comments on commit b0adc02

Please sign in to comment.