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

Side by Side Diff: third_party/WebKit/Source/modules/geolocation/GeolocationController.cpp

Issue 1686483002: Oilpan: Remove most WillBe types from the code base (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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 Apple Inc. All rights reserved. 2 * Copyright (C) 2009 Apple 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 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
66 { 66 {
67 ASSERT(m_observers.isEmpty()); 67 ASSERT(m_observers.isEmpty());
68 #if !ENABLE(OILPAN) 68 #if !ENABLE(OILPAN)
69 if (m_hasClientForTest) { 69 if (m_hasClientForTest) {
70 m_client->controllerForTestRemoved(this); 70 m_client->controllerForTestRemoved(this);
71 m_hasClientForTest = false; 71 m_hasClientForTest = false;
72 } 72 }
73 #endif 73 #endif
74 } 74 }
75 75
76 PassOwnPtrWillBeRawPtr<GeolocationController> GeolocationController::create(Loca lFrame& frame, GeolocationClient* client) 76 RawPtr<GeolocationController> GeolocationController::create(LocalFrame& frame, G eolocationClient* client)
77 { 77 {
78 return adoptPtrWillBeNoop(new GeolocationController(frame, client)); 78 return new GeolocationController(frame, client);
79 } 79 }
80 80
81 void GeolocationController::addObserver(Geolocation* observer, bool enableHighAc curacy) 81 void GeolocationController::addObserver(Geolocation* observer, bool enableHighAc curacy)
82 { 82 {
83 // This may be called multiple times with the same observer, though removeOb server() 83 // This may be called multiple times with the same observer, though removeOb server()
84 // is called only once with each. 84 // is called only once with each.
85 bool wasEmpty = m_observers.isEmpty(); 85 bool wasEmpty = m_observers.isEmpty();
86 m_observers.add(observer); 86 m_observers.add(observer);
87 if (enableHighAccuracy) 87 if (enableHighAccuracy)
88 m_highAccuracyObservers.add(observer); 88 m_highAccuracyObservers.add(observer);
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
180 { 180 {
181 return "GeolocationController"; 181 return "GeolocationController";
182 } 182 }
183 183
184 DEFINE_TRACE(GeolocationController) 184 DEFINE_TRACE(GeolocationController)
185 { 185 {
186 visitor->trace(m_client); 186 visitor->trace(m_client);
187 visitor->trace(m_lastPosition); 187 visitor->trace(m_lastPosition);
188 visitor->trace(m_observers); 188 visitor->trace(m_observers);
189 visitor->trace(m_highAccuracyObservers); 189 visitor->trace(m_highAccuracyObservers);
190 WillBeHeapSupplement<LocalFrame>::trace(visitor); 190 HeapSupplement<LocalFrame>::trace(visitor);
191 PageLifecycleObserver::trace(visitor); 191 PageLifecycleObserver::trace(visitor);
192 } 192 }
193 193
194 void provideGeolocationTo(LocalFrame& frame, GeolocationClient* client) 194 void provideGeolocationTo(LocalFrame& frame, GeolocationClient* client)
195 { 195 {
196 WillBeHeapSupplement<LocalFrame>::provideTo(frame, GeolocationController::su pplementName(), GeolocationController::create(frame, client)); 196 HeapSupplement<LocalFrame>::provideTo(frame, GeolocationController::suppleme ntName(), GeolocationController::create(frame, client));
197 } 197 }
198 198
199 } // namespace blink 199 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698