Bug 943201 - Add gradient to download progress ring image, rotate it with progress angle. r=mbrubeck, a=lsblakk
authorSam Foster <sfoster@mozilla.com>
Mon, 16 Dec 2013 10:33:36 -0800
changeset 174448 a9e112d16d126629e64c2fd1cce9e0a2e1670d5f
parent 174447 fdfb137e8e949161f499b01bbe8a61dc4f520d39
child 174449 5f8fe9d708c9dc385edf0625c1ade9659d1b851d
push id3224
push userlsblakk@mozilla.com
push dateTue, 04 Feb 2014 01:06:49 +0000
treeherdermozilla-beta@60c04d0987f1 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmbrubeck, lsblakk
bugs943201
milestone28.0a2
Bug 943201 - Add gradient to download progress ring image, rotate it with progress angle. r=mbrubeck, a=lsblakk
browser/metro/base/content/bindings/circularprogress.xml
browser/metro/theme/images/progresscircle.png
--- a/browser/metro/base/content/bindings/circularprogress.xml
+++ b/browser/metro/base/content/bindings/circularprogress.xml
@@ -62,17 +62,19 @@
               ctx.beginPath();
               let center = this._progressCanvas.width / 2;
               ctx.arc(center, center, center, startAngle, endAngle, false);
               ctx.lineTo(center, center);
               ctx.closePath();
               ctx.clip();
 
               // Draw circle image.
-              ctx.drawImage(this._img, 0, 0);
+              ctx.translate(center, center);
+              ctx.rotate(endAngle);
+              ctx.drawImage(this._img, -center, -center);
 
               ctx.restore();
             } else {
               //  Image is still loading
             }
             return [startAngle, endAngle];
           ]]>
         </body>
index fe2af4660b8e4bc9d39be9d075e31b72fd3747c7..3f74cdf6f76a6a39453c02a225807c129287d12b
GIT binary patch
literal 1945
zc$@*52WI$*P)<h;3K|Lk000e1NJLTq001Ze001Zm1^@s6jQ+T7000MINkl<ZScS!z
ze{5Cd8OJ}*d(XYSZEp*$KpSXFEfi*lpi^2LGIB+tBU>Q*gBUl)zl+8!#B3|emNc27
zBQY*>W?QlZ7uZx>4919yfSnNCV03^CksqZ$C`emu>5tnV_ug}!{qdf2?;S*GS?QkS
z=JcL>&UruQ`@GMO_pNXX*3_&{;Y>F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