summaryrefslogtreecommitdiff
path: root/setup/mainmenu.c
diff options
context:
space:
mode:
authorSimon Howard2011-01-02 02:49:20 +0000
committerSimon Howard2011-01-02 02:49:20 +0000
commit4fc7b22ad09759474706012251161caef3970420 (patch)
tree301dbb0e806e0f5d9a5fe7ab2df250e69df64272 /setup/mainmenu.c
parente63839de20c56649ce16adfe7e849735223ad130 (diff)
downloadchocolate-doom-4fc7b22ad09759474706012251161caef3970420.tar.gz
chocolate-doom-4fc7b22ad09759474706012251161caef3970420.tar.bz2
chocolate-doom-4fc7b22ad09759474706012251161caef3970420.zip
Restore window title when changing video driver in setup tool (thanks
AlexXav). Subversion-branch: /trunk/chocolate-doom Subversion-revision: 2233
Diffstat (limited to 'setup/mainmenu.c')
-rw-r--r--setup/mainmenu.c25
1 files changed, 20 insertions, 5 deletions
diff --git a/setup/mainmenu.c b/setup/mainmenu.c
index ae8ab9b0..a3dfafed 100644
--- a/setup/mainmenu.c
+++ b/setup/mainmenu.c
@@ -256,11 +256,9 @@ static void SetIcon(void)
free(mask);
}
-//
-// Initialize and run the textscreen GUI.
-//
+// Initialize the textscreen library.
-static void RunGUI(void)
+static void InitTextscreen(void)
{
SetDisplayDriver();
@@ -272,7 +270,24 @@ static void RunGUI(void)
TXT_SetDesktopTitle(PACKAGE_NAME " Setup ver " PACKAGE_VERSION);
SetIcon();
-
+}
+
+// Restart the textscreen library. Used when the video_driver variable
+// is changed.
+
+void RestartTextscreen(void)
+{
+ TXT_Shutdown();
+ InitTextscreen();
+}
+
+//
+// Initialize and run the textscreen GUI.
+//
+
+static void RunGUI(void)
+{
+ InitTextscreen();
MainMenu();
TXT_GUIMainLoop();