Bug 799335. Rename nsStyleImage::RequestDecode to StartDecoding. r=dholbert
authorJeff Muizelaar <jmuizelaar@mozilla.com>
Fri, 12 Oct 2012 16:04:03 -0400
changeset 110278 b8970531e93ee8b034c6e55650145ff43424f6e5
parent 110277 4ee4e3aa9ea6d133e9e29af1668ce21a5f98876c
child 110279 0ea416c21d176c96e9a792128a806245606e9fde
push id93
push usernmatsakis@mozilla.com
push dateWed, 31 Oct 2012 21:26:57 +0000
reviewersdholbert
bugs799335
milestone19.0a1
Bug 799335. Rename nsStyleImage::RequestDecode to StartDecoding. r=dholbert Now that RequestDecode call StartDecoding this make more sense.
layout/base/nsCSSRendering.cpp
layout/style/nsStyleStruct.cpp
layout/style/nsStyleStruct.h
--- a/layout/base/nsCSSRendering.cpp
+++ b/layout/base/nsCSSRendering.cpp
@@ -4011,17 +4011,17 @@ nsImageRenderer::~nsImageRenderer()
 {
 }
 
 bool
 nsImageRenderer::PrepareImage()
 {
   if (mImage->IsEmpty() || !mImage->IsComplete()) {
     // Make sure the image is actually decoding
-    mImage->RequestDecode();
+    mImage->StartDecoding();
 
     // We can not prepare the image for rendering if it is not fully loaded.
     //
     // Special case: If we requested a sync decode and we have an image, push
     // on through
     nsCOMPtr<imgIContainer> img;
     if (!((mFlags & FLAG_SYNC_DECODE_IMAGES) &&
           (mType == eStyleImageType_Image) &&
--- a/layout/style/nsStyleStruct.cpp
+++ b/layout/style/nsStyleStruct.cpp
@@ -1605,17 +1605,17 @@ nsStyleImage::ComputeActualCropRect(nsIn
   aActualCropRect.IntersectRect(imageRect, cropRect);
 
   if (aIsEntireImage)
     *aIsEntireImage = aActualCropRect.IsEqualInterior(imageRect);
   return true;
 }
 
 nsresult
-nsStyleImage::RequestDecode() const
+nsStyleImage::StartDecoding() const
 {
   if ((mType == eStyleImageType_Image) && mImage)
     return mImage->StartDecoding();
   return NS_OK;
 }
 
 bool
 nsStyleImage::IsOpaque() const
--- a/layout/style/nsStyleStruct.h
+++ b/layout/style/nsStyleStruct.h
@@ -220,19 +220,19 @@ struct nsStyleImage {
    * @param aIsEntireImage true iff |aActualCropRect| is identical to the
    * source image bounds.
    * @return true iff |aActualCropRect| holds a meaningful value.
    */
   bool ComputeActualCropRect(nsIntRect& aActualCropRect,
                                bool* aIsEntireImage = nullptr) const;
 
   /**
-   * Requests a decode on the image.
+   * Starts the decoding of a image.
    */
-  nsresult RequestDecode() const;
+  nsresult StartDecoding() const;
   /**
    * @return true if the item is definitely opaque --- i.e., paints every
    * pixel within its bounds opaquely, and the bounds contains at least a pixel.
    */
   bool IsOpaque() const;
   /**
    * @return true if this image is fully loaded, and its size is calculated;
    * always returns true if |mType| is |eStyleImageType_Gradient| or