(svn r1369) -Feature(ish): Added sprites for up/down and left/right arrows. Anywhere where there are horizontal scrollers these are now left/right arrows
authordarkvater
Tue, 04 Jan 2005 14:54:27 +0000
changeset 884 c5bf8b3dbab4
parent 883 9bfde7bab1f9
child 885 074558f61ce2
(svn r1369) -Feature(ish): Added sprites for up/down and left/right arrows. Anywhere where there are horizontal scrollers these are now left/right arrows
data/openttd.grf
spritecache.c
table/sprites.h
widget.c
Binary file data/openttd.grf has changed
--- a/spritecache.c	Tue Jan 04 13:45:58 2005 +0000
+++ b/spritecache.c	Tue Jan 04 14:54:27 2005 +0000
@@ -743,7 +743,7 @@
 	"cached_sprites.xx3",
 };
 
-#define OPENTTD_SPRITES_COUNT 94
+#define OPENTTD_SPRITES_COUNT 98
 static const uint16 _openttd_grf_indexes[] = {
 	SPR_OPENTTD_BASE+0,	SPR_OPENTTD_BASE+7, // icons etc
 	134, 134,  // euro symbol medium size
--- a/table/sprites.h	Tue Jan 04 13:45:58 2005 +0000
+++ b/table/sprites.h	Tue Jan 04 14:54:27 2005 +0000
@@ -51,6 +51,11 @@
 	SPR_PIN_UP        = SPR_OPENTTD_BASE + 62,   // pin icon
 	SPR_PIN_DOWN      = SPR_OPENTTD_BASE + 63,
 	SPR_WINDOW_RESIZE = SPR_OPENTTD_BASE + 94,   // resize icon
+	// arrow icons pointing in all 4 directions
+	SPR_ARROW_DOWN    = SPR_OPENTTD_BASE + 95,
+	SPR_ARROW_UP      = SPR_OPENTTD_BASE + 96,
+	SPR_ARROW_LEFT    = SPR_OPENTTD_BASE + 97,
+	SPR_ARROW_RIGHT   = SPR_OPENTTD_BASE + 98,
 
 
 	/* Network GUI sprites */
--- a/widget.c	Tue Jan 04 13:45:58 2005 +0000
+++ b/widget.c	Tue Jan 04 14:54:27 2005 +0000
@@ -337,8 +337,8 @@
 			DrawFrameRect(r.right-9, r.top, r.right, r.bottom, wi->color, (w->flags4 & (WF_SCROLL_DOWN | WF_HSCROLL)) == (WF_SCROLL_DOWN | WF_HSCROLL) ? 0x20 : 0);
 
 			// draw icons in up/down buttons
-			DoDrawString("\xA0", r.left+1, r.top+1, 0x10);
-			DoDrawString("\xAA", r.right-8, r.top+1, 0x10);
+			DrawSprite(SPR_ARROW_LEFT, r.left + 3, r.top + 2);
+			DrawSprite(SPR_ARROW_RIGHT, r.right - 6, r.top + 2);
 
 			c1 = _color_list[wi->color&0xF].window_color_1a;
 			c2 = _color_list[wi->color&0xF].window_color_2;