From a8e03a9490d759fdaa9ae021333f90ec4c8c976b Mon Sep 17 00:00:00 2001 From: Kelvin Sherlock Date: Sun, 16 May 2021 11:06:12 -0400 Subject: [PATCH] support for -share_directory (booti card). No UI support yet, though. --- Ample/LaunchWindowController.m | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Ample/LaunchWindowController.m b/Ample/LaunchWindowController.m index a7ff741..97622cb 100644 --- a/Ample/LaunchWindowController.m +++ b/Ample/LaunchWindowController.m @@ -46,6 +46,7 @@ static NSString *kContextMachine = @"kContextMachine"; @property NSString *mameAVIPath; @property NSString *mameWAVPath; @property NSString *mameVGMPath; +@property NSString *mameShareDirectory; @property NSInteger mameSpeed; @@ -91,6 +92,7 @@ static NSString *kContextMachine = @"kContextMachine"; @"mameAVI", @"mameAVIPath", @"mameWAV", @"mameWAVPath", @"mameVGM", @"mameVGMPath", + @"mameShareDirectory", @"mameBGFX", @"mameBackend", @"mameEffects", ]; @@ -405,6 +407,12 @@ static NSString *ShellQuote(NSString *s) { } } + if (_mameShareDirectory && [_mameShareDirectory length]) { + [argv addObject: @"-share_directory"]; + [argv addObject: _mameShareDirectory]; + } + + [self setCommandLine: JoinArguments(argv, nil)]; [self setArgs: argv]; }