Fix chrome upload with content uri

For android, the upload file dialog returns files with content uri scheme(content://).
This CL makes it possible for upload to work with this new file type.
It fixes both the form and fileapi based uploads.

BUG=278640

Review URL: https://codereview.chromium.org/75533002

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@236192 0039d316-1c4b-4281-b951-d872f2087c98


CrOS-Libchrome-Original-Commit: f12d1e1552d00cc2f4f38a37460dedd4737c5b05
diff --git a/base/files/file_path.h b/base/files/file_path.h
index 4d03da4..33beb0b 100644
--- a/base/files/file_path.h
+++ b/base/files/file_path.h
@@ -387,6 +387,15 @@
                                    const StringType& string2);
 #endif
 
+#if defined(OS_ANDROID)
+  // On android, file selection dialog can return a file with content uri
+  // scheme(starting with content://). Content uri needs to be opened with
+  // ContentResolver to guarantee that the app has appropriate permissions
+  // to access it.
+  // Returns true if the path is a content uri, or false otherwise.
+  bool IsContentUri() const;
+#endif
+
  private:
   // Remove trailing separators from this object.  If the path is absolute, it
   // will never be stripped any more than to refer to the absolute root