Documentation ¶
Index ¶
- Constants
- func FetchAlbumArt(ctx context.Context, track *state.Track, size int) *gdkpixbuf.Pixbuf
- func FetchAlbumArtScaled(ctx context.Context, track *state.Track, size, scale int) *gdkpixbuf.Pixbuf
- func MaxSize(w, h, maxW, maxH int) (int, int)
- type AlbumArt
- type Container
- type ParentController
- type Playlist
- type PlaylistList
Constants ¶
View Source
const AlbumArtSize = 192
Variables ¶
This section is empty.
Functions ¶
func FetchAlbumArt ¶
FetchAlbumArt fetches the track's album art into a pixbuf with the given size.
Types ¶
type AlbumArt ¶
type AlbumArt struct { *gtk.Revealer Path string Image *gtk.Image // contains filtered or unexported fields }
func NewAlbumArt ¶
func NewAlbumArt() *AlbumArt
type Container ¶
type Container struct { gtk.Box ListScroll *gtk.ScrolledWindow PlaylistList *PlaylistList AlbumArt *AlbumArt }
func NewContainer ¶
func NewContainer(parent ParentController) *Container
type ParentController ¶
type ParentController interface {
SelectPlaylist(name string)
}
type Playlist ¶
type Playlist struct { *gtk.ListBoxRow Name string Total int // contains filtered or unexported fields }
func NewPlaylist ¶
func (*Playlist) SetUnsaved ¶
type PlaylistList ¶
type PlaylistList struct { gtk.ListBox Playlists []*Playlist // contains filtered or unexported fields }
func NewPlaylistList ¶
func NewPlaylistList(parent ParentController) *PlaylistList
func (*PlaylistList) AddPlaylist ¶
func (l *PlaylistList) AddPlaylist(pl *state.Playlist) *Playlist
func (*PlaylistList) Playlist ¶
func (l *PlaylistList) Playlist(name string) *Playlist
func (*PlaylistList) SelectFirstPlaylist ¶
func (l *PlaylistList) SelectFirstPlaylist() *Playlist
SelectFirstPlaylist selects the first playlist. It does nothing if there are no playlists.
func (*PlaylistList) SelectPlaylist ¶
func (l *PlaylistList) SelectPlaylist(pl *Playlist)
SelectPlaylist selects the given playlist.
func (*PlaylistList) SetUnsaved ¶
func (l *PlaylistList) SetUnsaved(pl *state.Playlist)
Click to show internal directories.
Click to hide internal directories.