mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-08-12 06:06:17 +02:00
parent
07ac64bf09
commit
dccfdb4a11
@ -473,7 +473,10 @@ end;
|
|||||||
|
|
||||||
function TCustomVLCMediaListPlayer.GetPlaying: Boolean;
|
function TCustomVLCMediaListPlayer.GetPlaying: Boolean;
|
||||||
begin
|
begin
|
||||||
Result:=libvlc_media_list_player_is_playing(Instance)<>0;
|
if Assigned(FPlayer) then
|
||||||
|
Result:=libvlc_media_list_player_is_playing(Instance)<>0
|
||||||
|
else
|
||||||
|
Result:=false;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TCustomVLCMediaListPlayer.GetInstance: plibvlc_media_list_player_t;
|
function TCustomVLCMediaListPlayer.GetInstance: plibvlc_media_list_player_t;
|
||||||
@ -495,7 +498,10 @@ end;
|
|||||||
|
|
||||||
function TCustomVLCMediaListPlayer.GetState: libvlc_state_t;
|
function TCustomVLCMediaListPlayer.GetState: libvlc_state_t;
|
||||||
begin
|
begin
|
||||||
Result:=libvlc_media_list_player_get_state(Instance)
|
if Assigned(FInstance) then
|
||||||
|
Result:=libvlc_media_list_player_get_state(Instance)
|
||||||
|
else
|
||||||
|
Result:=libvlc_NothingSpecial;
|
||||||
end;
|
end;
|
||||||
|
|
||||||
function TCustomVLCMediaListPlayer.GetVLC: TVLCLibrary;
|
function TCustomVLCMediaListPlayer.GetVLC: TVLCLibrary;
|
||||||
@ -527,6 +533,7 @@ begin
|
|||||||
end;
|
end;
|
||||||
|
|
||||||
procedure TCustomVLCMediaListPlayer.SetPlayMode(AValue: TVLCPlayMode);
|
procedure TCustomVLCMediaListPlayer.SetPlayMode(AValue: TVLCPlayMode);
|
||||||
|
|
||||||
Const
|
Const
|
||||||
M : Array [TVLCPlayMode] of libvlc_playback_mode_t
|
M : Array [TVLCPlayMode] of libvlc_playback_mode_t
|
||||||
= (libvlc_playback_mode_default,
|
= (libvlc_playback_mode_default,
|
||||||
@ -534,6 +541,7 @@ Const
|
|||||||
libvlc_playback_mode_repeat);
|
libvlc_playback_mode_repeat);
|
||||||
|
|
||||||
begin
|
begin
|
||||||
|
if not Assigned(Finstance) then Exit;
|
||||||
if FPlayMode=AValue then Exit;
|
if FPlayMode=AValue then Exit;
|
||||||
FPlayMode:=AValue;
|
FPlayMode:=AValue;
|
||||||
libvlc_media_list_player_set_playback_mode(FInstance, M[AValue]);
|
libvlc_media_list_player_set_playback_mode(FInstance, M[AValue]);
|
||||||
|
Loading…
Reference in New Issue
Block a user