(FileHandle themeDir, String themeName, boolean silent)
| 61 | })), null, false, true)); |
| 62 | } |
| 63 | public static boolean isThemeValid(FileHandle themeDir, String themeName, boolean silent) { |
| 64 | int missing = 0; |
| 65 | if (!themeDir.child("bg_splash.png").exists()) { |
| 66 | if (!silent) |
| 67 | System.err.println(themeDir + themeName + "/bg_splash.png not found."); |
| 68 | missing++; |
| 69 | } |
| 70 | if (!themeDir.child("bg_match.jpg").exists()) { |
| 71 | if (!silent) |
| 72 | System.err.println(themeDir + themeName + "/bg_match.jpg not found."); |
| 73 | missing++; |
| 74 | } |
| 75 | if (!themeDir.child("bg_texture.jpg").exists()) { |
| 76 | if (!silent) |
| 77 | System.err.println(themeDir + themeName + "/bg_texture.jpg not found."); |
| 78 | missing++; |
| 79 | } |
| 80 | if (!themeDir.child("sprite_icons.png").exists()) { |
| 81 | if (!silent) |
| 82 | System.err.println(themeDir + themeName + "/sprite_icons.png not found."); |
| 83 | missing++; |
| 84 | } |
| 85 | if (!themeDir.child("font1.ttf").exists()) { |
| 86 | if (!silent) |
| 87 | System.err.println(themeDir + themeName + "/font1.ttf not found."); |
| 88 | missing++; |
| 89 | } |
| 90 | return missing == 0; |
| 91 | } |
| 92 | private static void checkThemeDir(FileHandle themeDir, String themeName) { |
| 93 | if (themeDir == null || !themeDir.exists() || !themeDir.isDirectory()) { |
| 94 | System.err.println("Skin not found. Defaulting to fallback_skin."); |
no outgoing calls
no test coverage detected