Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(241)

Unified Diff: editor/tools/plugins/com.google.dart.tools.search/src/com/google/dart/tools/search/internal/ui/text/TextSearchScopeFilter.java

Issue 10984082: Fix to exclude patch files from search results (dartbug.com/5492). (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « editor/tools/plugins/com.google.dart.tools.core/src/com/google/dart/tools/core/DartCore.java ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: editor/tools/plugins/com.google.dart.tools.search/src/com/google/dart/tools/search/internal/ui/text/TextSearchScopeFilter.java
===================================================================
--- editor/tools/plugins/com.google.dart.tools.search/src/com/google/dart/tools/search/internal/ui/text/TextSearchScopeFilter.java (revision 12972)
+++ editor/tools/plugins/com.google.dart.tools.search/src/com/google/dart/tools/search/internal/ui/text/TextSearchScopeFilter.java (working copy)
@@ -37,7 +37,7 @@
* @return <code>true</code> if the file should be excluded, <code>false</code> otherwise
*/
public static boolean isFiltered(File file) {
- return file.isFile() && isExternaFileNameFiltered(file.getName());
+ return isPatchFile(file) || (file.isFile() && isExternaFileNameFiltered(file.getName()));
}
/**
@@ -65,6 +65,10 @@
return true;
}
+ private static boolean isPatchFile(File file) {
+ return DartCore.isPatchfile(file);
+ }
+
/**
* Checks if the given file name should be filtered out of a search scope.
*
« no previous file with comments | « editor/tools/plugins/com.google.dart.tools.core/src/com/google/dart/tools/core/DartCore.java ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698