mirror of
https://github.com/13hannes11/toolbx-tuner.git
synced 2024-09-03 23:21:00 +02:00
add closing functionality to dialgoue
This commit is contained in:
@@ -12,6 +12,7 @@ use gtk::{gio, glib};
|
||||
use crate::config::{APP_ID, PROFILE};
|
||||
use crate::modals::about::AboutDialog;
|
||||
use crate::modals::unsupported::UnsupportedDialog;
|
||||
use crate::modals::unsupported::UnsupportedDialogOutput;
|
||||
|
||||
pub(super) struct App {
|
||||
unsupported_dialog: Controller<UnsupportedDialog>,
|
||||
@@ -101,7 +102,9 @@ impl SimpleComponent for App {
|
||||
let unsupported_dialog = UnsupportedDialog::builder()
|
||||
.transient_for(root)
|
||||
.launch(())
|
||||
.detach();
|
||||
.forward(sender.input_sender(), |msg| match msg {
|
||||
UnsupportedDialogOutput::CloseApplication => AppMsg::Quit,
|
||||
});
|
||||
|
||||
let model = Self {
|
||||
about_dialog,
|
||||
|
||||
Reference in New Issue
Block a user