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

Side by Side Diff: third_party/WebKit/Source/core/layout/ng/ng_box_fragment.h

Issue 2655783006: Top down version of algorithm to position margins and floats in LayoutNG (Closed)
Patch Set: git rebase-update Created 3 years, 10 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 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 NGBoxFragment_h 5 #ifndef NGBoxFragment_h
6 #define NGBoxFragment_h 6 #define NGBoxFragment_h
7 7
8 #include "core/CoreExport.h" 8 #include "core/CoreExport.h"
9 #include "core/layout/ng/ng_fragment.h" 9 #include "core/layout/ng/ng_fragment.h"
10 #include "core/layout/ng/ng_physical_box_fragment.h" 10 #include "core/layout/ng/ng_physical_box_fragment.h"
11 #include "core/layout/ng/ng_units.h" 11 #include "core/layout/ng/ng_units.h"
12 #include "core/layout/ng/ng_writing_mode.h" 12 #include "core/layout/ng/ng_writing_mode.h"
13 13
14 namespace blink { 14 namespace blink {
15 15
16 class CORE_EXPORT NGBoxFragment final : public NGFragment { 16 class CORE_EXPORT NGBoxFragment final : public NGFragment {
17 public: 17 public:
18 NGBoxFragment(NGWritingMode writing_mode, 18 NGBoxFragment(NGWritingMode writing_mode,
19 TextDirection direction, 19 TextDirection direction,
20 NGPhysicalBoxFragment* physical_fragment) 20 NGPhysicalBoxFragment* physical_fragment)
21 : NGFragment(writing_mode, direction, physical_fragment) {} 21 : NGFragment(writing_mode, direction, physical_fragment) {}
22 22
23 NGDeprecatedMarginStrut MarginStrut() const; 23 const WTF::Optional<NGLogicalOffset>& BfcOffset() const;
24
25 const NGMarginStrut& EndMarginStrut() const;
24 }; 26 };
25 27
26 DEFINE_TYPE_CASTS(NGBoxFragment, 28 DEFINE_TYPE_CASTS(NGBoxFragment,
27 NGFragment, 29 NGFragment,
28 fragment, 30 fragment,
29 fragment->Type() == NGPhysicalFragment::kFragmentBox, 31 fragment->Type() == NGPhysicalFragment::kFragmentBox,
30 fragment.Type() == NGPhysicalFragment::kFragmentBox); 32 fragment.Type() == NGPhysicalFragment::kFragmentBox);
31 33
32 } // namespace blink 34 } // namespace blink
33 35
34 #endif // NGBoxFragment_h 36 #endif // NGBoxFragment_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698