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

Unified Diff: ios/web/public/web_client.h

Issue 986743003: Upstream (most of) ios/web/public (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix namespace comment Created 5 years, 9 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
« no previous file with comments | « ios/web/public/user_metrics.h ('k') | ios/web/public/web_client.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ios/web/public/web_client.h
diff --git a/ios/web/public/web_client.h b/ios/web/public/web_client.h
index 41ee68089ddf442d3994466d2eede74eb62cd85a..d4bd2b04c16d4fab7589b3d95dff1302172a46b1 100644
--- a/ios/web/public/web_client.h
+++ b/ios/web/public/web_client.h
@@ -10,6 +10,7 @@
#include "base/strings/string16.h"
#include "base/strings/string_piece.h"
+#include "ios/web/public/web_view_type.h"
#include "ui/base/layout.h"
namespace base {
@@ -20,8 +21,10 @@ class GURL;
#ifdef __OBJC__
@class UIWebView;
+@class NSString;
#else
class UIWebView;
+class NSString;
#endif
namespace web {
@@ -61,6 +64,9 @@ class WebClient {
// Used to decide URL formating.
virtual std::string GetAcceptLangs(BrowserState* state) const;
+ // Returns the embedding application locale string.
+ virtual std::string GetApplicationLocale() const;
+
// Returns true if URL has application specific schema. Embedder must return
// true for every custom app specific schema it supports. For example Chromium
// browser would return true for "chrome://about" URL.
@@ -100,6 +106,10 @@ class WebClient {
// Gives the embedder a chance to add url rewriters to the BrowserURLRewriter
// singleton.
virtual void PostBrowserURLRewriterCreation(BrowserURLRewriter* rewriter) {}
+
+ // Gives the embedder a chance to provide the JavaScript to be injected into
+ // the web view as early as possible. Result must not be nil.
+ virtual NSString* GetEarlyPageScript(WebViewType web_view_type) const;
};
} // namespace web
« no previous file with comments | « ios/web/public/user_metrics.h ('k') | ios/web/public/web_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698