| Index: sky/engine/core/html/HTMLImageElement.cpp
|
| diff --git a/sky/engine/core/html/HTMLImageElement.cpp b/sky/engine/core/html/HTMLImageElement.cpp
|
| index 30a0ea1d3ed9a358bc5c90893a845b934354c0a1..bd19fe384eeff46b982aaef0cff52b44a95acb4e 100644
|
| --- a/sky/engine/core/html/HTMLImageElement.cpp
|
| +++ b/sky/engine/core/html/HTMLImageElement.cpp
|
| @@ -178,46 +178,6 @@ void HTMLImageElement::removedFrom(ContainerNode* insertionPoint)
|
| HTMLElement::removedFrom(insertionPoint);
|
| }
|
|
|
| -int HTMLImageElement::width()
|
| -{
|
| - if (!renderer()) {
|
| - // check the attribute first for an explicit pixel value
|
| - bool ok;
|
| - int width = getAttribute(HTMLNames::widthAttr).toInt(&ok);
|
| - if (ok)
|
| - return width;
|
| -
|
| - // if the image is available, use its width
|
| - if (imageLoader().image())
|
| - return imageLoader().image()->imageSizeForRenderer(renderer()).width();
|
| - }
|
| -
|
| - document().updateLayout();
|
| -
|
| - RenderBox* box = renderBox();
|
| - return box ? box->contentBoxRect().pixelSnappedWidth() : 0;
|
| -}
|
| -
|
| -int HTMLImageElement::height()
|
| -{
|
| - if (!renderer()) {
|
| - // check the attribute first for an explicit pixel value
|
| - bool ok;
|
| - int height = getAttribute(HTMLNames::heightAttr).toInt(&ok);
|
| - if (ok)
|
| - return height;
|
| -
|
| - // if the image is available, use its height
|
| - if (imageLoader().image())
|
| - return imageLoader().image()->imageSizeForRenderer(renderer()).height();
|
| - }
|
| -
|
| - document().updateLayout();
|
| -
|
| - RenderBox* box = renderBox();
|
| - return box ? box->contentBoxRect().pixelSnappedHeight() : 0;
|
| -}
|
| -
|
| int HTMLImageElement::naturalWidth() const
|
| {
|
| if (!imageLoader().image())
|
| @@ -252,11 +212,6 @@ bool HTMLImageElement::isURLAttribute(const Attribute& attribute) const
|
| || HTMLElement::isURLAttribute(attribute);
|
| }
|
|
|
| -void HTMLImageElement::setHeight(int value)
|
| -{
|
| - setIntegralAttribute(HTMLNames::heightAttr, value);
|
| -}
|
| -
|
| KURL HTMLImageElement::src() const
|
| {
|
| return document().completeURL(getAttribute(HTMLNames::srcAttr));
|
| @@ -267,35 +222,6 @@ void HTMLImageElement::setSrc(const String& value)
|
| setAttribute(HTMLNames::srcAttr, AtomicString(value));
|
| }
|
|
|
| -void HTMLImageElement::setWidth(int value)
|
| -{
|
| - setIntegralAttribute(HTMLNames::widthAttr, value);
|
| -}
|
| -
|
| -int HTMLImageElement::x() const
|
| -{
|
| - document().updateLayout();
|
| - RenderObject* r = renderer();
|
| - if (!r)
|
| - return 0;
|
| -
|
| - // FIXME: This doesn't work correctly with transforms.
|
| - FloatPoint absPos = r->localToAbsolute();
|
| - return absPos.x();
|
| -}
|
| -
|
| -int HTMLImageElement::y() const
|
| -{
|
| - document().updateLayout();
|
| - RenderObject* r = renderer();
|
| - if (!r)
|
| - return 0;
|
| -
|
| - // FIXME: This doesn't work correctly with transforms.
|
| - FloatPoint absPos = r->localToAbsolute();
|
| - return absPos.y();
|
| -}
|
| -
|
| bool HTMLImageElement::complete() const
|
| {
|
| return imageLoader().imageComplete();
|
|
|