Bug 1368776 - Part 7. Remove size parameter from ImageResource::UpdateImageContainer. r=tnikkel
authorAndrew Osmond <aosmond@mozilla.com>
Fri, 17 Nov 2017 06:45:25 -0500
changeset 392468 fd84718d8dbf50f149b6e131d496e495d1a08cf2
parent 392467 e9c89d2b9f99fd87749b63bf5b027b39d28a09d7
child 392469 9402cc966061e6954409bbe7ca8047ba1fd0eec1
push id32921
push usernerli@mozilla.com
push dateFri, 17 Nov 2017 22:02:18 +0000
treeherdermozilla-central@daa0dcd1616c [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerstnikkel
bugs1368776
milestone59.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1368776 - Part 7. Remove size parameter from ImageResource::UpdateImageContainer. r=tnikkel
image/Image.cpp
image/Image.h
image/RasterImage.cpp
--- a/image/Image.cpp
+++ b/image/Image.cpp
@@ -164,17 +164,17 @@ ImageResource::GetImageContainerImpl(Lay
 #endif
 
   entry->mLastDrawResult =
     AddCurrentImage(container, aSize, aFlags, true);
   return container.forget();
 }
 
 void
-ImageResource::UpdateImageContainer(const IntSize&)
+ImageResource::UpdateImageContainer()
 {
   MOZ_ASSERT(NS_IsMainThread());
 
   for (int i = mImageContainers.Length() - 1; i >= 0; --i) {
     ImageContainerEntry& entry = mImageContainers[i];
     RefPtr<ImageContainer> container = entry.mContainer.get();
     if (container) {
       entry.mLastDrawResult =
--- a/image/Image.h
+++ b/image/Image.h
@@ -344,17 +344,17 @@ protected:
     return MakePair(DrawResult::BAD_IMAGE, RefPtr<gfx::SourceSurface>());
   }
 
   already_AddRefed<layers::ImageContainer>
     GetImageContainerImpl(layers::LayerManager* aManager,
                           const gfx::IntSize& aSize,
                           uint32_t aFlags);
 
-  void UpdateImageContainer(const gfx::IntSize& aSize);
+  void UpdateImageContainer();
 
   void ReleaseImageContainer();
 
 private:
   DrawResult AddCurrentImage(layers::ImageContainer* aContainer,
                              const gfx::IntSize& aSize,
                              uint32_t aFlags,
                              bool aInTransaction);
--- a/image/RasterImage.cpp
+++ b/image/RasterImage.cpp
@@ -1599,17 +1599,17 @@ RasterImage::NotifyProgress(Progress aPr
 
   // Ensure that we stay alive long enough to finish notifying.
   RefPtr<RasterImage> image = this;
 
   const bool wasDefaultFlags = aSurfaceFlags == DefaultSurfaceFlags();
 
   if (!aInvalidRect.IsEmpty() && wasDefaultFlags) {
     // Update our image container since we're invalidating.
-    UpdateImageContainer(mSize);
+    UpdateImageContainer();
   }
 
   if (!(aDecoderFlags & DecoderFlags::FIRST_FRAME_ONLY)) {
     // We may have decoded new animation frames; update our animation state.
     MOZ_ASSERT_IF(aFrameCount && *aFrameCount > 1, mAnimationState || mError);
     if (mAnimationState && aFrameCount) {
       mAnimationState->UpdateKnownFrameCount(*aFrameCount);
     }