Bug 124338 [Dialogs] ResourceSelectionDialog should allow to implement custom acceptance criteria
I suggest to refactor ResourceSelectionDialog so there will be methods to access checked items and enable OK button respectively. This should allow to implement custom strategy to accept selected elements.
bundles/org.eclipse.ui.ide/extensions/org/eclipse/ui/dialogs/ResourceSearcher.java
}
		if (!text.equals("") && !text.endsWith("*")) { 
			return text + "*"; 
		}
		return text;
	}
	private void scheduleSearchJob() {
		searchJobTicket++;
		if (lastComplitedMacher != null
				&& lastComplitedMacher.match(patternString)) {
			searchJob = new ResourceCachedResultJob(searchJobTicket,
					lastCompletedResult, model, (ResourceHistory) history);
		} else {
			lastComplitedMacher = null;
			lastCompletedResult = null;
			searchJob = new ResourceSearchEngineJob(searchJobTicket, model,
					(ResourceHistory) history, this);
		}
		searchJob.schedule();
	}
	private void rememberResult(int ticket, final List result) {
		if (ticket == searchJobTicket) {
			if (lastCompletedResult == null) {
				lastComplitedMacher = stringMatcher;
				lastCompletedResult = result;
			}
		}
	}
	/**
	 * Returns whether derived resources should be shown in the list. The