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

Side by Side Diff: third_party/WebKit/Source/core/loader/appcache/ApplicationCacheHost.cpp

Issue 2014483003: Rename OwnPtr::clear() to reset() in core/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 7 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) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2009 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 166 matching lines...) Expand 10 before | Expand all | Expand 10 after
177 void ApplicationCacheHost::setApplicationCache(ApplicationCache* domApplicationC ache) 177 void ApplicationCacheHost::setApplicationCache(ApplicationCache* domApplicationC ache)
178 { 178 {
179 ASSERT(!m_domApplicationCache || !domApplicationCache); 179 ASSERT(!m_domApplicationCache || !domApplicationCache);
180 m_domApplicationCache = domApplicationCache; 180 m_domApplicationCache = domApplicationCache;
181 } 181 }
182 182
183 void ApplicationCacheHost::detachFromDocumentLoader() 183 void ApplicationCacheHost::detachFromDocumentLoader()
184 { 184 {
185 // Detach from the owning DocumentLoader and let go of WebApplicationCacheHo st. 185 // Detach from the owning DocumentLoader and let go of WebApplicationCacheHo st.
186 setApplicationCache(nullptr); 186 setApplicationCache(nullptr);
187 m_host.clear(); 187 m_host.reset();
188 m_documentLoader = nullptr; 188 m_documentLoader = nullptr;
189 } 189 }
190 190
191 void ApplicationCacheHost::notifyApplicationCache(EventID id, int progressTotal, int progressDone, WebApplicationCacheHost::ErrorReason errorReason, const Strin g& errorURL, int errorStatus, const String& errorMessage) 191 void ApplicationCacheHost::notifyApplicationCache(EventID id, int progressTotal, int progressDone, WebApplicationCacheHost::ErrorReason errorReason, const Strin g& errorURL, int errorStatus, const String& errorMessage)
192 { 192 {
193 if (id != PROGRESS_EVENT) 193 if (id != PROGRESS_EVENT)
194 InspectorInstrumentation::updateApplicationCacheStatus(m_documentLoader- >frame()); 194 InspectorInstrumentation::updateApplicationCacheStatus(m_documentLoader- >frame());
195 195
196 if (m_defersEvents) { 196 if (m_defersEvents) {
197 // Event dispatching is deferred until document.onload has fired. 197 // Event dispatching is deferred until document.onload has fired.
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after
303 notifyApplicationCache(ERROR_EVENT, 0, 0, reason, url.string(), status, mess age); 303 notifyApplicationCache(ERROR_EVENT, 0, 0, reason, url.string(), status, mess age);
304 } 304 }
305 305
306 DEFINE_TRACE(ApplicationCacheHost) 306 DEFINE_TRACE(ApplicationCacheHost)
307 { 307 {
308 visitor->trace(m_domApplicationCache); 308 visitor->trace(m_domApplicationCache);
309 visitor->trace(m_documentLoader); 309 visitor->trace(m_documentLoader);
310 } 310 }
311 311
312 } // namespace blink 312 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698