mirror of
https://github.com/yann64/haikuports.git
synced 2026-03-19 01:46:00 +01:00
95 lines
2.8 KiB
Diff
95 lines
2.8 KiB
Diff
From 0f837224651968661ccd2518d02a77648c33d539 Mon Sep 17 00:00:00 2001
|
|
From: Sune Vuorela <sune@vuorela.dk>
|
|
Date: Fri, 15 Aug 2025 10:06:04 +0000
|
|
Subject: [PATCH] Make KConfigWidgets and KIconThemes required
|
|
|
|
BUG: 506958
|
|
|
|
|
|
(cherry picked from commit 51d483c6945f1f6c50b39c4e062cd47efce9dfe1)
|
|
|
|
Co-authored-by: Nicolas Fella <nicolas.fella@gmx.de>
|
|
---
|
|
CMakeLists.txt | 17 +++++------------
|
|
kcharselectdia.cc | 5 -----
|
|
2 files changed, 5 insertions(+), 17 deletions(-)
|
|
|
|
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
|
index e944561..c4e2502 100644
|
|
--- a/CMakeLists.txt
|
|
+++ b/CMakeLists.txt
|
|
@@ -35,6 +35,8 @@ find_package(KF6 ${KF_MIN_VERSION} REQUIRED COMPONENTS
|
|
I18n
|
|
WidgetsAddons
|
|
XmlGui
|
|
+ ConfigWidgets
|
|
+ IconThemes
|
|
)
|
|
|
|
find_package(KF6DocTools ${KF_MIN_VERSION})
|
|
@@ -42,8 +44,6 @@ set_package_properties(KF6DocTools PROPERTIES DESCRIPTION
|
|
"Tools to generate documentation"
|
|
TYPE OPTIONAL
|
|
)
|
|
-find_package(KF6ConfigWidgets ${KF_DEP_VERSION} QUIET)
|
|
-find_package(KF6IconThemes ${KF_DEP_VERSION} QUIET)
|
|
|
|
ecm_setup_version(${RELEASE_SERVICE_VERSION} VARIABLE_PREFIX KCHARSELECT VERSION_HEADER kcharselect_version.h)
|
|
|
|
@@ -77,18 +77,11 @@ target_link_libraries(kcharselect
|
|
KF6::I18n
|
|
KF6::WidgetsAddons
|
|
KF6::XmlGui
|
|
+ KF6::ConfigWidgets
|
|
+ KF6::IconThemes
|
|
+ KF6::BookmarksWidgets
|
|
)
|
|
|
|
-if(TARGET KF6::ConfigWidgets)
|
|
- target_link_libraries(kcharselect KF6::ConfigWidgets)
|
|
- target_compile_definitions(kcharselect PRIVATE WITH_CONFIGWIDGET_LIB)
|
|
-endif()
|
|
-if(TARGET KF6::IconThemes)
|
|
- target_link_libraries(kcharselect KF6::IconThemes)
|
|
-endif ()
|
|
-
|
|
-target_link_libraries(kcharselect KF6::BookmarksWidgets)
|
|
-
|
|
install(TARGETS kcharselect ${KDE_INSTALL_TARGETS_DEFAULT_ARGS})
|
|
|
|
install(FILES org.kde.kcharselect.desktop DESTINATION ${KDE_INSTALL_APPDIR})
|
|
diff --git a/kcharselectdia.cc b/kcharselectdia.cc
|
|
index 3c4dedb..8c5edf6 100644
|
|
--- a/kcharselectdia.cc
|
|
+++ b/kcharselectdia.cc
|
|
@@ -25,12 +25,9 @@
|
|
#include <KStandardAction>
|
|
#include <KStandardShortcut>
|
|
#include <KToggleAction>
|
|
-
|
|
-#ifdef WITH_CONFIGWIDGET_LIB
|
|
#include <KActionMenu>
|
|
#include <KColorSchemeManager>
|
|
#include <KColorSchemeMenu>
|
|
-#endif
|
|
|
|
class KCharSelectBookmarkOwner : public KBookmarkOwner
|
|
{
|
|
@@ -172,13 +169,11 @@ KCharSelectDia::KCharSelectDia(QWidget *parent)
|
|
else
|
|
lined->setAlignment(Qt::AlignLeft);
|
|
|
|
-#if defined(WITH_CONFIGWIDGET_LIB)
|
|
// Load themes
|
|
KColorSchemeManager *manager = KColorSchemeManager::instance();
|
|
auto *colorSelectionMenu = KColorSchemeMenu::createMenu(manager, this);
|
|
colorSelectionMenu->menu()->setTitle(i18n("&Window Color Scheme"));
|
|
actionCollection()->addAction(QStringLiteral("colorscheme_menu"), colorSelectionMenu);
|
|
-#endif
|
|
|
|
QString filename = QStandardPaths::locate(QStandardPaths::GenericDataLocation, QStringLiteral("kcharselect/bookmarks.xml"));
|
|
if (filename.isEmpty()) {
|
|
--
|
|
GitLab
|
|
|