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

Side by Side Diff: third_party/WebKit/Source/platform/exported/WebSecurityOrigin.cpp

Issue 1723753002: Make Document::isSecureContext() work for OOPIFs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: more rebase fixups Created 4 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010 Google Inc. All rights reserved. 2 * Copyright (C) 2010 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after
116 ASSERT(other.m_private); 116 ASSERT(other.m_private);
117 return m_private->canAccess(other.m_private); 117 return m_private->canAccess(other.m_private);
118 } 118 }
119 119
120 bool WebSecurityOrigin::canRequest(const WebURL& url) const 120 bool WebSecurityOrigin::canRequest(const WebURL& url) const
121 { 121 {
122 ASSERT(m_private); 122 ASSERT(m_private);
123 return m_private->canRequest(url); 123 return m_private->canRequest(url);
124 } 124 }
125 125
126 bool WebSecurityOrigin::isPotentiallyTrustworthy(WebString& errorMessage) const 126 bool WebSecurityOrigin::isPotentiallyTrustworthy() const
127 { 127 {
128 ASSERT(m_private); 128 ASSERT(m_private);
129 bool result = m_private->isPotentiallyTrustworthy(); 129 return m_private->isPotentiallyTrustworthy();
130 if (!result)
131 errorMessage = WTF::String(m_private->isPotentiallyTrustworthyErrorMessa ge());
132 return result;
133 } 130 }
134 131
135 WebString WebSecurityOrigin::toString() const 132 WebString WebSecurityOrigin::toString() const
136 { 133 {
137 ASSERT(m_private); 134 ASSERT(m_private);
138 return m_private->toString(); 135 return m_private->toString();
139 } 136 }
140 137
141 WebString WebSecurityOrigin::databaseIdentifier() const 138 WebString WebSecurityOrigin::databaseIdentifier() const
142 { 139 {
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
178 m_private->deref(); 175 m_private->deref();
179 m_private = p; 176 m_private = p;
180 } 177 }
181 178
182 void WebSecurityOrigin::grantLoadLocalResources() const 179 void WebSecurityOrigin::grantLoadLocalResources() const
183 { 180 {
184 get()->grantLoadLocalResources(); 181 get()->grantLoadLocalResources();
185 } 182 }
186 183
187 } // namespace blink 184 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698