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

Side by Side Diff: Source/core/layout/LayoutPagedFlowThread.h

Issue 1181483005: Avoid stretching the parent of a column spanner. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Update unit tests that used to test the container stretching mechanism Created 5 years, 6 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef LayoutPagedFlowThread_h 5 #ifndef LayoutPagedFlowThread_h
6 #define LayoutPagedFlowThread_h 6 #define LayoutPagedFlowThread_h
7 7
8 #include "core/layout/LayoutMultiColumnFlowThread.h" 8 #include "core/layout/LayoutMultiColumnFlowThread.h"
9 9
10 namespace blink { 10 namespace blink {
11 11
12 // A flow thread for paged overflow. FIXME: The current implementation relies on the multicol 12 // A flow thread for paged overflow. FIXME: The current implementation relies on the multicol
13 // implementation, but it in the long run it would be better to have what's comm on between 13 // implementation, but it in the long run it would be better to have what's comm on between
14 // LayoutMultiColumnFlowThread and LayoutPagedFlowThread in LayoutFlowThread, an d have both of them 14 // LayoutMultiColumnFlowThread and LayoutPagedFlowThread in LayoutFlowThread, an d have both of them
15 // inherit from that one. 15 // inherit from that one.
16 class LayoutPagedFlowThread : public LayoutMultiColumnFlowThread { 16 class LayoutPagedFlowThread : public LayoutMultiColumnFlowThread {
17 public: 17 public:
18 static LayoutPagedFlowThread* createAnonymous(Document&, const ComputedStyle & parentStyle); 18 static LayoutPagedFlowThread* createAnonymous(Document&, const ComputedStyle & parentStyle);
19 19
20 LayoutBlockFlow* pagedBlockFlow() const { return toLayoutBlockFlow(parent()) ; } 20 LayoutBlockFlow* pagedBlockFlow() const { return toLayoutBlockFlow(parent()) ; }
21 21
22 // Return the number of pages. Will never be less than 1.
23 int pageCount();
24
22 virtual bool isLayoutPagedFlowThread() const override { return true; } 25 virtual bool isLayoutPagedFlowThread() const override { return true; }
23 virtual const char* name() const override { return "LayoutPagedFlowThread"; } 26 virtual const char* name() const override { return "LayoutPagedFlowThread"; }
24 virtual bool needsNewWidth() const override; 27 virtual bool needsNewWidth() const override;
25 virtual void updateLogicalWidth() override; 28 virtual void updateLogicalWidth() override;
26 virtual void layout(); 29 virtual void layout();
27 30
28 private: 31 private:
29 virtual bool descendantIsValidColumnSpanner(LayoutObject* /*descendant*/) co nst override { return false; } 32 virtual bool descendantIsValidColumnSpanner(LayoutObject* /*descendant*/) co nst override { return false; }
30 }; 33 };
31 34
32 } // namespace blink 35 } // namespace blink
33 36
34 #endif // LayoutPagedFlowThread_h 37 #endif // LayoutPagedFlowThread_h
OLDNEW
« no previous file with comments | « Source/core/layout/LayoutMultiColumnFlowThreadTest.cpp ('k') | Source/core/layout/LayoutPagedFlowThread.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698