foxygit / doom Log in
commit d0874f317888f9a05fd6783c9c9466ce83b148ca
Author:     Simon Howard <fraggle@gmail.com>
AuthorDate: Sun Sep 15 23:22:38 2013 +0000
Commit:     Simon Howard <fraggle@gmail.com>
CommitDate: Sun Sep 15 23:22:38 2013 +0000

    Open appropriate CMDLINE file depending on the currently-selected game.

    Subversion-branch: /branches/v2-branch
    Subversion-revision: 2655
---
 pkg/osx/LauncherManager.m | 11 ++++++++++-
 1 file changed, 10 insertions(+), 1 deletion(-)

diff --git a/pkg/osx/LauncherManager.m b/pkg/osx/LauncherManager.m
index a40ac7c9..0f4028eb 100644
--- a/pkg/osx/LauncherManager.m
+++ b/pkg/osx/LauncherManager.m
@@ -355,7 +355,16 @@ static NSString *AppendQuotedFilename(NSString *str, NSString *fileName)

 - (void) openCMDLINE: (id) sender
 {
-    OpenDocumentation("CMDLINE");
+    char *game_name;
+    char filename[32];
+
+    // We need to open the appropriate doc file for the currently
+    // selected game.
+
+    game_name = [self->iwadController getGameName];
+    sprintf(filename, "CMDLINE.%s", game_name);
+
+    OpenDocumentation(filename);
 }

 - (void) openCOPYING: (id) sender