WebKit Bugzilla
Attachment 360983 Details for
Bug 194197
: Tidy up data members of FrameView and related classes to shrink class sizes
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
Patch
bug-194197-20190202153635.patch (text/plain), 24.05 KB, created by
Simon Fraser (smfr)
on 2019-02-02 15:36:37 PST
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Simon Fraser (smfr)
Created:
2019-02-02 15:36:37 PST
Size:
24.05 KB
patch
obsolete
>Subversion Revision: 240899 >diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog >index 0583c72f630984342ef143ec8d5cf8a72769daff..e01ea7b2b51a5f2fd0f0375a8fe625d3726ea893 100644 >--- a/Source/WebCore/ChangeLog >+++ b/Source/WebCore/ChangeLog >@@ -1,3 +1,28 @@ >+2019-02-02 Simon Fraser <simon.fraser@apple.com> >+ >+ Tidy up data memebers of FrameView and related classes to shrink class sizes >+ https://bugs.webkit.org/show_bug.cgi?id=194197 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ Make various enums 8-bit. Re-order data members of FrameView, FrameViewLayoutContext, Widget >+ and ScrollView to optimize padding. >+ >+ Use more data member initializers. >+ >+ This shrinks FrameView from 1168 (144 padding bytes) to 1096 (96 padding bytes). >+ >+ * dom/Element.h: >+ * page/FrameView.cpp: >+ (WebCore::FrameView::FrameView): >+ * page/FrameView.h: >+ * page/FrameViewLayoutContext.h: >+ * platform/ScrollTypes.h: >+ * platform/ScrollView.h: Data members should come after member functions. >+ * platform/Widget.h: >+ * rendering/Pagination.h: >+ (WebCore::Pagination::Pagination): Deleted. >+ > 2019-02-02 Simon Fraser <simon.fraser@apple.com> > > Rename "scrollingLayer" in RenderLayerBacking to "scrollContainerLayer" for clarity >diff --git a/Source/WebKit/ChangeLog b/Source/WebKit/ChangeLog >index 121ee2dde5ca99e436bf9256d41294ab48adb8e6..9cc68ca05d36c4fe19ed42fae324eed44132a311 100644 >--- a/Source/WebKit/ChangeLog >+++ b/Source/WebKit/ChangeLog >@@ -1,3 +1,12 @@ >+2019-02-02 Simon Fraser <simon.fraser@apple.com> >+ >+ Tidy up data memebers of FrameView and related classes to shrink class sizes >+ https://bugs.webkit.org/show_bug.cgi?id=194197 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ * UIProcess/PageClient.h: Declare enum size. >+ > 2018-12-16 Darin Adler <darin@apple.com> > > Convert additional String::format clients to alternative approaches >diff --git a/Source/WebCore/dom/Element.h b/Source/WebCore/dom/Element.h >index a2599ada87d216034d75925cd31cc5fc50ee6aeb..64ebbc57a1d84b194b15f0a8e6f7613efb8b1e55 100644 >--- a/Source/WebCore/dom/Element.h >+++ b/Source/WebCore/dom/Element.h >@@ -70,12 +70,6 @@ enum SpellcheckAttributeState { > SpellcheckAttributeDefault > }; > >-enum class SelectionRevealMode { >- Reveal, >- RevealUpToMainFrame, // Scroll overflow and iframes, but not the main frame. >- DoNotReveal >-}; >- > #if ENABLE(POINTER_EVENTS) > enum class TouchAction : uint8_t; > #endif >diff --git a/Source/WebCore/page/FrameView.cpp b/Source/WebCore/page/FrameView.cpp >index 5e619d52a36fa63eb40ff81ddba31b45544d1ded..12c1de424c8ea0485a82e5d0eef049a21a0be71c 100644 >--- a/Source/WebCore/page/FrameView.cpp >+++ b/Source/WebCore/page/FrameView.cpp >@@ -183,36 +183,13 @@ Pagination::Mode paginationModeForRenderStyle(const RenderStyle& style) > > FrameView::FrameView(Frame& frame) > : m_frame(frame) >- , m_canHaveScrollbars(true) >+ , m_layoutContext(*this) > , m_updateEmbeddedObjectsTimer(*this, &FrameView::updateEmbeddedObjectsTimerFired) > , m_updateWidgetPositionsTimer(*this, &FrameView::updateWidgetPositionsTimerFired) >- , m_isTransparent(false) >- , m_baseBackgroundColor(Color::white) >- , m_mediaType("screen") >- , m_overflowStatusDirty(true) >- , m_wasScrolledByUser(false) >- , m_inProgrammaticScroll(false) > , m_delayedScrollEventTimer(*this, &FrameView::sendScrollEvent) >- , m_selectionRevealModeForFocusedElement(SelectionRevealMode::DoNotReveal) > , m_delayedScrollToFocusedElementTimer(*this, &FrameView::scrollToFocusedElementTimerFired) >- , m_isTrackingRepaints(false) >- , m_shouldUpdateWhileOffscreen(true) >- , m_speculativeTilingEnabled(false) > , m_speculativeTilingEnableTimer(*this, &FrameView::speculativeTilingEnableTimerFired) >-#if PLATFORM(IOS_FAMILY) >- , m_useCustomFixedPositionLayoutRect(false) >- , m_useCustomSizeForResizeEvent(false) >-#endif >- , m_shouldAutoSize(false) >- , m_inAutoSize(false) >- , m_didRunAutosize(false) >- , m_autoSizeFixedMinimumHeight(0) >- , m_headerHeight(0) >- , m_footerHeight(0) >- , m_visualUpdatesAllowedByClient(true) >- , m_hasFlippedBlockRenderers(false) >- , m_scrollPinningBehavior(DoNotPin) >- , m_layoutContext(*this) >+ , m_mediaType("screen") > { > init(); > >diff --git a/Source/WebCore/page/FrameView.h b/Source/WebCore/page/FrameView.h >index 636ecb92f92ba4346011aa678f8400eb76375584..9b4753cb6a8d8be7faad6f13b985af532b6bbc93 100644 >--- a/Source/WebCore/page/FrameView.h >+++ b/Source/WebCore/page/FrameView.h >@@ -66,7 +66,6 @@ class RenderView; > class RenderWidget; > > enum class FrameFlattening; >-enum class SelectionRevealMode; > > Pagination::Mode paginationModeForRenderStyle(const RenderStyle&); > >@@ -813,119 +812,80 @@ private: > }; > void overrideViewportSizeForCSSViewportUnits(OverrideViewportSize); > >- HashSet<Widget*> m_widgetsInRenderTree; >- > static MonotonicTime sCurrentPaintTimeStamp; // used for detecting decoded resource thrash in the cache > >- LayoutSize m_size; >- LayoutSize m_margins; >- >- std::unique_ptr<ListHashSet<RenderEmbeddedObject*>> m_embeddedObjectsToUpdate; > const Ref<Frame> m_frame; >+ FrameViewLayoutContext m_layoutContext; > >+ HashSet<Widget*> m_widgetsInRenderTree; >+ std::unique_ptr<ListHashSet<RenderEmbeddedObject*>> m_embeddedObjectsToUpdate; > std::unique_ptr<HashSet<const RenderElement*>> m_slowRepaintObjects; > >- bool m_canHaveScrollbars; >- bool m_cannotBlitToWindow; >- bool m_isOverlapped { false }; >- bool m_contentIsOpaque; >+ RefPtr<ContainerNode> m_maintainScrollPositionAnchor; >+ RefPtr<Node> m_nodeToDraw; >+ >+ // Renderer to hold our custom scroll corner. >+ RenderPtr<RenderScrollbarPart> m_scrollCorner; > > Timer m_updateEmbeddedObjectsTimer; > Timer m_updateWidgetPositionsTimer; >+ Timer m_delayedScrollEventTimer; >+ Timer m_delayedScrollToFocusedElementTimer; >+ Timer m_speculativeTilingEnableTimer; > >- bool m_firstLayoutCallbackPending; >+ MonotonicTime m_lastPaintTime; > >- bool m_isTransparent; >-#if ENABLE(DARK_MODE_CSS) >- bool m_usesDarkAppearance { false }; >-#endif >- Color m_baseBackgroundColor; >+ LayoutSize m_size; >+ LayoutSize m_margins; >+ >+ Color m_baseBackgroundColor { Color::white }; > IntSize m_lastViewportSize; >- float m_lastZoomFactor; > > String m_mediaType; > String m_mediaTypeWhenNotPrinting; > >- bool m_overflowStatusDirty; >- bool m_horizontalOverflow; >- bool m_verticalOverflow; >- enum class ViewportRendererType { None, Document, Body }; >- ViewportRendererType m_viewportRendererType { ViewportRendererType::None }; >- >- Pagination m_pagination; >- >- bool m_wasScrolledByUser; >- bool m_inProgrammaticScroll; >- Timer m_delayedScrollEventTimer; >- bool m_shouldScrollToFocusedElement { false }; >- SelectionRevealMode m_selectionRevealModeForFocusedElement; >- Timer m_delayedScrollToFocusedElementTimer; >- >- MonotonicTime m_lastPaintTime; >- >- bool m_isTrackingRepaints; // Used for testing. > Vector<FloatRect> m_trackedRepaintRects; >- >- bool m_shouldUpdateWhileOffscreen; >- >- Optional<FloatRect> m_viewExposedRect; > >+ IntRect* m_cachedWindowClipRect { nullptr }; >+ Vector<WTF::Function<void ()>> m_postLayoutCallbackQueue; >+ > LayoutPoint m_layoutViewportOrigin; > Optional<LayoutRect> m_layoutViewportOverrideRect; > Optional<LayoutRect> m_visualViewportOverrideRect; // Used when the iOS keyboard is showing. > >- RefPtr<Node> m_nodeToDraw; >+ Optional<FloatRect> m_viewExposedRect; >+ > OptionSet<PaintBehavior> m_paintBehavior; >- bool m_isPainting; > >- bool m_isVisuallyNonEmpty { false }; >+ float m_lastZoomFactor { 1 }; > unsigned m_visuallyNonEmptyCharacterCount { 0 }; > unsigned m_visuallyNonEmptyPixelCount { 0 }; >- > unsigned m_textRendererCountForVisuallyNonEmptyCharacters { 0 }; >- bool m_renderedSignificantAmountOfText { false }; >- bool m_hasReachedSignificantRenderedTextThreshold { false }; >- >- bool m_needsDeferredScrollbarsUpdate { false }; >- >- RefPtr<ContainerNode> m_maintainScrollPositionAnchor; >- >- // Renderer to hold our custom scroll corner. >- RenderPtr<RenderScrollbarPart> m_scrollCorner; >- >- bool m_speculativeTilingEnabled; >- Timer m_speculativeTilingEnableTimer; >+ int m_headerHeight { 0 }; >+ int m_footerHeight { 0 }; > > #if PLATFORM(IOS_FAMILY) >- bool m_useCustomFixedPositionLayoutRect; >- IntRect m_customFixedPositionLayoutRect; >+ bool m_useCustomFixedPositionLayoutRect { false }; >+ bool m_useCustomSizeForResizeEvent { false }; > >- bool m_useCustomSizeForResizeEvent; >+ IntRect m_customFixedPositionLayoutRect; > IntSize m_customSizeForResizeEvent; > #endif > > Optional<OverrideViewportSize> m_overrideViewportSize; > >- // If true, automatically resize the frame view around its content. >- bool m_shouldAutoSize; >- bool m_inAutoSize; >- // True if autosize has been run since m_shouldAutoSize was set. >- bool m_didRunAutosize; > // The lower bound on the size when autosizing. > IntSize m_minAutoSize; > // The upper bound on the size when autosizing. > IntSize m_maxAutoSize; > // The fixed height to resize the view to after autosizing is complete. >- int m_autoSizeFixedMinimumHeight; >+ int m_autoSizeFixedMinimumHeight { 0 }; > // The intrinsic content size decided by autosizing. > IntSize m_autoSizeContentSize; > > std::unique_ptr<ScrollableAreaSet> m_scrollableAreas; > std::unique_ptr<ViewportConstrainedObjectSet> m_viewportConstrainedObjects; > >- int m_headerHeight; >- int m_footerHeight; >- > OptionSet<LayoutMilestone> m_milestonesPendingPaint; > > static const unsigned visualCharacterThreshold = 200; >@@ -937,16 +897,51 @@ private: > IntSize m_initialViewportSize; > #endif > >- bool m_visualUpdatesAllowedByClient; >- bool m_hasFlippedBlockRenderers; >- bool m_speculativeTilingDelayDisabledForTesting { false }; >+ Pagination m_pagination; > >- ScrollPinningBehavior m_scrollPinningBehavior; >+ enum class ViewportRendererType : uint8_t { None, Document, Body }; >+ ViewportRendererType m_viewportRendererType { ViewportRendererType::None }; >+ ScrollPinningBehavior m_scrollPinningBehavior { DoNotPin }; >+ SelectionRevealMode m_selectionRevealModeForFocusedElement { SelectionRevealMode::DoNotReveal }; >+ >+ bool m_shouldUpdateWhileOffscreen { true }; >+ bool m_overflowStatusDirty { true }; >+ bool m_horizontalOverflow { false }; >+ bool m_verticalOverflow { false }; >+ bool m_canHaveScrollbars { true }; >+ bool m_cannotBlitToWindow { false }; >+ bool m_isOverlapped { false }; >+ bool m_contentIsOpaque { false }; >+ bool m_firstLayoutCallbackPending { false }; > >- IntRect* m_cachedWindowClipRect { nullptr }; >- Vector<WTF::Function<void ()>> m_postLayoutCallbackQueue; >+ bool m_isTransparent { false }; >+#if ENABLE(DARK_MODE_CSS) >+ bool m_usesDarkAppearance { false }; >+#endif > >- FrameViewLayoutContext m_layoutContext; >+ bool m_isTrackingRepaints { false }; // Used for testing. >+ bool m_wasScrolledByUser { false }; >+ bool m_inProgrammaticScroll { false }; >+ bool m_shouldScrollToFocusedElement { false }; >+ >+ bool m_isPainting { false }; >+ >+ bool m_isVisuallyNonEmpty { false }; >+ >+ bool m_renderedSignificantAmountOfText { false }; >+ bool m_hasReachedSignificantRenderedTextThreshold { false }; >+ >+ bool m_needsDeferredScrollbarsUpdate { false }; >+ bool m_speculativeTilingEnabled { false }; >+ bool m_visualUpdatesAllowedByClient { true }; >+ bool m_hasFlippedBlockRenderers { false }; >+ bool m_speculativeTilingDelayDisabledForTesting { false }; >+ >+ // If true, automatically resize the frame view around its content. >+ bool m_shouldAutoSize { false }; >+ bool m_inAutoSize { false }; >+ // True if autosize has been run since m_shouldAutoSize was set. >+ bool m_didRunAutosize { false }; > }; > > inline void FrameView::incrementVisuallyNonEmptyPixelCount(const IntSize& size) >diff --git a/Source/WebCore/page/FrameViewLayoutContext.h b/Source/WebCore/page/FrameViewLayoutContext.h >index b07cf5a5d9b38ec152273ba84773d3b3d7b1f88a..cf3c6bdb6d960e7cc9cc727da57cd68a3332f99a 100644 >--- a/Source/WebCore/page/FrameViewLayoutContext.h >+++ b/Source/WebCore/page/FrameViewLayoutContext.h >@@ -64,7 +64,7 @@ public: > void disableSetNeedsLayout(); > void enableSetNeedsLayout(); > >- enum class LayoutPhase { >+ enum class LayoutPhase : uint8_t { > OutsideLayout, > InPreLayout, > InRenderTreeLayout, >@@ -158,6 +158,7 @@ private: > FrameView& m_frameView; > Timer m_layoutTimer; > Timer m_asynchronousTasksTimer; >+ WeakPtr<RenderElement> m_subtreeLayoutRoot; > > bool m_layoutSchedulingIsEnabled { true }; > bool m_delayedLayout { false }; >@@ -166,14 +167,13 @@ private: > bool m_inAsynchronousTasks { false }; > bool m_setNeedsLayoutWasDeferred { false }; > LayoutPhase m_layoutPhase { LayoutPhase::OutsideLayout }; >- enum class LayoutNestedState { NotInLayout, NotNested, Nested }; >+ enum class LayoutNestedState : uint8_t { NotInLayout, NotNested, Nested }; > LayoutNestedState m_layoutNestedState { LayoutNestedState::NotInLayout }; > unsigned m_layoutCount { 0 }; > unsigned m_disableSetNeedsLayoutCount { 0 }; > int m_layoutDisallowedCount { 0 }; >- WeakPtr<RenderElement> m_subtreeLayoutRoot; >- LayoutStateStack m_layoutStateStack; > unsigned m_paintOffsetCacheDisableCount { 0 }; >+ LayoutStateStack m_layoutStateStack; > }; > > } // namespace WebCore >diff --git a/Source/WebCore/platform/ScrollTypes.h b/Source/WebCore/platform/ScrollTypes.h >index b97917a22f36693ef246652e2a2890b738b5f6bb..2b319518fa965175c2c155b022d2f433d2fb1a27 100644 >--- a/Source/WebCore/platform/ScrollTypes.h >+++ b/Source/WebCore/platform/ScrollTypes.h >@@ -23,8 +23,7 @@ > * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. > */ > >-#ifndef ScrollTypes_h >-#define ScrollTypes_h >+#pragma once > > #include <cstdint> > #include <wtf/Assertions.h> >@@ -111,23 +110,37 @@ enum ScrollGranularity : uint8_t { > ScrollByPixel > }; > >-enum ScrollElasticity { >+enum ScrollElasticity : uint8_t { > ScrollElasticityAutomatic, > ScrollElasticityNone, > ScrollElasticityAllowed > }; > >-enum ScrollbarOrientation { HorizontalScrollbar, VerticalScrollbar }; >- >-enum ScrollbarMode { ScrollbarAuto, ScrollbarAlwaysOff, ScrollbarAlwaysOn }; >+enum ScrollbarOrientation : uint8_t { >+ HorizontalScrollbar, >+ VerticalScrollbar >+}; > >-enum ScrollbarControlSize { RegularScrollbar, SmallScrollbar }; >+enum ScrollbarMode : uint8_t { >+ ScrollbarAuto, >+ ScrollbarAlwaysOff, >+ ScrollbarAlwaysOn >+}; > >-enum class ScrollbarExpansionState { Regular, Expanded }; >+enum ScrollbarControlSize : uint8_t { >+ RegularScrollbar, >+ SmallScrollbar >+}; > >-enum class ScrollEventAxis { Horizontal, Vertical }; >+enum class ScrollbarExpansionState : uint8_t { >+ Regular, >+ Expanded >+}; > >-typedef unsigned ScrollbarControlState; >+enum class ScrollEventAxis : uint8_t { >+ Horizontal, >+ Vertical >+}; > > enum ScrollbarControlStateMask { > ActiveScrollbarState = 1, >@@ -149,7 +162,7 @@ enum ScrollbarPart { > AllParts = 0xffffffff > }; > >-enum ScrollbarButtonsPlacement { >+enum ScrollbarButtonsPlacement : uint8_t { > ScrollbarButtonsNone, > ScrollbarButtonsSingle, > ScrollbarButtonsDoubleStart, >@@ -157,44 +170,48 @@ enum ScrollbarButtonsPlacement { > ScrollbarButtonsDoubleBoth > }; > >-enum class ScrollbarStyle { >+enum class ScrollbarStyle : uint8_t { > AlwaysVisible, > Overlay > }; > >-enum ScrollbarOverlayStyle { >+enum ScrollbarOverlayStyle: uint8_t { > ScrollbarOverlayStyleDefault, > ScrollbarOverlayStyleDark, > ScrollbarOverlayStyleLight > }; > >-typedef unsigned ScrollbarControlPartMask; >- >-enum ScrollPinningBehavior { >+enum ScrollPinningBehavior : uint8_t { > DoNotPin, > PinToTop, > PinToBottom > }; > >-enum class ScrollClamping { >+enum class ScrollClamping : uint8_t { > Unclamped, > Clamped > }; > >-enum ScrollBehaviorForFixedElements { >+enum ScrollBehaviorForFixedElements : uint8_t { > StickToDocumentBounds, > StickToViewportBounds > }; > >-enum class ScrollbarButtonPressAction { >+enum class ScrollbarButtonPressAction : uint8_t { > None, > CenterOnThumb, > StartDrag, > Scroll > }; > >-using ScrollingNodeID = uint64_t; >+enum class SelectionRevealMode : uint8_t { >+ Reveal, >+ RevealUpToMainFrame, // Scroll overflow and iframes, but not the main frame. >+ DoNotReveal >+}; > >-} >+using ScrollbarControlState = unsigned; >+using ScrollbarControlPartMask = unsigned; >+using ScrollingNodeID = uint64_t; > >-#endif >+} // namespace WebCore >diff --git a/Source/WebCore/platform/ScrollView.h b/Source/WebCore/platform/ScrollView.h >index 4675ce9ae3e7ac23c0d3da2c97af66f73415400a..8cf3e572a0563bdb44f6cf061b2c8c2d4ae05cb6 100644 >--- a/Source/WebCore/platform/ScrollView.h >+++ b/Source/WebCore/platform/ScrollView.h >@@ -427,6 +427,14 @@ protected: > virtual void unobscuredContentSizeChanged() = 0; > #endif > >+#if PLATFORM(COCOA) && defined __OBJC__ >+public: >+ WEBCORE_EXPORT NSView* documentView() const; >+ >+private: >+ NSScrollView<WebCoreFrameScrollView>* scrollView() const; >+#endif >+ > private: > // Size available for view contents, excluding content insets. Not affected by zooming. > IntSize sizeForUnobscuredContent(VisibleContentRectIncludesScrollbars = ExcludeScrollbars) const; >@@ -440,6 +448,39 @@ private: > > bool isScrollView() const final { return true; } > >+ void init(); >+ void destroy(); >+ >+ IntRect rectToCopyOnScroll() const; >+ >+ // Called when the scroll position within this view changes. FrameView overrides this to generate repaint invalidations. >+ virtual void updateLayerPositionsAfterScrolling() = 0; >+ virtual void updateCompositingLayersAfterScrolling() = 0; >+ >+ void platformAddChild(Widget*); >+ void platformRemoveChild(Widget*); >+ void platformSetScrollbarModes(); >+ void platformScrollbarModes(ScrollbarMode& horizontal, ScrollbarMode& vertical) const; >+ void platformSetCanBlitOnScroll(bool); >+ bool platformCanBlitOnScroll() const; >+ IntRect platformVisibleContentRect(bool includeScrollbars) const; >+ IntSize platformVisibleContentSize(bool includeScrollbars) const; >+ IntRect platformVisibleContentRectIncludingObscuredArea(bool includeScrollbars) const; >+ IntSize platformVisibleContentSizeIncludingObscuredArea(bool includeScrollbars) const; >+ void platformSetContentsSize(); >+ IntRect platformContentsToScreen(const IntRect&) const; >+ IntPoint platformScreenToContents(const IntPoint&) const; >+ void platformSetScrollPosition(const IntPoint&); >+ bool platformScroll(ScrollDirection, ScrollGranularity); >+ void platformSetScrollbarsSuppressed(bool repaintOnUnsuppress); >+ void platformRepaintContentRectangle(const IntRect&); >+ bool platformIsOffscreen() const; >+ void platformSetScrollbarOverlayStyle(ScrollbarOverlayStyle); >+ void platformSetScrollOrigin(const IntPoint&, bool updatePositionAtAll, bool updatePositionSynchronously); >+ >+ void calculateOverhangAreasForPainting(IntRect& horizontalOverhangRect, IntRect& verticalOverhangRect); >+ void updateOverhangAreas(); >+ > HashSet<Ref<Widget>> m_children; > > RefPtr<Scrollbar> m_horizontalScrollbar; >@@ -466,6 +507,8 @@ private: > > IntPoint m_panScrollIconPoint; > >+ unsigned m_updateScrollbarsPass { 0 }; >+ > bool m_horizontalScrollbarLock { false }; > bool m_verticalScrollbarLock { false }; > >@@ -477,58 +520,13 @@ private: > bool m_canBlitOnScroll { true }; > > bool m_scrollbarsSuppressed { false }; >- > bool m_inUpdateScrollbars { false }; >- unsigned m_updateScrollbarsPass { 0 }; > > bool m_drawPanScrollIcon { false }; > bool m_useFixedLayout { false }; > > bool m_paintsEntireContents { false }; > bool m_delegatesScrolling { false }; >- >- >- void init(); >- void destroy(); >- >- IntRect rectToCopyOnScroll() const; >- >- // Called when the scroll position within this view changes. FrameView overrides this to generate repaint invalidations. >- virtual void updateLayerPositionsAfterScrolling() = 0; >- virtual void updateCompositingLayersAfterScrolling() = 0; >- >- void platformAddChild(Widget*); >- void platformRemoveChild(Widget*); >- void platformSetScrollbarModes(); >- void platformScrollbarModes(ScrollbarMode& horizontal, ScrollbarMode& vertical) const; >- void platformSetCanBlitOnScroll(bool); >- bool platformCanBlitOnScroll() const; >- IntRect platformVisibleContentRect(bool includeScrollbars) const; >- IntSize platformVisibleContentSize(bool includeScrollbars) const; >- IntRect platformVisibleContentRectIncludingObscuredArea(bool includeScrollbars) const; >- IntSize platformVisibleContentSizeIncludingObscuredArea(bool includeScrollbars) const; >- void platformSetContentsSize(); >- IntRect platformContentsToScreen(const IntRect&) const; >- IntPoint platformScreenToContents(const IntPoint&) const; >- void platformSetScrollPosition(const IntPoint&); >- bool platformScroll(ScrollDirection, ScrollGranularity); >- void platformSetScrollbarsSuppressed(bool repaintOnUnsuppress); >- void platformRepaintContentRectangle(const IntRect&); >- bool platformIsOffscreen() const; >- void platformSetScrollbarOverlayStyle(ScrollbarOverlayStyle); >- >- void platformSetScrollOrigin(const IntPoint&, bool updatePositionAtAll, bool updatePositionSynchronously); >- >- void calculateOverhangAreasForPainting(IntRect& horizontalOverhangRect, IntRect& verticalOverhangRect); >- void updateOverhangAreas(); >- >-#if PLATFORM(COCOA) && defined __OBJC__ >-public: >- WEBCORE_EXPORT NSView* documentView() const; >- >-private: >- NSScrollView<WebCoreFrameScrollView>* scrollView() const; >-#endif > }; // class ScrollView > > } // namespace WebCore >diff --git a/Source/WebCore/platform/Widget.h b/Source/WebCore/platform/Widget.h >index 9e4be7cfb2976c1ec0f759c31d67f2fce8f345b9..211126544079a71667aea3f87cc2e844eeeca8e9 100644 >--- a/Source/WebCore/platform/Widget.h >+++ b/Source/WebCore/platform/Widget.h >@@ -205,14 +205,15 @@ private: > static IntPoint convertFromContainingWindowToRoot(const Widget* rootWidget, const IntPoint&); > > private: >+ bool m_selfVisible { false }; >+ bool m_parentVisible { false }; >+ > WeakPtr<ScrollView> m_parent; > #if !PLATFORM(COCOA) > PlatformWidget m_widget; > #else > RetainPtr<NSView> m_widget; > #endif >- bool m_selfVisible; >- bool m_parentVisible; > > IntRect m_frame; // Not used when a native widget exists. > }; >diff --git a/Source/WebCore/rendering/Pagination.h b/Source/WebCore/rendering/Pagination.h >index 8d5ca37dbd63a19ff08f9f8dc374b0b50b2fa11a..d7afebdad31cf731a844b611358e797bd1938532 100644 >--- a/Source/WebCore/rendering/Pagination.h >+++ b/Source/WebCore/rendering/Pagination.h >@@ -28,15 +28,9 @@ > namespace WebCore { > > struct Pagination { >- enum Mode { Unpaginated, LeftToRightPaginated, RightToLeftPaginated, TopToBottomPaginated, BottomToTopPaginated }; >+ enum Mode : uint8_t { Unpaginated, LeftToRightPaginated, RightToLeftPaginated, TopToBottomPaginated, BottomToTopPaginated }; > >- Pagination() >- : mode(Unpaginated) >- , behavesLikeColumns(false) >- , pageLength(0) >- , gap(0) >- { >- }; >+ Pagination() = default; > > bool operator==(const Pagination& other) const > { >@@ -48,10 +42,10 @@ struct Pagination { > return mode != other.mode || behavesLikeColumns != other.behavesLikeColumns || pageLength != other.pageLength || gap != other.gap; > } > >- Mode mode; >- bool behavesLikeColumns; >- unsigned pageLength; >- unsigned gap; >+ Mode mode { Unpaginated }; >+ bool behavesLikeColumns { false }; >+ unsigned pageLength { 0 }; >+ unsigned gap { 0 }; > }; > > } // namespace WebCore >diff --git a/Source/WebKit/UIProcess/PageClient.h b/Source/WebKit/UIProcess/PageClient.h >index 9617d0dac03bef66213d2ed06e86964762392b8f..38c6552bb1e8a95d02a1822387a0228300f0eb80 100644 >--- a/Source/WebKit/UIProcess/PageClient.h >+++ b/Source/WebKit/UIProcess/PageClient.h >@@ -83,7 +83,7 @@ class TextIndicator; > class WebMediaSessionManager; > > enum class RouteSharingPolicy : uint8_t; >-enum class ScrollbarStyle; >+enum class ScrollbarStyle : uint8_t; > enum class TextIndicatorWindowLifetime : uint8_t; > enum class TextIndicatorWindowDismissalAnimation : uint8_t; >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 194197
: 360983