← Back to team overview

widelands-dev team mailing list archive

[Merge] lp:~widelands-dev/widelands/bug-1519361 into lp:widelands

 

GunChleoc has proposed merging lp:~widelands-dev/widelands/bug-1519361 into lp:widelands.

Requested reviews:
  Widelands Developers (widelands-dev)
Related bugs:
  Bug #1519361 in widelands: "PlayerColor in Building menu causes render errors"
  https://bugs.launchpad.net/widelands/+bug/1519361

For more details, see:
https://code.launchpad.net/~widelands-dev/widelands/bug-1519361/+merge/278886

This should fix the render errors for buttons displaying animation images.
-- 
Your team Widelands Developers is requested to review the proposed merge of lp:~widelands-dev/widelands/bug-1519361 into lp:widelands.
=== modified file 'src/graphic/animation.cc'
--- src/graphic/animation.cc	2015-11-20 18:16:22 +0000
+++ src/graphic/animation.cc	2015-11-28 14:21:03 +0000
@@ -307,6 +307,10 @@
 	int h = image->height();
 
 	Texture* rv = new Texture(w, h);
+
+	// Initialize the rectangle
+	::fill_rect(Rect(Point(0, 0), w, h), RGBAColor(255, 255, 255, 0), rv);
+
 	if (!hasplrclrs_ || clr == nullptr) {
 		::blit(Rect(Point(0, 0), w, h),
 				 *image,


Follow ups