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

Side by Side Diff: third_party/WebKit/Source/core/layout/ng/ng_fragment_base.cc

Issue 2612103004: [ng_layout] Rename NGFragmentBase,NGFragment,NGPhysicalFragment (Closed)
Patch Set: CR: rename ifdef guards Created 3 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
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #include "core/layout/ng/ng_fragment_base.h"
6
7 namespace blink {
8
9 LayoutUnit NGFragmentBase::InlineSize() const {
10 return writing_mode_ == kHorizontalTopBottom ? physical_fragment_->Width()
11 : physical_fragment_->Height();
12 }
13
14 LayoutUnit NGFragmentBase::BlockSize() const {
15 return writing_mode_ == kHorizontalTopBottom ? physical_fragment_->Height()
16 : physical_fragment_->Width();
17 }
18
19 LayoutUnit NGFragmentBase::InlineOverflow() const {
20 return writing_mode_ == kHorizontalTopBottom
21 ? physical_fragment_->WidthOverflow()
22 : physical_fragment_->HeightOverflow();
23 }
24
25 LayoutUnit NGFragmentBase::BlockOverflow() const {
26 return writing_mode_ == kHorizontalTopBottom
27 ? physical_fragment_->HeightOverflow()
28 : physical_fragment_->WidthOverflow();
29 }
30
31 LayoutUnit NGFragmentBase::InlineOffset() const {
32 return writing_mode_ == kHorizontalTopBottom
33 ? physical_fragment_->LeftOffset()
34 : physical_fragment_->TopOffset();
35 }
36
37 LayoutUnit NGFragmentBase::BlockOffset() const {
38 return writing_mode_ == kHorizontalTopBottom
39 ? physical_fragment_->TopOffset()
40 : physical_fragment_->LeftOffset();
41 }
42
43 NGPhysicalFragmentBase::NGFragmentType NGFragmentBase::Type() const {
44 return physical_fragment_->Type();
45 }
46
47 DEFINE_TRACE(NGFragmentBase) {
48 visitor->trace(physical_fragment_);
49 }
50
51 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698