aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTomasz Zarna2011-11-04 10:14:41 -0400
committerMatthias Sohn2011-11-04 10:14:41 -0400
commit0af999b145ad7124793b0d468652a8818dcba2c7 (patch)
treee705c50e8309d00d1ba2f7d3831ea41a1c5d50e2
parentd8e4035759bf2177d7050f71263c4631ff7e7bf0 (diff)
downloadegit-0af999b145ad7124793b0d468652a8818dcba2c7.zip
egit-0af999b145ad7124793b0d468652a8818dcba2c7.tar.gz
egit-0af999b145ad7124793b0d468652a8818dcba2c7.tar.xz
Filtering doesn't work on selected branches in the Clone wizard
Selected branches were always displayed, no matter if they matched the filter or not. This patch changes that, and displays only branches that match the filter. Bug: 362051 Change-Id: Iec18e9084279292a142f43048cf79c8df606d42d Signed-off-by: Matthias Sohn <matthias.sohn@sap.com>
-rw-r--r--org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/clone/SourceBranchPage.java13
1 files changed, 2 insertions, 11 deletions
diff --git a/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/clone/SourceBranchPage.java b/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/clone/SourceBranchPage.java
index d50bd08..120ad14 100644
--- a/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/clone/SourceBranchPage.java
+++ b/org.eclipse.egit.ui/src/org/eclipse/egit/ui/internal/clone/SourceBranchPage.java
@@ -123,17 +123,8 @@ class SourceBranchPage extends WizardPage {
label = new Label(panel, SWT.NONE);
label.setLayoutData(new GridData(SWT.FILL, SWT.TOP, true, false));
- PatternFilter filter = new PatternFilter() {
- @Override
- public boolean isElementVisible(Viewer viewer, Object element) {
- if (getSelectedBranches().contains(element))
- return true;
- return super.isElementVisible(viewer, element);
- }
- };
-
- FilteredCheckboxTree fTree = new FilteredCheckboxTree(panel, null, SWT.NONE,
- filter);
+ FilteredCheckboxTree fTree = new FilteredCheckboxTree(panel, null,
+ SWT.NONE, new PatternFilter());
refsViewer = fTree.getCheckboxTreeViewer();
ITreeContentProvider provider = new ITreeContentProvider() {