mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1146114 - Make assertion checking additional leading in ruby frame non-crash. r=dholbert
This commit is contained in:
parent
89ad93c9a8
commit
e020f1328a
6
layout/generic/crashtests/1146114.html
Normal file
6
layout/generic/crashtests/1146114.html
Normal file
@ -0,0 +1,6 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<body>
|
||||
<div style="display: ruby-text; margin: 288230376151711740%"></div>
|
||||
</body>
|
||||
</html>
|
@ -579,3 +579,4 @@ asserts(3-7) load 1137723-2.html # bug 1019192, bug 1138133
|
||||
asserts(0-3) load 1134667.html
|
||||
asserts(0-3) load 1134667.html
|
||||
asserts(0-3) load 1134667.html
|
||||
load 1146114.html
|
||||
|
@ -374,9 +374,10 @@ nsRubyFrame::ReflowSegment(nsPresContext* aPresContext,
|
||||
// Set block leadings of the base container
|
||||
nscoord startLeading = baseRect.BStart(lineWM) - offsetRect.BStart(lineWM);
|
||||
nscoord endLeading = offsetRect.BEnd(lineWM) - baseRect.BEnd(lineWM);
|
||||
NS_ASSERTION(startLeading >= 0 && endLeading >= 0,
|
||||
"Leadings should be non-negative (because adding "
|
||||
"ruby annotation can only increase the size)");
|
||||
// XXX When bug 765861 gets fixed, this warning should be upgraded.
|
||||
NS_WARN_IF_FALSE(startLeading >= 0 && endLeading >= 0,
|
||||
"Leadings should be non-negative (because adding "
|
||||
"ruby annotation can only increase the size)");
|
||||
mBStartLeading = std::max(mBStartLeading, startLeading);
|
||||
mBEndLeading = std::max(mBEndLeading, endLeading);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user