Title: [135517] trunk/Source/WebCore
Revision
135517
Author
[email protected]
Date
2012-11-22 06:22:12 -0800 (Thu, 22 Nov 2012)

Log Message

[TexMap] Reduce public methods of TextureMapperTiledBackingStore.
https://bugs.webkit.org/show_bug.cgi?id=103032

Patch by Huang Dongsung <[email protected]> on 2012-11-22
Reviewed by Noam Rosenthal.

This patch makes two methods private and removes one method.

No new tests, refactoring only.

* platform/graphics/texmap/TextureMapperBackingStore.cpp:
(WebCore::TextureMapperTiledBackingStore::updateContentsFromImageIfNeeded):
* platform/graphics/texmap/TextureMapperBackingStore.h:
(WebCore::TextureMapperTiledBackingStore::create):
(TextureMapperTiledBackingStore):
(WebCore::TextureMapperTiledBackingStore::setContentsToImage):
(WebCore::TextureMapperTiledBackingStore::rect):

Modified Paths

Diff

Modified: trunk/Source/WebCore/ChangeLog (135516 => 135517)


--- trunk/Source/WebCore/ChangeLog	2012-11-22 14:06:17 UTC (rev 135516)
+++ trunk/Source/WebCore/ChangeLog	2012-11-22 14:22:12 UTC (rev 135517)
@@ -1,3 +1,22 @@
+2012-11-22  Huang Dongsung  <[email protected]>
+
+        [TexMap] Reduce public methods of TextureMapperTiledBackingStore.
+        https://bugs.webkit.org/show_bug.cgi?id=103032
+
+        Reviewed by Noam Rosenthal.
+
+        This patch makes two methods private and removes one method.
+
+        No new tests, refactoring only.
+
+        * platform/graphics/texmap/TextureMapperBackingStore.cpp:
+        (WebCore::TextureMapperTiledBackingStore::updateContentsFromImageIfNeeded):
+        * platform/graphics/texmap/TextureMapperBackingStore.h:
+        (WebCore::TextureMapperTiledBackingStore::create):
+        (TextureMapperTiledBackingStore):
+        (WebCore::TextureMapperTiledBackingStore::setContentsToImage):
+        (WebCore::TextureMapperTiledBackingStore::rect):
+
 2012-11-22  Simon Hausmann  <[email protected]>, Pierre Rossi <[email protected]>
 
         [Qt] Separate QWidget dependant code into separate WebKitWidgets static library

Modified: trunk/Source/WebCore/platform/graphics/texmap/TextureMapperBackingStore.cpp (135516 => 135517)


--- trunk/Source/WebCore/platform/graphics/texmap/TextureMapperBackingStore.cpp	2012-11-22 14:06:17 UTC (rev 135516)
+++ trunk/Source/WebCore/platform/graphics/texmap/TextureMapperBackingStore.cpp	2012-11-22 14:22:12 UTC (rev 135517)
@@ -96,7 +96,7 @@
     if (!m_image)
         return;
 
-    updateContents(textureMapper, m_image.get(), BitmapTexture::UpdateCannotModifyOriginalImageData);
+    updateContents(textureMapper, m_image.get(), m_image->size(), m_image->rect(), BitmapTexture::UpdateCannotModifyOriginalImageData);
     m_image.clear();
 }
 

Modified: trunk/Source/WebCore/platform/graphics/texmap/TextureMapperBackingStore.h (135516 => 135517)


--- trunk/Source/WebCore/platform/graphics/texmap/TextureMapperBackingStore.h	2012-11-22 14:06:17 UTC (rev 135516)
+++ trunk/Source/WebCore/platform/graphics/texmap/TextureMapperBackingStore.h	2012-11-22 14:22:12 UTC (rev 135517)
@@ -88,23 +88,22 @@
 
 class TextureMapperTiledBackingStore : public TextureMapperBackingStore {
 public:
-    void updateContentsFromLayer(TextureMapper*, GraphicsLayer*, const IntRect&);
+    static PassRefPtr<TextureMapperTiledBackingStore> create() { return adoptRef(new TextureMapperTiledBackingStore); }
     virtual ~TextureMapperTiledBackingStore() { }
-    virtual void paintToTextureMapper(TextureMapper*, const FloatRect&, const TransformationMatrix&, float, BitmapTexture*);
-    virtual PassRefPtr<BitmapTexture> texture() const;
+
+    virtual PassRefPtr<BitmapTexture> texture() const OVERRIDE;
+    virtual void paintToTextureMapper(TextureMapper*, const FloatRect&, const TransformationMatrix&, float, BitmapTexture*) OVERRIDE;
     void updateContents(TextureMapper*, Image*, const FloatSize&, const IntRect&, BitmapTexture::UpdateContentsFlag);
-    void updateContents(TextureMapper* textureMapper, Image* image, BitmapTexture::UpdateContentsFlag updateContentsFlag) { updateContents(textureMapper, image, image->size(), image->rect(), updateContentsFlag); }
-    inline FloatRect rect() const { return FloatRect(FloatPoint::zero(), m_size); }
-    static PassRefPtr<TextureMapperTiledBackingStore> create() { return adoptRef(new TextureMapperTiledBackingStore); }
-    void setContentsToImage(Image* image) { m_image = image; }
-    void updateContentsFromImageIfNeeded(TextureMapper*);
 
+    void setContentsToImage(Image* image) { m_image = image; }
     void setShowDebugBorders(bool drawsDebugBorders) { m_drawsDebugBorders = drawsDebugBorders; }
     void setDebugBorder(const Color&, float width);
 
 private:
     TextureMapperTiledBackingStore();
     void createOrDestroyTilesIfNeeded(const FloatSize& backingStoreSize, const IntSize& tileSize, bool hasAlpha);
+    void updateContentsFromImageIfNeeded(TextureMapper*);
+    inline FloatRect rect() const { return FloatRect(FloatPoint::zero(), m_size); }
 
     Vector<TextureMapperTile> m_tiles;
     FloatSize m_size;
_______________________________________________
webkit-changes mailing list
[email protected]
http://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to