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 73455 Details for
Bug 187741
Double Click doesn't work on objects in Team View
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
Log In
[x]
|
Terms of Use
|
Copyright Agent
[patch]
Implement handleDoubleClick in SystemTeamViewPart
patch.txt (text/plain), 2.76 KB, created by
Rupen Mardirossian
on 2007-07-10 13:31:13 EDT
(
hide
)
Description:
Implement handleDoubleClick in SystemTeamViewPart
Filename:
MIME Type:
Creator:
Rupen Mardirossian
Created:
2007-07-10 13:31:13 EDT
Size:
2.76 KB
patch
obsolete
>### Eclipse Workspace Patch 1.0 >#P org.eclipse.rse.ui >Index: UI/org/eclipse/rse/internal/ui/view/team/SystemTeamViewPart.java >=================================================================== >RCS file: /cvsroot/dsdp/org.eclipse.tm.rse/plugins/org.eclipse.rse.ui/UI/org/eclipse/rse/internal/ui/view/team/SystemTeamViewPart.java,v >retrieving revision 1.12 >diff -u -r1.12 SystemTeamViewPart.java >--- UI/org/eclipse/rse/internal/ui/view/team/SystemTeamViewPart.java 5 Jun 2007 01:39:24 -0000 1.12 >+++ UI/org/eclipse/rse/internal/ui/view/team/SystemTeamViewPart.java 10 Jul 2007 17:30:19 -0000 >@@ -15,6 +15,7 @@ > * Martin Oberhuber (Wind River) - [186773] split ISystemRegistryUI from ISystemRegistry > * David Dykstal (IBM) - [189858] Removed the remote systems project in the team view > * David Dykstal (IBM) - [186589] move user types, user actions, and compile commands >+ * Rupen Mardirossian (IBM) - [187741] Implemented the handleDoubleClick method > * API to the user actions plugin > ********************************************************************************/ > >@@ -51,9 +52,11 @@ > import org.eclipse.jface.viewers.ISelectionChangedListener; > import org.eclipse.jface.viewers.ISelectionProvider; > import org.eclipse.jface.viewers.IStructuredSelection; >+import org.eclipse.jface.viewers.ITreeSelection; > import org.eclipse.jface.viewers.OpenEvent; > import org.eclipse.jface.viewers.SelectionChangedEvent; > import org.eclipse.jface.viewers.StructuredSelection; >+import org.eclipse.jface.viewers.TreePath; > import org.eclipse.jface.viewers.TreeViewer; > import org.eclipse.jface.viewers.Viewer; > import org.eclipse.jface.window.SameShellProvider; >@@ -392,6 +395,37 @@ > */ > private void handleDoubleClick(DoubleClickEvent event) > { >+ ITreeSelection s = (ITreeSelection) event.getSelection(); >+ Object element = s.getFirstElement(); >+ >+ if (element == null) >+ return; >+ >+ ISystemViewElementAdapter adapter = (ISystemViewElementAdapter) ((IAdaptable) element).getAdapter(ISystemViewElementAdapter.class); >+ >+ if (adapter != null) >+ { >+ if (adapter.hasChildren((IAdaptable)element)) >+ { >+ // Get the path for the element and use it for setting expanded state, >+ // so the proper TreeItem is expanded/collapsed >+ TreePath[] paths = s.getPathsFor(element); >+ if (paths == null || paths.length == 0 || paths[0] == null) return; >+ TreePath elementPath = paths[0]; >+ if (treeViewer.getExpandedState(elementPath)) >+ { >+ treeViewer.collapseSelected(); >+ } >+ else >+ { >+ treeViewer.expandSelected(); >+ } >+ } >+ else >+ { >+ adapter.handleDoubleClick(element); >+ } >+ } > /* > IStructuredSelection rseSSel = > (IStructuredSelection) event.getSelection();
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:
mober.at+eclipse
:
iplog+
Actions:
View
|
Diff
Attachments on
bug 187741
: 73455