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

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

Issue 1394193003: Invalidate background-attachment:fixed on scroll. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 2 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 169 matching lines...) Expand 10 before | Expand all | Expand 10 after
180 180
181 void viewportSizeChanged(bool widthChanged, bool heightChanged); 181 void viewportSizeChanged(bool widthChanged, bool heightChanged);
182 182
183 AtomicString mediaType() const; 183 AtomicString mediaType() const;
184 void setMediaType(const AtomicString&); 184 void setMediaType(const AtomicString&);
185 void adjustMediaTypeForPrinting(bool printing); 185 void adjustMediaTypeForPrinting(bool printing);
186 186
187 WebDisplayMode displayMode() { return m_displayMode; } 187 WebDisplayMode displayMode() { return m_displayMode; }
188 void setDisplayMode(WebDisplayMode); 188 void setDisplayMode(WebDisplayMode);
189 189
190 void addSlowRepaintObject();
191 void removeSlowRepaintObject();
192 bool hasSlowRepaintObjects() const { return m_slowRepaintObjectCount; }
193
194 // Fixed-position objects. 190 // Fixed-position objects.
195 typedef HashSet<LayoutObject*> ViewportConstrainedObjectSet; 191 typedef HashSet<LayoutObject*> ViewportConstrainedObjectSet;
196 void addViewportConstrainedObject(LayoutObject*); 192 void addViewportConstrainedObject(LayoutObject*);
197 void removeViewportConstrainedObject(LayoutObject*); 193 void removeViewportConstrainedObject(LayoutObject*);
198 const ViewportConstrainedObjectSet* viewportConstrainedObjects() const { ret urn m_viewportConstrainedObjects.get(); } 194 const ViewportConstrainedObjectSet* viewportConstrainedObjects() const { ret urn m_viewportConstrainedObjects.get(); }
199 bool hasViewportConstrainedObjects() const { return m_viewportConstrainedObj ects && m_viewportConstrainedObjects->size() > 0; } 195 bool hasViewportConstrainedObjects() const { return m_viewportConstrainedObj ects && m_viewportConstrainedObjects->size() > 0; }
200 196
197 // Objects with background-attachment:fixed.
198 void addBackgroundAttachmentFixedObject(LayoutObject*);
199 void removeBackgroundAttachmentFixedObject(LayoutObject*);
200 bool hasBackgroundAttachmentFixedObjects() const { return m_backgroundAttach mentFixedObjects.size(); }
201 void invalidateBackgroundAttachmentFixedObjects();
202
201 void handleLoadCompleted(); 203 void handleLoadCompleted();
202 204
203 void updateDocumentAnnotatedRegions() const; 205 void updateDocumentAnnotatedRegions() const;
204 206
205 void restoreScrollbar(); 207 void restoreScrollbar();
206 208
207 void postLayoutTimerFired(Timer<FrameView>*); 209 void postLayoutTimerFired(Timer<FrameView>*);
208 210
209 bool safeToPropagateScrollToParent() const { return m_safeToPropagateScrollT oParent; } 211 bool safeToPropagateScrollToParent() const { return m_safeToPropagateScrollT oParent; }
210 void setSafeToPropagateScrollToParent(bool isSafe) { m_safeToPropagateScroll ToParent = isSafe; } 212 void setSafeToPropagateScrollToParent(bool isSafe) { m_safeToPropagateScroll ToParent = isSafe; }
(...skipping 515 matching lines...) Expand 10 before | Expand all | Expand 10 after
726 // For Oilpan, Member reference cycles pose no problem, but 728 // For Oilpan, Member reference cycles pose no problem, but
727 // LocalFrame's FrameView is also cleared by that setView(), so as to 729 // LocalFrame's FrameView is also cleared by that setView(), so as to
728 // keep the observable lifespan of LocalFrame::view() identical. 730 // keep the observable lifespan of LocalFrame::view() identical.
729 RefPtrWillBeMember<LocalFrame> m_frame; 731 RefPtrWillBeMember<LocalFrame> m_frame;
730 732
731 WebDisplayMode m_displayMode; 733 WebDisplayMode m_displayMode;
732 734
733 bool m_doFullPaintInvalidation; 735 bool m_doFullPaintInvalidation;
734 736
735 bool m_canHaveScrollbars; 737 bool m_canHaveScrollbars;
736 unsigned m_slowRepaintObjectCount;
737 738
738 bool m_hasPendingLayout; 739 bool m_hasPendingLayout;
739 LayoutSubtreeRootList m_layoutSubtreeRootList; 740 LayoutSubtreeRootList m_layoutSubtreeRootList;
740 741
741 bool m_layoutSchedulingEnabled; 742 bool m_layoutSchedulingEnabled;
742 bool m_inPerformLayout; 743 bool m_inPerformLayout;
743 bool m_inSynchronousPostLayout; 744 bool m_inSynchronousPostLayout;
744 int m_layoutCount; 745 int m_layoutCount;
745 unsigned m_nestedLayoutCount; 746 unsigned m_nestedLayoutCount;
746 Timer<FrameView> m_postLayoutTasksTimer; 747 Timer<FrameView> m_postLayoutTasksTimer;
(...skipping 23 matching lines...) Expand all
770 771
771 RefPtrWillBeMember<Node> m_scrollAnchor; 772 RefPtrWillBeMember<Node> m_scrollAnchor;
772 773
773 // layoutObject to hold our custom scroll corner. 774 // layoutObject to hold our custom scroll corner.
774 LayoutScrollbarPart* m_scrollCorner; 775 LayoutScrollbarPart* m_scrollCorner;
775 776
776 OwnPtrWillBeMember<ScrollableAreaSet> m_scrollableAreas; 777 OwnPtrWillBeMember<ScrollableAreaSet> m_scrollableAreas;
777 OwnPtrWillBeMember<ScrollableAreaSet> m_animatingScrollableAreas; 778 OwnPtrWillBeMember<ScrollableAreaSet> m_animatingScrollableAreas;
778 OwnPtr<ResizerAreaSet> m_resizerAreas; 779 OwnPtr<ResizerAreaSet> m_resizerAreas;
779 OwnPtr<ViewportConstrainedObjectSet> m_viewportConstrainedObjects; 780 OwnPtr<ViewportConstrainedObjectSet> m_viewportConstrainedObjects;
781 ViewportConstrainedObjectSet m_backgroundAttachmentFixedObjects;
780 OwnPtrWillBeMember<FrameViewAutoSizeInfo> m_autoSizeInfo; 782 OwnPtrWillBeMember<FrameViewAutoSizeInfo> m_autoSizeInfo;
781 783
782 IntSize m_inputEventsOffsetForEmulation; 784 IntSize m_inputEventsOffsetForEmulation;
783 float m_inputEventsScaleFactorForEmulation; 785 float m_inputEventsScaleFactorForEmulation;
784 786
785 IntSize m_layoutSize; 787 IntSize m_layoutSize;
786 bool m_layoutSizeFixedToFrameSize; 788 bool m_layoutSizeFixedToFrameSize;
787 789
788 Timer<FrameView> m_didScrollTimer; 790 Timer<FrameView> m_didScrollTimer;
789 791
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
850 static const unsigned visualPixelThreshold = 32 * 32; 852 static const unsigned visualPixelThreshold = 32 * 32;
851 if (m_visuallyNonEmptyPixelCount > visualPixelThreshold) 853 if (m_visuallyNonEmptyPixelCount > visualPixelThreshold)
852 setIsVisuallyNonEmpty(); 854 setIsVisuallyNonEmpty();
853 } 855 }
854 856
855 DEFINE_TYPE_CASTS(FrameView, Widget, widget, widget->isFrameView(), widget.isFra meView()); 857 DEFINE_TYPE_CASTS(FrameView, Widget, widget, widget->isFrameView(), widget.isFra meView());
856 858
857 } // namespace blink 859 } // namespace blink
858 860
859 #endif // FrameView_h 861 #endif // FrameView_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698