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 28324 Details for
Bug 112025
(PatchAttached) Add "pin" icon marker for pinned syncronizaations to "synchronize" drop-down
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]
Draft implementation cut for the proposed feature
pinned.overlay.patch (text/plain), 4.02 KB, created by
Eugene Kuleshov
on 2005-10-17 03:18:25 EDT
(
hide
)
Description:
Draft implementation cut for the proposed feature
Filename:
MIME Type:
Creator:
Eugene Kuleshov
Created:
2005-10-17 03:18:25 EDT
Size:
4.02 KB
patch
obsolete
>Index: src/org/eclipse/team/internal/ui/synchronize/actions/ShowSynchronizeParticipantAction.java >=================================================================== >RCS file: /home/eclipse/org.eclipse.team.ui/src/org/eclipse/team/internal/ui/synchronize/actions/ShowSynchronizeParticipantAction.java,v >retrieving revision 1.7 >diff -u -r1.7 ShowSynchronizeParticipantAction.java >--- src/org/eclipse/team/internal/ui/synchronize/actions/ShowSynchronizeParticipantAction.java 22 Feb 2005 19:46:01 -0000 1.7 >+++ src/org/eclipse/team/internal/ui/synchronize/actions/ShowSynchronizeParticipantAction.java 17 Oct 2005 07:14:07 -0000 >@@ -11,15 +11,24 @@ > package org.eclipse.team.internal.ui.synchronize.actions; > > import org.eclipse.jface.action.Action; >+import org.eclipse.jface.action.IAction; >+import org.eclipse.jface.resource.CompositeImageDescriptor; >+import org.eclipse.jface.util.IPropertyChangeListener; >+import org.eclipse.jface.util.PropertyChangeEvent; >+import org.eclipse.swt.graphics.ImageData; >+import org.eclipse.swt.graphics.Point; > import org.eclipse.team.core.TeamException; >+import org.eclipse.team.internal.ui.TeamUIPlugin; > import org.eclipse.team.internal.ui.Utils; > import org.eclipse.team.internal.ui.synchronize.SynchronizeView; >+import org.eclipse.team.ui.synchronize.AbstractSynchronizeParticipant; >+import org.eclipse.team.ui.synchronize.ISynchronizeParticipant; > import org.eclipse.team.ui.synchronize.ISynchronizeParticipantReference; > import org.eclipse.team.ui.synchronize.ISynchronizeView; > >-public class ShowSynchronizeParticipantAction extends Action { >+public class ShowSynchronizeParticipantAction extends Action implements IPropertyChangeListener { > >- private ISynchronizeParticipantReference fPage; >+ private ISynchronizeParticipantReference fPage; > private ISynchronizeView fView; > > public void run() { >@@ -43,6 +52,51 @@ > super(Utils.shortenText(SynchronizeView.MAX_NAME_LENGTH, ref.getDisplayName()), Action.AS_RADIO_BUTTON); > fPage = ref; > fView = view; >- setImageDescriptor(ref.getDescriptor().getImageDescriptor()); >+ setImageDescriptor( new ParticipantOverlay( ref)); >+ >+ try { >+ fPage.getParticipant().addPropertyChangeListener( this); >+ } catch( TeamException e) { >+ Utils.handle(e); >+ } >+ } >+ >+ public void propertyChange( PropertyChangeEvent event) { >+ if( AbstractSynchronizeParticipant.P_PINNED.equals( event.getProperty())) { >+ setImageDescriptor(new ParticipantOverlay( fPage)); >+ } >+ } >+ >+ >+ private static final class ParticipantOverlay extends CompositeImageDescriptor { >+ private ISynchronizeParticipantReference ref; >+ >+ private ImageData overlayData = TeamUIPlugin.getImageDescriptor( "elcl16/pinned_ovr.gif").getImageData(); >+ private ImageData imageData; >+ >+ private ISynchronizeParticipant participant; >+ >+ private ParticipantOverlay( ISynchronizeParticipantReference ref) { >+ this.ref = ref; >+ try { >+ this.participant = ref.getParticipant(); >+ this.imageData = ref.getDescriptor().getImageDescriptor().getImageData(); >+ } catch( TeamException ex) { >+ TeamUIPlugin.log(ex); >+ } >+ } >+ >+ protected void drawCompositeImage( int width, int height) { >+ drawImage(this.imageData, 0, 0); >+ if(this.participant.isPinned()) { >+ drawImage(overlayData, this.imageData.width - overlayData.width, 0); >+ } >+ } >+ >+ protected Point getSize() { >+ return new Point( this.imageData.width, this.imageData.height); >+ } >+ > } > } >+ >Index: icons/full/elcl16/pinned_ovr.gif >=================================================================== >RCS file: icons/full/elcl16/pinned_ovr.gif >diff -N icons/full/elcl16/pinned_ovr.gif >--- /dev/null 1 Jan 1970 00:00:00 -0000 >+++ icons/full/elcl16/pinned_ovr.gif 1 Jan 1970 00:00:00 -0000 >@@ -0,0 +1,2 @@ >+GIF89a³2]r6a.R'>5Xr¶I}µQ£Ê?§nÿÿÿÿÿÿ!ù,"pÉE >+Ksn&ÆVdA¡F(1²½J?E;
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 112025
: 28324