summaryrefslogtreecommitdiffstatsabout
diff options
context:
space:
mode:
authorDariusz Luksza2010-06-20 17:30:48 (EDT)
committer Matthias Sohn2010-06-20 17:30:48 (EDT)
commita58311f91838f1c8a6f6f31d99cb343f1acc1d18 (patch)
treea48e53760d89b5ecddb169ba86adbcaae4c1394c
parent41ada1c42f7a02d06e8e2030f4c81455e2319aca (diff)
downloadegit-a58311f91838f1c8a6f6f31d99cb343f1acc1d18.zip
egit-a58311f91838f1c8a6f6f31d99cb343f1acc1d18.tar.gz
egit-a58311f91838f1c8a6f6f31d99cb343f1acc1d18.tar.bz2
Show repository path in Synchronize Viewrefs/changes/06/906/2
Set repository path as name of SubscriberParticipant. This name is shown in the synchronization view and allows to distinguish which repository we are currently synchronizing. Bug: 317369 Change-Id: Iccdc5f16d68b1abdc2b599ed20a2204c3b6a5b7e Signed-off-by: Dariusz Luksza <dariusz@luksza.org> Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
-rw-r--r--org.eclipse.egit.core/src/org/eclipse/egit/core/synchronize/dto/GitSynchronizeDataSet.java12
-rw-r--r--org.eclipse.egit.ui/src/org/eclipse/egit/ui/UIText.java3
-rw-r--r--org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/synchronize/GitSubscriberParticipant.java3
-rw-r--r--org.eclipse.egit.ui/src/org/eclipse/egit/ui/uitext.properties2
4 files changed, 14 insertions, 6 deletions
diff --git a/org.eclipse.egit.core/src/org/eclipse/egit/core/synchronize/dto/GitSynchronizeDataSet.java b/org.eclipse.egit.core/src/org/eclipse/egit/core/synchronize/dto/GitSynchronizeDataSet.java
index 1a586bb..a9d28f8 100644
--- a/org.eclipse.egit.core/src/org/eclipse/egit/core/synchronize/dto/GitSynchronizeDataSet.java
+++ b/org.eclipse.egit.core/src/org/eclipse/egit/core/synchronize/dto/GitSynchronizeDataSet.java
@@ -85,4 +85,16 @@ public class GitSynchronizeDataSet implements Iterable<GitSynchronizeData> {
return resource.toArray(new IResource[resource.size()]);
}
+ @Override
+ public String toString() {
+ StringBuilder builder = new StringBuilder();
+
+ for (GitSynchronizeData data : gsd) {
+ builder.append(data.getRepository().getWorkDir());
+ builder.append(" "); //$NON-NLS-1$
+ }
+
+ return builder.toString();
+ }
+
}
diff --git a/org.eclipse.egit.ui/src/org/eclipse/egit/ui/UIText.java b/org.eclipse.egit.ui/src/org/eclipse/egit/ui/UIText.java
index 0d7ea0c..d1502c0 100644
--- a/org.eclipse.egit.ui/src/org/eclipse/egit/ui/UIText.java
+++ b/org.eclipse.egit.ui/src/org/eclipse/egit/ui/UIText.java
@@ -2048,9 +2048,6 @@ public class UIText extends NLS {
public static String GitBranchSynchronizeWizardPage_deselectAll;
/** */
- public static String GitBranchSubscriberParticipant_git;
-
- /** */
public static String RemoteSelectionCombo_remoteName;
/** */
diff --git a/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/synchronize/GitSubscriberParticipant.java b/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/synchronize/GitSubscriberParticipant.java
index 8974032..8f47f5b 100644
--- a/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/synchronize/GitSubscriberParticipant.java
+++ b/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/synchronize/GitSubscriberParticipant.java
@@ -43,7 +43,7 @@ public class GitSubscriberParticipant extends SubscriberParticipant {
public GitSubscriberParticipant(GitSynchronizeDataSet data) {
ResourceVariantByteStore store = new SessionResourceVariantByteStore();
setSubscriber(new GitResourceVariantTreeSubscriber(data, store));
- setName(UIText.GitBranchSubscriberParticipant_git);
+ setName(data.toString());
}
@Override
@@ -95,6 +95,7 @@ public class GitSubscriberParticipant extends SubscriberParticipant {
void reset(GitSynchronizeDataSet data) {
GitResourceVariantTreeSubscriber subscriber = (GitResourceVariantTreeSubscriber) getSubscriber();
subscriber.reset(data);
+ setName(data.toString());
reset();
}
diff --git a/org.eclipse.egit.ui/src/org/eclipse/egit/ui/uitext.properties b/org.eclipse.egit.ui/src/org/eclipse/egit/ui/uitext.properties
index 17c721e..c2e443b 100644
--- a/org.eclipse.egit.ui/src/org/eclipse/egit/ui/uitext.properties
+++ b/org.eclipse.egit.ui/src/org/eclipse/egit/ui/uitext.properties
@@ -727,8 +727,6 @@ GitBranchSynchronizeWizardPage_branches=Branches
GitBranchSynchronizeWizardPage_selectAll=Select All
GitBranchSynchronizeWizardPage_deselectAll=Deselect All
-GitBranchSubscriberParticipant_git=Git
-
RemoteSelectionCombo_remoteName=Remote Repository:
RemoteSelectionCombo_remoteRef=Ref: