adding the editor file
This commit is contained in:
parent
16cd19d33a
commit
2854aa536d
27
src/ui/editor.rs
Normal file
27
src/ui/editor.rs
Normal file
|
@ -0,0 +1,27 @@
|
||||||
|
use cosmic::{Element, Task};
|
||||||
|
|
||||||
|
use crate::core::songs::Song;
|
||||||
|
|
||||||
|
#[derive(Debug, Clone)]
|
||||||
|
pub struct SongEditor {
|
||||||
|
song: Song,
|
||||||
|
}
|
||||||
|
|
||||||
|
#[derive(Debug, Clone)]
|
||||||
|
pub enum Message {
|
||||||
|
ChangeSong(Song),
|
||||||
|
UpdateSong(Song),
|
||||||
|
}
|
||||||
|
|
||||||
|
impl SongEditor {
|
||||||
|
pub fn update(&self, message: Message) -> Task<Message> {
|
||||||
|
match message {
|
||||||
|
Message::ChangeSong(song) => todo!(),
|
||||||
|
Message::UpdateSong(song) => todo!(),
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
pub fn view(&self) -> Element<Message> {
|
||||||
|
todo!()
|
||||||
|
}
|
||||||
|
}
|
Loading…
Reference in a new issue