kwin/kcmkwin/kwinrules/CMakeLists.txt
Martin Gräßlin 2a8ab547e1 Move X11Cursor into the x11standalone platform plugin
At the same time the xinput2 integration is split out of X11Cursor
and made a standalone part of the platform plugin. XInput integration
is nowadays not only used by the cursor position polling, but also
for modifier only shortcuts.

By splitting it out the modifier shortcuts start to work also when
one doesn't have anything requesting a mouse position polling.

This also simplifies the conditional builds: xinput integration is
only included if we have support for it at compile time without having
to have many ifdefs in the cursor implementation. For the inclusion of
cursor in the kcmkwin this also removes all the ifdefs.

The key events are only requested if we have xinput 2.1. Otherwise we
would not get all raw events if the input device gets grabbed.

Reviewers: #kwin, #plasma_on_wayland

Subscribers: plasma-devel, kwin

Tags: #plasma_on_wayland, #kwin

Differential Revision: https://phabricator.kde.org/D2473
2016-08-19 10:57:09 +02:00

63 lines
1.7 KiB
CMake

# KI18N Translation Domain for this library
add_definitions(-DTRANSLATION_DOMAIN=\"kcmkwinrules\")
add_definitions(-DKCMRULES)
########### next target ###############
include_directories(../../)
set (kwinrules_MOC_HDRS yesnobox.h ../../client_machine.h ../../cursor.h ../../plugins/platforms/x11/standalone/x11cursor.h)
qt5_wrap_cpp(kwinrules_MOC_SRCS ${kwinrules_MOC_HDRS})
set(kwinrules_SRCS ruleswidget.cpp ruleslist.cpp kwinsrc.cpp detectwidget.cpp ${kwinrules_MOC_SRCS})
ki18n_wrap_ui(kwinrules_SRCS ruleslist.ui detectwidget.ui editshortcut.ui ruleswidgetbase.ui)
set(kwin_rules_dialog_KDEINIT_SRCS main.cpp ${kwinrules_SRCS})
kf5_add_kdeinit_executable( kwin_rules_dialog ${kwin_rules_dialog_KDEINIT_SRCS})
set(kwin_kcm_rules_XCB_LIBS
XCB::XCB
XCB::XFIXES
XCB::CURSOR
)
set(kcm_libs
Qt5::Concurrent
Qt5::X11Extras
KF5::Completion
KF5::ConfigWidgets
KF5::I18n
KF5::Service
KF5::WindowSystem
KF5::XmlGui
${X11_LIBRARIES}
)
if(KWIN_BUILD_ACTIVITIES)
set(kcm_libs ${kcm_libs} KF5::Activities)
endif()
target_link_libraries(kdeinit_kwin_rules_dialog ${kcm_libs} ${kwin_kcm_rules_XCB_LIBS})
install(TARGETS kdeinit_kwin_rules_dialog ${INSTALL_TARGETS_DEFAULT_ARGS} )
install(TARGETS kwin_rules_dialog DESTINATION ${LIBEXEC_INSTALL_DIR} )
########### next target ###############
set(kcm_kwinrules_PART_SRCS kcm.cpp ${kwinrules_SRCS})
add_library(kcm_kwinrules MODULE ${kcm_kwinrules_PART_SRCS})
target_link_libraries(kcm_kwinrules ${kcm_libs} ${kwin_kcm_rules_XCB_LIBS})
install(TARGETS kcm_kwinrules DESTINATION ${PLUGIN_INSTALL_DIR} )
########### next target ###############
########### install files ###############
install( FILES kwinrules.desktop DESTINATION ${SERVICES_INSTALL_DIR} )