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

Side by Side Diff: third_party/WebKit/Source/core/frame/FrameView.h

Issue 2251303003: Implement position: sticky updates on compositor (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Cleanup and add unit test for impl side sticky position update. Created 4 years, 3 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) 1997 Martin Jones (mjones@kde.org) 2 Copyright (C) 1997 Martin Jones (mjones@kde.org)
3 (C) 1998 Waldo Bastian (bastian@kde.org) 3 (C) 1998 Waldo Bastian (bastian@kde.org)
4 (C) 1998, 1999 Torben Weis (weis@kde.org) 4 (C) 1998, 1999 Torben Weis (weis@kde.org)
5 (C) 1999 Lars Knoll (knoll@kde.org) 5 (C) 1999 Lars Knoll (knoll@kde.org)
6 (C) 1999 Antti Koivisto (koivisto@kde.org) 6 (C) 1999 Antti Koivisto (koivisto@kde.org)
7 Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserv ed. 7 Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009 Apple Inc. All rights reserv ed.
8 8
9 This library is free software; you can redistribute it and/or 9 This library is free software; you can redistribute it and/or
10 modify it under the terms of the GNU Library General Public 10 modify it under the terms of the GNU Library General Public
(...skipping 192 matching lines...) Expand 10 before | Expand all | Expand 10 after
203 WebDisplayMode displayMode() { return m_displayMode; } 203 WebDisplayMode displayMode() { return m_displayMode; }
204 void setDisplayMode(WebDisplayMode); 204 void setDisplayMode(WebDisplayMode);
205 205
206 // Fixed-position objects. 206 // Fixed-position objects.
207 typedef HashSet<LayoutObject*> ViewportConstrainedObjectSet; 207 typedef HashSet<LayoutObject*> ViewportConstrainedObjectSet;
208 void addViewportConstrainedObject(LayoutObject*); 208 void addViewportConstrainedObject(LayoutObject*);
209 void removeViewportConstrainedObject(LayoutObject*); 209 void removeViewportConstrainedObject(LayoutObject*);
210 const ViewportConstrainedObjectSet* viewportConstrainedObjects() const { ret urn m_viewportConstrainedObjects.get(); } 210 const ViewportConstrainedObjectSet* viewportConstrainedObjects() const { ret urn m_viewportConstrainedObjects.get(); }
211 bool hasViewportConstrainedObjects() const { return m_viewportConstrainedObj ects && m_viewportConstrainedObjects->size() > 0; } 211 bool hasViewportConstrainedObjects() const { return m_viewportConstrainedObj ects && m_viewportConstrainedObjects->size() > 0; }
212 212
213 // Sticky objects.
214 void addStickyPositionObject() { ++m_stickyPositionObjectCount; }
215 void removeStickyPositionObject() { --m_stickyPositionObjectCount; }
216 bool hasStickyPositionObjects() const { return m_stickyPositionObjectCount; }
217
218 // Objects with background-attachment:fixed. 213 // Objects with background-attachment:fixed.
219 void addBackgroundAttachmentFixedObject(LayoutObject*); 214 void addBackgroundAttachmentFixedObject(LayoutObject*);
220 void removeBackgroundAttachmentFixedObject(LayoutObject*); 215 void removeBackgroundAttachmentFixedObject(LayoutObject*);
221 bool hasBackgroundAttachmentFixedObjects() const { return m_backgroundAttach mentFixedObjects.size(); } 216 bool hasBackgroundAttachmentFixedObjects() const { return m_backgroundAttach mentFixedObjects.size(); }
222 void invalidateBackgroundAttachmentFixedObjects(); 217 void invalidateBackgroundAttachmentFixedObjects();
223 218
224 void handleLoadCompleted(); 219 void handleLoadCompleted();
225 220
226 void updateDocumentAnnotatedRegions() const; 221 void updateDocumentAnnotatedRegions() const;
227 222
(...skipping 741 matching lines...) Expand 10 before | Expand all | Expand 10 after
969 if (m_visuallyNonEmptyPixelCount > visualPixelThreshold) 964 if (m_visuallyNonEmptyPixelCount > visualPixelThreshold)
970 setIsVisuallyNonEmpty(); 965 setIsVisuallyNonEmpty();
971 } 966 }
972 967
973 DEFINE_TYPE_CASTS(FrameView, Widget, widget, widget->isFrameView(), widget.isFra meView()); 968 DEFINE_TYPE_CASTS(FrameView, Widget, widget, widget->isFrameView(), widget.isFra meView());
974 DEFINE_TYPE_CASTS(FrameView, ScrollableArea, scrollableArea, scrollableArea->isF rameView(), scrollableArea.isFrameView()); 969 DEFINE_TYPE_CASTS(FrameView, ScrollableArea, scrollableArea, scrollableArea->isF rameView(), scrollableArea.isFrameView());
975 970
976 } // namespace blink 971 } // namespace blink
977 972
978 #endif // FrameView_h 973 #endif // FrameView_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698