forked from mbk-lab/rui_orig
36 lines
715 B
Go
36 lines
715 B
Go
package rui
|
|
|
|
type AudioPlayer interface {
|
|
MediaPlayer
|
|
}
|
|
|
|
type audioPlayerData struct {
|
|
mediaPlayerData
|
|
}
|
|
|
|
// NewAudioPlayer create new MediaPlayer object and return it
|
|
func NewAudioPlayer(session Session, params Params) AudioPlayer {
|
|
view := new(audioPlayerData)
|
|
view.init(session)
|
|
view.tag = "AudioPlayer"
|
|
setInitParams(view, params)
|
|
return view
|
|
}
|
|
|
|
func newAudioPlayer(session Session) View {
|
|
return NewAudioPlayer(session, nil)
|
|
}
|
|
|
|
func (player *audioPlayerData) init(session Session) {
|
|
player.mediaPlayerData.init(session)
|
|
player.tag = "AudioPlayer"
|
|
}
|
|
|
|
func (player *audioPlayerData) String() string {
|
|
return getViewString(player)
|
|
}
|
|
|
|
func (player *audioPlayerData) htmlTag() string {
|
|
return "audio"
|
|
}
|