am f9e0b264: Move check for hidden files in the proper method.

Merge commit 'f9e0b264422d086066a9d9deb2118617735e8d65' into eclair-mr2

* commit 'f9e0b264422d086066a9d9deb2118617735e8d65':
  Move check for hidden files in the proper method.
This commit is contained in:
Xavier Ducrohet
2009-11-03 11:34:02 -08:00
committed by Android Git Automerger

View File

@@ -68,10 +68,6 @@ public class JavaResourceFilter implements IZipEntryFilter {
* @return true if the file should be packaged as standard java resources. * @return true if the file should be packaged as standard java resources.
*/ */
public static boolean checkFileForPackaging(String fileName) { public static boolean checkFileForPackaging(String fileName) {
if (fileName.charAt(0) == '.') { // ignore hidden files.
return false;
}
String[] fileSegments = fileName.split("\\."); String[] fileSegments = fileName.split("\\.");
String fileExt = ""; String fileExt = "";
if (fileSegments.length > 1) { if (fileSegments.length > 1) {
@@ -88,7 +84,11 @@ public class JavaResourceFilter implements IZipEntryFilter {
* @return true if the file should be packaged as standard java resources. * @return true if the file should be packaged as standard java resources.
*/ */
public static boolean checkFileForPackaging(String fileName, String extension) { public static boolean checkFileForPackaging(String fileName, String extension) {
// Note: this method is used by ApkBuilder // Note: this method is used by com.android.ide.eclipse.adt.internal.build.ApkBuilder
if (fileName.charAt(0) == '.') { // ignore hidden files.
return false;
}
return "aidl".equalsIgnoreCase(extension) == false && // Aidl files return "aidl".equalsIgnoreCase(extension) == false && // Aidl files
"java".equalsIgnoreCase(extension) == false && // Java files "java".equalsIgnoreCase(extension) == false && // Java files
"class".equalsIgnoreCase(extension) == false && // Java class files "class".equalsIgnoreCase(extension) == false && // Java class files