Move menubar to app_menu, fix #7
This commit is contained in:
parent
7db6e0f07f
commit
d9b7b1a1cc
@ -150,16 +150,12 @@ impl Ui {
|
|||||||
|
|
||||||
fn create_main_menu(&self, app: >k::Application) {
|
fn create_main_menu(&self, app: >k::Application) {
|
||||||
let menu = Menu::new();
|
let menu = Menu::new();
|
||||||
let help = Menu::new();
|
|
||||||
|
|
||||||
let about = MenuItem::new("About", None);
|
let about = MenuItem::new("About", None);
|
||||||
about.set_detailed_action("app.HelpAbout");
|
about.set_detailed_action("app.HelpAbout");
|
||||||
help.append_item(&about);
|
menu.append_item(&about);
|
||||||
|
|
||||||
|
app.set_app_menu(Some(&menu));
|
||||||
menu.append_item(&MenuItem::new_submenu("Help", &help));
|
|
||||||
|
|
||||||
app.set_menubar(Some(&menu));
|
|
||||||
|
|
||||||
|
|
||||||
let about_action = SimpleAction::new("HelpAbout", None);
|
let about_action = SimpleAction::new("HelpAbout", None);
|
||||||
|
Loading…
Reference in New Issue
Block a user