Download
Getting Started
Members
Projects
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
More
Community
Marketplace
Events
Planet Eclipse
Newsletter
Videos
Participate
Report a Bug
Forums
Mailing Lists
Wiki
IRC
How to Contribute
Working Groups
Automotive
Internet of Things
LocationTech
Long-Term Support
PolarSys
Science
OpenMDM
Toggle navigation
Bugzilla – Attachment 76578 Details for
Bug 185312
Provide a detail pane for SWT images
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
Work in progress
185312ImageDetailPane (text/plain), 5.28 KB, created by
Curtis Windatt
on 2007-08-21 15:10:41 EDT
(
hide
)
Description:
Work in progress
Filename:
MIME Type:
Creator:
Curtis Windatt
Created:
2007-08-21 15:10:41 EDT
Size:
5.28 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.jdt.debug.ui >Index: plugin.xml >=================================================================== >RCS file: /cvsroot/eclipse/org.eclipse.jdt.debug.ui/plugin.xml,v >retrieving revision 1.459 >diff -u -r1.459 plugin.xml >--- plugin.xml 16 Aug 2007 14:11:39 -0000 1.459 >+++ plugin.xml 21 Aug 2007 19:04:51 -0000 >@@ -3306,4 +3306,11 @@ > targetId="org.eclipse.jdt.ui.javaCode"> > </hyperlinkDetector> > </extension> >+ <extension >+ point="org.eclipse.debug.ui.detailPaneFactories"> >+ <detailFactories >+ class="org.eclipse.jdt.internal.debug.ui.variables.ImageDetailPaneFactory" >+ id="org.eclipse.jdt.debug.ui.imageDetailPaneFactory"> >+ </detailFactories> >+ </extension> > </plugin> >Index: ui/org/eclipse/jdt/internal/debug/ui/variables/ImageDetailPaneFactory.java >=================================================================== >RCS file: ui/org/eclipse/jdt/internal/debug/ui/variables/ImageDetailPaneFactory.java >diff -N ui/org/eclipse/jdt/internal/debug/ui/variables/ImageDetailPaneFactory.java >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ ui/org/eclipse/jdt/internal/debug/ui/variables/ImageDetailPaneFactory.java 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,55 @@ >+package org.eclipse.jdt.internal.debug.ui.variables; >+ >+import java.util.HashSet; >+import java.util.Set; >+ >+import org.eclipse.debug.core.DebugException; >+import org.eclipse.debug.ui.IDetailPane; >+import org.eclipse.debug.ui.IDetailPaneFactory; >+import org.eclipse.jdt.debug.core.IJavaDebugTarget; >+import org.eclipse.jdt.debug.core.IJavaValue; >+import org.eclipse.jdt.debug.core.IJavaVariable; >+import org.eclipse.jface.viewers.IStructuredSelection; >+ >+public class ImageDetailPaneFactory implements IDetailPaneFactory { >+ >+ public IDetailPane createDetailPane(String paneID) { >+ if (ImageDetailPane.ID.equals(paneID)){ >+ return new ImageDetailPane(); >+ } >+ return null; >+ } >+ >+ public String getDefaultDetailPane(IStructuredSelection selection) { >+ return null; >+ } >+ >+ public String getDetailPaneDescription(String paneID) { >+ return "Awesomest detail pane ever"; >+ } >+ >+ public String getDetailPaneName(String paneID) { >+ return "Image detail pane"; >+ } >+ >+ public Set getDetailPaneTypes(IStructuredSelection selection) { >+ System.out.println(selection); >+ if (selection != null && !selection.isEmpty()){ >+ Object element = selection.getFirstElement(); >+ if (element instanceof IJavaVariable){ >+ IJavaVariable variable = (IJavaVariable)element; >+ try { >+ if (variable.getValue() instanceof IJavaValue){ >+ IJavaValue value = (IJavaValue)variable.getValue(); >+ IJavaDebugTarget target = (IJavaDebugTarget)value.getDebugTarget(); >+ } >+ } catch (DebugException e) { >+ // TODO Auto-generated catch block >+ e.printStackTrace(); >+ } >+ } >+ } >+ return new HashSet(); >+ } >+ >+} >Index: ui/org/eclipse/jdt/internal/debug/ui/variables/ImageDetailPane.java >=================================================================== >RCS file: ui/org/eclipse/jdt/internal/debug/ui/variables/ImageDetailPane.java >diff -N ui/org/eclipse/jdt/internal/debug/ui/variables/ImageDetailPane.java >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ ui/org/eclipse/jdt/internal/debug/ui/variables/ImageDetailPane.java 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,81 @@ >+/** >+ * >+ */ >+package org.eclipse.jdt.internal.debug.ui.variables; >+ >+import org.eclipse.debug.ui.IDetailPane; >+import org.eclipse.jdt.internal.debug.ui.SWTFactory; >+import org.eclipse.jface.viewers.IStructuredSelection; >+import org.eclipse.swt.widgets.Composite; >+import org.eclipse.swt.widgets.Control; >+import org.eclipse.swt.widgets.Label; >+import org.eclipse.ui.IWorkbenchPartSite; >+ >+/** >+ * @author DeleteMe >+ * >+ */ >+public class ImageDetailPane implements IDetailPane { >+ >+ public static final String ID = "IMAGE_DETAIL_PANE"; //$NON-NLS-1$ >+ >+ private Label fLabel; >+ >+ /* (non-Javadoc) >+ * @see org.eclipse.debug.ui.IDetailPane#createControl(org.eclipse.swt.widgets.Composite) >+ */ >+ public Control createControl(Composite parent) { >+ if (fLabel == null){ >+ fLabel = SWTFactory.createLabel(parent, "", 1); >+ } >+ return fLabel; >+ } >+ >+ /* (non-Javadoc) >+ * @see org.eclipse.debug.ui.IDetailPane#display(org.eclipse.jface.viewers.IStructuredSelection) >+ */ >+ public void display(IStructuredSelection selection) { >+ System.out.println(selection); >+ } >+ >+ /* (non-Javadoc) >+ * @see org.eclipse.debug.ui.IDetailPane#dispose() >+ */ >+ public void dispose() { >+ } >+ >+ /* (non-Javadoc) >+ * @see org.eclipse.debug.ui.IDetailPane#getDescription() >+ */ >+ public String getDescription() { >+ return "Awesomest detail pane ever"; >+ } >+ >+ /* (non-Javadoc) >+ * @see org.eclipse.debug.ui.IDetailPane#getID() >+ */ >+ public String getID() { >+ return ID; >+ } >+ >+ /* (non-Javadoc) >+ * @see org.eclipse.debug.ui.IDetailPane#getName() >+ */ >+ public String getName() { >+ return "Image detail pane"; >+ } >+ >+ /* (non-Javadoc) >+ * @see org.eclipse.debug.ui.IDetailPane#init(org.eclipse.ui.IWorkbenchPartSite) >+ */ >+ public void init(IWorkbenchPartSite partSite) { >+ } >+ >+ /* (non-Javadoc) >+ * @see org.eclipse.debug.ui.IDetailPane#setFocus() >+ */ >+ public boolean setFocus() { >+ return false; >+ } >+ >+}
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 185312
:
76578