mirror of
https://github.com/eclipse-cdt/cdt
synced 2025-08-04 14:55:41 +02:00
Added image icon when attaching.
This commit is contained in:
parent
75e82f6762
commit
9bf8316c22
4 changed files with 27 additions and 1 deletions
|
@ -1,3 +1,11 @@
|
||||||
|
2004-02-18 Alain Magloire
|
||||||
|
|
||||||
|
Added image to the label provider
|
||||||
|
|
||||||
|
* icons/obj16/exec_obj.gif
|
||||||
|
* src/org/eclipse/cdt/launch/internal/LocalCLaunchConfigurationDelegate.java
|
||||||
|
* src/org/eclipse/cdt/launch/internal/ui/LaunchImages.java
|
||||||
|
|
||||||
2004-02-17 Alain Magloire
|
2004-02-17 Alain Magloire
|
||||||
|
|
||||||
Use a TwoPanel dialog when we attach more user friendly.
|
Use a TwoPanel dialog when we attach more user friendly.
|
||||||
|
|
BIN
launch/org.eclipse.cdt.launch/icons/obj16/exec_obj.gif
Normal file
BIN
launch/org.eclipse.cdt.launch/icons/obj16/exec_obj.gif
Normal file
Binary file not shown.
After Width: | Height: | Size: 125 B |
|
@ -23,6 +23,7 @@ import org.eclipse.cdt.debug.core.cdi.ICDIRuntimeOptions;
|
||||||
import org.eclipse.cdt.debug.core.cdi.ICDISession;
|
import org.eclipse.cdt.debug.core.cdi.ICDISession;
|
||||||
import org.eclipse.cdt.debug.core.cdi.model.ICDITarget;
|
import org.eclipse.cdt.debug.core.cdi.model.ICDITarget;
|
||||||
import org.eclipse.cdt.launch.AbstractCLaunchDelegate;
|
import org.eclipse.cdt.launch.AbstractCLaunchDelegate;
|
||||||
|
import org.eclipse.cdt.launch.internal.ui.LaunchImages;
|
||||||
import org.eclipse.cdt.launch.internal.ui.LaunchUIPlugin;
|
import org.eclipse.cdt.launch.internal.ui.LaunchUIPlugin;
|
||||||
import org.eclipse.cdt.utils.spawner.ProcessFactory;
|
import org.eclipse.cdt.utils.spawner.ProcessFactory;
|
||||||
import org.eclipse.core.resources.IFile;
|
import org.eclipse.core.resources.IFile;
|
||||||
|
@ -42,6 +43,7 @@ import org.eclipse.debug.core.model.IProcess;
|
||||||
import org.eclipse.jface.dialogs.MessageDialog;
|
import org.eclipse.jface.dialogs.MessageDialog;
|
||||||
import org.eclipse.jface.viewers.ILabelProvider;
|
import org.eclipse.jface.viewers.ILabelProvider;
|
||||||
import org.eclipse.jface.viewers.LabelProvider;
|
import org.eclipse.jface.viewers.LabelProvider;
|
||||||
|
import org.eclipse.swt.graphics.Image;
|
||||||
import org.eclipse.swt.widgets.Display;
|
import org.eclipse.swt.widgets.Display;
|
||||||
import org.eclipse.swt.widgets.Shell;
|
import org.eclipse.swt.widgets.Shell;
|
||||||
import org.eclipse.ui.dialogs.ElementListSelectionDialog;
|
import org.eclipse.ui.dialogs.ElementListSelectionDialog;
|
||||||
|
@ -164,12 +166,24 @@ public class LocalCLaunchConfigurationDelegate extends AbstractCLaunchDelegate {
|
||||||
IPath path = new Path(info.getName());
|
IPath path = new Path(info.getName());
|
||||||
return path.lastSegment() + " - " + info.getPid();
|
return path.lastSegment() + " - " + info.getPid();
|
||||||
}
|
}
|
||||||
|
/* (non-Javadoc)
|
||||||
|
* @see org.eclipse.jface.viewers.LabelProvider#getImage(java.lang.Object)
|
||||||
|
*/
|
||||||
|
public Image getImage(Object element) {
|
||||||
|
return LaunchImages.get(LaunchImages.IMG_OBJS_EXEC);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
ILabelProvider qprovider = new LabelProvider() {
|
ILabelProvider qprovider = new LabelProvider() {
|
||||||
public String getText(Object element) {
|
public String getText(Object element) {
|
||||||
IProcessInfo info = (IProcessInfo) element;
|
IProcessInfo info = (IProcessInfo) element;
|
||||||
return info.getName();
|
return info.getName();
|
||||||
}
|
}
|
||||||
|
/* (non-Javadoc)
|
||||||
|
* @see org.eclipse.jface.viewers.LabelProvider#getImage(java.lang.Object)
|
||||||
|
*/
|
||||||
|
public Image getImage(Object element) {
|
||||||
|
return LaunchImages.get(LaunchImages.IMG_OBJS_EXEC);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
TwoPaneElementSelector dialog = new TwoPaneElementSelector(shell, provider, qprovider);
|
TwoPaneElementSelector dialog = new TwoPaneElementSelector(shell, provider, qprovider);
|
||||||
dialog.setTitle("Select Process");
|
dialog.setTitle("Select Process");
|
||||||
|
|
|
@ -30,6 +30,7 @@ public class LaunchImages {
|
||||||
}
|
}
|
||||||
|
|
||||||
private static final String T_TABS = "tabs/";
|
private static final String T_TABS = "tabs/";
|
||||||
|
private static final String T_OBJS = "obj16/";
|
||||||
|
|
||||||
public static String IMG_VIEW_MAIN_TAB = NAME_PREFIX + "main_tab.gif";
|
public static String IMG_VIEW_MAIN_TAB = NAME_PREFIX + "main_tab.gif";
|
||||||
public static String IMG_VIEW_ARGUMENTS_TAB = NAME_PREFIX + "arguments_tab.gif";
|
public static String IMG_VIEW_ARGUMENTS_TAB = NAME_PREFIX + "arguments_tab.gif";
|
||||||
|
@ -42,7 +43,10 @@ public class LaunchImages {
|
||||||
public static final ImageDescriptor DESC_TAB_ENVIRONMENT = createManaged(T_TABS, IMG_VIEW_ENVIRONMENT_TAB);
|
public static final ImageDescriptor DESC_TAB_ENVIRONMENT = createManaged(T_TABS, IMG_VIEW_ENVIRONMENT_TAB);
|
||||||
public static final ImageDescriptor DESC_TAB_DEBUGGER = createManaged(T_TABS, IMG_VIEW_DEBUGGER_TAB);
|
public static final ImageDescriptor DESC_TAB_DEBUGGER = createManaged(T_TABS, IMG_VIEW_DEBUGGER_TAB);
|
||||||
public static final ImageDescriptor DESC_TAB_SOURCE = createManaged(T_TABS, IMG_VIEW_SOURCE_TAB);
|
public static final ImageDescriptor DESC_TAB_SOURCE = createManaged(T_TABS, IMG_VIEW_SOURCE_TAB);
|
||||||
|
|
||||||
|
public static String IMG_OBJS_EXEC= NAME_PREFIX + "exec_obj.gif";
|
||||||
|
public static final ImageDescriptor DESC_OBJS_EXEC = createManaged(T_OBJS, IMG_OBJS_EXEC);
|
||||||
|
|
||||||
public static void initialize() {
|
public static void initialize() {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue