Add a menu bar option to the desktop config (#2107)

* add an option to set a custom menu in the desktop config

* Fix rename issue

---------

Co-authored-by: Jonathan Kelley <jkelleyrtp@gmail.com>
This commit is contained in:
Evan AlmloffandJonathan Kelley authored and GitHub committed 2024-03-18 22:36:47 -07:00
1 parent 10d361a44e
commit d442dac168
11 files changed
+152 -95

No files matched your search

+2 -2
View File
@@ -8,12 +8,12 @@
use dioxus::desktop::tao::event::Event as WryEvent;
use dioxus::desktop::tao::event::WindowEvent;
use dioxus::desktop::use_wry_event_handler;
use dioxus::desktop::{Config, WindowCloseBehaviour};
use dioxus::desktop::{Config, WindowCloseBehavior};
use dioxus::prelude::*;
fn main() {
LaunchBuilder::desktop()
.with_cfg(Config::new().with_close_behaviour(WindowCloseBehaviour::CloseWindow))
.with_cfg(Config::new().with_close_behaviour(WindowCloseBehavior::CloseWindow))
.launch(app)
}