[BugFix]修復firebase的崩潰

This commit is contained in:
wushaocheng
2023-03-29 21:07:04 +08:00
parent 17d7c10068
commit 1bae5d8f53
4 changed files with 6 additions and 36 deletions

View File

@@ -570,29 +570,5 @@ public class WatchMessagePictureActivity extends UI {
});
});
// String srcFilename = attachment.getFileName();
// //默认jpg
// String extension = TextUtils.isEmpty(attachment.getExtension()) ? "jpg" : attachment.getExtension();
// srcFilename += ("." + extension);
//
// String picPath = StorageUtil.getSystemImagePath();
// String dstPath = picPath + srcFilename;
// if (AttachmentStore.copy(path, dstPath) != -1) {
// try {
// ContentValues values = new ContentValues(2);
// values.put(MediaStore.Images.Media.MIME_TYPE, C.MimeType.MIME_JPEG);
// values.put(MediaStore.Images.Media.DATA, dstPath);
// getContentResolver().insert(MediaStore.Images.Media.EXTERNAL_CONTENT_URI, values);
//// Toast.makeText(WatchMessagePictureActivity.this, getString(R.string.picture_save_to), Toast.LENGTH_LONG).show();
// SingleToastUtil.showToastShort(R.string.picture_save_to);
// } catch (Exception e) {
// // may be java.lang.UnsupportedOperationException
//// Toast.makeText(WatchMessagePictureActivity.this, getString(R.string.picture_save_fail), Toast.LENGTH_LONG).show();
// SingleToastUtil.showToastShort(R.string.picture_save_fail);
// }
// } else {
//// Toast.makeText(WatchMessagePictureActivity.this, getString(R.string.picture_save_fail), Toast.LENGTH_LONG).show();
// SingleToastUtil.showToastShort(R.string.picture_save_fail);
// }
}
}