public long getContentLength() { int size = 0; size += topBytes.length; try { InputStream mediaStream = AppMonk.getContentResolver().openInputStream(media); size += IOTricks.countBytesInStream(mediaStream); mediaStream.close(); } catch (Exception e) { return 0; } size += bottomBytes.length; return size; }