| /*=============================================================================# |
| # Copyright (c) 2006, 2021 Stephan Wahlbrink and others. |
| # |
| # This program and the accompanying materials are made available under the |
| # terms of the Eclipse Public License 2.0 which is available at |
| # https://www.eclipse.org/legal/epl-2.0, or the Apache License, Version 2.0 |
| # which is available at https://www.apache.org/licenses/LICENSE-2.0. |
| # |
| # SPDX-License-Identifier: EPL-2.0 OR Apache-2.0 |
| # |
| # Contributors: |
| # Stephan Wahlbrink <sw@wahlbrink.eu> - initial API and implementation |
| #=============================================================================*/ |
| |
| package org.eclipse.statet.nico.ui; |
| |
| import org.eclipse.jface.resource.ImageDescriptor; |
| import org.eclipse.swt.graphics.Image; |
| |
| import org.eclipse.statet.ecommons.ts.ui.workbench.WorkbenchToolRegistry; |
| |
| import org.eclipse.statet.internal.nico.ui.NicoUIPlugin; |
| |
| |
| /** |
| * Public Nico-UI services. |
| * <p> |
| * Access via static methods. |
| */ |
| public class NicoUI { |
| |
| |
| public static final String BUNDLE_ID= "org.eclipse.statet.nico.ui"; //$NON-NLS-1$ |
| |
| |
| public static final String LOCTOOL_CANCEL_IMAGE_ID = BUNDLE_ID + "/imgage/loctool/cancel"; //$NON-NLS-1$ |
| public static final String LOCTOOLD_CANCEL_IMAGE_ID = BUNDLE_ID + "/image/loctoold/cancel"; //$NON-NLS-1$ |
| |
| public static final String LOCTOOL_PAUSE_IMAGE_ID = BUNDLE_ID + "/image/loctool/pause"; //$NON-NLS-1$ |
| public static final String LOCTOOLD_PAUSE_IMAGE_ID = BUNDLE_ID + "/image/loctoold/pause"; //$NON-NLS-1$ |
| |
| public static final String LOCTOOL_TERMINATE_IMAGE_ID = BUNDLE_ID + "/image/loctool/terminate"; //$NON-NLS-1$ |
| public static final String LOCTOOLD_TERMINATE_IMAGE_ID = BUNDLE_ID + "/image/loctoold/terminate"; //$NON-NLS-1$ |
| |
| public static final String OBJ_TASK_CONSOLECOMMAND_IMAGE_ID = BUNDLE_ID + "/image/obj/task.consolecommand"; //$NON-NLS-1$ |
| public static final String OBJ_TASK_DUMMY_IMAGE_ID = BUNDLE_ID + "/image/obj/task.commanddummy"; //$NON-NLS-1$ |
| |
| public static final String OBJ_CONSOLECOMMAND_IMAGE_ID = BUNDLE_ID + "/image/obj/consolecommand"; //$NON-NLS-1$ |
| |
| public static final String HISTORY_VIEW_ID = "org.eclipse.statet.nico.views.HistoryView"; //$NON-NLS-1$ |
| public static final String QUEUE_VIEW_ID = "org.eclipse.statet.nico.views.QueueView"; //$NON-NLS-1$ |
| |
| public static final String PAUSE_COMMAND_ID = "org.eclipse.statet.nico.commands.PauseEngine"; //$NON-NLS-1$ |
| public static final String DISCONNECT_COMMAND_ID = "org.eclipse.statet.nico.commands.DisconnectEngine"; //$NON-NLS-1$ |
| public static final String RECONNECT_COMMAND_ID = "org.eclipse.statet.nico.commands.ReconnectEngine"; //$NON-NLS-1$ |
| |
| public static final String CANCEL_CURRENT_COMMAND_ID = "org.eclipse.statet.nico.commands.CancelCurrent"; //$NON-NLS-1$ |
| public static final String CANCEL_ALL_COMMAND_ID = "org.eclipse.statet.nico.commands.CancelAll"; //$NON-NLS-1$ |
| public static final String CANCEL_PAUSE_COMMAND_ID = "org.eclipse.statet.nico.commands.CancelCurrentAndPause"; //$NON-NLS-1$ |
| |
| |
| public static ImageDescriptor getImageDescriptor(final String key) { |
| return NicoUIPlugin.getInstance().getImageRegistry().getDescriptor(key); |
| } |
| |
| public static Image getImage(final String key) { |
| return NicoUIPlugin.getInstance().getImageRegistry().get(key); |
| } |
| |
| public static WorkbenchToolRegistry getToolRegistry() { |
| return NicoUIPlugin.getInstance().getToolRegistry(); |
| } |
| |
| |
| private NicoUI() {} |
| |
| } |