Skip to content

Commit f70f7f7

Browse files
committed
feat: link xdgactivation-client library instead of source inclusion
- Remove direct source file inclusion from tray-wayland-integration - Link against xdgactivation-client shared library - Other plugins can now also use xdgactivationclient
1 parent 4b054f7 commit f70f7f7

1 file changed

Lines changed: 2 additions & 10 deletions

File tree

plugins/application-tray/CMakeLists.txt

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,6 @@ set(TRAY_SOURCES
3333
c_ptr.h
3434
traymanager1.cpp traymanager1.h
3535
fdoselectionmanager.cpp fdoselectionmanager.h
36-
37-
${CMAKE_SOURCE_DIR}/src/tray-wayland-integration/xdgactivationclient.h
38-
${CMAKE_SOURCE_DIR}/src/tray-wayland-integration/xdgactivationclient.cpp
3936
)
4037

4138
set_source_files_properties(
@@ -72,12 +69,6 @@ add_library(${PLUGIN_NAME} SHARED
7269
application-tray.qrc
7370
)
7471

75-
qt_generate_wayland_protocol_client_sources(${PLUGIN_NAME}
76-
NO_INCLUDE_CORE_ONLY
77-
FILES
78-
${WAYLAND_PROTOCOLS_DATADIR}/staging/xdg-activation/xdg-activation-v1.xml
79-
)
80-
8172
target_compile_definitions(${PLUGIN_NAME} PRIVATE "QT_PLUGIN")
8273

8374
target_link_libraries(${PLUGIN_NAME}
@@ -99,6 +90,7 @@ target_link_libraries(${PLUGIN_NAME}
9990
PkgConfig::WaylandClient
10091
dbusmenuqt
10192
dockpluginmanager-interface
93+
xdgactivation-client
10294
)
10395

10496
target_include_directories(${PLUGIN_NAME} PUBLIC
@@ -109,4 +101,4 @@ target_include_directories(${PLUGIN_NAME} PUBLIC
109101
)
110102
set_target_properties(${PLUGIN_NAME} PROPERTIES LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/plugins/dde-dock)
111103
# 设置执行 make install 时哪个目标应该被 install 到哪个位置
112-
install(TARGETS ${PLUGIN_NAME} LIBRARY DESTINATION lib/dde-dock/plugins)
104+
install(TARGETS ${PLUGIN_NAME} LIBRARY DESTINATION lib/dde-dock/plugins)

0 commit comments

Comments
 (0)