OLD | NEW |
---|---|
1 /** | 1 /** |
2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 2000 Lars Knoll (knoll@kde.org) |
3 * Copyright (C) 2006 Apple Computer, Inc. | 3 * Copyright (C) 2006 Apple Computer, Inc. |
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 27 matching lines...) Expand all Loading... | |
38 : LayoutText(node, newlineString()) | 38 : LayoutText(node, newlineString()) |
39 { | 39 { |
40 } | 40 } |
41 | 41 |
42 LayoutBR::~LayoutBR() | 42 LayoutBR::~LayoutBR() |
43 { | 43 { |
44 } | 44 } |
45 | 45 |
46 LayoutRect LayoutBR::selectionRectForPaintInvalidation(const LayoutBoxModelObjec t* paintInvalidationContainer) const | 46 LayoutRect LayoutBR::selectionRectForPaintInvalidation(const LayoutBoxModelObjec t* paintInvalidationContainer) const |
47 { | 47 { |
48 if (!RuntimeEnabledFeatures::selectionPaintingWithoutSelectionGapsEnabled()) | |
chrishtr
2016/01/28 22:06:22
Why was this a negation of the feature when early-
wkorman
2016/01/28 22:54:32
This code was added as part of the new selection g
| |
49 return LayoutRect(); | |
50 | |
51 // Although line breaks contain no actual text, if we're selected we need | 48 // Although line breaks contain no actual text, if we're selected we need |
52 // to return a rect that includes space to illustrate a newline. | 49 // to return a rect that includes space to illustrate a newline. |
53 return LayoutText::selectionRectForPaintInvalidation(paintInvalidationContai ner); | 50 return LayoutText::selectionRectForPaintInvalidation(paintInvalidationContai ner); |
54 } | 51 } |
55 | 52 |
56 int LayoutBR::lineHeight(bool firstLine) const | 53 int LayoutBR::lineHeight(bool firstLine) const |
57 { | 54 { |
58 const ComputedStyle& style = styleRef(firstLine && document().styleEngine(). usesFirstLineRules()); | 55 const ComputedStyle& style = styleRef(firstLine && document().styleEngine(). usesFirstLineRules()); |
59 return style.computedLineHeight(); | 56 return style.computedLineHeight(); |
60 } | 57 } |
(...skipping 12 matching lines...) Expand all Loading... | |
73 { | 70 { |
74 return 1; | 71 return 1; |
75 } | 72 } |
76 | 73 |
77 PositionWithAffinity LayoutBR::positionForPoint(const LayoutPoint&) | 74 PositionWithAffinity LayoutBR::positionForPoint(const LayoutPoint&) |
78 { | 75 { |
79 return createPositionWithAffinity(0); | 76 return createPositionWithAffinity(0); |
80 } | 77 } |
81 | 78 |
82 } // namespace blink | 79 } // namespace blink |
OLD | NEW |