| | |
| | | return new File(dir, shortFileName);
|
| | | }
|
| | |
|
| | | public static File getPhotoFile() {
|
| | | File dir = new File(MainActivity.getInstance().getFilesDir().getAbsolutePath());
|
| | | File[] photoFiles = dir.listFiles();
|
| | | if (photoFiles != null) {
|
| | | for (File file : photoFiles) {
|
| | | if (file.isDirectory()) {
|
| | | continue;
|
| | | }
|
| | | String name = file.getName();
|
| | | if (name.length() != "c248fe8f-6da5-4ec9-bffa-1a11bcf2fdc7".length()) {
|
| | | continue;
|
| | | }
|
| | | if (file.isFile()) {
|
| | | return file;
|
| | | }
|
| | | }
|
| | | }
|
| | | return null;
|
| | | }
|
| | |
|
| | |
|
| | | public static byte[] readFile(File file) {
|
| | | // Open file
|