[vlc-commits] macosx: select the right playlist item when a new file in playlist begins to play

David Fuhrmann git at videolan.org
Sat Jan 21 22:21:01 CET 2012


vlc/vlc-1.2 | branch: master | David Fuhrmann <david.fuhrmann at googlemail.com> | Fri Jan 20 12:58:26 2012 +0100| [f49f5d38f1eb56e4e83f67afe7bcd9b0f017b8b9] | committer: Jean-Baptiste Kempf

macosx: select the right playlist item when a new file in playlist begins to play

should fix #4812 for vlc 2

Signed-off-by: Felix Paul Kühne <fkuehne at videolan.org>
(cherry picked from commit 9ae001675da6a878b4bdbe3fc4c693bd9a802013)

Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>

> http://git.videolan.org/gitweb.cgi/vlc/vlc-1.2.git/?a=commit;h=f49f5d38f1eb56e4e83f67afe7bcd9b0f017b8b9
---

 modules/gui/macosx/playlist.m |    4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diff --git a/modules/gui/macosx/playlist.m b/modules/gui/macosx/playlist.m
index ea7a97b..d322ae0 100644
--- a/modules/gui/macosx/playlist.m
+++ b/modules/gui/macosx/playlist.m
@@ -597,6 +597,10 @@
             [o_outline_view expandItem: o_item];
         }
     }
+
+    id o_item = [o_outline_dict objectForKey:[NSString stringWithFormat: @"%p", p_item]];
+    NSInteger i_index = [o_outline_view rowForItem:o_item];
+    [o_outline_view selectRowIndexes:[NSIndexSet indexSetWithIndex:i_index] byExtendingSelection:NO];
 }
 
 /* Check if p_item is a child of p_node recursively. We need to check the item



More information about the vlc-commits mailing list