Changeset 9c4f520e6526f194e27b9d293132a492de05dde8

Show
Ignore:
Timestamp:
10/21/07 17:42:29 (11 months ago)
Author:
Rémi Denis-Courmont <rem@videolan.org>
git-committer:
Rémi Denis-Courmont <rem@videolan.org> 1192981349 +0000
git-parent:

[734f58f588595ee512f37ce0b29aa2ed5633a597]

git-author:
Rémi Denis-Courmont <rem@videolan.org> 1192981349 +0000
Message:

"Advanced" playlist add

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • bindings/cil/Makefile

    r77aa5b9 r9c4f520  
    22CSFLAGS = 
    33 
    4 TARGETS = VideoLAN.VLC.Control.dll testvlc.exe 
     4TARGETS = VideoLAN.LibVLC.dll testvlc.exe 
    55 
    66all: $(TARGETS) 
    77 
    88clean: 
    9     rm -f -- $(TARGETS) *.netmodule *~ 
     9    rm -f -- *.netmodule *.dll *.exe *~ 
    1010 
    11 VideoLAN.VLC.Control.dll: marshal.cs ustring.cs exception.cs libvlc.cs 
    12 testvlc.exe: testvlc.cs VideoLAN.VLC.Control.dll 
     11VideoLAN.LibVLC.dll: marshal.cs ustring.cs exception.cs libvlc.cs 
     12testvlc.exe: testvlc.cs VideoLAN.LibVLC.dll 
    1313 
    1414%.netmodule: %.cs Makefile 
  • bindings/cil/libvlc.cs

    r54f91fa r9c4f520  
    8585 
    8686        [DllImport ("libvlc-control.dll", EntryPoint="libvlc_playlist_loop")] 
    87         static extern void PlaylistLoop (InstanceHandle self, int b, 
     87        static extern void PlaylistLoop (InstanceHandle self, bool b, 
    8888                                         NativeException ex); 
    8989        /** Sets the playlist loop flag */ 
     
    9292            set 
    9393            { 
    94                 PlaylistLoop (self, value ? 1 : 0, ex); 
     94                PlaylistLoop (self, value, ex); 
    9595                ex.Raise (); 
    9696            } 
     
    172172        } 
    173173 
    174         [DllImport ("libvlc-control.dll", EntryPoint="libvlc_playlist_add")] 
     174        [DllImport ("libvlc-control.dll", 
     175                    EntryPoint="libvlc_playlist_add_extended")] 
    175176        static extern void PlaylistAdd (InstanceHandle self, U8String uri, 
    176                                         U8String name, NativeException e); 
    177         /** Appends an item to the playlist */ 
    178         public void Add (string mrl) 
    179         { 
    180             Add (mrl, null); 
    181         } 
    182         /** Appends an item to the playlist */ 
    183         public void Add (string mrl, string name) 
     177                                        U8String name, int optc, 
     178                                        U8String[] optv, NativeException e); 
     179        /** Appends an item to the playlist with options */ 
     180        public void Add (string mrl, string name, string[] opts) 
    184181        { 
    185182            U8String umrl = new U8String (mrl); 
    186183            U8String uname = new U8String (name); 
    187  
    188             PlaylistAdd (self, umrl, uname, ex); 
    189             ex.Raise (); 
     184            U8String[] optv = new U8String[opts.Length]; 
     185            for (int i = 0; i < opts.Length; i++) 
     186                optv[i] = new U8String (opts[i]); 
     187 
     188            PlaylistAdd (self, umrl, uname, optv.Length, optv, ex); 
     189            ex.Raise (); 
     190        } 
     191        public void Add (string mrl, string[] opts) 
     192        { 
     193            Add (mrl, null, opts); 
     194        } 
     195        public void Add (string mrl, string name) 
     196        { 
     197            Add (mrl, name, new string[0]); 
     198        } 
     199        public void Add (string mrl) 
     200        { 
     201            Add (mrl, null, new string[0]); 
    190202        } 
    191203    };