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

Side by Side Diff: sky/engine/core/rendering/RenderBox.h

Issue 840403003: First pass at deleting paint invalidation code. (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Created 5 years, 11 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
« no previous file with comments | « sky/engine/core/frame/FrameView.cpp ('k') | sky/engine/core/rendering/RenderBox.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
3 * (C) 1999 Antti Koivisto (koivisto@kde.org) 3 * (C) 1999 Antti Koivisto (koivisto@kde.org)
4 * Copyright (C) 2003, 2006, 2007 Apple Inc. All rights reserved. 4 * Copyright (C) 2003, 2006, 2007 Apple Inc. All rights reserved.
5 * 5 *
6 * This library is free software; you can redistribute it and/or 6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Library General Public 7 * modify it under the terms of the GNU Library General Public
8 * License as published by the Free Software Foundation; either 8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version. 9 * version 2 of the License, or (at your option) any later version.
10 * 10 *
(...skipping 519 matching lines...) Expand 10 before | Expand all | Expand 10 after
530 530
531 void paintRootBoxFillLayers(const PaintInfo&); 531 void paintRootBoxFillLayers(const PaintInfo&);
532 532
533 RenderObject* splitAnonymousBoxesAroundChild(RenderObject* beforeChild); 533 RenderObject* splitAnonymousBoxesAroundChild(RenderObject* beforeChild);
534 534
535 void updateIntrinsicContentLogicalHeight(LayoutUnit intrinsicContentLogicalH eight) const { m_intrinsicContentLogicalHeight = intrinsicContentLogicalHeight; } 535 void updateIntrinsicContentLogicalHeight(LayoutUnit intrinsicContentLogicalH eight) const { m_intrinsicContentLogicalHeight = intrinsicContentLogicalHeight; }
536 536
537 virtual InvalidationReason getPaintInvalidationReason(const RenderLayerModel Object& paintInvalidationContainer, 537 virtual InvalidationReason getPaintInvalidationReason(const RenderLayerModel Object& paintInvalidationContainer,
538 const LayoutRect& oldBounds, const LayoutPoint& oldPositionFromPaintInva lidationContainer, 538 const LayoutRect& oldBounds, const LayoutPoint& oldPositionFromPaintInva lidationContainer,
539 const LayoutRect& newBounds, const LayoutPoint& newPositionFromPaintInva lidationContainer) override; 539 const LayoutRect& newBounds, const LayoutPoint& newPositionFromPaintInva lidationContainer) override;
540 virtual void incrementallyInvalidatePaint(const RenderLayerModelObject& pain tInvalidationContainer, const LayoutRect& oldBounds, const LayoutRect& newBounds , const LayoutPoint& positionFromPaintInvalidationContainer) override;
541 540
542 virtual void clearPaintInvalidationState(const PaintInvalidationState&) over ride; 541 virtual void clearPaintInvalidationState(const PaintInvalidationState&) over ride;
543 #if ENABLE(ASSERT) 542 #if ENABLE(ASSERT)
544 virtual bool paintInvalidationStateIsDirty() const override; 543 virtual bool paintInvalidationStateIsDirty() const override;
545 #endif 544 #endif
546 545
547 private: 546 private:
548 void shrinkToFitWidth(const LayoutUnit availableSpace, const LayoutUnit logi calLeftValue, const LayoutUnit bordersPlusPadding, LogicalExtentComputedValues&) const; 547 void shrinkToFitWidth(const LayoutUnit availableSpace, const LayoutUnit logi calLeftValue, const LayoutUnit bordersPlusPadding, LogicalExtentComputedValues&) const;
549 548
550 // Returns true if we queued up a paint invalidation. 549 // Returns true if we queued up a paint invalidation.
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
582 if (!m_rareData) 581 if (!m_rareData)
583 m_rareData = adoptPtr(new RenderBoxRareData()); 582 m_rareData = adoptPtr(new RenderBoxRareData());
584 return *m_rareData.get(); 583 return *m_rareData.get();
585 } 584 }
586 585
587 void savePreviousBorderBoxSizeIfNeeded(); 586 void savePreviousBorderBoxSizeIfNeeded();
588 LayoutSize computePreviousBorderBoxSize(const LayoutSize& previousBoundsSize ) const; 587 LayoutSize computePreviousBorderBoxSize(const LayoutSize& previousBoundsSize ) const;
589 588
590 bool logicalHeightComputesAsNone(SizeType) const; 589 bool logicalHeightComputesAsNone(SizeType) const;
591 590
592 virtual InvalidationReason invalidatePaintIfNeeded(const PaintInvalidationSt ate&, const RenderLayerModelObject& newPaintInvalidationContainer) override fina l;
593
594 bool isBox() const = delete; // This will catch anyone doing an unnecessary check. 591 bool isBox() const = delete; // This will catch anyone doing an unnecessary check.
595 592
596 // The width/height of the contents + borders + padding. The x/y location i s relative to our container (which is not always our parent). 593 // The width/height of the contents + borders + padding. The x/y location i s relative to our container (which is not always our parent).
597 LayoutRect m_frameRect; 594 LayoutRect m_frameRect;
598 595
599 // Our intrinsic height, used for min-height: min-content etc. Maintained by 596 // Our intrinsic height, used for min-height: min-content etc. Maintained by
600 // updateLogicalHeight. This is logicalHeight() before it is clamped to 597 // updateLogicalHeight. This is logicalHeight() before it is clamped to
601 // min/max. 598 // min/max.
602 mutable LayoutUnit m_intrinsicContentLogicalHeight; 599 mutable LayoutUnit m_intrinsicContentLogicalHeight;
603 600
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
657 if (UNLIKELY(inlineBoxWrapper() != 0)) 654 if (UNLIKELY(inlineBoxWrapper() != 0))
658 deleteLineBoxWrapper(); 655 deleteLineBoxWrapper();
659 } 656 }
660 657
661 ensureRareData().m_inlineBoxWrapper = boxWrapper; 658 ensureRareData().m_inlineBoxWrapper = boxWrapper;
662 } 659 }
663 660
664 } // namespace blink 661 } // namespace blink
665 662
666 #endif // SKY_ENGINE_CORE_RENDERING_RENDERBOX_H_ 663 #endif // SKY_ENGINE_CORE_RENDERING_RENDERBOX_H_
OLDNEW
« no previous file with comments | « sky/engine/core/frame/FrameView.cpp ('k') | sky/engine/core/rendering/RenderBox.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698