Commit 31f4c4db authored by David Fuhrmann's avatar David Fuhrmann

macosx: fix bug in disk open panel regarding selected folders

Previously, the open panel always converted the mrl to an (not available)
mount point when you want to setup a playback without menus
(cherry picked from commit f8d14c628d05db37c286cc48ad44a2555dd53639)
Signed-off-by: default avatarDavid Fuhrmann <david.fuhrmann@googlemail.com>
parent bdd4d52f
...@@ -910,9 +910,18 @@ static VLCOpen *_o_sharedMainInstance = nil; ...@@ -910,9 +910,18 @@ static VLCOpen *_o_sharedMainInstance = nil;
- (IBAction)dvdreadOptionChanged:(id)sender - (IBAction)dvdreadOptionChanged:(id)sender
{ {
NSString *o_device_path = [o_opticalDevices objectAtIndex: [o_disc_selector_pop indexOfSelectedItem]];
char *diskType = [self getVolumeTypeFromMountPath:o_device_path];
NSString *pathToOpen;
if (diskType == kVLCMediaVideoTSFolder)
pathToOpen = o_device_path;
else
pathToOpen = [self getBSDNodeFromMountPath: o_device_path];
if (sender == o_disc_dvdwomenus_enablemenus_btn) { if (sender == o_disc_dvdwomenus_enablemenus_btn) {
b_nodvdmenus = NO; b_nodvdmenus = NO;
[self setMRL: [NSString stringWithFormat: @"dvdnav://%@", [self getBSDNodeFromMountPath:[o_opticalDevices objectAtIndex: [o_disc_selector_pop indexOfSelectedItem]]]]]; [self setMRL: [NSString stringWithFormat: @"dvdnav://%@", pathToOpen]];
[self showOpticalMediaView: o_disc_dvd_view withIcon: [o_currentOpticalMediaIconView image]]; [self showOpticalMediaView: o_disc_dvd_view withIcon: [o_currentOpticalMediaIconView image]];
return; return;
} }
...@@ -930,7 +939,7 @@ static VLCOpen *_o_sharedMainInstance = nil; ...@@ -930,7 +939,7 @@ static VLCOpen *_o_sharedMainInstance = nil;
if (sender == o_disc_dvdwomenus_chapter_stp) if (sender == o_disc_dvdwomenus_chapter_stp)
[o_disc_dvdwomenus_chapter setIntValue: [o_disc_dvdwomenus_chapter_stp intValue]]; [o_disc_dvdwomenus_chapter setIntValue: [o_disc_dvdwomenus_chapter_stp intValue]];
[self setMRL: [NSString stringWithFormat: @"dvdread://%@#%i:%i-", [self getBSDNodeFromMountPath:[o_opticalDevices objectAtIndex: [o_disc_selector_pop indexOfSelectedItem]]], [o_disc_dvdwomenus_title intValue], [o_disc_dvdwomenus_chapter intValue]]]; [self setMRL: [NSString stringWithFormat: @"dvdread://%@#%i:%i-", pathToOpen, [o_disc_dvdwomenus_title intValue], [o_disc_dvdwomenus_chapter intValue]]];
} }
- (IBAction)vcdOptionChanged:(id)sender - (IBAction)vcdOptionChanged:(id)sender
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment