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

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

Issue 1231643010: Remove 'blink::WebSerializedOrigin' (6/6) (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@webnotificationmanager
Patch Set: Created 5 years, 5 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
« no previous file with comments | « Source/platform/blink_platform.gypi ('k') | Source/platform/exported/WebSerializedOrigin.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 ASSERT(m_private); 128 ASSERT(m_private);
129 return createDatabaseIdentifierFromSecurityOrigin(m_private); 129 return createDatabaseIdentifierFromSecurityOrigin(m_private);
130 } 130 }
131 131
132 bool WebSecurityOrigin::canAccessPasswordManager() const 132 bool WebSecurityOrigin::canAccessPasswordManager() const
133 { 133 {
134 ASSERT(m_private); 134 ASSERT(m_private);
135 return m_private->canAccessPasswordManager(); 135 return m_private->canAccessPasswordManager();
136 } 136 }
137 137
138 WebSecurityOrigin::WebSecurityOrigin(SecurityOrigin* origin)
139 : m_private(static_cast<WebSecurityOriginPrivate*>(origin->isolatedCopy().le akRef()))
Mike West 2015/07/10 14:02:31 This feels a little ugly. If you have suggestions,
Peter Beverloo 2015/07/10 14:27:03 The obvious option would be for ExecutionContext::
140 {
141 }
142
138 WebSecurityOrigin::WebSecurityOrigin(const WTF::PassRefPtr<SecurityOrigin>& orig in) 143 WebSecurityOrigin::WebSecurityOrigin(const WTF::PassRefPtr<SecurityOrigin>& orig in)
139 : m_private(static_cast<WebSecurityOriginPrivate*>(origin.leakRef())) 144 : m_private(static_cast<WebSecurityOriginPrivate*>(origin.leakRef()))
140 { 145 {
141 } 146 }
142 147
143 WebSecurityOrigin& WebSecurityOrigin::operator=(const WTF::PassRefPtr<SecurityOr igin>& origin) 148 WebSecurityOrigin& WebSecurityOrigin::operator=(const WTF::PassRefPtr<SecurityOr igin>& origin)
144 { 149 {
145 assign(static_cast<WebSecurityOriginPrivate*>(origin.leakRef())); 150 assign(static_cast<WebSecurityOriginPrivate*>(origin.leakRef()));
146 return *this; 151 return *this;
147 } 152 }
(...skipping 15 matching lines...) Expand all
163 m_private->deref(); 168 m_private->deref();
164 m_private = p; 169 m_private = p;
165 } 170 }
166 171
167 void WebSecurityOrigin::grantLoadLocalResources() const 172 void WebSecurityOrigin::grantLoadLocalResources() const
168 { 173 {
169 get()->grantLoadLocalResources(); 174 get()->grantLoadLocalResources();
170 } 175 }
171 176
172 } // namespace blink 177 } // namespace blink
OLDNEW
« no previous file with comments | « Source/platform/blink_platform.gypi ('k') | Source/platform/exported/WebSerializedOrigin.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698