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

Side by Side Diff: third_party/WebKit/Source/core/observer/ResizeObservation.cpp

Issue 2161313002: ResizeObserver implementation, part 2: lifetime (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 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
OLDNEW
(Empty)
1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "core/observer/ResizeObservation.h"
6
7 #include "core/dom/Element.h"
8 #include "core/observer/ResizeObserver.h"
9
10 namespace blink {
11
12 ResizeObservation::ResizeObservation(Element* target, ResizeObserver* observer)
13 : m_target(target)
14 , m_observer(observer)
15 {
16 DCHECK(m_target);
17 m_target->ensureResizeObserverData().set(observer, this);
esprehn 2016/07/21 17:52:28 Can the caller do this instead? See IntersectionOb
atotic1 2016/07/21 19:15:00 Done. Impressed you've caught this one. As I was
18 }
19
20 DEFINE_TRACE(ResizeObservation)
21 {
22 visitor->trace(m_target);
23 visitor->trace(m_observer);
24 }
25
26
27 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698