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

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

Issue 1162383003: C++11: Replace 0 with nullptr where applicable in layout code. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Add one more file. 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
« no previous file with comments | « Source/core/layout/LayoutTextCombine.h ('k') | Source/core/layout/LayoutTextControl.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) 2006, 2007 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2007 Apple Inc. All rights reserved.
3 * (C) 2008 Torch Mobile Inc. All rights reserved. (http://www.torchmo bile.com/) 3 * (C) 2008 Torch Mobile Inc. All rights reserved. (http://www.torchmo bile.com/)
4 * 4 *
5 * This library is free software; you can redistribute it and/or 5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Library General Public 6 * modify it under the terms of the GNU Library General Public
7 * License as published by the Free Software Foundation; either 7 * License as published by the Free Software Foundation; either
8 * version 2 of the License, or (at your option) any later version. 8 * version 2 of the License, or (at your option) any later version.
9 * 9 *
10 * This library is distributed in the hope that it will be useful, 10 * This library is distributed in the hope that it will be useful,
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
73 virtual int inlineBlockBaseline(LineDirectionMode direction) const override { return lastLineBoxBaseline(direction); } 73 virtual int inlineBlockBaseline(LineDirectionMode direction) const override { return lastLineBoxBaseline(direction); }
74 74
75 virtual bool isOfType(LayoutObjectType type) const override { return type == LayoutObjectTextControl || LayoutBlockFlow::isOfType(type); } 75 virtual bool isOfType(LayoutObjectType type) const override { return type == LayoutObjectTextControl || LayoutBlockFlow::isOfType(type); }
76 76
77 private: 77 private:
78 virtual void computeIntrinsicLogicalWidths(LayoutUnit& minLogicalWidth, Layo utUnit& maxLogicalWidth) const override final; 78 virtual void computeIntrinsicLogicalWidths(LayoutUnit& minLogicalWidth, Layo utUnit& maxLogicalWidth) const override final;
79 virtual void computePreferredLogicalWidths() override final; 79 virtual void computePreferredLogicalWidths() override final;
80 virtual void removeLeftoverAnonymousBlock(LayoutBlock*) override final { } 80 virtual void removeLeftoverAnonymousBlock(LayoutBlock*) override final { }
81 virtual bool avoidsFloats() const override final { return true; } 81 virtual bool avoidsFloats() const override final { return true; }
82 82
83 virtual void addChild(LayoutObject* newChild, LayoutObject* beforeChild = 0) override final; 83 virtual void addChild(LayoutObject* newChild, LayoutObject* beforeChild = nu llptr) override final;
84 84
85 virtual void addFocusRingRects(Vector<LayoutRect>&, const LayoutPoint& addit ionalOffset) const override final; 85 virtual void addFocusRingRects(Vector<LayoutRect>&, const LayoutPoint& addit ionalOffset) const override final;
86 86
87 virtual bool canBeProgramaticallyScrolled() const override final { return tr ue; } 87 virtual bool canBeProgramaticallyScrolled() const override final { return tr ue; }
88 }; 88 };
89 89
90 DEFINE_LAYOUT_OBJECT_TYPE_CASTS(LayoutTextControl, isTextControl()); 90 DEFINE_LAYOUT_OBJECT_TYPE_CASTS(LayoutTextControl, isTextControl());
91 91
92 // LayoutObject for our inner container, for <search> and others. 92 // LayoutObject for our inner container, for <search> and others.
93 // We can't use LayoutFlexibleBox directly, because flexboxes have a different 93 // We can't use LayoutFlexibleBox directly, because flexboxes have a different
(...skipping 11 matching lines...) Expand all
105 return LayoutBlock::baselinePosition(baseline, firstLine, direction, pos ition); 105 return LayoutBlock::baselinePosition(baseline, firstLine, direction, pos ition);
106 } 106 }
107 virtual int firstLineBoxBaseline() const override { return LayoutBlock::firs tLineBoxBaseline(); } 107 virtual int firstLineBoxBaseline() const override { return LayoutBlock::firs tLineBoxBaseline(); }
108 virtual int inlineBlockBaseline(LineDirectionMode direction) const override { return lastLineBoxBaseline(direction); } 108 virtual int inlineBlockBaseline(LineDirectionMode direction) const override { return lastLineBoxBaseline(direction); }
109 }; 109 };
110 110
111 111
112 } // namespace blink 112 } // namespace blink
113 113
114 #endif // LayoutTextControl_h 114 #endif // LayoutTextControl_h
OLDNEW
« no previous file with comments | « Source/core/layout/LayoutTextCombine.h ('k') | Source/core/layout/LayoutTextControl.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698