diff options
Diffstat (limited to 'Userland/Applications/FontEditor')
-rw-r--r-- | Userland/Applications/FontEditor/FontEditor.cpp | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/Userland/Applications/FontEditor/FontEditor.cpp b/Userland/Applications/FontEditor/FontEditor.cpp index d263299d3e..1480be6841 100644 --- a/Userland/Applications/FontEditor/FontEditor.cpp +++ b/Userland/Applications/FontEditor/FontEditor.cpp @@ -421,17 +421,6 @@ FontEditorWidget::FontEditorWidget() }; m_glyph_map_widget->on_context_menu_request = [this](auto& event) { - if (!m_context_menu) { - m_context_menu = GUI::Menu::construct(); - m_context_menu->add_action(*m_cut_action); - m_context_menu->add_action(*m_copy_action); - m_context_menu->add_action(*m_paste_action); - m_context_menu->add_action(*m_delete_action); - m_context_menu->add_separator(); - m_context_menu->add_action(*m_select_all_action); - m_context_menu->add_separator(); - m_context_menu->add_action(*m_copy_text_action); - } m_context_menu->popup(event.screen_position()); }; @@ -649,6 +638,8 @@ ErrorOr<void> FontEditorWidget::initialize_menubar(GUI::Window& window) TRY(edit_menu->try_add_separator()); TRY(edit_menu->try_add_action(*m_copy_text_action)); + m_context_menu = edit_menu; + auto go_menu = TRY(window.try_add_menu("&Go")); TRY(go_menu->try_add_action(*m_previous_glyph_action)); TRY(go_menu->try_add_action(*m_next_glyph_action)); |