blob: a119789826ee5365719c32a2d1691b4b498a0359 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
/*******************************************************************************
* Copyright (c) 2008-2010 Sonatype, Inc.
* 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:
* Sonatype, Inc. - initial API and implementation
*******************************************************************************/
package org.eclipse.m2e.ui.internal.launch;
import java.util.ArrayList;
import java.util.List;
import org.eclipse.debug.ui.AbstractLaunchConfigurationTabGroup;
import org.eclipse.debug.ui.CommonTab;
import org.eclipse.debug.ui.EnvironmentTab;
import org.eclipse.debug.ui.ILaunchConfigurationDialog;
import org.eclipse.debug.ui.ILaunchConfigurationTab;
import org.eclipse.debug.ui.RefreshTab;
import org.eclipse.debug.ui.sourcelookup.SourceLookupTab;
import org.eclipse.m2e.internal.launch.MavenLaunchParticipantInfo;
public class MavenLaunchConfigurationTabGroup extends AbstractLaunchConfigurationTabGroup {
public void createTabs(ILaunchConfigurationDialog dialog, String mode) {
List<ILaunchConfigurationTab> tabs = new ArrayList<ILaunchConfigurationTab>();
tabs.add(new MavenLaunchMainTab(false));
tabs.add(new MavenJRETab());
tabs.add(new RefreshTab());
tabs.add(new SourceLookupTab());
List<MavenLaunchParticipantInfo> participants = MavenLaunchParticipantInfo.readParticipantsInfo();
if(!participants.isEmpty()) {
tabs.add(new MavenLaunchExtensionsTab(participants));
}
tabs.add(new EnvironmentTab());
tabs.add(new CommonTab());
setTabs(tabs.toArray(new ILaunchConfigurationTab[tabs.size()]));
}
}
|