From 58da86dfe87255dfef5c3b83eb0d0d31b421529b Mon Sep 17 00:00:00 2001 From: Konstantin Bulenkov Date: Fri, 22 Nov 2013 14:51:20 +0100 Subject: [PATCH] don't search classes if there is dot in pattern (cherry picked from commit f231438d3d50044033963cbdb4a5b0a9d7a69cf9) --- .../src/com/intellij/ide/actions/SearchEverywhereAction.java | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/platform/lang-impl/src/com/intellij/ide/actions/SearchEverywhereAction.java b/platform/lang-impl/src/com/intellij/ide/actions/SearchEverywhereAction.java index 0d1c34300e42..81b51bfb03ba 100644 --- a/platform/lang-impl/src/com/intellij/ide/actions/SearchEverywhereAction.java +++ b/platform/lang-impl/src/com/intellij/ide/actions/SearchEverywhereAction.java @@ -1213,6 +1213,11 @@ public class SearchEverywhereAction extends AnAction implements CustomComponentA } private void buildClasses(String pattern, boolean includeLibraries) { + if (pattern.indexOf('.') != -1) { + //todo[kb] it's not a mistake. If we search for "*.png" or "index.xml" in SearchEverywhere + //todo[kb] we don't want to see Java classes started with Png or Xml. This approach should be reworked someday. + return; + } boolean includeLibs = includeLibraries || showAll.get(); int clsCounter = 0; final int maxCount = includeLibraries ? 5 : MAX_CLASSES;