diff options
Diffstat (limited to 'target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org')
58 files changed, 1471 insertions, 1471 deletions
diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/activator/UIPlugin.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/activator/UIPlugin.java index fd92c8e1d..df80d5d2c 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/activator/UIPlugin.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/activator/UIPlugin.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2011, 2013 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2011, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/DeleteHandler.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/DeleteHandler.java index 6e3029334..2b7c00f87 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/DeleteHandler.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/DeleteHandler.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/LaunchDialogHandler.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/LaunchDialogHandler.java index 2af388ab9..cf5259ba7 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/LaunchDialogHandler.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/LaunchDialogHandler.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/LaunchHandler.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/LaunchHandler.java index d476b4101..e3fe96617 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/LaunchHandler.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/LaunchHandler.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/LaunchLaunchConfigurationContributionItem.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/LaunchLaunchConfigurationContributionItem.java index 66c487f66..0a9766bdc 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/LaunchLaunchConfigurationContributionItem.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/LaunchLaunchConfigurationContributionItem.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/LaunchShortcutHandler.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/LaunchShortcutHandler.java index 2c3583a12..07cc61a16 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/LaunchShortcutHandler.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/LaunchShortcutHandler.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/NewLaunchConfigurationContributionItem.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/NewLaunchConfigurationContributionItem.java index 00197f176..6b31d852d 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/NewLaunchConfigurationContributionItem.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/NewLaunchConfigurationContributionItem.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/OpenActionProvider.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/OpenActionProvider.java index 088617357..83c3d39ae 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/OpenActionProvider.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/OpenActionProvider.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/OpenLaunchConfigurationContributionItem.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/OpenLaunchConfigurationContributionItem.java index b6450ed39..ab92a5b09 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/OpenLaunchConfigurationContributionItem.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/OpenLaunchConfigurationContributionItem.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/RefreshHandler.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/RefreshHandler.java index 133661b58..cada7d230 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/RefreshHandler.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/handler/RefreshHandler.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/help/IContextHelpIds.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/help/IContextHelpIds.java index 44b819aeb..8ff6fbcaf 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/help/IContextHelpIds.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/help/IContextHelpIds.java @@ -1,28 +1,28 @@ -/*******************************************************************************
- * Copyright (c) 2011, 2012 Wind River Systems, Inc. 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:
- * Wind River Systems - initial API and implementation
- *******************************************************************************/
-package org.eclipse.tcf.te.launch.ui.help;
-
-import org.eclipse.tcf.te.launch.ui.activator.UIPlugin;
-
-/**
- * Context help id definitions.
- */
-public interface IContextHelpIds {
-
- /**
- * UI plug-in common context help id prefix.
- */
- public final static String PREFIX = UIPlugin.getUniqueIdentifier() + "."; //$NON-NLS-1$
-
- /**
- * Launch editor page.
- */
- public final static String LAUNCH_EDITOR = PREFIX + "LaunchEditor"; //$NON-NLS-1$
-}
+/******************************************************************************* + * Copyright (c) 2011, 2014 Wind River Systems, Inc. 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: + * Wind River Systems - initial API and implementation + *******************************************************************************/ +package org.eclipse.tcf.te.launch.ui.help; + +import org.eclipse.tcf.te.launch.ui.activator.UIPlugin; + +/** + * Context help id definitions. + */ +public interface IContextHelpIds { + + /** + * UI plug-in common context help id prefix. + */ + public final static String PREFIX = UIPlugin.getUniqueIdentifier() + "."; //$NON-NLS-1$ + + /** + * Launch editor page. + */ + public final static String LAUNCH_EDITOR = PREFIX + "LaunchEditor"; //$NON-NLS-1$ +} diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/interfaces/ILaunchConfigurationTabFormPart.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/interfaces/ILaunchConfigurationTabFormPart.java index c5b4c25d8..b9bbaaef6 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/interfaces/ILaunchConfigurationTabFormPart.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/interfaces/ILaunchConfigurationTabFormPart.java @@ -1,49 +1,49 @@ -/*******************************************************************************
- * Copyright (c) 2012 Wind River Systems, Inc. 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:
- * Wind River Systems - initial API and implementation
- *******************************************************************************/
-package org.eclipse.tcf.te.launch.ui.interfaces;
-
-import org.eclipse.debug.core.ILaunchConfiguration;
-import org.eclipse.debug.core.ILaunchConfigurationWorkingCopy;
-
-/**
- * A form part which can be added to launch configuration tabs and participate at the launch
- * configuration tab life cycle.
- */
-public interface ILaunchConfigurationTabFormPart {
-
- /**
- * Initializes this form part controls with values from the given launch configuration. This
- * method is called when a configuration is selected to view or edit, after this form part's
- * control has been created.
- *
- * @param configuration The launch configuration. Must not be <code>null</code>.
- */
- public void initializeFrom(ILaunchConfiguration configuration);
-
- /**
- * Copies values from this form part into the given launch configuration.
- *
- * @param configuration The launch configuration. Must not be <code>null</code>.
- */
- public void performApply(ILaunchConfigurationWorkingCopy configuration);
-
- /**
- * Returns whether this form part is in a valid state in the context of the specified launch
- * configuration.
- * <p>
- * This information is typically used by the launch configuration dialog to decide when it is
- * okay to launch.
- * </p>
- *
- * @param configuration The launch configuration. Must not be <code>null</code>.
- * @return <code>True</code> if this form part is in a valid state.
- */
- public boolean isValid(ILaunchConfiguration configuration);
-}
+/******************************************************************************* + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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: + * Wind River Systems - initial API and implementation + *******************************************************************************/ +package org.eclipse.tcf.te.launch.ui.interfaces; + +import org.eclipse.debug.core.ILaunchConfiguration; +import org.eclipse.debug.core.ILaunchConfigurationWorkingCopy; + +/** + * A form part which can be added to launch configuration tabs and participate at the launch + * configuration tab life cycle. + */ +public interface ILaunchConfigurationTabFormPart { + + /** + * Initializes this form part controls with values from the given launch configuration. This + * method is called when a configuration is selected to view or edit, after this form part's + * control has been created. + * + * @param configuration The launch configuration. Must not be <code>null</code>. + */ + public void initializeFrom(ILaunchConfiguration configuration); + + /** + * Copies values from this form part into the given launch configuration. + * + * @param configuration The launch configuration. Must not be <code>null</code>. + */ + public void performApply(ILaunchConfigurationWorkingCopy configuration); + + /** + * Returns whether this form part is in a valid state in the context of the specified launch + * configuration. + * <p> + * This information is typically used by the launch configuration dialog to decide when it is + * okay to launch. + * </p> + * + * @param configuration The launch configuration. Must not be <code>null</code>. + * @return <code>True</code> if this form part is in a valid state. + */ + public boolean isValid(ILaunchConfiguration configuration); +} diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/ImageConsts.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/ImageConsts.java index cf1abc71b..673c4352e 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/ImageConsts.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/ImageConsts.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012, 2013 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/PropertyTester.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/PropertyTester.java index be40a7568..d4651b05d 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/PropertyTester.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/PropertyTester.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/adapters/AdapterFactory.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/adapters/AdapterFactory.java index aa10eedd5..b99abd0fc 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/adapters/AdapterFactory.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/adapters/AdapterFactory.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/adapters/CategorizableAdapter.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/adapters/CategorizableAdapter.java index d455122a3..7f107e64f 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/adapters/CategorizableAdapter.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/adapters/CategorizableAdapter.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012, 2013 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/pages/LaunchExplorerEditorPage.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/pages/LaunchExplorerEditorPage.java index dbe0d9205..2904a56c6 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/pages/LaunchExplorerEditorPage.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/pages/LaunchExplorerEditorPage.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2011, 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2011, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/preferences/PreferencesInitializer.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/preferences/PreferencesInitializer.java index 9af212341..4767343d3 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/preferences/PreferencesInitializer.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/preferences/PreferencesInitializer.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/FileTransferFilter.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/FileTransferFilter.java index 86250deb7..ac87247d0 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/FileTransferFilter.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/FileTransferFilter.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/FileTransferPropertiesSection.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/FileTransferPropertiesSection.java index 88e90afd8..63c5c30d3 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/FileTransferPropertiesSection.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/FileTransferPropertiesSection.java @@ -1,147 +1,147 @@ -/*******************************************************************************
- * Copyright (c) 2012 Wind River Systems, Inc. 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:
- * Wind River Systems - initial API and implementation
- *******************************************************************************/
-package org.eclipse.tcf.te.launch.ui.internal.properties;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.List;
-
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.debug.core.ILaunchConfiguration;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.ITableLabelProvider;
-import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.FormAttachment;
-import org.eclipse.swt.layout.FormData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.tcf.te.launch.core.persistence.filetransfer.FileTransfersPersistenceDelegate;
-import org.eclipse.tcf.te.launch.ui.model.LaunchNode;
-import org.eclipse.tcf.te.launch.ui.nls.Messages;
-import org.eclipse.tcf.te.launch.ui.properties.BaseTitledSection;
-import org.eclipse.tcf.te.launch.ui.tabs.filetransfers.FileTransferContentProvider;
-import org.eclipse.tcf.te.runtime.services.interfaces.filetransfer.IFileTransferItem;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.views.properties.tabbed.ITabbedPropertyConstants;
-import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage;
-
-/**
- * The property section to display the file transfer property of a launch configuration.
- */
-public class FileTransferPropertiesSection extends BaseTitledSection {
-
- protected static class FileTransferLabelProvider extends LabelProvider implements ITableLabelProvider {
- /* (non-Javadoc)
- * @see org.eclipse.jface.viewers.ITableLabelProvider#getColumnImage(java.lang.Object, int)
- */
- @Override
- public Image getColumnImage(Object element, int columnIndex) {
- return null;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.viewers.ITableLabelProvider#getColumnText(java.lang.Object, int)
- */
- @Override
- public String getColumnText(Object element, int columnIndex) {
- switch (columnIndex) {
- case 0:
- return ((IFileTransferItem)element).getHostPath().toOSString();
- case 1:
- return (((IFileTransferItem)element).getDirection() == IFileTransferItem.TARGET_TO_HOST ?
- Messages.FileTransferSection_toHost_text : Messages.FileTransferSection_toTarget_text);
- case 2:
- return ((IFileTransferItem)element).getTargetPath().toPortableString();
- case 3:
- return ((IFileTransferItem)element).getOptions();
- }
- return ""; //$NON-NLS-1$
- }
- }
-
- private IFileTransferItem[] items;
- // The table control to display the properties.
- private TableViewer viewer;
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#createControls(org.eclipse.swt.widgets.Composite, org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage)
- */
- @Override
- public void createControls(Composite parent, TabbedPropertySheetPage aTabbedPropertySheetPage) {
- super.createControls(parent, aTabbedPropertySheetPage);
-
- Table table = getWidgetFactory().createTable(composite, SWT.FULL_SELECTION | SWT.MULTI | SWT.BORDER);
- FormData data = new FormData();
- data.left = new FormAttachment(0, 0);
- data.right = new FormAttachment(100, 0);
- data.top = new FormAttachment(0, ITabbedPropertyConstants.VSPACE);
- data.bottom = new FormAttachment(100, -ITabbedPropertyConstants.VSPACE);
- table.setLayoutData(data);
- TableColumn column = new TableColumn(table, SWT.LEFT);
- column.setText(Messages.FileTransferSection_host_column);
- column.setWidth(200);
- column = new TableColumn(table, SWT.CENTER);
- column.setWidth(30);
- column = new TableColumn(table, SWT.LEFT);
- column.setText(Messages.FileTransferSection_target_column);
- column.setWidth(200);
- column = new TableColumn(table, SWT.LEFT);
- column.setText(Messages.FileTransferSection_options_column);
- column.setWidth(100);
- table.setHeaderVisible(true);
- table.setLinesVisible(true);
- viewer = new TableViewer(table);
- viewer.setContentProvider(new FileTransferContentProvider());
- viewer.setLabelProvider(new FileTransferLabelProvider());
- }
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#setInput(org.eclipse.ui.IWorkbenchPart, org.eclipse.jface.viewers.ISelection)
- */
- @Override
- public void setInput(IWorkbenchPart part, ISelection selection) {
- super.setInput(part, selection);
- Assert.isTrue(selection instanceof IStructuredSelection);
- Object input = ((IStructuredSelection) selection).getFirstElement();
- Assert.isTrue(input instanceof LaunchNode);
- ILaunchConfiguration node = ((LaunchNode)input).getLaunchConfiguration();
- List<IFileTransferItem> list = new ArrayList<IFileTransferItem>();
- for (IFileTransferItem item : Arrays.asList(FileTransfersPersistenceDelegate.getFileTransfers(node))) {
- if (item.isEnabled()) {
- list.add(item);
- }
- }
- items = list.toArray(new IFileTransferItem[list.size()]);
- }
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#refresh()
- */
- @Override
- public void refresh() {
- if (viewer != null) viewer.setInput(items);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.tcf.te.ui.views.tabbed.BaseTitledSection#getText()
- */
- @Override
- protected String getText() {
- return Messages.FileTransferSection_title;
- }
-}
+/******************************************************************************* + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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: + * Wind River Systems - initial API and implementation + *******************************************************************************/ +package org.eclipse.tcf.te.launch.ui.internal.properties; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; + +import org.eclipse.core.runtime.Assert; +import org.eclipse.debug.core.ILaunchConfiguration; +import org.eclipse.jface.viewers.ISelection; +import org.eclipse.jface.viewers.IStructuredSelection; +import org.eclipse.jface.viewers.ITableLabelProvider; +import org.eclipse.jface.viewers.LabelProvider; +import org.eclipse.jface.viewers.TableViewer; +import org.eclipse.swt.SWT; +import org.eclipse.swt.graphics.Image; +import org.eclipse.swt.layout.FormAttachment; +import org.eclipse.swt.layout.FormData; +import org.eclipse.swt.widgets.Composite; +import org.eclipse.swt.widgets.Table; +import org.eclipse.swt.widgets.TableColumn; +import org.eclipse.tcf.te.launch.core.persistence.filetransfer.FileTransfersPersistenceDelegate; +import org.eclipse.tcf.te.launch.ui.model.LaunchNode; +import org.eclipse.tcf.te.launch.ui.nls.Messages; +import org.eclipse.tcf.te.launch.ui.properties.BaseTitledSection; +import org.eclipse.tcf.te.launch.ui.tabs.filetransfers.FileTransferContentProvider; +import org.eclipse.tcf.te.runtime.services.interfaces.filetransfer.IFileTransferItem; +import org.eclipse.ui.IWorkbenchPart; +import org.eclipse.ui.views.properties.tabbed.ITabbedPropertyConstants; +import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage; + +/** + * The property section to display the file transfer property of a launch configuration. + */ +public class FileTransferPropertiesSection extends BaseTitledSection { + + protected static class FileTransferLabelProvider extends LabelProvider implements ITableLabelProvider { + /* (non-Javadoc) + * @see org.eclipse.jface.viewers.ITableLabelProvider#getColumnImage(java.lang.Object, int) + */ + @Override + public Image getColumnImage(Object element, int columnIndex) { + return null; + } + + /* (non-Javadoc) + * @see org.eclipse.jface.viewers.ITableLabelProvider#getColumnText(java.lang.Object, int) + */ + @Override + public String getColumnText(Object element, int columnIndex) { + switch (columnIndex) { + case 0: + return ((IFileTransferItem)element).getHostPath().toOSString(); + case 1: + return (((IFileTransferItem)element).getDirection() == IFileTransferItem.TARGET_TO_HOST ? + Messages.FileTransferSection_toHost_text : Messages.FileTransferSection_toTarget_text); + case 2: + return ((IFileTransferItem)element).getTargetPath().toPortableString(); + case 3: + return ((IFileTransferItem)element).getOptions(); + } + return ""; //$NON-NLS-1$ + } + } + + private IFileTransferItem[] items; + // The table control to display the properties. + private TableViewer viewer; + + /* + * (non-Javadoc) + * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#createControls(org.eclipse.swt.widgets.Composite, org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage) + */ + @Override + public void createControls(Composite parent, TabbedPropertySheetPage aTabbedPropertySheetPage) { + super.createControls(parent, aTabbedPropertySheetPage); + + Table table = getWidgetFactory().createTable(composite, SWT.FULL_SELECTION | SWT.MULTI | SWT.BORDER); + FormData data = new FormData(); + data.left = new FormAttachment(0, 0); + data.right = new FormAttachment(100, 0); + data.top = new FormAttachment(0, ITabbedPropertyConstants.VSPACE); + data.bottom = new FormAttachment(100, -ITabbedPropertyConstants.VSPACE); + table.setLayoutData(data); + TableColumn column = new TableColumn(table, SWT.LEFT); + column.setText(Messages.FileTransferSection_host_column); + column.setWidth(200); + column = new TableColumn(table, SWT.CENTER); + column.setWidth(30); + column = new TableColumn(table, SWT.LEFT); + column.setText(Messages.FileTransferSection_target_column); + column.setWidth(200); + column = new TableColumn(table, SWT.LEFT); + column.setText(Messages.FileTransferSection_options_column); + column.setWidth(100); + table.setHeaderVisible(true); + table.setLinesVisible(true); + viewer = new TableViewer(table); + viewer.setContentProvider(new FileTransferContentProvider()); + viewer.setLabelProvider(new FileTransferLabelProvider()); + } + + /* + * (non-Javadoc) + * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#setInput(org.eclipse.ui.IWorkbenchPart, org.eclipse.jface.viewers.ISelection) + */ + @Override + public void setInput(IWorkbenchPart part, ISelection selection) { + super.setInput(part, selection); + Assert.isTrue(selection instanceof IStructuredSelection); + Object input = ((IStructuredSelection) selection).getFirstElement(); + Assert.isTrue(input instanceof LaunchNode); + ILaunchConfiguration node = ((LaunchNode)input).getLaunchConfiguration(); + List<IFileTransferItem> list = new ArrayList<IFileTransferItem>(); + for (IFileTransferItem item : Arrays.asList(FileTransfersPersistenceDelegate.getFileTransfers(node))) { + if (item.isEnabled()) { + list.add(item); + } + } + items = list.toArray(new IFileTransferItem[list.size()]); + } + + /* + * (non-Javadoc) + * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#refresh() + */ + @Override + public void refresh() { + if (viewer != null) viewer.setInput(items); + } + + /* (non-Javadoc) + * @see org.eclipse.tcf.te.ui.views.tabbed.BaseTitledSection#getText() + */ + @Override + protected String getText() { + return Messages.FileTransferSection_title; + } +} diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/LaunchConfigTypeFilter.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/LaunchConfigTypeFilter.java index 5e3f6c362..7cc194521 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/LaunchConfigTypeFilter.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/LaunchConfigTypeFilter.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/LaunchConfigTypePropertiesSection.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/LaunchConfigTypePropertiesSection.java index 46047a538..a023fd80d 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/LaunchConfigTypePropertiesSection.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/LaunchConfigTypePropertiesSection.java @@ -1,74 +1,74 @@ -/*******************************************************************************
- * Copyright (c) 2011, 2012 Wind River Systems, Inc. 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:
- * Wind River Systems - initial API and implementation
- *******************************************************************************/
-package org.eclipse.tcf.te.launch.ui.internal.properties;
-
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.debug.core.ILaunchConfigurationType;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.tcf.te.launch.ui.model.LaunchNode;
-import org.eclipse.tcf.te.launch.ui.nls.Messages;
-import org.eclipse.tcf.te.launch.ui.properties.BaseTitledSection;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage;
-
-/**
- * The property section to display the properties of a launch configuration.
- */
-public class LaunchConfigTypePropertiesSection extends BaseTitledSection {
- private String nameValue = ""; //$NON-NLS-1$
-
- private Text name;
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#createControls(org.eclipse.swt.widgets.Composite, org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage)
- */
- @Override
- public void createControls(Composite parent, TabbedPropertySheetPage aTabbedPropertySheetPage) {
- super.createControls(parent, aTabbedPropertySheetPage);
-
- name = createTextField(null, Messages.LaunchConfigType_label);
- }
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#setInput(org.eclipse.ui.IWorkbenchPart, org.eclipse.jface.viewers.ISelection)
- */
- @Override
- public void setInput(IWorkbenchPart part, ISelection selection) {
- super.setInput(part, selection);
- Assert.isTrue(selection instanceof IStructuredSelection);
- Object input = ((IStructuredSelection) selection).getFirstElement();
- Assert.isTrue(input instanceof LaunchNode);
- ILaunchConfigurationType node = ((LaunchNode)input).getLaunchConfigurationType();
-
- nameValue = node.getName();
- }
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#refresh()
- */
- @Override
- public void refresh() {
- if (name != null) name.setText(nameValue);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.tcf.te.ui.views.tabbed.BaseTitledSection#getText()
- */
- @Override
- protected String getText() {
- return Messages.LaunchConfigType_title;
- }
-}
+/******************************************************************************* + * Copyright (c) 2011, 2014 Wind River Systems, Inc. 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: + * Wind River Systems - initial API and implementation + *******************************************************************************/ +package org.eclipse.tcf.te.launch.ui.internal.properties; + +import org.eclipse.core.runtime.Assert; +import org.eclipse.debug.core.ILaunchConfigurationType; +import org.eclipse.jface.viewers.ISelection; +import org.eclipse.jface.viewers.IStructuredSelection; +import org.eclipse.swt.widgets.Composite; +import org.eclipse.swt.widgets.Text; +import org.eclipse.tcf.te.launch.ui.model.LaunchNode; +import org.eclipse.tcf.te.launch.ui.nls.Messages; +import org.eclipse.tcf.te.launch.ui.properties.BaseTitledSection; +import org.eclipse.ui.IWorkbenchPart; +import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage; + +/** + * The property section to display the properties of a launch configuration. + */ +public class LaunchConfigTypePropertiesSection extends BaseTitledSection { + private String nameValue = ""; //$NON-NLS-1$ + + private Text name; + + /* + * (non-Javadoc) + * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#createControls(org.eclipse.swt.widgets.Composite, org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage) + */ + @Override + public void createControls(Composite parent, TabbedPropertySheetPage aTabbedPropertySheetPage) { + super.createControls(parent, aTabbedPropertySheetPage); + + name = createTextField(null, Messages.LaunchConfigType_label); + } + + /* + * (non-Javadoc) + * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#setInput(org.eclipse.ui.IWorkbenchPart, org.eclipse.jface.viewers.ISelection) + */ + @Override + public void setInput(IWorkbenchPart part, ISelection selection) { + super.setInput(part, selection); + Assert.isTrue(selection instanceof IStructuredSelection); + Object input = ((IStructuredSelection) selection).getFirstElement(); + Assert.isTrue(input instanceof LaunchNode); + ILaunchConfigurationType node = ((LaunchNode)input).getLaunchConfigurationType(); + + nameValue = node.getName(); + } + + /* + * (non-Javadoc) + * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#refresh() + */ + @Override + public void refresh() { + if (name != null) name.setText(nameValue); + } + + /* (non-Javadoc) + * @see org.eclipse.tcf.te.ui.views.tabbed.BaseTitledSection#getText() + */ + @Override + protected String getText() { + return Messages.LaunchConfigType_title; + } +} diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/LaunchContextFilter.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/LaunchContextFilter.java index 05c10fb0d..dce9a2a5c 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/LaunchContextFilter.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/LaunchContextFilter.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/LaunchContextPropertiesSection.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/LaunchContextPropertiesSection.java index ec90e02d9..f733ae869 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/LaunchContextPropertiesSection.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/LaunchContextPropertiesSection.java @@ -1,91 +1,91 @@ -/*******************************************************************************
- * Copyright (c) 2011, 2012 Wind River Systems, Inc. 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:
- * Wind River Systems - initial API and implementation
- *******************************************************************************/
-package org.eclipse.tcf.te.launch.ui.internal.properties;
-
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.debug.core.ILaunchConfiguration;
-import org.eclipse.jface.viewers.ILabelDecorator;
-import org.eclipse.jface.viewers.ILabelProvider;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.tcf.te.launch.core.persistence.launchcontext.LaunchContextsPersistenceDelegate;
-import org.eclipse.tcf.te.launch.ui.model.LaunchNode;
-import org.eclipse.tcf.te.launch.ui.nls.Messages;
-import org.eclipse.tcf.te.launch.ui.properties.BaseTitledSection;
-import org.eclipse.tcf.te.runtime.model.interfaces.IModelNode;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage;
-
-/**
- * The property section to display the properties of a launch configuration.
- */
-public class LaunchContextPropertiesSection extends BaseTitledSection {
- private String launchContextValue = ""; //$NON-NLS-1$
-
- private Text launchContext;
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#createControls(org.eclipse.swt.widgets.Composite, org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage)
- */
- @Override
- public void createControls(Composite parent, TabbedPropertySheetPage aTabbedPropertySheetPage) {
- super.createControls(parent, aTabbedPropertySheetPage);
-
- launchContext = createTextField(null, Messages.ContextSelectorSection_label);
- }
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#setInput(org.eclipse.ui.IWorkbenchPart, org.eclipse.jface.viewers.ISelection)
- */
- @Override
- public void setInput(IWorkbenchPart part, ISelection selection) {
- super.setInput(part, selection);
- Assert.isTrue(selection instanceof IStructuredSelection);
- Object input = ((IStructuredSelection) selection).getFirstElement();
- Assert.isTrue(input instanceof LaunchNode);
- ILaunchConfiguration node = ((LaunchNode)input).getLaunchConfiguration();
-
- IModelNode[] contexts = LaunchContextsPersistenceDelegate.getLaunchContexts(node);
- if (contexts != null && contexts.length > 0) {
- ILabelProvider labelProvider = (ILabelProvider)contexts[0].getAdapter(ILabelProvider.class);
- launchContextValue = labelProvider.getText(contexts[0]);
- if (labelProvider instanceof ILabelDecorator) {
- launchContextValue = ((ILabelDecorator)labelProvider).decorateText(launchContextValue, contexts[0]);
- }
- if (contexts.length > 1) {
- launchContextValue += ", ..."; //$NON-NLS-1$
- }
- }
- else {
- launchContextValue = ""; //$NON-NLS-1$
- }
- }
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#refresh()
- */
- @Override
- public void refresh() {
- if (launchContext != null) launchContext.setText(launchContextValue);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.tcf.te.ui.views.tabbed.BaseTitledSection#getText()
- */
- @Override
- protected String getText() {
- return Messages.ContextSelectorSection_title;
- }
-}
+/******************************************************************************* + * Copyright (c) 2011, 2014 Wind River Systems, Inc. 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: + * Wind River Systems - initial API and implementation + *******************************************************************************/ +package org.eclipse.tcf.te.launch.ui.internal.properties; + +import org.eclipse.core.runtime.Assert; +import org.eclipse.debug.core.ILaunchConfiguration; +import org.eclipse.jface.viewers.ILabelDecorator; +import org.eclipse.jface.viewers.ILabelProvider; +import org.eclipse.jface.viewers.ISelection; +import org.eclipse.jface.viewers.IStructuredSelection; +import org.eclipse.swt.widgets.Composite; +import org.eclipse.swt.widgets.Text; +import org.eclipse.tcf.te.launch.core.persistence.launchcontext.LaunchContextsPersistenceDelegate; +import org.eclipse.tcf.te.launch.ui.model.LaunchNode; +import org.eclipse.tcf.te.launch.ui.nls.Messages; +import org.eclipse.tcf.te.launch.ui.properties.BaseTitledSection; +import org.eclipse.tcf.te.runtime.model.interfaces.IModelNode; +import org.eclipse.ui.IWorkbenchPart; +import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage; + +/** + * The property section to display the properties of a launch configuration. + */ +public class LaunchContextPropertiesSection extends BaseTitledSection { + private String launchContextValue = ""; //$NON-NLS-1$ + + private Text launchContext; + + /* + * (non-Javadoc) + * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#createControls(org.eclipse.swt.widgets.Composite, org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage) + */ + @Override + public void createControls(Composite parent, TabbedPropertySheetPage aTabbedPropertySheetPage) { + super.createControls(parent, aTabbedPropertySheetPage); + + launchContext = createTextField(null, Messages.ContextSelectorSection_label); + } + + /* + * (non-Javadoc) + * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#setInput(org.eclipse.ui.IWorkbenchPart, org.eclipse.jface.viewers.ISelection) + */ + @Override + public void setInput(IWorkbenchPart part, ISelection selection) { + super.setInput(part, selection); + Assert.isTrue(selection instanceof IStructuredSelection); + Object input = ((IStructuredSelection) selection).getFirstElement(); + Assert.isTrue(input instanceof LaunchNode); + ILaunchConfiguration node = ((LaunchNode)input).getLaunchConfiguration(); + + IModelNode[] contexts = LaunchContextsPersistenceDelegate.getLaunchContexts(node); + if (contexts != null && contexts.length > 0) { + ILabelProvider labelProvider = (ILabelProvider)contexts[0].getAdapter(ILabelProvider.class); + launchContextValue = labelProvider.getText(contexts[0]); + if (labelProvider instanceof ILabelDecorator) { + launchContextValue = ((ILabelDecorator)labelProvider).decorateText(launchContextValue, contexts[0]); + } + if (contexts.length > 1) { + launchContextValue += ", ..."; //$NON-NLS-1$ + } + } + else { + launchContextValue = ""; //$NON-NLS-1$ + } + } + + /* + * (non-Javadoc) + * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#refresh() + */ + @Override + public void refresh() { + if (launchContext != null) launchContext.setText(launchContextValue); + } + + /* (non-Javadoc) + * @see org.eclipse.tcf.te.ui.views.tabbed.BaseTitledSection#getText() + */ + @Override + protected String getText() { + return Messages.ContextSelectorSection_title; + } +} diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/RefProjectsFilter.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/RefProjectsFilter.java index 47f36fc84..fc04832ea 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/RefProjectsFilter.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/RefProjectsFilter.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/RefProjectsPropertiesSection.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/RefProjectsPropertiesSection.java index 5c0c07dad..ee5901311 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/RefProjectsPropertiesSection.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/internal/properties/RefProjectsPropertiesSection.java @@ -1,132 +1,132 @@ -/*******************************************************************************
- * Copyright (c) 2012 Wind River Systems, Inc. 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:
- * Wind River Systems - initial API and implementation
- *******************************************************************************/
-package org.eclipse.tcf.te.launch.ui.internal.properties;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.List;
-
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.debug.core.ILaunchConfiguration;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.jface.viewers.ITableLabelProvider;
-import org.eclipse.jface.viewers.LabelProvider;
-import org.eclipse.jface.viewers.TableViewer;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.FormAttachment;
-import org.eclipse.swt.layout.FormData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Table;
-import org.eclipse.swt.widgets.TableColumn;
-import org.eclipse.tcf.te.launch.core.interfaces.IReferencedProjectItem;
-import org.eclipse.tcf.te.launch.core.persistence.projects.ReferencedProjectsPersistenceDelegate;
-import org.eclipse.tcf.te.launch.ui.model.LaunchNode;
-import org.eclipse.tcf.te.launch.ui.nls.Messages;
-import org.eclipse.tcf.te.launch.ui.properties.BaseTitledSection;
-import org.eclipse.tcf.te.launch.ui.tabs.refprojects.RefProjectsContentProvider;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.views.properties.tabbed.ITabbedPropertyConstants;
-import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage;
-
-/**
- * The property section to display the file transfer property of a launch configuration.
- */
-public class RefProjectsPropertiesSection extends BaseTitledSection {
-
- protected static class FileTransferLabelProvider extends LabelProvider implements ITableLabelProvider {
- /* (non-Javadoc)
- * @see org.eclipse.jface.viewers.ITableLabelProvider#getColumnImage(java.lang.Object, int)
- */
- @Override
- public Image getColumnImage(Object element, int columnIndex) {
- return null;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.jface.viewers.ITableLabelProvider#getColumnText(java.lang.Object, int)
- */
- @Override
- public String getColumnText(Object element, int columnIndex) {
- switch (columnIndex) {
- case 0:
- return ((IReferencedProjectItem)element).getProjectName();
- }
- return ""; //$NON-NLS-1$
- }
- }
-
- private IReferencedProjectItem[] items;
- // The table control to display the properties.
- private TableViewer viewer;
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#createControls(org.eclipse.swt.widgets.Composite, org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage)
- */
- @Override
- public void createControls(Composite parent, TabbedPropertySheetPage aTabbedPropertySheetPage) {
- super.createControls(parent, aTabbedPropertySheetPage);
-
- Table table = getWidgetFactory().createTable(composite, SWT.FULL_SELECTION | SWT.MULTI | SWT.BORDER);
- FormData data = new FormData();
- data.left = new FormAttachment(0, 0);
- data.right = new FormAttachment(100, 0);
- data.top = new FormAttachment(0, ITabbedPropertyConstants.VSPACE);
- data.bottom = new FormAttachment(100, -ITabbedPropertyConstants.VSPACE);
- table.setLayoutData(data);
- TableColumn column = new TableColumn(table, SWT.LEFT);
- column.setText(Messages.ReferencedProjectsSection_name_column);
- column.setWidth(200);
- table.setHeaderVisible(true);
- table.setLinesVisible(true);
- viewer = new TableViewer(table);
- viewer.setContentProvider(new RefProjectsContentProvider());
- viewer.setLabelProvider(new FileTransferLabelProvider());
- }
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#setInput(org.eclipse.ui.IWorkbenchPart, org.eclipse.jface.viewers.ISelection)
- */
- @Override
- public void setInput(IWorkbenchPart part, ISelection selection) {
- super.setInput(part, selection);
- Assert.isTrue(selection instanceof IStructuredSelection);
- Object input = ((IStructuredSelection) selection).getFirstElement();
- Assert.isTrue(input instanceof LaunchNode);
- ILaunchConfiguration node = ((LaunchNode)input).getLaunchConfiguration();
- List<IReferencedProjectItem> list = new ArrayList<IReferencedProjectItem>();
- for (IReferencedProjectItem item : Arrays.asList(ReferencedProjectsPersistenceDelegate.getReferencedProjects(node))) {
- if (item.isEnabled()) {
- list.add(item);
- }
- }
- items = list.toArray(new IReferencedProjectItem[list.size()]);
- }
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#refresh()
- */
- @Override
- public void refresh() {
- if (viewer != null) viewer.setInput(items);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.tcf.te.ui.views.tabbed.BaseTitledSection#getText()
- */
- @Override
- protected String getText() {
- return Messages.ReferencedProjectsSection_title;
- }
-}
+/******************************************************************************* + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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: + * Wind River Systems - initial API and implementation + *******************************************************************************/ +package org.eclipse.tcf.te.launch.ui.internal.properties; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; + +import org.eclipse.core.runtime.Assert; +import org.eclipse.debug.core.ILaunchConfiguration; +import org.eclipse.jface.viewers.ISelection; +import org.eclipse.jface.viewers.IStructuredSelection; +import org.eclipse.jface.viewers.ITableLabelProvider; +import org.eclipse.jface.viewers.LabelProvider; +import org.eclipse.jface.viewers.TableViewer; +import org.eclipse.swt.SWT; +import org.eclipse.swt.graphics.Image; +import org.eclipse.swt.layout.FormAttachment; +import org.eclipse.swt.layout.FormData; +import org.eclipse.swt.widgets.Composite; +import org.eclipse.swt.widgets.Table; +import org.eclipse.swt.widgets.TableColumn; +import org.eclipse.tcf.te.launch.core.interfaces.IReferencedProjectItem; +import org.eclipse.tcf.te.launch.core.persistence.projects.ReferencedProjectsPersistenceDelegate; +import org.eclipse.tcf.te.launch.ui.model.LaunchNode; +import org.eclipse.tcf.te.launch.ui.nls.Messages; +import org.eclipse.tcf.te.launch.ui.properties.BaseTitledSection; +import org.eclipse.tcf.te.launch.ui.tabs.refprojects.RefProjectsContentProvider; +import org.eclipse.ui.IWorkbenchPart; +import org.eclipse.ui.views.properties.tabbed.ITabbedPropertyConstants; +import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage; + +/** + * The property section to display the file transfer property of a launch configuration. + */ +public class RefProjectsPropertiesSection extends BaseTitledSection { + + protected static class FileTransferLabelProvider extends LabelProvider implements ITableLabelProvider { + /* (non-Javadoc) + * @see org.eclipse.jface.viewers.ITableLabelProvider#getColumnImage(java.lang.Object, int) + */ + @Override + public Image getColumnImage(Object element, int columnIndex) { + return null; + } + + /* (non-Javadoc) + * @see org.eclipse.jface.viewers.ITableLabelProvider#getColumnText(java.lang.Object, int) + */ + @Override + public String getColumnText(Object element, int columnIndex) { + switch (columnIndex) { + case 0: + return ((IReferencedProjectItem)element).getProjectName(); + } + return ""; //$NON-NLS-1$ + } + } + + private IReferencedProjectItem[] items; + // The table control to display the properties. + private TableViewer viewer; + + /* + * (non-Javadoc) + * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#createControls(org.eclipse.swt.widgets.Composite, org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage) + */ + @Override + public void createControls(Composite parent, TabbedPropertySheetPage aTabbedPropertySheetPage) { + super.createControls(parent, aTabbedPropertySheetPage); + + Table table = getWidgetFactory().createTable(composite, SWT.FULL_SELECTION | SWT.MULTI | SWT.BORDER); + FormData data = new FormData(); + data.left = new FormAttachment(0, 0); + data.right = new FormAttachment(100, 0); + data.top = new FormAttachment(0, ITabbedPropertyConstants.VSPACE); + data.bottom = new FormAttachment(100, -ITabbedPropertyConstants.VSPACE); + table.setLayoutData(data); + TableColumn column = new TableColumn(table, SWT.LEFT); + column.setText(Messages.ReferencedProjectsSection_name_column); + column.setWidth(200); + table.setHeaderVisible(true); + table.setLinesVisible(true); + viewer = new TableViewer(table); + viewer.setContentProvider(new RefProjectsContentProvider()); + viewer.setLabelProvider(new FileTransferLabelProvider()); + } + + /* + * (non-Javadoc) + * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#setInput(org.eclipse.ui.IWorkbenchPart, org.eclipse.jface.viewers.ISelection) + */ + @Override + public void setInput(IWorkbenchPart part, ISelection selection) { + super.setInput(part, selection); + Assert.isTrue(selection instanceof IStructuredSelection); + Object input = ((IStructuredSelection) selection).getFirstElement(); + Assert.isTrue(input instanceof LaunchNode); + ILaunchConfiguration node = ((LaunchNode)input).getLaunchConfiguration(); + List<IReferencedProjectItem> list = new ArrayList<IReferencedProjectItem>(); + for (IReferencedProjectItem item : Arrays.asList(ReferencedProjectsPersistenceDelegate.getReferencedProjects(node))) { + if (item.isEnabled()) { + list.add(item); + } + } + items = list.toArray(new IReferencedProjectItem[list.size()]); + } + + /* + * (non-Javadoc) + * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#refresh() + */ + @Override + public void refresh() { + if (viewer != null) viewer.setInput(items); + } + + /* (non-Javadoc) + * @see org.eclipse.tcf.te.ui.views.tabbed.BaseTitledSection#getText() + */ + @Override + protected String getText() { + return Messages.ReferencedProjectsSection_title; + } +} diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/model/LaunchModel.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/model/LaunchModel.java index c3e1bd789..32bf37e96 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/model/LaunchModel.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/model/LaunchModel.java @@ -1,307 +1,307 @@ -/*******************************************************************************
- * Copyright (c) 2012 Wind River Systems, Inc. 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:
- * Wind River Systems - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tcf.te.launch.ui.model;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.EventObject;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-import org.eclipse.core.resources.IProject;
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.debug.core.DebugPlugin;
-import org.eclipse.debug.core.ILaunchConfiguration;
-import org.eclipse.debug.core.ILaunchConfigurationListener;
-import org.eclipse.debug.core.ILaunchConfigurationType;
-import org.eclipse.tcf.te.launch.core.bindings.LaunchConfigTypeBindingsManager;
-import org.eclipse.tcf.te.launch.core.interfaces.IReferencedProjectItem;
-import org.eclipse.tcf.te.launch.core.lm.interfaces.ICommonLaunchAttributes;
-import org.eclipse.tcf.te.launch.core.persistence.DefaultPersistenceDelegate;
-import org.eclipse.tcf.te.launch.core.persistence.launchcontext.LaunchContextsPersistenceDelegate;
-import org.eclipse.tcf.te.launch.core.persistence.projects.ReferencedProjectItem;
-import org.eclipse.tcf.te.launch.core.persistence.projects.ReferencedProjectsPersistenceDelegate;
-import org.eclipse.tcf.te.launch.core.selection.LaunchSelection;
-import org.eclipse.tcf.te.launch.core.selection.ProjectSelectionContext;
-import org.eclipse.tcf.te.launch.core.selection.RemoteSelectionContext;
-import org.eclipse.tcf.te.runtime.events.ChangeEvent;
-import org.eclipse.tcf.te.runtime.events.EventManager;
-import org.eclipse.tcf.te.runtime.interfaces.events.IEventListener;
-import org.eclipse.tcf.te.runtime.model.interfaces.IContainerModelNode;
-import org.eclipse.tcf.te.runtime.model.interfaces.IModelNode;
-import org.eclipse.tcf.te.ui.views.Managers;
-import org.eclipse.tcf.te.ui.views.interfaces.ICategory;
-
-/**
- * LaunchModel
- */
-public final class LaunchModel implements IEventListener, ILaunchConfigurationListener {
-
- private static final Map<Object,LaunchModel> models = new HashMap<Object, LaunchModel>();
- private static final Map<String,String> nameToUUID = new HashMap<String, String>();
-
- /**
- * Get the launch model of the rootNode.
- * If it does not exist yet, create a new instance and store it.
- *
- * @param rootNode The rootNode of the model.
- * @return The launch model.
- */
- public static LaunchModel getLaunchModel(final Object modelRoot) {
- if (modelRoot instanceof ICategory || modelRoot instanceof IModelNode || modelRoot instanceof IProject) {
- LaunchModel model = models.get(modelRoot);
- if (model == null) {
- model = new LaunchModel(modelRoot);
- models.put(modelRoot, model);
- }
- return model;
- }
- return null;
- }
-
- private final LaunchNode rootNode;
- private final Object modelRoot;
-
- private String lastAddedUUID = null;
-
- /**
- * Constructor.
- */
- private LaunchModel(Object modelRoot) {
- Assert.isNotNull(modelRoot);
- this.modelRoot = modelRoot;
- rootNode = new LaunchNode(this);
- refresh();
- DebugPlugin.getDefault().getLaunchManager().addLaunchConfigurationListener(this);
-
- if (modelRoot instanceof ICategory) {
- EventManager.getInstance().addEventListener(this, ChangeEvent.class);
- }
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.debug.core.ILaunchConfigurationListener#launchConfigurationRemoved(org.eclipse.debug.core.ILaunchConfiguration)
- */
- @Override
- public void launchConfigurationRemoved(ILaunchConfiguration configuration) {
- if (!configuration.isWorkingCopy()) {
- if (getModelRoot() instanceof ICategory) {
- if (!getCategoryId(configuration).equals(lastAddedUUID)) {
- Managers.getCategoryManager().remove(((ICategory)getModelRoot()).getId(), getCategoryId(configuration));
- }
- nameToUUID.remove(configuration.getName());
- lastAddedUUID = null;
- }
- if (refresh()) {
- EventManager.getInstance().fireEvent(new ChangeEvent(this, ChangeEvent.ID_REMOVED, null, null));
- }
- }
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.debug.core.ILaunchConfigurationListener#launchConfigurationChanged(org.eclipse.debug.core.ILaunchConfiguration)
- */
- @Override
- public void launchConfigurationChanged(ILaunchConfiguration configuration) {
- if (!configuration.isWorkingCopy()) {
- refresh();
- EventManager.getInstance().fireEvent(new ChangeEvent(this, ChangeEvent.ID_CHANGED, null, null));
- }
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.debug.core.ILaunchConfigurationListener#launchConfigurationAdded(org.eclipse.debug.core.ILaunchConfiguration)
- */
- @Override
- public void launchConfigurationAdded(ILaunchConfiguration configuration) {
- if (!configuration.isWorkingCopy()) {
- if (getModelRoot() instanceof ICategory) {
- if (Managers.getCategoryManager().belongsTo(((ICategory)getModelRoot()).getId(), getCategoryId(configuration))) {
- lastAddedUUID = getCategoryId(configuration);
- }
- }
- if (refresh()) {
- EventManager.getInstance().fireEvent(new ChangeEvent(this, ChangeEvent.ID_ADDED, null, null));
- }
- }
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.tcf.te.runtime.interfaces.events.IEventListener#eventFired(java.util.EventObject)
- */
- @Override
- public void eventFired(EventObject event) {
- if (event instanceof ChangeEvent) {
- ChangeEvent e = (ChangeEvent)event;
- if (e.getSource() instanceof ICategory &&
- ((e.getNewValue() instanceof String && ((String)e.getNewValue()).startsWith(LaunchNode.class.getName())) ||
- (e.getOldValue() instanceof String && ((String)e.getOldValue()).startsWith(LaunchNode.class.getName())))) {
- if (refresh()) {
- EventManager.getInstance().fireEvent(new ChangeEvent(this, ((ChangeEvent)event).getEventId(), null, null));
- }
- }
- }
- }
-
- /**
- * Return the root node of the model tree.
- */
- public LaunchNode getRootNode() {
- return rootNode;
- }
-
- /**
- * Return the model root (IModelNode, IProject, ICategory).
- */
- public Object getModelRoot() {
- return modelRoot;
- }
-
- /**
- * Refresh the model.
- * @return <code>true</code> if the model has changed.
- */
- public boolean refresh() {
- boolean changed = false;
- Object parent = rootNode.getModel().getModelRoot();
- String[] typeIds = new String[0];
- if (parent instanceof ICategory) {
- List<String> ids = new ArrayList<String>();
- for (ILaunchConfigurationType type : DebugPlugin.getDefault().getLaunchManager().getLaunchConfigurationTypes()) {
- ids.add(type.getIdentifier());
- }
- typeIds = ids.toArray(new String[ids.size()]);
- }
- if (parent instanceof IProject) {
- typeIds = LaunchConfigTypeBindingsManager.getInstance().getValidLaunchConfigTypes(
- new LaunchSelection(null, new ProjectSelectionContext((IProject)parent, true)));
- }
- else if (parent instanceof IModelNode) {
- typeIds = LaunchConfigTypeBindingsManager.getInstance().getValidLaunchConfigTypes(
- new LaunchSelection(null, new RemoteSelectionContext((IModelNode)parent, true)));
- }
- List<IModelNode> typeNodes = new ArrayList<IModelNode>(Arrays.asList(rootNode.getChildren()));
- for (String typeId : typeIds) {
- ILaunchConfigurationType type = DebugPlugin.getDefault().getLaunchManager().getLaunchConfigurationType(typeId);
- if (type.isPublic()) {
- IModelNode typeNode = find(type, typeNodes);
- if (typeNode != null) {
- typeNodes.remove(typeNode);
- }
- else {
- typeNode = new LaunchNode(type);
- rootNode.add(typeNode);
- changed = true;
- }
-
- ILaunchConfiguration[] configs;
- try {
- configs = DebugPlugin.getDefault().getLaunchManager().getLaunchConfigurations(type);
- }
- catch (Exception e) {
- configs = new ILaunchConfiguration[0];
- }
-
- List<IModelNode> configNodes = new ArrayList<IModelNode>(Arrays.asList(((IContainerModelNode)typeNode).getChildren()));
- for (ILaunchConfiguration config : configs) {
- if (parent instanceof ICategory) {
- if (Managers.getCategoryManager().belongsTo(((ICategory)parent).getId(), getCategoryId(config))) {
- changed |= checkAndAdd(config, (IContainerModelNode)typeNode, configNodes);
- }
- }
- else if (parent instanceof IModelNode) {
- IModelNode[] contexts = LaunchContextsPersistenceDelegate.getLaunchContexts(config);
- if (contexts != null && Arrays.asList(contexts).contains(parent)) {
- changed |= checkAndAdd(config, (IContainerModelNode)typeNode, configNodes);
- }
- }
- else if (parent instanceof IProject) {
- IReferencedProjectItem[] projects = ReferencedProjectsPersistenceDelegate.getReferencedProjects(config);
- IReferencedProjectItem project = new ReferencedProjectItem();
- project.setProperty(IReferencedProjectItem.PROPERTY_PROJECT_NAME, ((IProject)parent).getName());
- if (projects != null && Arrays.asList(projects).contains(project)) {
- changed |= checkAndAdd(config, (IContainerModelNode)typeNode, configNodes);
- }
- }
- }
- for (IModelNode configToDelete : configNodes) {
- ((IContainerModelNode)typeNode).remove(configToDelete, true);
- changed = true;
- }
- if (parent instanceof ICategory && typeNode.isEmpty()) {
- typeNodes.add(typeNode);
- }
- }
- }
- for (IModelNode typeToDelete : typeNodes) {
- rootNode.remove(typeToDelete, true);
- changed = true;
- }
- return changed;
- }
-
- private boolean checkAndAdd(ILaunchConfiguration config, IContainerModelNode typeNode, List<IModelNode> configNodes) {
- IModelNode configNode = find(config, configNodes);
- if (configNode != null) {
- configNodes.remove(configNode);
- }
- else {
- configNode = new LaunchNode(config);
- typeNode.add(configNode);
- return true;
- }
- return false;
- }
-
- private IModelNode find(ILaunchConfiguration config, List<IModelNode> list) {
- for (IModelNode candidate : list) {
- if (candidate instanceof LaunchNode) {
- LaunchNode node = new LaunchNode(config);
- node.setProperty(LaunchNode.PROPERTY_MODEL, this);
- if (((LaunchNode)candidate).equals(node)) {
- return candidate;
- }
- }
- }
- return null;
- }
-
- private IModelNode find(ILaunchConfigurationType type, List<IModelNode> list) {
- for (IModelNode candidate : list) {
- if (candidate instanceof LaunchNode) {
- LaunchNode node = new LaunchNode(type);
- node.setProperty(LaunchNode.PROPERTY_MODEL, this);
- if (((LaunchNode)candidate).equals(node)) {
- return candidate;
- }
- }
- }
- return null;
- }
-
- /**
- * Get the unique category id for this launch config.
- * @param config The launch configuration.
- * @return The unique category id.
- */
- public static String getCategoryId(ILaunchConfiguration config) {
- String uuid = DefaultPersistenceDelegate.getAttribute(config, ICommonLaunchAttributes.ATTR_UUID, (String)null);
- if (uuid == null) {
- uuid = nameToUUID.get(config.getName());
- }
- if (uuid != null && !nameToUUID.containsKey(config.getName())) {
- nameToUUID.put(config.getName(), uuid);
- }
-
- return LaunchNode.class.getName() + "." + (uuid != null ? uuid : config.getName()); //$NON-NLS-1$
- }
-}
+/******************************************************************************* + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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: + * Wind River Systems - initial API and implementation + *******************************************************************************/ + +package org.eclipse.tcf.te.launch.ui.model; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.EventObject; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + +import org.eclipse.core.resources.IProject; +import org.eclipse.core.runtime.Assert; +import org.eclipse.debug.core.DebugPlugin; +import org.eclipse.debug.core.ILaunchConfiguration; +import org.eclipse.debug.core.ILaunchConfigurationListener; +import org.eclipse.debug.core.ILaunchConfigurationType; +import org.eclipse.tcf.te.launch.core.bindings.LaunchConfigTypeBindingsManager; +import org.eclipse.tcf.te.launch.core.interfaces.IReferencedProjectItem; +import org.eclipse.tcf.te.launch.core.lm.interfaces.ICommonLaunchAttributes; +import org.eclipse.tcf.te.launch.core.persistence.DefaultPersistenceDelegate; +import org.eclipse.tcf.te.launch.core.persistence.launchcontext.LaunchContextsPersistenceDelegate; +import org.eclipse.tcf.te.launch.core.persistence.projects.ReferencedProjectItem; +import org.eclipse.tcf.te.launch.core.persistence.projects.ReferencedProjectsPersistenceDelegate; +import org.eclipse.tcf.te.launch.core.selection.LaunchSelection; +import org.eclipse.tcf.te.launch.core.selection.ProjectSelectionContext; +import org.eclipse.tcf.te.launch.core.selection.RemoteSelectionContext; +import org.eclipse.tcf.te.runtime.events.ChangeEvent; +import org.eclipse.tcf.te.runtime.events.EventManager; +import org.eclipse.tcf.te.runtime.interfaces.events.IEventListener; +import org.eclipse.tcf.te.runtime.model.interfaces.IContainerModelNode; +import org.eclipse.tcf.te.runtime.model.interfaces.IModelNode; +import org.eclipse.tcf.te.ui.views.Managers; +import org.eclipse.tcf.te.ui.views.interfaces.ICategory; + +/** + * LaunchModel + */ +public final class LaunchModel implements IEventListener, ILaunchConfigurationListener { + + private static final Map<Object,LaunchModel> models = new HashMap<Object, LaunchModel>(); + private static final Map<String,String> nameToUUID = new HashMap<String, String>(); + + /** + * Get the launch model of the rootNode. + * If it does not exist yet, create a new instance and store it. + * + * @param rootNode The rootNode of the model. + * @return The launch model. + */ + public static LaunchModel getLaunchModel(final Object modelRoot) { + if (modelRoot instanceof ICategory || modelRoot instanceof IModelNode || modelRoot instanceof IProject) { + LaunchModel model = models.get(modelRoot); + if (model == null) { + model = new LaunchModel(modelRoot); + models.put(modelRoot, model); + } + return model; + } + return null; + } + + private final LaunchNode rootNode; + private final Object modelRoot; + + private String lastAddedUUID = null; + + /** + * Constructor. + */ + private LaunchModel(Object modelRoot) { + Assert.isNotNull(modelRoot); + this.modelRoot = modelRoot; + rootNode = new LaunchNode(this); + refresh(); + DebugPlugin.getDefault().getLaunchManager().addLaunchConfigurationListener(this); + + if (modelRoot instanceof ICategory) { + EventManager.getInstance().addEventListener(this, ChangeEvent.class); + } + } + + /* (non-Javadoc) + * @see org.eclipse.debug.core.ILaunchConfigurationListener#launchConfigurationRemoved(org.eclipse.debug.core.ILaunchConfiguration) + */ + @Override + public void launchConfigurationRemoved(ILaunchConfiguration configuration) { + if (!configuration.isWorkingCopy()) { + if (getModelRoot() instanceof ICategory) { + if (!getCategoryId(configuration).equals(lastAddedUUID)) { + Managers.getCategoryManager().remove(((ICategory)getModelRoot()).getId(), getCategoryId(configuration)); + } + nameToUUID.remove(configuration.getName()); + lastAddedUUID = null; + } + if (refresh()) { + EventManager.getInstance().fireEvent(new ChangeEvent(this, ChangeEvent.ID_REMOVED, null, null)); + } + } + } + + /* (non-Javadoc) + * @see org.eclipse.debug.core.ILaunchConfigurationListener#launchConfigurationChanged(org.eclipse.debug.core.ILaunchConfiguration) + */ + @Override + public void launchConfigurationChanged(ILaunchConfiguration configuration) { + if (!configuration.isWorkingCopy()) { + refresh(); + EventManager.getInstance().fireEvent(new ChangeEvent(this, ChangeEvent.ID_CHANGED, null, null)); + } + } + + /* (non-Javadoc) + * @see org.eclipse.debug.core.ILaunchConfigurationListener#launchConfigurationAdded(org.eclipse.debug.core.ILaunchConfiguration) + */ + @Override + public void launchConfigurationAdded(ILaunchConfiguration configuration) { + if (!configuration.isWorkingCopy()) { + if (getModelRoot() instanceof ICategory) { + if (Managers.getCategoryManager().belongsTo(((ICategory)getModelRoot()).getId(), getCategoryId(configuration))) { + lastAddedUUID = getCategoryId(configuration); + } + } + if (refresh()) { + EventManager.getInstance().fireEvent(new ChangeEvent(this, ChangeEvent.ID_ADDED, null, null)); + } + } + } + + /* (non-Javadoc) + * @see org.eclipse.tcf.te.runtime.interfaces.events.IEventListener#eventFired(java.util.EventObject) + */ + @Override + public void eventFired(EventObject event) { + if (event instanceof ChangeEvent) { + ChangeEvent e = (ChangeEvent)event; + if (e.getSource() instanceof ICategory && + ((e.getNewValue() instanceof String && ((String)e.getNewValue()).startsWith(LaunchNode.class.getName())) || + (e.getOldValue() instanceof String && ((String)e.getOldValue()).startsWith(LaunchNode.class.getName())))) { + if (refresh()) { + EventManager.getInstance().fireEvent(new ChangeEvent(this, ((ChangeEvent)event).getEventId(), null, null)); + } + } + } + } + + /** + * Return the root node of the model tree. + */ + public LaunchNode getRootNode() { + return rootNode; + } + + /** + * Return the model root (IModelNode, IProject, ICategory). + */ + public Object getModelRoot() { + return modelRoot; + } + + /** + * Refresh the model. + * @return <code>true</code> if the model has changed. + */ + public boolean refresh() { + boolean changed = false; + Object parent = rootNode.getModel().getModelRoot(); + String[] typeIds = new String[0]; + if (parent instanceof ICategory) { + List<String> ids = new ArrayList<String>(); + for (ILaunchConfigurationType type : DebugPlugin.getDefault().getLaunchManager().getLaunchConfigurationTypes()) { + ids.add(type.getIdentifier()); + } + typeIds = ids.toArray(new String[ids.size()]); + } + if (parent instanceof IProject) { + typeIds = LaunchConfigTypeBindingsManager.getInstance().getValidLaunchConfigTypes( + new LaunchSelection(null, new ProjectSelectionContext((IProject)parent, true))); + } + else if (parent instanceof IModelNode) { + typeIds = LaunchConfigTypeBindingsManager.getInstance().getValidLaunchConfigTypes( + new LaunchSelection(null, new RemoteSelectionContext((IModelNode)parent, true))); + } + List<IModelNode> typeNodes = new ArrayList<IModelNode>(Arrays.asList(rootNode.getChildren())); + for (String typeId : typeIds) { + ILaunchConfigurationType type = DebugPlugin.getDefault().getLaunchManager().getLaunchConfigurationType(typeId); + if (type.isPublic()) { + IModelNode typeNode = find(type, typeNodes); + if (typeNode != null) { + typeNodes.remove(typeNode); + } + else { + typeNode = new LaunchNode(type); + rootNode.add(typeNode); + changed = true; + } + + ILaunchConfiguration[] configs; + try { + configs = DebugPlugin.getDefault().getLaunchManager().getLaunchConfigurations(type); + } + catch (Exception e) { + configs = new ILaunchConfiguration[0]; + } + + List<IModelNode> configNodes = new ArrayList<IModelNode>(Arrays.asList(((IContainerModelNode)typeNode).getChildren())); + for (ILaunchConfiguration config : configs) { + if (parent instanceof ICategory) { + if (Managers.getCategoryManager().belongsTo(((ICategory)parent).getId(), getCategoryId(config))) { + changed |= checkAndAdd(config, (IContainerModelNode)typeNode, configNodes); + } + } + else if (parent instanceof IModelNode) { + IModelNode[] contexts = LaunchContextsPersistenceDelegate.getLaunchContexts(config); + if (contexts != null && Arrays.asList(contexts).contains(parent)) { + changed |= checkAndAdd(config, (IContainerModelNode)typeNode, configNodes); + } + } + else if (parent instanceof IProject) { + IReferencedProjectItem[] projects = ReferencedProjectsPersistenceDelegate.getReferencedProjects(config); + IReferencedProjectItem project = new ReferencedProjectItem(); + project.setProperty(IReferencedProjectItem.PROPERTY_PROJECT_NAME, ((IProject)parent).getName()); + if (projects != null && Arrays.asList(projects).contains(project)) { + changed |= checkAndAdd(config, (IContainerModelNode)typeNode, configNodes); + } + } + } + for (IModelNode configToDelete : configNodes) { + ((IContainerModelNode)typeNode).remove(configToDelete, true); + changed = true; + } + if (parent instanceof ICategory && typeNode.isEmpty()) { + typeNodes.add(typeNode); + } + } + } + for (IModelNode typeToDelete : typeNodes) { + rootNode.remove(typeToDelete, true); + changed = true; + } + return changed; + } + + private boolean checkAndAdd(ILaunchConfiguration config, IContainerModelNode typeNode, List<IModelNode> configNodes) { + IModelNode configNode = find(config, configNodes); + if (configNode != null) { + configNodes.remove(configNode); + } + else { + configNode = new LaunchNode(config); + typeNode.add(configNode); + return true; + } + return false; + } + + private IModelNode find(ILaunchConfiguration config, List<IModelNode> list) { + for (IModelNode candidate : list) { + if (candidate instanceof LaunchNode) { + LaunchNode node = new LaunchNode(config); + node.setProperty(LaunchNode.PROPERTY_MODEL, this); + if (((LaunchNode)candidate).equals(node)) { + return candidate; + } + } + } + return null; + } + + private IModelNode find(ILaunchConfigurationType type, List<IModelNode> list) { + for (IModelNode candidate : list) { + if (candidate instanceof LaunchNode) { + LaunchNode node = new LaunchNode(type); + node.setProperty(LaunchNode.PROPERTY_MODEL, this); + if (((LaunchNode)candidate).equals(node)) { + return candidate; + } + } + } + return null; + } + + /** + * Get the unique category id for this launch config. + * @param config The launch configuration. + * @return The unique category id. + */ + public static String getCategoryId(ILaunchConfiguration config) { + String uuid = DefaultPersistenceDelegate.getAttribute(config, ICommonLaunchAttributes.ATTR_UUID, (String)null); + if (uuid == null) { + uuid = nameToUUID.get(config.getName()); + } + if (uuid != null && !nameToUUID.containsKey(config.getName())) { + nameToUUID.put(config.getName(), uuid); + } + + return LaunchNode.class.getName() + "." + (uuid != null ? uuid : config.getName()); //$NON-NLS-1$ + } +} diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/model/LaunchNode.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/model/LaunchNode.java index 64751e6da..11bd5e623 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/model/LaunchNode.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/model/LaunchNode.java @@ -1,187 +1,187 @@ -/*******************************************************************************
- * Copyright (c) 2012 Wind River Systems, Inc. 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:
- * Wind River Systems - initial API and implementation
- *******************************************************************************/
-
-package org.eclipse.tcf.te.launch.ui.model;
-
-import java.util.ArrayList;
-import java.util.Arrays;
-import java.util.List;
-
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.debug.core.ILaunchConfiguration;
-import org.eclipse.debug.core.ILaunchConfigurationType;
-import org.eclipse.tcf.te.launch.core.lm.LaunchConfigHelper;
-import org.eclipse.tcf.te.launch.core.lm.LaunchManager;
-import org.eclipse.tcf.te.launch.core.lm.interfaces.ILaunchManagerDelegate;
-import org.eclipse.tcf.te.runtime.model.ContainerModelNode;
-import org.eclipse.tcf.te.runtime.model.interfaces.IModelNode;
-
-/**
- * LaunchNode
- */
-public class LaunchNode extends ContainerModelNode {
-
- public static final String TYPE_ROOT = "root"; //$NON-NLS-1$
- public static final String TYPE_LAUNCH_CONFIG_TYPE = "launchConfigType"; //$NON-NLS-1$
- public static final String TYPE_LAUNCH_CONFIG = "launchConfig"; //$NON-NLS-1$
-
- protected static final String PROPERTY_LAUNCH_CONFIG_TYPE = TYPE_LAUNCH_CONFIG_TYPE;
- protected static final String PROPERTY_LAUNCH_CONFIG = TYPE_LAUNCH_CONFIG;
- protected static final String PROPERTY_MODEL = "model"; //$NON-NLS-1$
-
- private LaunchNode(String type) {
- super();
- setProperty(IModelNode.PROPERTY_TYPE, type);
- }
-
- public LaunchNode(LaunchModel model) {
- this(TYPE_ROOT);
- setProperty(PROPERTY_MODEL, model);
- }
-
- public LaunchNode(ILaunchConfiguration config) {
- this(TYPE_LAUNCH_CONFIG);
- setProperty(PROPERTY_LAUNCH_CONFIG, config);
- }
-
- public LaunchNode(ILaunchConfigurationType configType) {
- this(TYPE_LAUNCH_CONFIG_TYPE);
- setProperty(PROPERTY_LAUNCH_CONFIG_TYPE, configType);
- }
-
- public boolean isType(String type) {
- return type.equals(getStringProperty(IModelNode.PROPERTY_TYPE));
- }
-
- /**
- * Return the model for this node. Must not be <code>null</code>.
- */
- public LaunchModel getModel() {
- LaunchModel model = (LaunchModel)getProperty(PROPERTY_MODEL);
- IModelNode parent = getParent();
-
- while (model == null && parent != null) {
- model = (LaunchModel)parent.getProperty(PROPERTY_MODEL);
- parent = parent.getParent();
- }
-
- Assert.isNotNull(model);
- return model;
- }
-
- /**
- * Return the launch confuration for this node or <code>null</code>.
- */
- public ILaunchConfiguration getLaunchConfiguration() {
- return (ILaunchConfiguration)getProperty(PROPERTY_LAUNCH_CONFIG);
- }
-
- /**
- * Return the launch configuration type for this launch node or <code>null</code>.
- */
- public ILaunchConfigurationType getLaunchConfigurationType() {
- if (getLaunchConfiguration() != null) {
- try {
- return getLaunchConfiguration().getType();
- }
- catch (Exception e) {
- }
- }
- else if (isType(TYPE_LAUNCH_CONFIG)) {
- return ((LaunchNode)getParent()).getLaunchConfigurationType();
- }
- return (ILaunchConfigurationType)getProperty(PROPERTY_LAUNCH_CONFIG_TYPE);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.tcf.te.runtime.model.ModelNode#getName()
- */
- @Override
- public String getName() {
- if (isType(TYPE_ROOT)) {
- return "Launches"; //$NON-NLS-1$
- }
- else if (isType(TYPE_LAUNCH_CONFIG_TYPE)) {
- return getLaunchConfigurationType().getName();
- }
- else if (isType(TYPE_LAUNCH_CONFIG)) {
- return getLaunchConfiguration().getName();
- }
- return super.getName();
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.tcf.te.runtime.properties.PropertiesContainer#hashCode()
- */
- @Override
- public int hashCode() {
- if (isType(TYPE_LAUNCH_CONFIG_TYPE) && getLaunchConfigurationType() != null) {
- return getLaunchConfigurationType().hashCode();
- }
- else if (isType(TYPE_LAUNCH_CONFIG) && getLaunchConfiguration() != null) {
- return getLaunchConfiguration().hashCode();
- }
- return super.hashCode();
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.tcf.te.runtime.properties.PropertiesContainer#equals(java.lang.Object)
- */
- @Override
- public boolean equals(Object obj) {
- if (obj instanceof LaunchNode && isType(((LaunchNode)obj).getStringProperty(PROPERTY_TYPE))) {
- if (getModel().getModelRoot().equals(((LaunchNode)obj).getModel().getModelRoot())) {
- if (isType(TYPE_LAUNCH_CONFIG_TYPE)) {
- return getLaunchConfigurationType().equals(((LaunchNode)obj).getLaunchConfigurationType());
- }
- else if (isType(TYPE_LAUNCH_CONFIG)) {
- return getLaunchConfiguration().equals(((LaunchNode)obj).getLaunchConfiguration());
- }
- }
- }
- return super.equals(obj);
- }
-
- /**
- * Check if the launch config node is valid for the given launch mode.
- * @param mode The launch mode or <code>null</code> to check for all supported modes;
- * @return <code>true</code> if the node is valid for the the given launch mode (or all supported modes if mode is <code>null</code>).
- */
- public boolean isValidFor(String mode) {
- if (isType(TYPE_LAUNCH_CONFIG)) {
- if (getLaunchConfigurationType() == null) {
- return false;
- }
- List<String> modes;
- if (mode != null && mode.trim().length() > 0) {
- modes = new ArrayList<String>();
- modes.add(mode);
- }
- else {
- modes = Arrays.asList(LaunchConfigHelper.getLaunchConfigTypeModes(getLaunchConfigurationType(), false));
- }
- for (String m : modes) {
- if (!getLaunchConfigurationType().supportsMode(m)) {
- return false;
- }
- ILaunchManagerDelegate delegate = LaunchManager.getInstance().getLaunchManagerDelegate(getLaunchConfigurationType(), m);
- if (delegate != null) {
- try {
- delegate.validate(mode, getLaunchConfiguration());
- }
- catch (Exception e) {
- return false;
- }
- }
- }
- }
- return true;
- }
-}
+/******************************************************************************* + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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: + * Wind River Systems - initial API and implementation + *******************************************************************************/ + +package org.eclipse.tcf.te.launch.ui.model; + +import java.util.ArrayList; +import java.util.Arrays; +import java.util.List; + +import org.eclipse.core.runtime.Assert; +import org.eclipse.debug.core.ILaunchConfiguration; +import org.eclipse.debug.core.ILaunchConfigurationType; +import org.eclipse.tcf.te.launch.core.lm.LaunchConfigHelper; +import org.eclipse.tcf.te.launch.core.lm.LaunchManager; +import org.eclipse.tcf.te.launch.core.lm.interfaces.ILaunchManagerDelegate; +import org.eclipse.tcf.te.runtime.model.ContainerModelNode; +import org.eclipse.tcf.te.runtime.model.interfaces.IModelNode; + +/** + * LaunchNode + */ +public class LaunchNode extends ContainerModelNode { + + public static final String TYPE_ROOT = "root"; //$NON-NLS-1$ + public static final String TYPE_LAUNCH_CONFIG_TYPE = "launchConfigType"; //$NON-NLS-1$ + public static final String TYPE_LAUNCH_CONFIG = "launchConfig"; //$NON-NLS-1$ + + protected static final String PROPERTY_LAUNCH_CONFIG_TYPE = TYPE_LAUNCH_CONFIG_TYPE; + protected static final String PROPERTY_LAUNCH_CONFIG = TYPE_LAUNCH_CONFIG; + protected static final String PROPERTY_MODEL = "model"; //$NON-NLS-1$ + + private LaunchNode(String type) { + super(); + setProperty(IModelNode.PROPERTY_TYPE, type); + } + + public LaunchNode(LaunchModel model) { + this(TYPE_ROOT); + setProperty(PROPERTY_MODEL, model); + } + + public LaunchNode(ILaunchConfiguration config) { + this(TYPE_LAUNCH_CONFIG); + setProperty(PROPERTY_LAUNCH_CONFIG, config); + } + + public LaunchNode(ILaunchConfigurationType configType) { + this(TYPE_LAUNCH_CONFIG_TYPE); + setProperty(PROPERTY_LAUNCH_CONFIG_TYPE, configType); + } + + public boolean isType(String type) { + return type.equals(getStringProperty(IModelNode.PROPERTY_TYPE)); + } + + /** + * Return the model for this node. Must not be <code>null</code>. + */ + public LaunchModel getModel() { + LaunchModel model = (LaunchModel)getProperty(PROPERTY_MODEL); + IModelNode parent = getParent(); + + while (model == null && parent != null) { + model = (LaunchModel)parent.getProperty(PROPERTY_MODEL); + parent = parent.getParent(); + } + + Assert.isNotNull(model); + return model; + } + + /** + * Return the launch confuration for this node or <code>null</code>. + */ + public ILaunchConfiguration getLaunchConfiguration() { + return (ILaunchConfiguration)getProperty(PROPERTY_LAUNCH_CONFIG); + } + + /** + * Return the launch configuration type for this launch node or <code>null</code>. + */ + public ILaunchConfigurationType getLaunchConfigurationType() { + if (getLaunchConfiguration() != null) { + try { + return getLaunchConfiguration().getType(); + } + catch (Exception e) { + } + } + else if (isType(TYPE_LAUNCH_CONFIG)) { + return ((LaunchNode)getParent()).getLaunchConfigurationType(); + } + return (ILaunchConfigurationType)getProperty(PROPERTY_LAUNCH_CONFIG_TYPE); + } + + /* (non-Javadoc) + * @see org.eclipse.tcf.te.runtime.model.ModelNode#getName() + */ + @Override + public String getName() { + if (isType(TYPE_ROOT)) { + return "Launches"; //$NON-NLS-1$ + } + else if (isType(TYPE_LAUNCH_CONFIG_TYPE)) { + return getLaunchConfigurationType().getName(); + } + else if (isType(TYPE_LAUNCH_CONFIG)) { + return getLaunchConfiguration().getName(); + } + return super.getName(); + } + + /* (non-Javadoc) + * @see org.eclipse.tcf.te.runtime.properties.PropertiesContainer#hashCode() + */ + @Override + public int hashCode() { + if (isType(TYPE_LAUNCH_CONFIG_TYPE) && getLaunchConfigurationType() != null) { + return getLaunchConfigurationType().hashCode(); + } + else if (isType(TYPE_LAUNCH_CONFIG) && getLaunchConfiguration() != null) { + return getLaunchConfiguration().hashCode(); + } + return super.hashCode(); + } + + /* (non-Javadoc) + * @see org.eclipse.tcf.te.runtime.properties.PropertiesContainer#equals(java.lang.Object) + */ + @Override + public boolean equals(Object obj) { + if (obj instanceof LaunchNode && isType(((LaunchNode)obj).getStringProperty(PROPERTY_TYPE))) { + if (getModel().getModelRoot().equals(((LaunchNode)obj).getModel().getModelRoot())) { + if (isType(TYPE_LAUNCH_CONFIG_TYPE)) { + return getLaunchConfigurationType().equals(((LaunchNode)obj).getLaunchConfigurationType()); + } + else if (isType(TYPE_LAUNCH_CONFIG)) { + return getLaunchConfiguration().equals(((LaunchNode)obj).getLaunchConfiguration()); + } + } + } + return super.equals(obj); + } + + /** + * Check if the launch config node is valid for the given launch mode. + * @param mode The launch mode or <code>null</code> to check for all supported modes; + * @return <code>true</code> if the node is valid for the the given launch mode (or all supported modes if mode is <code>null</code>). + */ + public boolean isValidFor(String mode) { + if (isType(TYPE_LAUNCH_CONFIG)) { + if (getLaunchConfigurationType() == null) { + return false; + } + List<String> modes; + if (mode != null && mode.trim().length() > 0) { + modes = new ArrayList<String>(); + modes.add(mode); + } + else { + modes = Arrays.asList(LaunchConfigHelper.getLaunchConfigTypeModes(getLaunchConfigurationType(), false)); + } + for (String m : modes) { + if (!getLaunchConfigurationType().supportsMode(m)) { + return false; + } + ILaunchManagerDelegate delegate = LaunchManager.getInstance().getLaunchManagerDelegate(getLaunchConfigurationType(), m); + if (delegate != null) { + try { + delegate.validate(mode, getLaunchConfiguration()); + } + catch (Exception e) { + return false; + } + } + } + } + return true; + } +} diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/nls/Messages.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/nls/Messages.java index 74b7ac194..f27007c4b 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/nls/Messages.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/nls/Messages.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2011, 2013 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2011, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/nls/Messages.properties b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/nls/Messages.properties index 4b3b01f31..ac63caac9 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/nls/Messages.properties +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/nls/Messages.properties @@ -1,5 +1,5 @@ ############################################################################### -# Copyright (c) 2012, 2013 Wind River Systems, Inc. and others. All rights reserved. +# Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/properties/BaseTitledSection.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/properties/BaseTitledSection.java index cefc0bb97..83126c43c 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/properties/BaseTitledSection.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/properties/BaseTitledSection.java @@ -1,256 +1,256 @@ -/*******************************************************************************
- * Copyright (c) 2011, 2012 Wind River Systems, Inc. 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:
- * Wind River Systems - initial API and implementation
- *******************************************************************************/
-package org.eclipse.tcf.te.launch.ui.properties;
-
-import java.beans.PropertyChangeEvent;
-import java.beans.PropertyChangeListener;
-
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.core.runtime.IAdaptable;
-import org.eclipse.jface.viewers.ISelection;
-import org.eclipse.jface.viewers.IStructuredSelection;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.custom.CLabel;
-import org.eclipse.swt.layout.FormAttachment;
-import org.eclipse.swt.layout.FormData;
-import org.eclipse.swt.layout.FormLayout;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.swt.widgets.Control;
-import org.eclipse.swt.widgets.Display;
-import org.eclipse.swt.widgets.Text;
-import org.eclipse.tcf.te.core.interfaces.IPropertyChangeProvider;
-import org.eclipse.tcf.te.runtime.model.interfaces.IModelNode;
-import org.eclipse.tcf.te.runtime.model.interfaces.IModelNodeProvider;
-import org.eclipse.ui.IWorkbenchPart;
-import org.eclipse.ui.forms.widgets.ExpandableComposite;
-import org.eclipse.ui.forms.widgets.Section;
-import org.eclipse.ui.views.properties.tabbed.AbstractPropertySection;
-import org.eclipse.ui.views.properties.tabbed.ITabbedPropertyConstants;
-import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage;
-
-/**
- * The base section that displays a title in a title bar.
- */
-public abstract class BaseTitledSection extends AbstractPropertySection implements PropertyChangeListener {
-
- // The main composite used to create the section content.
- protected Composite composite;
-
- protected IPropertyChangeProvider viewerInput;
-
- // The input node.
- protected IModelNodeProvider provider;
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#setInput(org.eclipse.ui.IWorkbenchPart, org.eclipse.jface.viewers.ISelection)
- */
- @Override
- public void setInput(IWorkbenchPart part, ISelection selection) {
- super.setInput(part, selection);
- if (this.viewerInput != null) {
- this.viewerInput.removePropertyChangeListener(this);
- }
- Assert.isTrue(selection instanceof IStructuredSelection);
- Object input = ((IStructuredSelection) selection).getFirstElement();
- if (input instanceof IAdaptable) {
- this.viewerInput = (IPropertyChangeProvider)((IAdaptable)input).getAdapter(IPropertyChangeProvider.class);
- if (this.viewerInput != null) {
- this.viewerInput.addPropertyChangeListener(this);
- }
- }
- if (this.viewerInput == null && input instanceof IModelNodeProvider) {
- this.provider = (IModelNodeProvider) input;
- IModelNode modelNode = this.provider.getModelNode();
- this.viewerInput = (IPropertyChangeProvider)modelNode.getAdapter(IPropertyChangeProvider.class);
- if (this.viewerInput != null) {
- this.viewerInput.addPropertyChangeListener(this);
- }
- }
- else {
- this.provider = null;
- this.viewerInput = null;
- }
- updateInput(provider);
- }
-
- /**
- * Update the input node.
- *
- * @param input The input node.
- */
- protected void updateInput(IModelNodeProvider input) {
- }
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#aboutToBeHidden()
- */
- @Override
- public void aboutToBeHidden() {
- if(this.viewerInput != null) {
- this.viewerInput.removePropertyChangeListener(this);
- }
- }
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#createControls(org.eclipse.swt.widgets.Composite, org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage)
- */
- @Override
- public void createControls(Composite parent, TabbedPropertySheetPage aTabbedPropertySheetPage) {
- super.createControls(parent, aTabbedPropertySheetPage);
- parent.setLayout(new FormLayout());
-
- Section section = getWidgetFactory().createSection(parent, ExpandableComposite.TITLE_BAR);
- section.setText(getText());
- FormData data = new FormData();
- data.left = new FormAttachment(0, ITabbedPropertyConstants.HMARGIN);
- data.right = new FormAttachment(100, -ITabbedPropertyConstants.HMARGIN);
- data.top = new FormAttachment(0, 2 * ITabbedPropertyConstants.VMARGIN);
- section.setLayoutData(data);
-
- composite = getWidgetFactory().createComposite(parent);
- FormLayout layout = new FormLayout();
- layout.spacing = ITabbedPropertyConstants.HMARGIN;
- composite.setLayout(layout);
-
- data = new FormData();
- data.left = new FormAttachment(0, 2 * ITabbedPropertyConstants.HMARGIN);
- data.right = new FormAttachment(100, -2 * ITabbedPropertyConstants.HMARGIN);
- data.top = new FormAttachment(section, ITabbedPropertyConstants.VSPACE);
- data.bottom = new FormAttachment(100, 0);
- composite.setLayoutData(data);
- }
-
- /**
- * Create a label for the control using the specified text.
- *
- * @param control The control for which the label is created.
- * @param text The label text.
- */
- protected void createLabel(Control control, String text) {
- CLabel nameLabel = getWidgetFactory().createCLabel(composite, text);
- FormData data = new FormData();
- data.left = new FormAttachment(0, 0);
- data.right = new FormAttachment(control, -ITabbedPropertyConstants.HSPACE);
- data.top = new FormAttachment(control, 0, SWT.CENTER);
- nameLabel.setLayoutData(data);
- }
-
- /**
- * Create a text field and a label with the specified label
- * relative to the specified control.
- *
- * @param control The control relative to.
- * @param label The text of the label.
- * @return The new text created.
- */
- protected Text createTextField(Control control, String label) {
- Text text = createText(control);
- createLabel(text, label);
- return text;
- }
-
- /**
- * Create a wrap text field and a label with the specified label
- * relative to the specified control.
- *
- * @param control The control relative to.
- * @param label The text of the label.
- * @return The new wrap text created.
- */
- protected Text createWrapTextField(Control control, String label) {
- Text text = createWrapText(control);
- createLabel(text, label);
- return text;
- }
-
- /**
- * Create a text field relative to the specified control.
- *
- * @param control The control to layout the new text field.
- * @return The new text field created.
- */
- private Text createText(Control control) {
- Text text = getWidgetFactory().createText(composite, ""); //$NON-NLS-1$
- FormData data = new FormData();
- data.left = new FormAttachment(0, STANDARD_LABEL_WIDTH);
- data.right = new FormAttachment(100, 0);
- if (control == null) {
- data.top = new FormAttachment(0, ITabbedPropertyConstants.VSPACE);
- }
- else {
- data.top = new FormAttachment(control, ITabbedPropertyConstants.VSPACE);
- }
- text.setLayoutData(data);
- text.setEditable(false);
- return text;
- }
-
- /**
- * Create a wrap text field relative to the specified control.
- *
- * @param control The control to layout the new wrap text field.
- * @return The new wrap text field created.
- */
- private Text createWrapText(Control control) {
- Text text = getWidgetFactory().createText(composite, "", SWT.WRAP); //$NON-NLS-1$
- FormData data = new FormData();
- data.left = new FormAttachment(0, STANDARD_LABEL_WIDTH);
- data.right = new FormAttachment(100, 0);
- if (control == null) {
- data.top = new FormAttachment(0, ITabbedPropertyConstants.VSPACE);
- }
- else {
- data.top = new FormAttachment(control, ITabbedPropertyConstants.VSPACE);
- }
- data.width = 200;
- text.setLayoutData(data);
- text.setEditable(false);
- return text;
- }
-
- /*
- * (non-Javadoc)
- * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#refresh()
- */
- @Override
- public void refresh() {
- if (composite != null) {
- composite.layout();
- }
- }
-
- /*
- * (non-Javadoc)
- * @see java.beans.PropertyChangeListener#propertyChange(java.beans.PropertyChangeEvent)
- */
- @Override
- public void propertyChange(PropertyChangeEvent event) {
- if (event.getSource() == provider) {
- updateInput(provider);
- Display display = getPart().getSite().getShell().getDisplay();
- display.asyncExec(new Runnable() {
- @Override
- public void run() {
- refresh();
- }
- });
- }
- }
-
- /**
- * Get the text which is used as the title in the title bar of the section.
- *
- * @return A text string representing the section.
- */
- protected abstract String getText();
+/******************************************************************************* + * Copyright (c) 2011, 2014 Wind River Systems, Inc. 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: + * Wind River Systems - initial API and implementation + *******************************************************************************/ +package org.eclipse.tcf.te.launch.ui.properties; + +import java.beans.PropertyChangeEvent; +import java.beans.PropertyChangeListener; + +import org.eclipse.core.runtime.Assert; +import org.eclipse.core.runtime.IAdaptable; +import org.eclipse.jface.viewers.ISelection; +import org.eclipse.jface.viewers.IStructuredSelection; +import org.eclipse.swt.SWT; +import org.eclipse.swt.custom.CLabel; +import org.eclipse.swt.layout.FormAttachment; +import org.eclipse.swt.layout.FormData; +import org.eclipse.swt.layout.FormLayout; +import org.eclipse.swt.widgets.Composite; +import org.eclipse.swt.widgets.Control; +import org.eclipse.swt.widgets.Display; +import org.eclipse.swt.widgets.Text; +import org.eclipse.tcf.te.core.interfaces.IPropertyChangeProvider; +import org.eclipse.tcf.te.runtime.model.interfaces.IModelNode; +import org.eclipse.tcf.te.runtime.model.interfaces.IModelNodeProvider; +import org.eclipse.ui.IWorkbenchPart; +import org.eclipse.ui.forms.widgets.ExpandableComposite; +import org.eclipse.ui.forms.widgets.Section; +import org.eclipse.ui.views.properties.tabbed.AbstractPropertySection; +import org.eclipse.ui.views.properties.tabbed.ITabbedPropertyConstants; +import org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage; + +/** + * The base section that displays a title in a title bar. + */ +public abstract class BaseTitledSection extends AbstractPropertySection implements PropertyChangeListener { + + // The main composite used to create the section content. + protected Composite composite; + + protected IPropertyChangeProvider viewerInput; + + // The input node. + protected IModelNodeProvider provider; + + /* + * (non-Javadoc) + * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#setInput(org.eclipse.ui.IWorkbenchPart, org.eclipse.jface.viewers.ISelection) + */ + @Override + public void setInput(IWorkbenchPart part, ISelection selection) { + super.setInput(part, selection); + if (this.viewerInput != null) { + this.viewerInput.removePropertyChangeListener(this); + } + Assert.isTrue(selection instanceof IStructuredSelection); + Object input = ((IStructuredSelection) selection).getFirstElement(); + if (input instanceof IAdaptable) { + this.viewerInput = (IPropertyChangeProvider)((IAdaptable)input).getAdapter(IPropertyChangeProvider.class); + if (this.viewerInput != null) { + this.viewerInput.addPropertyChangeListener(this); + } + } + if (this.viewerInput == null && input instanceof IModelNodeProvider) { + this.provider = (IModelNodeProvider) input; + IModelNode modelNode = this.provider.getModelNode(); + this.viewerInput = (IPropertyChangeProvider)modelNode.getAdapter(IPropertyChangeProvider.class); + if (this.viewerInput != null) { + this.viewerInput.addPropertyChangeListener(this); + } + } + else { + this.provider = null; + this.viewerInput = null; + } + updateInput(provider); + } + + /** + * Update the input node. + * + * @param input The input node. + */ + protected void updateInput(IModelNodeProvider input) { + } + + /* + * (non-Javadoc) + * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#aboutToBeHidden() + */ + @Override + public void aboutToBeHidden() { + if(this.viewerInput != null) { + this.viewerInput.removePropertyChangeListener(this); + } + } + + /* + * (non-Javadoc) + * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#createControls(org.eclipse.swt.widgets.Composite, org.eclipse.ui.views.properties.tabbed.TabbedPropertySheetPage) + */ + @Override + public void createControls(Composite parent, TabbedPropertySheetPage aTabbedPropertySheetPage) { + super.createControls(parent, aTabbedPropertySheetPage); + parent.setLayout(new FormLayout()); + + Section section = getWidgetFactory().createSection(parent, ExpandableComposite.TITLE_BAR); + section.setText(getText()); + FormData data = new FormData(); + data.left = new FormAttachment(0, ITabbedPropertyConstants.HMARGIN); + data.right = new FormAttachment(100, -ITabbedPropertyConstants.HMARGIN); + data.top = new FormAttachment(0, 2 * ITabbedPropertyConstants.VMARGIN); + section.setLayoutData(data); + + composite = getWidgetFactory().createComposite(parent); + FormLayout layout = new FormLayout(); + layout.spacing = ITabbedPropertyConstants.HMARGIN; + composite.setLayout(layout); + + data = new FormData(); + data.left = new FormAttachment(0, 2 * ITabbedPropertyConstants.HMARGIN); + data.right = new FormAttachment(100, -2 * ITabbedPropertyConstants.HMARGIN); + data.top = new FormAttachment(section, ITabbedPropertyConstants.VSPACE); + data.bottom = new FormAttachment(100, 0); + composite.setLayoutData(data); + } + + /** + * Create a label for the control using the specified text. + * + * @param control The control for which the label is created. + * @param text The label text. + */ + protected void createLabel(Control control, String text) { + CLabel nameLabel = getWidgetFactory().createCLabel(composite, text); + FormData data = new FormData(); + data.left = new FormAttachment(0, 0); + data.right = new FormAttachment(control, -ITabbedPropertyConstants.HSPACE); + data.top = new FormAttachment(control, 0, SWT.CENTER); + nameLabel.setLayoutData(data); + } + + /** + * Create a text field and a label with the specified label + * relative to the specified control. + * + * @param control The control relative to. + * @param label The text of the label. + * @return The new text created. + */ + protected Text createTextField(Control control, String label) { + Text text = createText(control); + createLabel(text, label); + return text; + } + + /** + * Create a wrap text field and a label with the specified label + * relative to the specified control. + * + * @param control The control relative to. + * @param label The text of the label. + * @return The new wrap text created. + */ + protected Text createWrapTextField(Control control, String label) { + Text text = createWrapText(control); + createLabel(text, label); + return text; + } + + /** + * Create a text field relative to the specified control. + * + * @param control The control to layout the new text field. + * @return The new text field created. + */ + private Text createText(Control control) { + Text text = getWidgetFactory().createText(composite, ""); //$NON-NLS-1$ + FormData data = new FormData(); + data.left = new FormAttachment(0, STANDARD_LABEL_WIDTH); + data.right = new FormAttachment(100, 0); + if (control == null) { + data.top = new FormAttachment(0, ITabbedPropertyConstants.VSPACE); + } + else { + data.top = new FormAttachment(control, ITabbedPropertyConstants.VSPACE); + } + text.setLayoutData(data); + text.setEditable(false); + return text; + } + + /** + * Create a wrap text field relative to the specified control. + * + * @param control The control to layout the new wrap text field. + * @return The new wrap text field created. + */ + private Text createWrapText(Control control) { + Text text = getWidgetFactory().createText(composite, "", SWT.WRAP); //$NON-NLS-1$ + FormData data = new FormData(); + data.left = new FormAttachment(0, STANDARD_LABEL_WIDTH); + data.right = new FormAttachment(100, 0); + if (control == null) { + data.top = new FormAttachment(0, ITabbedPropertyConstants.VSPACE); + } + else { + data.top = new FormAttachment(control, ITabbedPropertyConstants.VSPACE); + } + data.width = 200; + text.setLayoutData(data); + text.setEditable(false); + return text; + } + + /* + * (non-Javadoc) + * @see org.eclipse.ui.views.properties.tabbed.AbstractPropertySection#refresh() + */ + @Override + public void refresh() { + if (composite != null) { + composite.layout(); + } + } + + /* + * (non-Javadoc) + * @see java.beans.PropertyChangeListener#propertyChange(java.beans.PropertyChangeEvent) + */ + @Override + public void propertyChange(PropertyChangeEvent event) { + if (event.getSource() == provider) { + updateInput(provider); + Display display = getPart().getSite().getShell().getDisplay(); + display.asyncExec(new Runnable() { + @Override + public void run() { + refresh(); + } + }); + } + } + + /** + * Get the text which is used as the title in the title bar of the section. + * + * @return A text string representing the section. + */ + protected abstract String getText(); }
\ No newline at end of file diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/selection/LaunchSelectionManager.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/selection/LaunchSelectionManager.java index b42996d03..0934676d9 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/selection/LaunchSelectionManager.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/selection/LaunchSelectionManager.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012, 2013 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/services/UIService.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/services/UIService.java index e5a529d3f..9b3c9e578 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/services/UIService.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/services/UIService.java @@ -2,7 +2,7 @@ * UIService.java * Created on Nov 15, 2012 * - * Copyright (c) 2012, 2013 Wind River Systems, Inc. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. * * The right to copy, distribute, modify, or otherwise make use * of this software may be licensed only pursuant to the terms diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/AbstractFormsLaunchConfigurationTab.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/AbstractFormsLaunchConfigurationTab.java index 2ef66edf9..d5bc75b89 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/AbstractFormsLaunchConfigurationTab.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/AbstractFormsLaunchConfigurationTab.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/AbstractLaunchConfigurationTab.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/AbstractLaunchConfigurationTab.java index 509c38de9..162fe2cea 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/AbstractLaunchConfigurationTab.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/AbstractLaunchConfigurationTab.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012, 2013 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/AbstractLaunchConfigurationTabGroup.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/AbstractLaunchConfigurationTabGroup.java index a6f1da8b4..0e2bddc63 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/AbstractLaunchConfigurationTabGroup.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/AbstractLaunchConfigurationTabGroup.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/filetransfers/AbstractFileTransferSection.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/filetransfers/AbstractFileTransferSection.java index 86841e5fb..1f74c70f0 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/filetransfers/AbstractFileTransferSection.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/filetransfers/AbstractFileTransferSection.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/filetransfers/AbstractFileTransferTab.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/filetransfers/AbstractFileTransferTab.java index 4130daf0c..ce38a70cb 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/filetransfers/AbstractFileTransferTab.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/filetransfers/AbstractFileTransferTab.java @@ -1,76 +1,76 @@ -/*******************************************************************************
- * Copyright (c) 2012 Wind River Systems, Inc. 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:
- * Wind River Systems - initial API and implementation
- *******************************************************************************/
-package org.eclipse.tcf.te.launch.ui.tabs.filetransfers;
-
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.tcf.te.launch.ui.nls.Messages;
-import org.eclipse.tcf.te.launch.ui.tabs.AbstractFormsLaunchConfigurationTab;
-import org.eclipse.tcf.te.ui.forms.CustomFormToolkit;
-import org.eclipse.ui.forms.IManagedForm;
-import org.eclipse.ui.forms.widgets.TableWrapData;
-import org.eclipse.ui.forms.widgets.TableWrapLayout;
-
-/**
- * File transfer launch configuration tab implementation.
- */
-public abstract class AbstractFileTransferTab extends AbstractFormsLaunchConfigurationTab {
- // References to the tab sub sections
- private AbstractFileTransferSection section;
-
- /* (non-Javadoc)
- * @see org.eclipse.tcf.te.launch.ui.tabs.AbstractFormsLaunchConfigurationTab#dispose()
- */
- @Override
- public void dispose() {
- if (section != null) { section.dispose(); section = null; }
- super.dispose();
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.tcf.te.launch.ui.tabs.AbstractFormsLaunchConfigurationTab#doCreateFormContent(org.eclipse.swt.widgets.Composite, org.eclipse.tcf.te.ui.forms.CustomFormToolkit)
- */
- @Override
- protected void doCreateFormContent(Composite parent, CustomFormToolkit toolkit) {
- Assert.isNotNull(parent);
- Assert.isNotNull(toolkit);
-
- // Setup the main panel (using the table wrap layout)
- Composite panel = toolkit.getFormToolkit().createComposite(parent);
- TableWrapLayout layout = new TableWrapLayout();
- layout.makeColumnsEqualWidth = true;
- layout.numColumns = 1;
- panel.setLayout(layout);
- panel.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true));
- panel.setBackground(parent.getBackground());
-
- section = createFileTransferSection(getManagedForm(), panel);
- section.getSection().setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB, TableWrapData.TOP));
- getManagedForm().addPart(section);
- }
-
- /**
- * Create the transfer section.
- * @param form
- * @param panel
- * @return
- */
- protected abstract AbstractFileTransferSection createFileTransferSection(IManagedForm form, Composite panel);
-
- /* (non-Javadoc)
- * @see org.eclipse.debug.ui.ILaunchConfigurationTab#getName()
- */
- @Override
- public String getName() {
- return Messages.FileTransferTab_name;
- }
-}
+/******************************************************************************* + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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: + * Wind River Systems - initial API and implementation + *******************************************************************************/ +package org.eclipse.tcf.te.launch.ui.tabs.filetransfers; + +import org.eclipse.core.runtime.Assert; +import org.eclipse.swt.SWT; +import org.eclipse.swt.layout.GridData; +import org.eclipse.swt.widgets.Composite; +import org.eclipse.tcf.te.launch.ui.nls.Messages; +import org.eclipse.tcf.te.launch.ui.tabs.AbstractFormsLaunchConfigurationTab; +import org.eclipse.tcf.te.ui.forms.CustomFormToolkit; +import org.eclipse.ui.forms.IManagedForm; +import org.eclipse.ui.forms.widgets.TableWrapData; +import org.eclipse.ui.forms.widgets.TableWrapLayout; + +/** + * File transfer launch configuration tab implementation. + */ +public abstract class AbstractFileTransferTab extends AbstractFormsLaunchConfigurationTab { + // References to the tab sub sections + private AbstractFileTransferSection section; + + /* (non-Javadoc) + * @see org.eclipse.tcf.te.launch.ui.tabs.AbstractFormsLaunchConfigurationTab#dispose() + */ + @Override + public void dispose() { + if (section != null) { section.dispose(); section = null; } + super.dispose(); + } + + /* (non-Javadoc) + * @see org.eclipse.tcf.te.launch.ui.tabs.AbstractFormsLaunchConfigurationTab#doCreateFormContent(org.eclipse.swt.widgets.Composite, org.eclipse.tcf.te.ui.forms.CustomFormToolkit) + */ + @Override + protected void doCreateFormContent(Composite parent, CustomFormToolkit toolkit) { + Assert.isNotNull(parent); + Assert.isNotNull(toolkit); + + // Setup the main panel (using the table wrap layout) + Composite panel = toolkit.getFormToolkit().createComposite(parent); + TableWrapLayout layout = new TableWrapLayout(); + layout.makeColumnsEqualWidth = true; + layout.numColumns = 1; + panel.setLayout(layout); + panel.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true)); + panel.setBackground(parent.getBackground()); + + section = createFileTransferSection(getManagedForm(), panel); + section.getSection().setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB, TableWrapData.TOP)); + getManagedForm().addPart(section); + } + + /** + * Create the transfer section. + * @param form + * @param panel + * @return + */ + protected abstract AbstractFileTransferSection createFileTransferSection(IManagedForm form, Composite panel); + + /* (non-Javadoc) + * @see org.eclipse.debug.ui.ILaunchConfigurationTab#getName() + */ + @Override + public String getName() { + return Messages.FileTransferTab_name; + } +} diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/filetransfers/FileTransferCheckStateProvider.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/filetransfers/FileTransferCheckStateProvider.java index 70e1a2aa4..58c359fbb 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/filetransfers/FileTransferCheckStateProvider.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/filetransfers/FileTransferCheckStateProvider.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/filetransfers/FileTransferContentProvider.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/filetransfers/FileTransferContentProvider.java index bd1aa5c9a..0a6acee00 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/filetransfers/FileTransferContentProvider.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/filetransfers/FileTransferContentProvider.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/launchcontext/AbstractContextSelectorTab.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/launchcontext/AbstractContextSelectorTab.java index ac5f61ab4..a85eafcb9 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/launchcontext/AbstractContextSelectorTab.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/launchcontext/AbstractContextSelectorTab.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012, 2013 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/refprojects/RefProjectsCheckStateProvider.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/refprojects/RefProjectsCheckStateProvider.java index 16730eb6e..93ada03cf 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/refprojects/RefProjectsCheckStateProvider.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/refprojects/RefProjectsCheckStateProvider.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/refprojects/RefProjectsContentProvider.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/refprojects/RefProjectsContentProvider.java index 9240be8d9..75c81e620 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/refprojects/RefProjectsContentProvider.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/refprojects/RefProjectsContentProvider.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/refprojects/RefProjectsSection.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/refprojects/RefProjectsSection.java index 7365ddd90..9afef7ccd 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/refprojects/RefProjectsSection.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/refprojects/RefProjectsSection.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/refprojects/RefProjetcsTab.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/refprojects/RefProjetcsTab.java index a71c5efc9..2c3bfebad 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/refprojects/RefProjetcsTab.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/tabs/refprojects/RefProjetcsTab.java @@ -1,78 +1,78 @@ -/*******************************************************************************
- * Copyright (c) 2012 Wind River Systems, Inc. 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:
- * Wind River Systems - initial API and implementation
- *******************************************************************************/
-package org.eclipse.tcf.te.launch.ui.tabs.refprojects;
-
-import org.eclipse.core.runtime.Assert;
-import org.eclipse.swt.SWT;
-import org.eclipse.swt.graphics.Image;
-import org.eclipse.swt.layout.GridData;
-import org.eclipse.swt.widgets.Composite;
-import org.eclipse.tcf.te.launch.ui.nls.Messages;
-import org.eclipse.tcf.te.launch.ui.tabs.AbstractFormsLaunchConfigurationTab;
-import org.eclipse.tcf.te.ui.forms.CustomFormToolkit;
-import org.eclipse.ui.PlatformUI;
-import org.eclipse.ui.forms.widgets.TableWrapData;
-import org.eclipse.ui.forms.widgets.TableWrapLayout;
-import org.eclipse.ui.ide.IDE;
-
-/**
- * Referenced projetcs launch configuration tab implementation.
- */
-public class RefProjetcsTab extends AbstractFormsLaunchConfigurationTab {
- // References to the tab sub sections
- private RefProjectsSection section;
-
- /* (non-Javadoc)
- * @see org.eclipse.tcf.te.launch.ui.tabs.AbstractFormsLaunchConfigurationTab#dispose()
- */
- @Override
- public void dispose() {
- if (section != null) { section.dispose(); section = null; }
- super.dispose();
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.tcf.te.launch.ui.tabs.AbstractFormsLaunchConfigurationTab#doCreateFormContent(org.eclipse.swt.widgets.Composite, org.eclipse.tcf.te.ui.forms.CustomFormToolkit)
- */
- @Override
- protected void doCreateFormContent(Composite parent, CustomFormToolkit toolkit) {
- Assert.isNotNull(parent);
- Assert.isNotNull(toolkit);
-
- // Setup the main panel (using the table wrap layout)
- Composite panel = toolkit.getFormToolkit().createComposite(parent);
- TableWrapLayout layout = new TableWrapLayout();
- layout.makeColumnsEqualWidth = true;
- layout.numColumns = 1;
- panel.setLayout(layout);
- panel.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true));
- panel.setBackground(parent.getBackground());
-
- section = new RefProjectsSection(getManagedForm(), panel);
- section.getSection().setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB, TableWrapData.TOP));
- getManagedForm().addPart(section);
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.debug.ui.ILaunchConfigurationTab#getName()
- */
- @Override
- public String getName() {
- return Messages.ReferencedProjectsTab_name;
- }
-
- /* (non-Javadoc)
- * @see org.eclipse.debug.ui.AbstractLaunchConfigurationTab#getImage()
- */
- @Override
- public Image getImage() {
- return PlatformUI.getWorkbench().getSharedImages().getImage(IDE.SharedImages.IMG_OBJ_PROJECT);
- }
-}
+/******************************************************************************* + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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: + * Wind River Systems - initial API and implementation + *******************************************************************************/ +package org.eclipse.tcf.te.launch.ui.tabs.refprojects; + +import org.eclipse.core.runtime.Assert; +import org.eclipse.swt.SWT; +import org.eclipse.swt.graphics.Image; +import org.eclipse.swt.layout.GridData; +import org.eclipse.swt.widgets.Composite; +import org.eclipse.tcf.te.launch.ui.nls.Messages; +import org.eclipse.tcf.te.launch.ui.tabs.AbstractFormsLaunchConfigurationTab; +import org.eclipse.tcf.te.ui.forms.CustomFormToolkit; +import org.eclipse.ui.PlatformUI; +import org.eclipse.ui.forms.widgets.TableWrapData; +import org.eclipse.ui.forms.widgets.TableWrapLayout; +import org.eclipse.ui.ide.IDE; + +/** + * Referenced projetcs launch configuration tab implementation. + */ +public class RefProjetcsTab extends AbstractFormsLaunchConfigurationTab { + // References to the tab sub sections + private RefProjectsSection section; + + /* (non-Javadoc) + * @see org.eclipse.tcf.te.launch.ui.tabs.AbstractFormsLaunchConfigurationTab#dispose() + */ + @Override + public void dispose() { + if (section != null) { section.dispose(); section = null; } + super.dispose(); + } + + /* (non-Javadoc) + * @see org.eclipse.tcf.te.launch.ui.tabs.AbstractFormsLaunchConfigurationTab#doCreateFormContent(org.eclipse.swt.widgets.Composite, org.eclipse.tcf.te.ui.forms.CustomFormToolkit) + */ + @Override + protected void doCreateFormContent(Composite parent, CustomFormToolkit toolkit) { + Assert.isNotNull(parent); + Assert.isNotNull(toolkit); + + // Setup the main panel (using the table wrap layout) + Composite panel = toolkit.getFormToolkit().createComposite(parent); + TableWrapLayout layout = new TableWrapLayout(); + layout.makeColumnsEqualWidth = true; + layout.numColumns = 1; + panel.setLayout(layout); + panel.setLayoutData(new GridData(SWT.FILL, SWT.FILL, true, true)); + panel.setBackground(parent.getBackground()); + + section = new RefProjectsSection(getManagedForm(), panel); + section.getSection().setLayoutData(new TableWrapData(TableWrapData.FILL_GRAB, TableWrapData.TOP)); + getManagedForm().addPart(section); + } + + /* (non-Javadoc) + * @see org.eclipse.debug.ui.ILaunchConfigurationTab#getName() + */ + @Override + public String getName() { + return Messages.ReferencedProjectsTab_name; + } + + /* (non-Javadoc) + * @see org.eclipse.debug.ui.AbstractLaunchConfigurationTab#getImage() + */ + @Override + public Image getImage() { + return PlatformUI.getWorkbench().getSharedImages().getImage(IDE.SharedImages.IMG_OBJ_PROJECT); + } +} diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/DescriptionColumnLabelProvider.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/DescriptionColumnLabelProvider.java index 8820ab00b..4158860fe 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/DescriptionColumnLabelProvider.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/DescriptionColumnLabelProvider.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LastLaunchedColumnLabelProvider.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LastLaunchedColumnLabelProvider.java index 6f426dce7..4e9ee06dd 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LastLaunchedColumnLabelProvider.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LastLaunchedColumnLabelProvider.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LaunchEditorContentProvider.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LaunchEditorContentProvider.java index f3e2ea2ce..ebda65ec2 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LaunchEditorContentProvider.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LaunchEditorContentProvider.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2011, 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2011, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LaunchFavoritesContentProvider.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LaunchFavoritesContentProvider.java index eff005daf..088d3eb69 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LaunchFavoritesContentProvider.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LaunchFavoritesContentProvider.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LaunchNavigatorContentProvider.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LaunchNavigatorContentProvider.java index dcaa63d24..715a1a180 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LaunchNavigatorContentProvider.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LaunchNavigatorContentProvider.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012, 2013 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LaunchNodeImageDescriptor.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LaunchNodeImageDescriptor.java index 9af69167d..0d566cb42 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LaunchNodeImageDescriptor.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LaunchNodeImageDescriptor.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LaunchTreeLabelProvider.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LaunchTreeLabelProvider.java index 85bc16861..5f9bfc061 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LaunchTreeLabelProvider.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LaunchTreeLabelProvider.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LaunchTreeViewerSorter.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LaunchTreeViewerSorter.java index f3b936a2f..4a0f5629e 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LaunchTreeViewerSorter.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/LaunchTreeViewerSorter.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/dnd/CommonDnD.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/dnd/CommonDnD.java index c4c2285e1..d9cfe5505 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/dnd/CommonDnD.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/dnd/CommonDnD.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/dnd/DragAssistant.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/dnd/DragAssistant.java index d3078565e..f1c27ca21 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/dnd/DragAssistant.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/dnd/DragAssistant.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/dnd/DragSourceListener.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/dnd/DragSourceListener.java index 3bf0460cf..a50629cc4 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/dnd/DragSourceListener.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/dnd/DragSourceListener.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/dnd/DropAssistant.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/dnd/DropAssistant.java index 32c4cec0d..b84df5db7 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/dnd/DropAssistant.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/dnd/DropAssistant.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 diff --git a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/dnd/DropTargetListener.java b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/dnd/DropTargetListener.java index 2e607782a..ab40e5c5c 100644 --- a/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/dnd/DropTargetListener.java +++ b/target_explorer/plugins/org.eclipse.tcf.te.launch.ui/src/org/eclipse/tcf/te/launch/ui/viewer/dnd/DropTargetListener.java @@ -1,5 +1,5 @@ /******************************************************************************* - * Copyright (c) 2012 Wind River Systems, Inc. and others. All rights reserved. + * Copyright (c) 2012, 2014 Wind River Systems, Inc. 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 |