]> git.sesse.net Git - vlc/blobdiff - projects/activex/plugin.h
Release the display mode when we are done with it.
[vlc] / projects / activex / plugin.h
index 8541262d8e778049cbc79742f20dacc4b0c17aff..7db813ac19301572755d4003bad64248b0f58d0b 100644 (file)
@@ -239,21 +239,21 @@ public:
     void fireOnStopEvent(void);
 
     // async events;
-    void fireOnIdleEvent();
-    void fireOnOpeningEvent();
-    void fireOnBufferingEvent();
-    void fireOnPlayingEvent();
-    void fireOnPausedEvent();
-    void fireOnErrorEvent();
-    void fireOnEndedEvent();
-    void fireOnStoppedEvent();
-    void fireOnForwardEvent();
-    void fireOnBackwardEvent();
-
-    void fireOnTimeChangedEvent(long time);
-    void fireOnPositionChangedEvent(long position);
-    void fireOnSeekableChangedEvent(VARIANT_BOOL seekable);
-    void fireOnPausableChangedEvent(VARIANT_BOOL pausable);
+    void fireOnMediaPlayerNothingSpecialEvent();
+    void fireOnMediaPlayerOpeningEvent();
+    void fireOnMediaPlayerBufferingEvent(long cache);
+    void fireOnMediaPlayerPlayingEvent();
+    void fireOnMediaPlayerPausedEvent();
+    void fireOnMediaPlayerForwardEvent();
+    void fireOnMediaPlayerBackwardEvent();
+    void fireOnMediaPlayerEncounteredErrorEvent();
+    void fireOnMediaPlayerEndReachedEvent();
+    void fireOnMediaPlayerStoppedEvent();
+
+    void fireOnMediaPlayerTimeChangedEvent(long time);
+    void fireOnMediaPlayerPositionChangedEvent(long position);
+    void fireOnMediaPlayerSeekableChangedEvent(VARIANT_BOOL seekable);
+    void fireOnMediaPlayerPausableChangedEvent(VARIANT_BOOL pausable);
 
     // controlling IUnknown interface
     LPUNKNOWN pUnkOuter;
@@ -270,7 +270,11 @@ public:
     void playlist_delete_item(int idx)
     {
         if( _p_mlist )
+        {
+            libvlc_media_list_lock(_p_mlist);
             libvlc_media_list_remove_index(_p_mlist,idx);
+            libvlc_media_list_unlock(_p_mlist);
+        }
     }
     void playlist_clear()
     {
@@ -297,15 +301,11 @@ public:
     }
     void playlist_play()
     {
-        if( !_p_libvlc )
-            initVLC();
         if( _p_mplayer || playlist_select(0) )
             libvlc_media_player_play(_p_mplayer);
     }
     void playlist_play_item(int idx)
     {
-        if( !_p_libvlc )
-            initVLC();
         if( playlist_select(idx) )
             libvlc_media_player_play(_p_mplayer);
     }