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 249815 Details for
Bug 56062
[source lookup] Duplicate source lookup should indicate full location of duplicate
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read
this important communication.
[patch]
WorkbenchAdapter to append rootpath to labels
Bug 56062 - [source lookup] Duplicate source lookup should indicate full location of duplicate.patch (text/plain), 3.99 KB, created by
Sarika Sinha
on 2015-01-09 04:30:02 EST
(
hide
)
Description:
WorkbenchAdapter to append rootpath to labels
Filename:
MIME Type:
Creator:
Sarika Sinha
Created:
2015-01-09 04:30:02 EST
Size:
3.99 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.jdt.debug.ui >diff --git plugin.xml plugin.xml >index 8e0b12a..58425fb 100644 >--- plugin.xml >+++ plugin.xml >@@ -1,7 +1,7 @@ > <?xml version="1.0" encoding="UTF-8"?> > <?eclipse version="3.0"?> > <!-- >- Copyright (c) 2005, 2014 IBM Corporation and others. >+ Copyright (c) 2005, 2015 IBM Corporation and others. > 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 >@@ -3216,6 +3216,11 @@ > adaptableType="org.eclipse.jdt.launching.sourcelookup.containers.ClasspathContainerSourceContainer"> > <adapter type="org.eclipse.ui.model.IWorkbenchAdapter"/> > </factory> >+ <factory >+ class="org.eclipse.jdt.internal.debug.ui.sourcelookup.WorkbenchAdapterFactory" >+ adaptableType="org.eclipse.jdt.core.IJavaElement"> >+ <adapter type="org.eclipse.ui.model.IWorkbenchAdapter"/> >+ </factory> > > <!-- Adapters for runtime classpath entries --> > <factory >diff --git ui/org/eclipse/jdt/internal/debug/ui/sourcelookup/JavaDebugWorkbenchAdapter.java ui/org/eclipse/jdt/internal/debug/ui/sourcelookup/JavaDebugWorkbenchAdapter.java >new file mode 100644 >index 0000000..afb95bb >--- /dev/null >+++ ui/org/eclipse/jdt/internal/debug/ui/sourcelookup/JavaDebugWorkbenchAdapter.java >@@ -0,0 +1,30 @@ >+/******************************************************************************* >+ * Copyright (c) 2015 IBM Corporation and others. >+ * 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: >+ * IBM Corporation - initial API and implementation >+ *******************************************************************************/ >+ >+package org.eclipse.jdt.internal.debug.ui.sourcelookup; >+ >+import org.eclipse.jdt.internal.ui.JavaWorkbenchAdapter; >+import org.eclipse.jdt.ui.JavaElementLabels; >+ >+/** >+ * Class provides the JavaElement labels for WorkbenchAdapater Objects >+ */ >+public class JavaDebugWorkbenchAdapter extends JavaWorkbenchAdapter { >+ /* >+ * Append Root path to identify full path for duplicate Java elements in source lookup dialog >+ */ >+ @Override >+ public String getLabel(Object element) { >+ return JavaElementLabels.getTextLabel(getJavaElement(element), JavaElementLabels.ALL_DEFAULT | JavaElementLabels.APPEND_ROOT_PATH); >+ } >+ >+ >+} >diff --git ui/org/eclipse/jdt/internal/debug/ui/sourcelookup/WorkbenchAdapterFactory.java ui/org/eclipse/jdt/internal/debug/ui/sourcelookup/WorkbenchAdapterFactory.java >index c92dce1..18bdeba 100644 >--- ui/org/eclipse/jdt/internal/debug/ui/sourcelookup/WorkbenchAdapterFactory.java >+++ ui/org/eclipse/jdt/internal/debug/ui/sourcelookup/WorkbenchAdapterFactory.java >@@ -1,5 +1,5 @@ > /******************************************************************************* >- * Copyright (c) 2000, 2005 IBM Corporation and others. >+ * Copyright (c) 2000, 2015 IBM Corporation and others. > * 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 >@@ -11,6 +11,7 @@ > package org.eclipse.jdt.internal.debug.ui.sourcelookup; > > import org.eclipse.core.runtime.IAdapterFactory; >+import org.eclipse.jdt.core.IJavaElement; > import org.eclipse.ui.model.IWorkbenchAdapter; > > /** >@@ -22,6 +23,9 @@ > * @see org.eclipse.core.runtime.IAdapterFactory#getAdapter(java.lang.Object, java.lang.Class) > */ > public Object getAdapter(Object adaptableObject, Class adapterType) { >+ if (adaptableObject instanceof IJavaElement && adapterType.equals(IWorkbenchAdapter.class)) { >+ return new JavaDebugWorkbenchAdapter(); >+ } > if (adapterType.equals(IWorkbenchAdapter.class)) { > return new WorkbenchAdapter(); > }
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
Flags:
daniel_megert
:
review-
Actions:
View
|
Diff
Attachments on
bug 56062
:
249815
|
249920
|
252111
|
252112
|
252338
|
252343