Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
View | Details | Raw Unified | Return to bug 391608
Collapse All | Expand All

(-)a/profiling/org.eclipse.linuxtools.profiling.launch/META-INF/MANIFEST.MF (-1 / +2 lines)
Lines 8-14 Link Here
8
 org.eclipse.core.runtime,
8
 org.eclipse.core.runtime,
9
 org.eclipse.cdt.core,
9
 org.eclipse.cdt.core,
10
 org.eclipse.cdt.launch;bundle-version="7.0.0",
10
 org.eclipse.cdt.launch;bundle-version="7.0.0",
11
 org.eclipse.core.filesystem;bundle-version="1.3.100"
11
 org.eclipse.core.filesystem;bundle-version="1.3.100",
12
 org.eclipse.cdt.debug.ui
12
Bundle-ActivationPolicy: lazy
13
Bundle-ActivationPolicy: lazy
13
Bundle-RequiredExecutionEnvironment: J2SE-1.5
14
Bundle-RequiredExecutionEnvironment: J2SE-1.5
14
Import-Package: org.eclipse.cdt.core.model,
15
Import-Package: org.eclipse.cdt.core.model,
(-)a/profiling/org.eclipse.linuxtools.profiling.launch/plugin.xml (+105 lines)
Lines 413-416 Link Here
413
               mode="linuxtools">
413
               mode="linuxtools">
414
         </launchMode>
414
         </launchMode>
415
      </extension>
415
      </extension>
416
   <extension point="org.eclipse.debug.core.launchDelegates">
417
      <launchDelegate
418
            id="org.eclipse.linuxtools.profilingDelegate"
419
            type="org.eclipse.cdt.launch.applicationLaunchType"
420
            modes="profile"
421
            delegate="org.eclipse.linuxtools.internal.profiling.launch.provider.launch.ProviderLaunchConfigurationDelegate"
422
            name="ProfilingDelegate"
423
            delegateDescription="%launchDelegate.localApplication.description"
424
            sourceLocatorId="org.eclipse.cdt.debug.core.sourceLocator"
425
            sourcePathComputerId="org.eclipse.cdt.debug.core.sourcePathComputer">
426
      </launchDelegate>
427
     </extension>
428
      <extension
429
            point="org.eclipse.debug.ui.launchConfigurationTabs">
430
       <!-- Profiling launch tabs-->
431
      <tab
432
            id="org.eclipse.cdt.cdi.launch.profileApplicationLaunch.mainTab"
433
            group="org.eclipse.cdt.launch.applicationProfileLaunchTabGroup"
434
            name="Main"
435
            class="org.eclipse.cdt.launch.ui.CMainTab">
436
        <associatedDelegate delegate="org.eclipse.linuxtools.profilingDelegate"/>
437
      </tab>
438
      <tab
439
            id="org.eclipse.cdt.cdi.launch.profileApplicationLaunch.argumentsTab"
440
            group="org.eclipse.cdt.launch.applicationProfileLaunchTabGroup"
441
            name="Arguments"
442
            class="org.eclipse.cdt.launch.ui.CArgumentsTab">
443
        <associatedDelegate delegate="org.eclipse.linuxtools.profilingDelegate"/>
444
        <placement after="org.eclipse.cdt.cdi.launch.mainTab"/>
445
      </tab>
446
      <tab
447
            id="org.eclipse.cdt.cdi.launch.profileApplicationLaunch.environmentTab"
448
            group="org.eclipse.cdt.launch.applicationProfileLaunchTabGroup"
449
            name="Environment"
450
            class="org.eclipse.debug.ui.EnvironmentTab">
451
        <associatedDelegate delegate="org.eclipse.linuxtools.profilingDelegate"/>
452
        <placement after="org.eclipse.cdt.cdi.launch.argumentsTab"/>
453
      </tab>
454
      <tab
455
            id="org.eclipse.cdt.cdi.launch.profileApplicationLaunch.commonTab"
456
            group="org.eclipse.cdt.launch.applicationProfileLaunchTabGroup"
457
            name="Common"
458
            class="org.eclipse.debug.ui.CommonTab">
459
        <associatedDelegate delegate="org.eclipse.linuxtools.profilingDelegate"/>
460
        <placement after="org.eclipse.debug.ui.environmentTab"/>
461
      </tab>
462
      <tab
463
            id="org.eclipse.cdt.cdi.launch.profileApplicationLaunch.profilingTab"
464
            group="org.eclipse.cdt.launch.applicationProfileLaunchTabGroup"
465
            name="Profiler"
466
            class="org.eclipse.linuxtools.profiling.launch.RemoteProxyCMainTab"> <!--Link to the proper tab-->
467
        <associatedDelegate delegate="org.eclipse.linuxtools.profilingDelegate"/>
468
        <placement after="org.eclipse.debug.ui.commonTab"/>
469
      </tab> 
470
      </extension>
471
      <extension
472
         point="org.eclipse.debug.ui.launchConfigurationTabGroups">
473
      <launchConfigurationTabGroup
