mirror of
https://github.com/AynaLivePlayer/AynaLivePlayer.git
synced 2025-12-20 00:43:23 +08:00
rewrite using IoC and DI
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
package player
|
||||
|
||||
import (
|
||||
"AynaLivePlayer/model"
|
||||
"fmt"
|
||||
"github.com/aynakeya/go-mpv"
|
||||
"testing"
|
||||
@@ -18,7 +19,7 @@ func TestPlayer(t *testing.T) {
|
||||
player.ObserveProperty("percent-pos", func(property *mpv.EventProperty) {
|
||||
fmt.Println(2, property.Data)
|
||||
})
|
||||
player.Play(&Media{
|
||||
player.Play(&model.Media{
|
||||
Url: "https://ia600809.us.archive.org/19/items/VillagePeopleYMCAOFFICIALMusicVideo1978/Village%20People%20-%20YMCA%20OFFICIAL%20Music%20Video%201978.mp4",
|
||||
})
|
||||
time.Sleep(time.Second * 15)
|
||||
|
||||
Reference in New Issue
Block a user