From f1e9fdf76d951dec71c330f12783917cae464160 Mon Sep 17 00:00:00 2001 From: dominik Date: Wed, 5 Jan 2005 14:20:23 +0000 Subject: [PATCH] (svn r1388) Feature: [SDL] Show revision number in window title --- sdl.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/sdl.c b/sdl.c index c9275f37a6..e400566194 100644 --- a/sdl.c +++ b/sdl.c @@ -319,9 +319,12 @@ static int GetAvailableVideoMode(int *w, int *h) return 2; } +extern const char _openttd_revision[]; + static bool CreateMainSurface(int w, int h) { SDL_Surface *newscreen; + char *caption; GetAvailableVideoMode(&w, &h); @@ -339,7 +342,8 @@ static bool CreateMainSurface(int w, int h) _sdl_screen = newscreen; InitPalette(); - SDL_CALL SDL_WM_SetCaption("OpenTTD", "OpenTTD"); + caption = str_fmt("OpenTTD %s", _openttd_revision); + SDL_CALL SDL_WM_SetCaption(caption, caption); SDL_CALL SDL_ShowCursor(0); GameSizeChanged();