474
            type="org.eclipse.cdt.launch.applicationLaunchType"
475
            class="org.eclipse.linuxtools.profiling.launch.PlaceHolderLaunchConfigurationTabGroup"
476
            id="org.eclipse.cdt.launch.applicationProfileLaunchTabGroup">
477
         <launchMode mode="profile"/>
478
      </launchConfigurationTabGroup>
479
      </extension>
480
         <extension
481
         point="org.eclipse.debug.ui.launchShortcuts">
482
      <shortcut
483
            label="Local C/C++ Application"
484
            icon="icons/time_obj.gif"
485
            modes="profile"
486
            class="org.eclipse.linuxtools.profiling.launch.CApplicationLaunchShortcut"
487
            id="org.eclipse.cdt.debug.ui.localCShortcut">
488
         <contextualLaunch>
489
           <enablement>
490
             <with variable="selection">
491
               <count value="1"/>
492
               <iterate>
493
                   <or>
494
                     <instanceof value="org.eclipse.cdt.core.model.IBinary"/>
495
                     <instanceof value="org.eclipse.cdt.core.model.ICProject"/>
496
                     <test
497
                           forcePluginActivation="true"
498
                           property="org.eclipse.cdt.launch.isExecutable"/>
499
                     <test
500
                           forcePluginActivation="true"
501
                           property="org.eclipse.cdt.launch.isCProject"/>
502
                     <and>
503
                       <instanceof value="org.eclipse.ui.IFileEditorInput"/>
504
                       <adapt type="org.eclipse.core.resources.IResource">
505
                         <adapt type="org.eclipse.cdt.core.model.ICElement"/>
506
                       </adapt>
507
                     </and>
508
                   </or>
509
               </iterate>
510
             </with>
511
           </enablement>
512
         </contextualLaunch>
513
         <description
514
             mode="profile"
515
             description="Profiles a local C/C++ application"/>
516
         <configurationType
517
               id="org.eclipse.cdt.launch.applicationLaunchType">
518
         </configurationType>
519
	</shortcut>
520
   </extension>
416
</plugin>
521
</plugin>
(-)a/profiling/org.eclipse.linuxtools.profiling.launch/src/org/eclipse/linuxtools/profiling/launch/CApplicationLaunchShortcut.java (+20 lines)
Added Link Here
1
/*******************************************************************************
2
 * Copyright (c) 2005, 2011 QNX Software Systems and others.
3
 * All rights reserved. This program and the accompanying materials
4
 * are made available under the terms of the Eclipse Public License v1.0
5
 * which accompanies this distribution, and is available at
6
 * http://www.eclipse.org/legal/epl-v10.html
7
 *
8
 * Contributors:
9
 *     QNX Software Systems - Initial API and implementation
10
 *     Ken Ryall (Nokia) - bug 178731
11
 *     Ken Ryall (Nokia) - bug 246201
12
 *******************************************************************************/
13
package org.eclipse.linuxtools.profiling.launch;
14
15
16
/**
17
 * @since 2.0
18
 */
19
public class CApplicationLaunchShortcut extends org.eclipse.cdt.debug.internal.ui.launch.CApplicationLaunchShortcut {
20
}
(-)a/profiling/org.eclipse.linuxtools.profiling.launch/src/org/eclipse/linuxtools/profiling/launch/PlaceHolderLaunchConfigurationTabGroup.java (+32 lines)
Added Link Here
1
/*******************************************************************************
2
 * Copyright (c) 2008, 2009 Wind River Systems and others.
3
 * All rights reserved. This program and the accompanying materials
4
 * are made available under the terms of the Eclipse Public License v1.0
5
 * which accompanies this distribution, and is available at
6
 * http://www.eclipse.org/legal/epl-v10.html
7
 * 
8
 * Contributors:
9
 *     Wind River Systems - initial API and implementation
10
 *******************************************************************************/
11
package org.eclipse.linuxtools.profiling.launch;
12
13
import org.eclipse.debug.ui.AbstractLaunchConfigurationTabGroup;
14
import org.eclipse.debug.ui.ILaunchConfigurationDialog;
15
import org.eclipse.debug.ui.ILaunchConfigurationTab;
16
17
/**
18
 * This implementation is used where the composition of the tab group is defined
19
 * via the launchConfigurationTabGroups extension-point. Thus we just provide an
20
 * empty array of tab objects. The platform will add the ones declared in the
21
 * extension.
22
 * @since 2.0
23
 */
24
public class PlaceHolderLaunchConfigurationTabGroup extends AbstractLaunchConfigurationTabGroup {
25
	
26
    /* (non-Javadoc)
27
     * @see org.eclipse.debug.ui.ILaunchConfigurationTabGroup#createTabs(org.eclipse.debug.ui.ILaunchConfigurationDialog, java.lang.String)
28
     */
29
	public void createTabs(ILaunchConfigurationDialog dialog, String mode) {
30
        setTabs(new ILaunchConfigurationTab[0]);
31
    }
32
}

Return to bug 391608