/*****************************************************************************
-* VLCLibVLCbridging.h: VLC.framework VLCLibVLCBridging header
+* VLCLibVLCbridging.h: VLC.framework VLCLibVLCBridging (Private) header
*****************************************************************************
* Copyright (C) 2007 Pierre d'Herbemont
* Copyright (C) 2007 the VideoLAN team
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301, USA.
*****************************************************************************/
-#include "VLCLibrary.h"
+#import "VLCLibrary.h"
// TODO: Documentation
@interface VLCMediaList (LibVLCBridging)
- (void *)libVLCMediaDescriptor;
@end
+
// TODO: Documentation
@interface VLCMedia (VLCMediaPlayerBridging)
- (void)setLength:(VLCTime *)value;
- (void *)instance;
@end
+@interface VLCMediaListAspect (VLCLibVLCBridging)
++ (id)mediaListAspectWithLibVLCMediaListView:(libvlc_media_list_view_t *)p_new_mlv;
+- (id)initWithLibVLCMediaListView:(libvlc_media_list_view_t *)p_new_mlv;
+- (libvlc_media_list_view_t *)libVLCMediaListView;
+@end
+
// TODO: Documentation
@interface VLCLibrary (VLCAudioBridging)
- (void)setAudio:(VLCAudio *)value;
#import <VLC/VLCMedia.h>
#import <VLC/VLCMediaLibrary.h>
#import <VLC/VLCMediaList.h>
+#import <VLC/VLCMediaListAspect.h>
#import <VLC/VLCTime.h>
#import <VLC/VLCVideoView.h>
@class VLCMedia;
@class VLCMediaList;
+@class VLCMediaListAspect;
// TODO: Documentation
@protocol VLCMediaListDelegate
- (VLCMedia *)mediaAtIndex:(int)index;
- (int)indexOfMedia:(VLCMedia *)media;
- (int)count;
+
+/* Media list aspect */
+- (VLCMediaListAspect *)hierarchicalAspect;
+- (VLCMediaListAspect *)flatAspect;
@end
\ No newline at end of file
return result;
}
+
+/* Media list aspect */
+- (VLCMediaListAspect *)hierarchicalAspect
+{
+ VLCMediaListAspect * hierarchicalAspect;
+ libvlc_media_list_view_t * p_mlv = libvlc_media_list_hierarchical_view( p_mlist, NULL );
+ hierarchicalAspect = [VLCMediaListAspect mediaListAspectWithLibVLCMediaListView: p_mlv];
+ libvlc_media_list_view_release( p_mlv );
+ return hierarchicalAspect;
+}
+
+- (VLCMediaListAspect *)flatAspect
+{
+ VLCMediaListAspect * flatAspect;
+ libvlc_media_list_view_t * p_mlv = libvlc_media_list_flat_view( p_mlist, NULL );
+ flatAspect = [VLCMediaListAspect mediaListAspectWithLibVLCMediaListView: p_mlv];
+ libvlc_media_list_view_release( p_mlv );
+ return flatAspect;
+}
+
@end
@implementation VLCMediaList (LibVLCBridging)
@end
@implementation VLCMediaListAspect (LibVLCBridging)
-+ (id)mediaListAspectWithLibVLCMediaListView:(void *)p_new_mlv;
++ (id)mediaListAspectWithLibVLCMediaListView:(libvlc_media_list_view_t *)p_new_mlv;
{
return [[[VLCMediaList alloc] initWithLibVLCMediaList:p_new_mlv] autorelease];
}
-- (id)initWithLibVLCMediaListView:(void *)p_new_mlv;
+- (id)initWithLibVLCMediaListView:(libvlc_media_list_view_t *)p_new_mlv;
{
if( self = [super init] )
{
return self;
}
-- (void *)libVLCMediaListView
+- (libvlc_media_list_view_t *)libVLCMediaListView
{
- return p_mlv;
+ return (libvlc_media_list_view_t *)p_mlv;
}
@end