Add basic album list
This commit is contained in:
@@ -6,6 +6,7 @@ import { Header } from "header.slint";
|
||||
import { Footer, FooterButton } from "footer.slint";
|
||||
|
||||
import { Global } from "global.slint";
|
||||
import { Albums } from "albums.slint";
|
||||
export { Global }
|
||||
|
||||
enum View {
|
||||
@@ -32,6 +33,7 @@ export component AppWindow inherits Window {
|
||||
|
||||
if !Global.logged-in: LoginView {}
|
||||
if Global.logged-in && view == View.Timeline: Timeline {}
|
||||
if Global.logged-in && view == View.Albums: Albums {}
|
||||
|
||||
Footer {
|
||||
FooterButton {
|
||||
@@ -46,7 +48,10 @@ export component AppWindow inherits Window {
|
||||
FooterButton {
|
||||
title: "Album";
|
||||
icon: @image-url("../assets/album.svg");
|
||||
clicked => { view = View.Albums}
|
||||
clicked => {
|
||||
view = View.Albums;
|
||||
Global.load-albums();
|
||||
}
|
||||
}
|
||||
FooterButton {
|
||||
title: "Library";
|
||||
|
||||
Reference in New Issue
Block a user