mirror of
https://invent.kde.org/plasma/plasma-desktop.git
synced 2026-11-03 22:59:45 -09:00
Authorization for set-time implies set-ntp and set-timezone, if acquired first then the user will only see one polkit dialog. However ntp needs to be disabled first before the time can be changed. Unfortunately due to deficiencies inside KAuth with the Polkit backend it's not possible to authorize an arbitrary action, so Polkit-qt is used for this. The code "executes" still a KAuth action to make use of the side channel for parent window and activation token to our agent, but since the action doesn't have a helper will actually not execute anything.
31 lines
828 B
CMake
31 lines
828 B
CMake
# KI18N Translation Domain for this library
|
|
add_definitions(-DTRANSLATION_DOMAIN=\"kcmkclock\")
|
|
########### next target ###############
|
|
|
|
set(kcm_clock_PART_SRCS dtime.cpp main.cpp)
|
|
|
|
ki18n_wrap_ui(kcm_clock_PART_SRCS dateandtime.ui)
|
|
|
|
qt_add_dbus_interface(kcm_clock_PART_SRCS ${CMAKE_CURRENT_SOURCE_DIR}/timedated1.xml timedated_interface)
|
|
|
|
add_library(kcm_clock MODULE ${kcm_clock_PART_SRCS})
|
|
kcmutils_generate_desktop_file(kcm_clock)
|
|
|
|
add_subdirectory( ui )
|
|
|
|
target_link_libraries(kcm_clock
|
|
Qt::DBus
|
|
Qt::Quick
|
|
Qt::QuickWidgets
|
|
KF6::ItemViews
|
|
KF6::GuiAddons
|
|
KF6::KCMUtils
|
|
KF6::I18n
|
|
KF6::I18nLocaleData
|
|
KF6::KIOCore
|
|
KF6::KIOWidgets
|
|
KF6::Svg
|
|
KF6::AuthCore
|
|
PolkitQt6-1::Core
|
|
)
|
|
install(TARGETS kcm_clock DESTINATION ${KDE_INSTALL_PLUGINDIR}/plasma/kcms/systemsettings_qwidgets )
|