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

Unified Diff: Source/core/page/InjectedStyleSheet.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, 2 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/core/dom/StyleEngine.cpp ('k') | Source/core/page/PageGroup.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/page/InjectedStyleSheet.h
diff --git a/Source/core/page/UserStyleSheet.h b/Source/core/page/InjectedStyleSheet.h
similarity index 64%
rename from Source/core/page/UserStyleSheet.h
rename to Source/core/page/InjectedStyleSheet.h
index c5f8e197234cf9a4642a5ac0e4a12eabf7d3780a..cdee055660e54b5ea4cfbba3f5f330f176b7b652 100644
--- a/Source/core/page/UserStyleSheet.h
+++ b/Source/core/page/InjectedStyleSheet.h
@@ -23,51 +23,38 @@
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
*/
-#ifndef UserStyleSheet_h
-#define UserStyleSheet_h
+#ifndef InjectedStyleSheet_h
+#define InjectedStyleSheet_h
-#include "core/page/UserContentTypes.h"
-#include "core/page/UserStyleSheetTypes.h"
-#include "weborigin/KURL.h"
#include "wtf/Vector.h"
+#include "wtf/text/WTFString.h"
namespace WebCore {
-class UserStyleSheet {
+enum StyleInjectionTarget { InjectStyleInAllFrames, InjectStyleInTopFrameOnly };
+
+class InjectedStyleSheet {
WTF_MAKE_FAST_ALLOCATED;
public:
- UserStyleSheet()
- : m_injectedFrames(InjectInAllFrames)
- , m_level(UserStyleUserLevel)
- {
- }
-
- UserStyleSheet(const String& source, const KURL& url, const Vector<String>& whitelist, const Vector<String>& blacklist, UserContentInjectedFrames injectedFrames, UserStyleLevel level)
+ InjectedStyleSheet(const String& source, const Vector<String>& whitelist, StyleInjectionTarget injectedFrames)
: m_source(source)
- , m_url(url)
, m_whitelist(whitelist)
- , m_blacklist(blacklist)
, m_injectedFrames(injectedFrames)
- , m_level(level)
{
}
const String& source() const { return m_source; }
- const KURL& url() const { return m_url; }
const Vector<String>& whitelist() const { return m_whitelist; }
- const Vector<String>& blacklist() const { return m_blacklist; }
- UserContentInjectedFrames injectedFrames() const { return m_injectedFrames; }
- UserStyleLevel level() const { return m_level; }
+ StyleInjectionTarget injectedFrames() const { return m_injectedFrames; }
private:
String m_source;
- KURL m_url;
Vector<String> m_whitelist;
- Vector<String> m_blacklist;
- UserContentInjectedFrames m_injectedFrames;
- UserStyleLevel m_level;
+ StyleInjectionTarget m_injectedFrames;
};
+typedef Vector<OwnPtr<InjectedStyleSheet> > InjectedStyleSheetVector;
+
} // namespace WebCore
-#endif // UserStyleSheet_h
+#endif // InjectedStyleSheet_h
« no previous file with comments | « Source/core/dom/StyleEngine.cpp ('k') | Source/core/page/PageGroup.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698