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
private static final String NODE_ROOT = "resourceInfoHistroy"; 
		private static final String NODE_TYPE_INFO = "resourceInfo"; 
		private static ResourceHistory fgInstance;
		public static synchronized ResourceHistory getInstance() {
			if (fgInstance == null)
				fgInstance = new ResourceHistory();
			return fgInstance;
		}
		private ResourceHistory() {
			super(NODE_ROOT, NODE_TYPE_INFO);
		}
		public synchronized boolean contains(IResource resource) {
			return super.contains(resource);
		}
		public synchronized void accessed(IResource resource) {
			super.accessed(resource);
		}
		public synchronized IResource remove(IResource resource) {
			return (IResource) super.remove(resource);
		}
		public synchronized IResource[] getMatchedElements(
				StringMatcher matcher, IContainer container) {