summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSND\MaddTheSane_cp <SND\MaddTheSane_cp@e17a0e51-4ae3-4d35-97c3-1a29b211df97>2013-06-26 01:05:20 +0000
committerSND\MaddTheSane_cp <SND\MaddTheSane_cp@e17a0e51-4ae3-4d35-97c3-1a29b211df97>2013-06-26 01:05:20 +0000
commit21b5b2706fdd83fc225d340a0e347d7d0d0c000c (patch)
treee4428a5e49d685082ece3811efaed547cee2550f
parent6349404da5984e6785574c96db3eb3a08a515b37 (diff)
downloadpcsxr-21b5b2706fdd83fc225d340a0e347d7d0d0c000c.tar.gz
Don't open plug-ins or memory cards if the emulator is running.
git-svn-id: https://pcsxr.svn.codeplex.com/svn/pcsxr@85559 e17a0e51-4ae3-4d35-97c3-1a29b211df97
-rwxr-xr-xmacosx/ConfigurationController.m1
-rwxr-xr-xmacosx/PcsxrMemCardHandler.m6
-rwxr-xr-xmacosx/PcsxrPluginHandler.m5
3 files changed, 10 insertions, 2 deletions
diff --git a/macosx/ConfigurationController.m b/macosx/ConfigurationController.m
index 270abc97..8f6a296d 100755
--- a/macosx/ConfigurationController.m
+++ b/macosx/ConfigurationController.m
@@ -127,7 +127,6 @@ NSString *const memCardChangeNumberKey = @"PcsxrMemoryCardThatChangedKey";
RELEASEOBJ(openDlg);
}
-
- (IBAction)setVideoType:(id)sender
{
int tag = [[sender selectedItem] tag];
diff --git a/macosx/PcsxrMemCardHandler.m b/macosx/PcsxrMemCardHandler.m
index 21a96869..32f6b0dd 100755
--- a/macosx/PcsxrMemCardHandler.m
+++ b/macosx/PcsxrMemCardHandler.m
@@ -8,6 +8,7 @@
#import "PcsxrMemCardHandler.h"
#import "ConfigurationController.h"
+#import "EmuThread.h"
#import "ARCBridge.h"
@implementation PcsxrMemCardHandler
@@ -54,10 +55,13 @@
- (BOOL)handleFile:(NSString *)theFile
{
+ if ([EmuThread active]) {
+ return NO;
+ }
if (![self window]) {
[NSBundle loadNibNamed:@"PcsxrMemCardDocument" owner:self];
}
- [cardPath setObjectValue:[theFile lastPathComponent]];
+ [cardPath setObjectValue:[[NSFileManager defaultManager] displayNameAtPath:theFile]];
[NSApp runModalForWindow:[self window]];
diff --git a/macosx/PcsxrPluginHandler.m b/macosx/PcsxrPluginHandler.m
index 7fde32c9..07ecd3b2 100755
--- a/macosx/PcsxrPluginHandler.m
+++ b/macosx/PcsxrPluginHandler.m
@@ -7,6 +7,7 @@
//
#import "PcsxrPluginHandler.h"
+#import "EmuThread.h"
#import "ARCBridge.h"
@implementation PcsxrPluginHandler
@@ -55,6 +56,10 @@
- (BOOL)handleFile:(NSString *)theFile
{
+ if ([EmuThread active]) {
+ return NO;
+ }
+
if (![self window])
[NSBundle loadNibNamed:@"AddPluginSheet" owner:self];