Fix: Render background-size correctly with no-repeat #447

This commit is contained in:
Niklas von Hertzen
2014-09-27 17:02:46 +03:00
parent 1d8a316f13
commit 3f3424e49c
4 changed files with 17 additions and 5 deletions

View File

@ -95,7 +95,7 @@ Renderer.prototype.renderBackgroundRepeating = function(container, bounds, image
this.backgroundRepeatShape(imageContainer, position, size, bounds, bounds.left + position.left + borderData[3], bounds.top + borderData[0], imageContainer.image.width, 99999, borderData);
break;
case "no-repeat":
this.backgroundRepeatShape(imageContainer, position, size, bounds, bounds.left + position.left + borderData[3], bounds.top + position.top + borderData[0], imageContainer.image.width, imageContainer.image.height, borderData);
this.backgroundRepeatShape(imageContainer, position, size, bounds, bounds.left + position.left + borderData[3], bounds.top + position.top + borderData[0], size.width, size.height, borderData);
break;
default:
this.renderBackgroundRepeat(imageContainer, position, size, {top: bounds.top, left: bounds.left}, borderData[3], borderData[0]);