~ubuntu-branches/ubuntu/lucid/webkit/lucid-updates

« back to all changes in this revision

Viewing changes to WebCore/svg/SVGLineElement.cpp

  • Committer: Bazaar Package Importer
  • Author(s): Gustavo Noronha Silva
  • Date: 2010-02-04 19:30:57 UTC
  • mfrom: (1.2.8 upstream) (4.3.9 sid)
  • Revision ID: james.westby@ubuntu.com-20100204193057-d3018lm1fipb0703
* New upstream release
* debian/copyright:
- Updated with changes since 1.1.19.

Show diffs side-by-side

added added

removed removed

Lines of Context:
36
36
    , SVGTests()
37
37
    , SVGLangSpace()
38
38
    , SVGExternalResourcesRequired()
39
 
    , m_x1(this, SVGNames::x1Attr, LengthModeWidth)
40
 
    , m_y1(this, SVGNames::y1Attr, LengthModeHeight)
41
 
    , m_x2(this, SVGNames::x2Attr, LengthModeWidth)
42
 
    , m_y2(this, SVGNames::y2Attr, LengthModeHeight)
43
 
    , m_externalResourcesRequired(this, SVGNames::externalResourcesRequiredAttr, false)
 
39
    , m_x1(LengthModeWidth)
 
40
    , m_y1(LengthModeHeight)
 
41
    , m_x2(LengthModeWidth)
 
42
    , m_y2(LengthModeHeight)
44
43
{
45
44
}
46
45
 
85
84
        renderer()->setNeedsLayout(true);
86
85
}
87
86
 
 
87
void SVGLineElement::synchronizeProperty(const QualifiedName& attrName)
 
88
{
 
89
    SVGStyledTransformableElement::synchronizeProperty(attrName);
 
90
 
 
91
    if (attrName == anyQName()) {
 
92
        synchronizeX1();
 
93
        synchronizeY1();
 
94
        synchronizeX2();
 
95
        synchronizeY2();
 
96
        synchronizeExternalResourcesRequired();
 
97
        return;
 
98
    }
 
99
 
 
100
    if (attrName == SVGNames::x1Attr)
 
101
        synchronizeX1();
 
102
    else if (attrName == SVGNames::y1Attr)
 
103
        synchronizeY1();
 
104
    else if (attrName == SVGNames::x2Attr)
 
105
        synchronizeX2();
 
106
    else if (attrName == SVGNames::y2Attr)
 
107
        synchronizeY2();
 
108
    else if (SVGExternalResourcesRequired::isKnownAttribute(attrName))
 
109
        synchronizeExternalResourcesRequired();
 
110
}
 
111
 
88
112
Path SVGLineElement::toPathData() const
89
113
{
90
114
    return Path::createLine(FloatPoint(x1().value(this), y1().value(this)),