|
Lines 1-5
Link Here
|
| 1 |
/******************************************************************************* |
1 |
/******************************************************************************* |
| 2 |
* Copyright (c) 2007, 2013 IBM Corporation and others. |
2 |
* Copyright (c) 2007, 2015 IBM Corporation and others. |
| 3 |
* All rights reserved. This program and the accompanying materials |
3 |
* All rights reserved. This program and the accompanying materials |
| 4 |
* are made available under the terms of the Eclipse Public License v1.0 |
4 |
* are made available under the terms of the Eclipse Public License v1.0 |
| 5 |
* which accompanies this distribution, and is available at |
5 |
* which accompanies this distribution, and is available at |
|
Lines 177-182
Link Here
|
| 177 |
|
177 |
|
| 178 |
//remove conflicting duplicates - if they have same version or both are singleton |
178 |
//remove conflicting duplicates - if they have same version or both are singleton |
| 179 |
HashMap<String, IPluginModelBase> pluginMap = new HashMap<String, IPluginModelBase>(); |
179 |
HashMap<String, IPluginModelBase> pluginMap = new HashMap<String, IPluginModelBase>(); |
|
|
180 |
Set<IPluginModelBase> pluginSet = new HashSet<IPluginModelBase>(); |
| 180 |
List<IPluginModelBase> workspaceModels = null; |
181 |
List<IPluginModelBase> workspaceModels = null; |
| 181 |
for (Iterator<IPluginModelBase> iterator = launchPlugins.iterator(); iterator.hasNext();) { |
182 |
for (Iterator<IPluginModelBase> iterator = launchPlugins.iterator(); iterator.hasNext();) { |
| 182 |
IPluginModelBase model = iterator.next(); |
183 |
IPluginModelBase model = iterator.next(); |
|
Lines 187-202
Link Here
|
| 187 |
if (workspaceModels == null) |
188 |
if (workspaceModels == null) |
| 188 |
workspaceModels = Arrays.asList(PluginRegistry.getWorkspaceModels()); |
189 |
workspaceModels = Arrays.asList(PluginRegistry.getWorkspaceModels()); |
| 189 |
if (!workspaceModels.contains(existing)) { //if existing model is external |
190 |
if (!workspaceModels.contains(existing)) { //if existing model is external |
| 190 |
pluginMap.put(id, model); // launch the workspace model |
191 |
pluginSet.add(model);// launch the workspace model |
| 191 |
continue; |
192 |
continue; |
| 192 |
} |
193 |
} |
| 193 |
} |
194 |
} |
| 194 |
} |
195 |
} |
| 195 |
pluginMap.put(id, model); |
196 |
pluginSet.add(model); |
| 196 |
} |
197 |
} |
|
|
198 |
pluginMap.clear(); |
| 197 |
|
199 |
|
| 198 |
// Create the start levels for the selected plugins and add them to the map |
200 |
// Create the start levels for the selected plugins and add them to the map |
| 199 |
for (Iterator<IPluginModelBase> iterator = pluginMap.values().iterator(); iterator.hasNext();) { |
201 |
for (Iterator<IPluginModelBase> iterator = pluginSet.iterator(); iterator.hasNext();) { |
| 200 |
IPluginModelBase model = iterator.next(); |
202 |
IPluginModelBase model = iterator.next(); |
| 201 |
addBundleToMap(map, model, "default:default"); //$NON-NLS-1$ |
203 |
addBundleToMap(map, model, "default:default"); //$NON-NLS-1$ |
| 202 |
} |
204 |
} |