зеркало из https://github.com/mozilla/gecko-dev.git
Bug 893484 - Set second last polygon marker type before appending last one. r=jwatt
This commit is contained in:
Родитель
bbb7ca8e58
Коммит
b05fa0ae0b
|
@ -48,6 +48,7 @@ SVGPolygonElement::GetMarkPoints(nsTArray<nsSVGMark> *aMarks)
|
|||
nsSVGMark *startMark = &aMarks->ElementAt(0);
|
||||
float angle = atan2(startMark->y - endMark->y, startMark->x - endMark->x);
|
||||
|
||||
endMark->type = nsSVGMark::eMid;
|
||||
endMark->angle = SVGContentUtils::AngleBisect(angle, endMark->angle);
|
||||
startMark->angle = SVGContentUtils::AngleBisect(angle, startMark->angle);
|
||||
// for a polygon (as opposed to a polyline) there's an implicit extra point
|
||||
|
@ -55,7 +56,6 @@ SVGPolygonElement::GetMarkPoints(nsTArray<nsSVGMark> *aMarks)
|
|||
// doesn't return
|
||||
aMarks->AppendElement(nsSVGMark(startMark->x, startMark->y, startMark->angle,
|
||||
nsSVGMark::eEnd));
|
||||
endMark->type = nsSVGMark::eMid;
|
||||
}
|
||||
|
||||
void
|
||||
|
|
Загрузка…
Ссылка в новой задаче