]> git.sesse.net Git - vlc/blobdiff - modules/gui/macosx/playlist.m
macosx: The menu title should be Information... not Information.
[vlc] / modules / gui / macosx / playlist.m
index 70eaaa806a77d31634967ba472890d9c0c7457ee..0f761f759b70a0a9a454a11fcf2f83f05d13d317 100644 (file)
     [o_outline_view setTarget: self];
     [o_outline_view setDelegate: self];
     [o_outline_view setDataSource: self];
+    [o_outline_view setAllowsEmptySelection: NO];
 
     vlc_object_release( p_playlist );
     [self initStrings];
     [o_mi_delete setTitle: _NS("Delete")];
     [o_mi_recursive_expand setTitle: _NS("Expand Node")];
     [o_mi_selectall setTitle: _NS("Select All")];
-    [o_mi_info setTitle: _NS("Information")];
+    [o_mi_info setTitle: _NS("Information...")];
     [o_mi_preparse setTitle: _NS("Get Stream Information")];
     [o_mi_sort_name setTitle: _NS("Sort Node by Name")];
     [o_mi_sort_author setTitle: _NS("Sort Node by Author")];
 
     pt = [o_outline_view convertPoint: [o_event locationInWindow]
                                                  fromView: nil];
-    b_item_sel = ( [o_outline_view rowAtPoint: pt] != -1 &&
-                   [o_outline_view selectedRow] != -1 );
+    NSInteger row = [o_outline_view rowAtPoint:pt];
+    if( row != -1 )
+        [o_outline_view selectRowIndexes:[NSIndexSet indexSetWithIndex:row] byExtendingSelection:NO];
+
+    b_item_sel = ( row != -1 && [o_outline_view selectedRow] != -1 );
     b_rows = [o_outline_view numberOfRows] != 0;
 
     [o_mi_play setEnabled: b_item_sel];