Fix image loading and implement icon class
git-svn-id: http://svn.webkit.org/repository/webkit/trunk@19137 268f45cc-cd09-0410-ab3c-d52691b4dbfc
diff --git a/WebCore/platform/graphics/qt/ImageQt.cpp b/WebCore/platform/graphics/qt/ImageQt.cpp
index ed46b42..c431442 100644
--- a/WebCore/platform/graphics/qt/ImageQt.cpp
+++ b/WebCore/platform/graphics/qt/ImageQt.cpp
@@ -133,7 +133,7 @@
QPixmap* framePixmap = nativeImageForCurrentFrame();
if (!framePixmap) // If it's too early we won't have an image yet.
return;
-
+
QPixmap pixmap = *framePixmap;
QRect tr = QRectF(tileRect).toRect();
if (tr.x() || tr.y() || tr.width() != pixmap.width() || tr.height() != pixmap.height())
@@ -159,6 +159,11 @@
m_isSolidColor = false;
}
+QPixmap* BitmapImage::getPixmap() const
+{
+ return const_cast<BitmapImage*>(this)->frameAtIndex(0);
+}
+
}