Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(3858)

Unified Diff: chrome/browser/android/android_protocol_adapter.h

Issue 10880025: [Android] Fix handling of asset files loading. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Comments addressed Created 8 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: chrome/browser/android/android_protocol_adapter.h
diff --git a/chrome/browser/android/android_protocol_adapter.h b/chrome/browser/android/android_protocol_adapter.h
index 3cf11e801fdb5d48da38246fcc553d7b6b658bcd..108c1c96e7d746309d2fcc5552c34be4a75d4453 100644
--- a/chrome/browser/android/android_protocol_adapter.h
+++ b/chrome/browser/android/android_protocol_adapter.h
@@ -9,13 +9,30 @@
#include "net/url_request/url_request.h"
+namespace net {
+
+class URLRequestContextGetter;
+
+}
+
+// This class adds support for Android WebView-specific protocol schemes:
+//
+// - "content:" scheme is used for accessing data from Android content
+// providers, see http://developer.android.com/guide/topics/providers/
+// content-provider-basics.html#ContentURIs
+//
+// - "file:" scheme extension for accessing application assets and resources
+// (file:///android_asset/ and file:///android_res/), see
+// http://developer.android.com/reference/android/webkit/
+// WebSettings.html#setAllowFileAccess(boolean)
+//
class AndroidProtocolAdapter {
public:
static net::URLRequest::ProtocolFactory Factory;
- // Register the protocol factories for all supported Android protocol
- // schemes.
- static bool RegisterProtocols(JNIEnv* env);
+ // Register handlers for all supported Android protocol schemes.
+ static void RegisterProtocols(
+ JNIEnv* env, net::URLRequestContextGetter* context_getter);
private:
DISALLOW_IMPLICIT_CONSTRUCTORS(AndroidProtocolAdapter);
« no previous file with comments | « no previous file | chrome/browser/android/android_protocol_adapter.cc » ('j') | chrome/browser/android/android_protocol_adapter.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698