Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Valenta2006-01-26 16:41:11 +0000
committerMichael Valenta2006-01-26 16:41:11 +0000
commit7091ddc69cba7e994ee1b50d36ca583a8060cc1f (patch)
tree0e36d17c34683a3dc4023b006c655731f82baefa
parent1a0c120be0fee1bce3fc83e202ff6f7b5db324c1 (diff)
downloadeclipse.platform.team-7091ddc69cba7e994ee1b50d36ca583a8060cc1f.tar.gz
eclipse.platform.team-7091ddc69cba7e994ee1b50d36ca583a8060cc1f.tar.xz
eclipse.platform.team-7091ddc69cba7e994ee1b50d36ca583a8060cc1f.zip
Put proper labels on model participants
-rw-r--r--bundles/org.eclipse.team.cvs.ui/plugin.properties2
-rw-r--r--bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/actions/OutgoingChangesDialog.java2
-rw-r--r--bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/mappings/CVSResourceMappingParticipant.java11
-rw-r--r--bundles/org.eclipse.team.ui/src/org/eclipse/team/ui/operations/ResourceMappingMergeOperation.java2
-rw-r--r--bundles/org.eclipse.team.ui/src/org/eclipse/team/ui/operations/ResourceMappingSynchronizeParticipant.java21
5 files changed, 33 insertions, 5 deletions
diff --git a/bundles/org.eclipse.team.cvs.ui/plugin.properties b/bundles/org.eclipse.team.cvs.ui/plugin.properties
index 0e758a153..a75eb73d7 100644
--- a/bundles/org.eclipse.team.cvs.ui/plugin.properties
+++ b/bundles/org.eclipse.team.cvs.ui/plugin.properties
@@ -25,7 +25,7 @@ SharingWizard.name=CVS
WorkspaceSynchronizeWizard.name=CVS
WorkspaceSynchronizeWizard.description=Synchronize resources in the workspace with their associated remote CVS repository.
CVSWorkspaceParticipant=CVS
-CVSResourceMappingParticipant=CVS (Model)
+CVSResourceMappingParticipant=CVS
CVSMergeParticipant=CVS Merge
CVSCompareParticipant=CVS Compare
diff --git a/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/actions/OutgoingChangesDialog.java b/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/actions/OutgoingChangesDialog.java
index acc54518f..f68413c20 100644
--- a/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/actions/OutgoingChangesDialog.java
+++ b/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/actions/OutgoingChangesDialog.java
@@ -110,7 +110,7 @@ public class OutgoingChangesDialog extends DetailsDialog {
private ResourceMappingSynchronizeParticipant createParticipant() throws InvocationTargetException, InterruptedException {
ISynchronizationContext context = createSynchronizationContext(scope);
- ResourceMappingSynchronizeParticipant participant = new ResourceMappingSynchronizeParticipant(context, title);
+ ResourceMappingSynchronizeParticipant participant = ResourceMappingSynchronizeParticipant.createParticipant(context, title);
participant.setMergingEnabled(false);
return participant;
}
diff --git a/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/mappings/CVSResourceMappingParticipant.java b/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/mappings/CVSResourceMappingParticipant.java
index e8cb4dd0a..7bad626b4 100644
--- a/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/mappings/CVSResourceMappingParticipant.java
+++ b/bundles/org.eclipse.team.cvs.ui/src/org/eclipse/team/internal/ccvs/ui/mappings/CVSResourceMappingParticipant.java
@@ -10,12 +10,15 @@
*******************************************************************************/
package org.eclipse.team.internal.ccvs.ui.mappings;
+import org.eclipse.core.runtime.CoreException;
import org.eclipse.jface.action.*;
import org.eclipse.team.core.mapping.ISynchronizationContext;
import org.eclipse.team.internal.ccvs.ui.Policy;
import org.eclipse.team.internal.ccvs.ui.actions.*;
import org.eclipse.team.internal.ccvs.ui.subscriber.*;
+import org.eclipse.team.internal.ui.TeamUIPlugin;
import org.eclipse.team.internal.ui.Utils;
+import org.eclipse.team.ui.TeamUI;
import org.eclipse.team.ui.mapping.SynchronizationActionProvider;
import org.eclipse.team.ui.operations.MergeActionGroup;
import org.eclipse.team.ui.operations.ResourceMappingSynchronizeParticipant;
@@ -128,7 +131,13 @@ public class CVSResourceMappingParticipant extends
}
public CVSResourceMappingParticipant(ISynchronizationContext context, String name) {
- super(context, name);
+ super(context);
+ try {
+ setInitializationData(TeamUI.getSynchronizeManager().getParticipantDescriptor("org.eclipse.team.cvs.ui.workspace-participant")); //$NON-NLS-1$
+ } catch (CoreException e) {
+ TeamUIPlugin.log(e);
+ }
+ setSecondaryId(Long.toString(System.currentTimeMillis()));
}
protected void initializeConfiguration(ISynchronizePageConfiguration configuration) {
diff --git a/bundles/org.eclipse.team.ui/src/org/eclipse/team/ui/operations/ResourceMappingMergeOperation.java b/bundles/org.eclipse.team.ui/src/org/eclipse/team/ui/operations/ResourceMappingMergeOperation.java
index 3a3fa1025..6bbb07ef5 100644
--- a/bundles/org.eclipse.team.ui/src/org/eclipse/team/ui/operations/ResourceMappingMergeOperation.java
+++ b/bundles/org.eclipse.team.ui/src/org/eclipse/team/ui/operations/ResourceMappingMergeOperation.java
@@ -388,7 +388,7 @@ public abstract class ResourceMappingMergeOperation extends ResourceMappingOpera
* @return a newly created synchronize pariticipant to be used by this operation
*/
protected ResourceMappingSynchronizeParticipant createParticipant() {
- return new ResourceMappingSynchronizeParticipant(getContext(), getJobName());
+ return ResourceMappingSynchronizeParticipant.createParticipant(getContext(), getJobName());
}
}
diff --git a/bundles/org.eclipse.team.ui/src/org/eclipse/team/ui/operations/ResourceMappingSynchronizeParticipant.java b/bundles/org.eclipse.team.ui/src/org/eclipse/team/ui/operations/ResourceMappingSynchronizeParticipant.java
index 8f6a1553a..fbb44f9f6 100644
--- a/bundles/org.eclipse.team.ui/src/org/eclipse/team/ui/operations/ResourceMappingSynchronizeParticipant.java
+++ b/bundles/org.eclipse.team.ui/src/org/eclipse/team/ui/operations/ResourceMappingSynchronizeParticipant.java
@@ -58,7 +58,16 @@ public class ResourceMappingSynchronizeParticipant extends
* @param context the synchronization context
* @param name the name of the participant
*/
- public ResourceMappingSynchronizeParticipant(ISynchronizationContext context, String name) {
+ public static ResourceMappingSynchronizeParticipant createParticipant(ISynchronizationContext context, String name) {
+ return new ResourceMappingSynchronizeParticipant(context, name);
+ }
+
+ /*
+ * Create a participant for the given context
+ * @param context the synchronization context
+ * @param name the name of the participant
+ */
+ private ResourceMappingSynchronizeParticipant(ISynchronizationContext context, String name) {
initializeContext(context);
try {
setInitializationData(TeamUI.getSynchronizeManager().getParticipantDescriptor("org.eclipse.team.ui.synchronization_context_synchronize_participant")); //$NON-NLS-1$
@@ -71,6 +80,16 @@ public class ResourceMappingSynchronizeParticipant extends
refreshSchedule = new SubscriberRefreshSchedule(createRefreshable());
}
+ /**
+ * Create a participant for the given context
+ * @param context the synchronization context
+ */
+ public ResourceMappingSynchronizeParticipant(ISynchronizationContext context) {
+ initializeContext(context);
+ mergingEnabled = context instanceof IMergeContext;
+ refreshSchedule = new SubscriberRefreshSchedule(createRefreshable());
+ }
+
/* (non-Javadoc)
* @see org.eclipse.team.ui.synchronize.AbstractSynchronizeParticipant#getName()
*/

Back to the top