refactor(surface): type surface actions on the message they carry
This commit is contained in:
parent
376f1b8850
commit
a8fe59f388
21 changed files with 194 additions and 181 deletions
|
|
@ -98,7 +98,7 @@ pub enum Message {
|
|||
Input2(String),
|
||||
Ignore,
|
||||
ToggleHide,
|
||||
Surface(cosmic::surface::Action),
|
||||
Surface(cosmic::surface::Action<Message>),
|
||||
Hi,
|
||||
Hi2,
|
||||
Hi3,
|
||||
|
|
@ -255,9 +255,7 @@ impl cosmic::Application for App {
|
|||
self.hidden = !self.hidden;
|
||||
}
|
||||
Message::Surface(a) => {
|
||||
return cosmic::task::message(cosmic::Action::Cosmic(
|
||||
cosmic::app::Action::Surface(a),
|
||||
));
|
||||
return cosmic::task::message(cosmic::Action::Surface(a));
|
||||
}
|
||||
Message::Hi => {
|
||||
dbg!("hi");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue