From 3d440b2d85c09b33fe679214eb9df72228c4f14c Mon Sep 17 00:00:00 2001 From: mcmartin Date: Fri, 10 Mar 2006 10:34:26 +0000 Subject: [PATCH] Report on setup stringtable resource. Does not actually load it yet. git-svn-id: svn://svn.code.sf.net/p/sc2/code/trunk@2267 8092fc87-c524-0410-9efc-e669fe64eaf9 --- sc2/src/sc2code/setupmenu.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/sc2/src/sc2code/setupmenu.c b/sc2/src/sc2code/setupmenu.c index e33df6d22..99c07b635 100644 --- a/sc2/src/sc2code/setupmenu.c +++ b/sc2/src/sc2code/setupmenu.c @@ -26,10 +26,13 @@ #include "libs/graphics/gfx_common.h" #include "libs/graphics/widgets.h" #include "libs/graphics/tfb_draw.h" +#include "libs/strlib.h" #include "libs/reslib.h" #include "libs/sound/sound.h" #include "resinst.h" +#include "nameref.h" +static STRING SetupTab; typedef struct setup_menu_state { BOOLEAN (*InputFunc) (struct setup_menu_state *pInputState); @@ -736,10 +739,25 @@ SetupMenu (void) s.InputFunc = DoSetupMenu; s.initialized = FALSE; SetMenuSounds (0, MENU_SOUND_SELECT); + SetupTab = CaptureStringTable (LoadStringTable (SETUP_MENU_STRTAB)); + if (SetupTab) + { + fprintf (stderr, "GetStringTableCount reports %d entries.\n", GetStringTableCount (SetupTab)); + } + else + { + fprintf (stderr, "Could not find setup strings!\n"); + } done = FALSE; + DoInput ((PVOID)&s, TRUE); GLOBAL (CurrentActivity) &= ~CHECK_ABORT; PropagateResults (); + if (SetupTab) + { + DestroyStringTable (ReleaseStringTable (SetupTab)); + SetupTab = 0; + } } void