aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMarkus Keller2012-04-18 15:27:39 (EDT)
committerMatthias Sohn2012-04-18 15:27:39 (EDT)
commitfc52e1639e0d8cf4749177a696f8e3cb978ff405 (patch)
tree50a2c19cb56be705f7a62bd6cbd57099bc709e9c
parentc220bdae1d52635dfad621aac03b8847e7038be9 (diff)
downloadegit-fc52e1639e0d8cf4749177a696f8e3cb978ff405.zip
egit-fc52e1639e0d8cf4749177a696f8e3cb978ff405.tar.gz
egit-fc52e1639e0d8cf4749177a696f8e3cb978ff405.tar.bz2
Make order predictable when pulling multiple projectsrefs/changes/23/5623/2
https://git.eclipse.org/r/#/c/4937/ tried to make the order predictable, but HashMap was used again in two locations. Change-Id: I5bef6478eea34aff13af570f0932e2fc842fd8cb Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
-rw-r--r--org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/actions/RepositoryActionHandler.java5
1 files changed, 2 insertions, 3 deletions
diff --git a/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/actions/RepositoryActionHandler.java b/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/actions/RepositoryActionHandler.java
index 1a94dcc..980509b 100644
--- a/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/actions/RepositoryActionHandler.java
+++ b/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/actions/RepositoryActionHandler.java
@@ -16,7 +16,6 @@ import java.io.IOException;
import java.lang.reflect.Array;
import java.util.ArrayList;
import java.util.Arrays;
-import java.util.HashSet;
import java.util.Iterator;
import java.util.LinkedHashSet;
import java.util.Set;
@@ -297,7 +296,7 @@ abstract class RepositoryActionHandler extends AbstractHandler {
return getRepositoriesFor(selectedProjects);
IStructuredSelection selection = getSelection(event);
if (!selection.isEmpty()) {
- Set<Repository> repos = new HashSet<Repository>();
+ Set<Repository> repos = new LinkedHashSet<Repository>();
for (Object o : selection.toArray())
if (o instanceof Repository)
repos.add((Repository) o);
@@ -324,7 +323,7 @@ abstract class RepositoryActionHandler extends AbstractHandler {
return getRepositoriesFor(selectedProjects);
IStructuredSelection selection = getSelection();
if (!selection.isEmpty()) {
- Set<Repository> repos = new HashSet<Repository>();
+ Set<Repository> repos = new LinkedHashSet<Repository>();
for (Object o : selection.toArray())
if (o instanceof Repository)
repos.add((Repository) o);