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

Unified Diff: Source/core/dom/Document.h

Issue 758913002: Implement the 'document.origin' accessor. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Moar assertions. Created 6 years, 1 month 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: Source/core/dom/Document.h
diff --git a/Source/core/dom/Document.h b/Source/core/dom/Document.h
index 662468f3e3332e81fef7c1737e24a464977a7eca..37e99ceb8b72968b3381c2494e6b748d6cbe6a06 100644
--- a/Source/core/dom/Document.h
+++ b/Source/core/dom/Document.h
@@ -349,6 +349,8 @@ public:
virtual KURL baseURI() const override final;
+ String origin() const { return securityOrigin()->toString(); }
+
String visibilityState() const;
bool hidden() const;
void didChangeVisibilityState();
« no previous file with comments | « LayoutTests/http/tests/security/resources/postmessage-document-origin.html ('k') | Source/core/dom/Document.idl » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698