diff options
| author | SND\MaddTheSane_cp <SND\MaddTheSane_cp@e17a0e51-4ae3-4d35-97c3-1a29b211df97> | 2011-12-03 01:32:30 +0000 |
|---|---|---|
| committer | SND\MaddTheSane_cp <SND\MaddTheSane_cp@e17a0e51-4ae3-4d35-97c3-1a29b211df97> | 2011-12-03 01:32:30 +0000 |
| commit | 4273fdfc90a1e1eedb1a425925a589b8e231ed64 (patch) | |
| tree | f3796c10d60f22e7f141cb36f30b24fcf7de999b /macosx/ConfigurationController.m | |
| parent | e46e672bf9d13a5aefeed9520cc68fec1bff583e (diff) | |
| download | pcsxr-4273fdfc90a1e1eedb1a425925a589b8e231ed64.tar.gz | |
Link Enable NetPlay button to the proper action.
Open dialogs now have a set file types that they can open (Set by UTIs, with a new imported UTI for disc images).
Retaining openDlg, then releasing when done, as per the suggestion of Apple's documentation.
git-svn-id: https://pcsxr.svn.codeplex.com/svn/pcsxr@72823 e17a0e51-4ae3-4d35-97c3-1a29b211df97
Diffstat (limited to 'macosx/ConfigurationController.m')
| -rw-r--r-- | macosx/ConfigurationController.m | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/macosx/ConfigurationController.m b/macosx/ConfigurationController.m index 288f56e3..0faccc89 100644 --- a/macosx/ConfigurationController.m +++ b/macosx/ConfigurationController.m @@ -40,6 +40,7 @@ char *mcd; NSTextField *label; NSOpenPanel *openDlg = [NSOpenPanel openPanel]; + [openDlg retain]; NSString *path; if (tag == 1) { mcd = Config.Mcd1; label = mcd1Label; } @@ -47,6 +48,7 @@ [openDlg setCanChooseFiles:YES]; [openDlg setCanChooseDirectories:NO]; + [openDlg setAllowedFileTypes:[NSArray arrayWithObject:@"com.codeplex.pcsxr.memcard"]]; path = [[NSFileManager defaultManager] stringWithFileSystemRepresentation:mcd length:strlen(mcd)]; @@ -65,6 +67,7 @@ else [[NSUserDefaults standardUserDefaults] setObject:mcdPath forKey:@"Mcd2"]; } + [openDlg release]; } - (IBAction)mcdNewClicked:(id)sender @@ -73,6 +76,7 @@ char *mcd; NSTextField *label; NSSavePanel *openDlg = [NSSavePanel savePanel]; + [openDlg retain]; NSString *path; if (tag == 1) { mcd = Config.Mcd1; label = mcd1Label; } @@ -82,6 +86,7 @@ [openDlg setDirectoryURL:[NSURL fileURLWithPath:[path stringByDeletingLastPathComponent]]]; [openDlg setNameFieldStringValue:@"New Memory Card File.mcr"]; + [openDlg setAllowedFileTypes:[NSArray arrayWithObject:@"com.codeplex.pcsxr.memcard"]]; if ([openDlg runModal] == NSFileHandlingPanelOKButton) { NSString *mcdPath = [[openDlg URL] path]; @@ -96,6 +101,7 @@ CreateMcd(mcd); } + [openDlg release]; } - (IBAction)setVideoType:(id)sender |
