Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fancy Menu: New main menu similar to XFCE Whiskermenu #1975

Merged
merged 1 commit into from
Jan 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,14 @@ if(DESKTOPSWITCH_PLUGIN)
add_subdirectory(plugin-desktopswitch)
endif()

setByDefault(FANCYMENU_PLUGIN Yes)
if(FANCYMENU_PLUGIN)
list(APPEND STATIC_PLUGINS "fancymenu")
add_definitions(-DWITH_FANCYMENU_PLUGIN)
list(APPEND ENABLED_PLUGINS "Application fancy menu")
add_subdirectory(plugin-fancymenu)
endif()

setByDefault(KBINDICATOR_PLUGIN Yes)
if(KBINDICATOR_PLUGIN)
list(APPEND ENABLED_PLUGINS "Keyboard Indicator")
Expand Down
7 changes: 7 additions & 0 deletions panel/plugin.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,10 @@
#include "../plugin-desktopswitch/desktopswitch.h" // desktopswitch
extern void * loadPluginTranslation_desktopswitch_helper;
#endif
#if defined(WITH_FANCYMENU_PLUGIN)
#include "../plugin-fancymenu/lxqtfancymenu.h" // fancymenu
extern void * loadPluginTranslation_fancymenu_helper;
#endif
#if defined(WITH_MAINMENU_PLUGIN)
#include "../plugin-mainmenu/lxqtmainmenu.h" // mainmenu
extern void * loadPluginTranslation_mainmenu_helper;
Expand Down Expand Up @@ -218,6 +222,9 @@ namespace
#if defined(WITH_DESKTOPSWITCH_PLUGIN)
std::make_tuple(QLatin1String("desktopswitch"), plugin_ptr_t{new DesktopSwitchPluginLibrary}, loadPluginTranslation_desktopswitch_helper),// desktopswitch
#endif
#if defined(WITH_FANCYMENU_PLUGIN)
std::make_tuple(QLatin1String("fancymenu"), plugin_ptr_t{new LXQtFancyMenuPluginLibrary}, loadPluginTranslation_fancymenu_helper),// fancymenu
#endif
#if defined(WITH_MAINMENU_PLUGIN)
std::make_tuple(QLatin1String("mainmenu"), plugin_ptr_t{new LXQtMainMenuPluginLibrary}, loadPluginTranslation_mainmenu_helper),// mainmenu
#endif
Expand Down
52 changes: 52 additions & 0 deletions plugin-fancymenu/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
set(PLUGIN "fancymenu")

set(HEADERS
lxqtfancymenu.h
lxqtfancymenuconfiguration.h
lxqtfancymenuwindow.h
lxqtfancymenuappmap.h
lxqtfancymenuappmodel.h
lxqtfancymenucategoriesmodel.h
lxqtfancymenutypes.h
)

set(SOURCES
lxqtfancymenu.cpp
lxqtfancymenuconfiguration.cpp
lxqtfancymenuwindow.cpp
lxqtfancymenuappmap.cpp
lxqtfancymenuappmodel.cpp
lxqtfancymenucategoriesmodel.cpp
)

set(UIS
lxqtfancymenuconfiguration.ui
)


# optionally use libmenu-cache to generate the application menu
if(USE_MENU_CACHE)
find_package(MenuCache "0.3.3")
endif()

set(LIBRARIES
lxqt
lxqt-globalkeys
lxqt-globalkeys-ui
)

if(MENUCACHE_FOUND)
list(APPEND SOURCES xdgcachedmenu.cpp)
list(APPEND MOCS xdgcachedmenu.h)

include_directories(${MENUCACHE_INCLUDE_DIRS})
list(APPEND LIBRARIES ${MENUCACHE_LIBRARIES})
add_definitions(-DHAVE_MENU_CACHE=1)

endif()


set(QT_USE_QTXML 1)
set(QT_USE_QTDBUS 1)

BUILD_LXQT_PLUGIN(${PLUGIN})
Loading
Loading