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

Unified Diff: public/web/WebView.h

Issue 25505007: Remove bogus use of the term "user style" in Blink and Blink API (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Patch for landing Created 7 years, 3 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 | « Source/web/WebViewImpl.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: public/web/WebView.h
diff --git a/public/web/WebView.h b/public/web/WebView.h
index 9145e03ce557939156181f47027c0309d59a8700..4f8d4b5a17afaed933cd270e38d42589180147df 100644
--- a/public/web/WebView.h
+++ b/public/web/WebView.h
@@ -74,12 +74,19 @@ public:
BLINK_EXPORT static const float minPageScaleFactor;
BLINK_EXPORT static const float maxPageScaleFactor;
+ enum StyleInjectionTarget {
+ InjectStyleInAllFrames,
+ InjectStyleInTopFrameOnly
+ };
+
+ // FIXME: Remove this enum once callers have switched to StyleInjectionTarget
// Controls which frames user content is injected into.
enum UserContentInjectIn {
UserContentInjectInAllFrames,
UserContentInjectInTopFrameOnly
};
+ // FIXME: Remove this enum once callers stop referring to it.
// Controls which documents user styles are injected into.
enum UserStyleInjectionTime {
UserStyleInjectInExistingDocuments,
@@ -478,7 +485,11 @@ public:
unsigned inactiveBackgroundColor,
unsigned inactiveForegroundColor) = 0;
- // User scripts --------------------------------------------------------
+ // Injected style ------------------------------------------------------
+ BLINK_EXPORT static void injectStyleSheet(const WebString& sourceCode, const WebVector<WebString>& patterns, StyleInjectionTarget);
+ BLINK_EXPORT static void removeInjectedStyleSheets();
+
+ // FIXME: Remove these two methods once their callers have switched to the new names above.
BLINK_EXPORT static void addUserStyleSheet(const WebString& sourceCode,
const WebVector<WebString>& patterns,
UserContentInjectIn injectIn,
« no previous file with comments | « Source/web/WebViewImpl.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698