Commit d4a64d58 authored by Aleix Pol Gonzalez's avatar Aleix Pol Gonzalez 🐧
Browse files

Make ktp-text-ui with Qt5+KF5

parent 8804cc12
project(ktp-text-ui)
cmake_minimum_required(VERSION 2.8.12)
set(KTP_TEXT_UI_VERSION "0.8.80")
set(KTP_MESSAGE_FILTER_FRAMEWORK_VERSION "4")
set(IS_KTP_INTERNAL_MODULE TRUE)
......@@ -11,43 +13,33 @@ set (CMAKE_MODULE_PATH
)
# cmake_policy(SET CMP0002 OLD)
set(KDE_MIN_VERSION "4.4.75")
find_package (KDE4 ${KDE_MIN_VERSION} REQUIRED)
find_package(ECM 1.3.0 REQUIRED NO_MODULE)
set(CMAKE_MODULE_PATH ${ECM_MODULE_PATH} ${ECM_KDE_MODULE_DIR})
find_package (KF5 REQUIRED COMPONENTS Archive Sonnet WidgetsAddons Service Emoticons KIO KCMUtils NotifyConfig I18n WebKit KDELibs4Support)
find_package (Qt5 REQUIRED COMPONENTS WebKitWidgets)
find_package (TelepathyQt4 0.9.5 REQUIRED)
find_package (KTp REQUIRED)
find_package (KPeople 0.2)
find_package (KF5People)
include(KDEInstallDirs)
include(KDECMakeSettings)
include(KDECompilerSettings)
include(ECMSetupVersion)
include(FeatureSummary)
macro_log_feature(KPEOPLE_FOUND "KPeople" "Support for KDE Contact Aggregation" "https://projects.kde.org/libkpeople" FALSE "" "")
macro_display_feature_log()
set_package_properties(KF5People PROPERTIES DESCRIPTION "KDE Contacts aggregation"
TYPE OPTIONAL
)
if (KPEOPLE_FOUND)
if (KF5People_FOUND)
add_definitions(-DHAVE_KPEOPLE)
find_package (KdepimLibs REQUIRED)
include_directories(${KPEOPLE_INCLUDES} ${KDEPIMLIBS_INCLUDE_DIRS})
endif (KPEOPLE_FOUND)
endif ()
# FUTURE: When we can depend on KDE 4.10, use emoticoncontexteditaction from here
# find_package(KdepimLibs 4.10 REQUIRED)
include (CheckIncludeFiles)
include (KDE4Defaults)
include (MacroLibrary)
include_directories (${KDE4_INCLUDES}
${TELEPATHY_QT4_INCLUDE_DIR}
${QT_QTWEBKIT_INCLUDES}
${KTP_INCLUDE_DIR}
"${CMAKE_CURRENT_SOURCE_DIR}/lib"
)
add_definitions (${KDE4_DEFINITIONS}
-DQT_NO_CAST_FROM_ASCII
-DQT_NO_KEYWORDS)
configure_file(version.h.in ${CMAKE_CURRENT_BINARY_DIR}/version.h @ONLY)
include_directories(${CMAKE_CURRENT_BINARY_DIR})
add_subdirectory(image-sharer)
add_subdirectory(lib)
add_subdirectory(app)
......@@ -56,3 +48,8 @@ add_subdirectory(data)
add_subdirectory(adiumxtra-protocol-handler)
add_subdirectory(filters)
add_subdirectory(logviewer)
ecm_setup_version(${KTP_TEXT_UI_VERSION} VARIABLE_PREFIX KTP_TEXT_UI
VERSION_HEADER "${CMAKE_CURRENT_BINARY_DIR}/ktptextui_version.h")
feature_summary(WHAT ALL FATAL_ON_MISSING_REQUIRED_PACKAGES)
......@@ -8,15 +8,15 @@ set(ktp-adiumxtra-protocol-handler_SRCS
main.cpp
)
kde4_add_executable(ktp-adiumxtra-protocol-handler ${ktp-adiumxtra-protocol-handler_SRCS})
add_executable(ktp-adiumxtra-protocol-handler ${ktp-adiumxtra-protocol-handler_SRCS})
target_link_libraries(ktp-adiumxtra-protocol-handler
${KDE4_KDECORE_LIBS}
${KDE4_KDEUI_LIBS}
${QT_QTWEBKIT_LIBRARY}
${KDE4_KEMOTICONS_LIBS}
${QT_QTXML_LIBRARY}
${KDE4_KIO_LIBS}
KF5::Emoticons
Qt5::Xml
KF5::KIOWidgets
ktpchat)
......
......@@ -32,13 +32,13 @@
#include <KMimeType>
#include <KAboutData>
#include <KComponentData>
#include <KUrl>
// FIXME: Part of a hack to let adiumxtra-protocol-handler use the main ktelepathy.notifyrc because
// the string freeze does not permit adding a new notifyrc only for adiumxtra-protocol-handler.
// Remove this after 0.7 is released.
static KComponentData ktelepathyComponentData() {
KAboutData telepathySharedAboutData("ktelepathy",0,KLocalizedString(),0);
return KComponentData(telepathySharedAboutData);
static QString ktelepathyComponentName() {
return QStringLiteral("ktelepathy");
}
AdiumxtraProtocolHandler::AdiumxtraProtocolHandler()
......@@ -94,7 +94,7 @@ void AdiumxtraProtocolHandler::install()
notification->setActions( QStringList() << i18n("OK") );
QObject::connect(notification, SIGNAL(action1Activated()), notification, SLOT(close()));
QObject::connect(notification, SIGNAL(ignored()), notification, SLOT(close()));
notification->setComponentData(ktelepathyComponentData());
notification->setComponentName(ktelepathyComponentName());
notification->sendEvent();
kDebug() << "Unsupported file type" << currentBundleMimeType;
kDebug() << tmpFile->fileName();
......@@ -152,7 +152,7 @@ void AdiumxtraProtocolHandler::install()
QObject::connect(notification, SIGNAL(action1Activated()), notification, SLOT(close()));
QObject::connect(notification, SIGNAL(ignored()), notification, SLOT(close()));
notification->setActions( QStringList() << i18n("OK") );
notification->setComponentData(ktelepathyComponentData());
notification->setComponentName(ktelepathyComponentName());
notification->sendEvent();
kDebug() << "Sent error";
......
......@@ -34,9 +34,8 @@
// FIXME: Part of a hack to let adiumxtra-protocol-handler use the main ktelepathy.notifyrc because
// the string freeze does not permit adding a new notifyrc only for adiumxtra-protocol-handler.
// Remove this after 0.7 is released.
static KComponentData ktelepathyComponentData() {
KAboutData telepathySharedAboutData("ktelepathy",0,KLocalizedString(),0);
return KComponentData(telepathySharedAboutData);
static QString ktelepathyComponentName() {
return QStringLiteral("ktelepathy");
}
ChatStyleInstaller::ChatStyleInstaller(KArchive *archive, KTemporaryFile *tmpFile)
......@@ -141,7 +140,7 @@ void ChatStyleInstaller::showRequest()
QObject::connect(notification, SIGNAL(action2Activated()), this, SLOT(ignoreRequest()));
QObject::connect(notification, SIGNAL(action2Activated()), notification, SLOT(close()));
notification->setComponentData(ktelepathyComponentData());
notification->setComponentName(ktelepathyComponentName());
notification->sendEvent();
}
......@@ -159,7 +158,7 @@ void ChatStyleInstaller::showResult()
notification = new KNotification(QLatin1String("chatstyleFailure"));
notification->setText( i18n("Installation of Chatstyle %1 failed.", this->bundleName()) );
}
notification->setComponentData(ktelepathyComponentData());
notification->setComponentName(ktelepathyComponentName());
notification->sendEvent();
Q_EMIT showedResult();
......
......@@ -33,9 +33,8 @@
// FIXME: Part of a hack to let adiumxtra-protocol-handler use the main ktelepathy.notifyrc because
// the string freeze does not permit adding a new notifyrc only for adiumxtra-protocol-handler.
// Remove this after 0.7 is released.
static KComponentData ktelepathyComponentData() {
KAboutData telepathySharedAboutData("ktelepathy",0,KLocalizedString(),0);
return KComponentData(telepathySharedAboutData);
static QString ktelepathyComponentName() {
return QStringLiteral("ktelepathy");
}
EmoticonSetInstaller::EmoticonSetInstaller(KArchive *archive, KTemporaryFile *tmpFile)
......@@ -123,7 +122,7 @@ void EmoticonSetInstaller::showRequest()
QObject::connect(notification, SIGNAL(action2Activated()), this, SLOT(ignoreRequest()));
QObject::connect(notification, SIGNAL(action2Activated()), notification, SLOT(close()));
notification->setComponentData(ktelepathyComponentData());
notification->setComponentName(ktelepathyComponentName());
notification->sendEvent();
}
......@@ -133,7 +132,7 @@ void EmoticonSetInstaller::showResult()
KNotification *notification = new KNotification(QLatin1String("emoticonsSuccess"));
notification->setText( i18n("Installed Emoticonset %1 successfully.", this->bundleName()) );
notification->setComponentData(ktelepathyComponentData());
notification->setComponentName(ktelepathyComponentName());
notification->sendEvent();
Q_EMIT showedResult();
......@@ -145,3 +144,5 @@ void EmoticonSetInstaller::ignoreRequest()
Q_EMIT ignoredRequest();
}
#include "emoticon-set-installer.moc"
......@@ -17,23 +17,23 @@
*/
#include "adiumxtra-protocol-handler.h"
#include "version.h"
#include "../ktptextui_version.h"
#include <KApplication>
#include <KAboutData>
#include <k4aboutdata.h>
#include <KCmdLineArgs>
#include <QTimer>
int main(int argc, char *argv[])
{
KAboutData aboutData("ktp-adiumxtra-protocol-handler",
K4AboutData aboutData("ktp-adiumxtra-protocol-handler",
0,
ki18n("AdiumXtra Protocol Handler"),
KTP_TEXT_UI_VERSION);
KTP_TEXT_UI_VERSION_STRING);
aboutData.addAuthor(ki18n("Dominik Schmidt"), ki18n("Developer"), "kde@dominik-schmidt.de");
aboutData.addAuthor(ki18n("Daniele E. Domenichelli"), ki18n("Developer"), "daniele.domenichelli@gmail.com");
aboutData.setProductName("telepathy/text-ui"); //set the correct name for bug reporting
aboutData.setLicense(KAboutData::License_GPL_V2);
aboutData.setLicense(K4AboutData::License_GPL_V2);
KCmdLineArgs::init(argc, argv, &aboutData);
KCmdLineOptions options;
options.add("!+adium-bundle", ki18n("Adium package to install"));
......
......@@ -12,32 +12,27 @@ set(ktp-text-ui_SRCS
)
set (ktp-text-ui_LIBS
${KDE4_KDECORE_LIBS}
${KDE4_KDEUI_LIBS}
${KDE4_KIO_LIBS}
${KDE4_KEMOTICONS_LIBS}
${TELEPATHY_QT4_LIBRARIES}
${KTP_LIBRARIES}
${KTP_MODELS_LIBRARIES}
${KTP_WIDGETS_LIBRARIES}
${KTP_OTR_LIBRARIES}
${QT_QTWEBKIT_LIBRARY}
${KDE4_KNOTIFYCONFIG_LIBS}
${KDE4_KCMUTILS_LIBS}
Qt5::WebKit
KF5::KIOWidgets
KF5::Emoticons
KTp::CommonInternals
KTp::Models
KTp::Widgets
KTp::OTR
KF5::NotifyConfig
KF5::KCMUtils
${KDEPIMLIBS_KPIMTEXTEDIT_LIBS}
ktpchat
)
if(KPEOPLE_FOUND)
set (ktp-text-ui_LIBS
${ktp-text-ui_LIBS}
${KPEOPLE_LIBRARY}
${KDEPIMLIBS_KABC_LIBS}
${KPEOPLEWIDGETS_LIBRARY}
)
endif(KPEOPLE_FOUND)
if(KF5People_FOUND)
set (ktp-text-ui_LIBS
${ktp-text-ui_LIBS}
KF5::PeopleWidgets
)
endif()
kde4_add_executable(ktp-text-ui ${ktp-text-ui_SRCS})
add_executable(ktp-text-ui ${ktp-text-ui_SRCS})
target_link_libraries(ktp-text-ui
${ktp-text-ui_LIBS})
......
......@@ -23,7 +23,7 @@
#include "chat-widget.h"
#include <QtCore/QString>
#include <QtGui/QWidget>
#include <QWidget>
#include <KIcon>
#include <KColorScheme>
......
......@@ -49,6 +49,7 @@
#include <KToolBar>
#include <KToolInvocation>
#include <KCModuleProxy>
#include <KIconLoader>
#include <QEvent>
#include <QWidgetAction>
......@@ -77,7 +78,7 @@
#define PREFERRED_RFB_HANDLER "org.freedesktop.Telepathy.Client.krfb_rfb_handler"
K_GLOBAL_STATIC_WITH_ARGS(KTp::ServiceAvailabilityChecker, s_krfbAvailableChecker,
Q_GLOBAL_STATIC_WITH_ARGS(KTp::ServiceAvailabilityChecker, s_krfbAvailableChecker,
(QLatin1String(PREFERRED_RFB_HANDLER)));
ChatWindow::ChatWindow()
......@@ -585,7 +586,7 @@ void ChatWindow::onTabStateChanged()
{
kDebug();
KIcon windowIcon;
QIcon windowIcon;
ChatTab *sender = qobject_cast<ChatTab*>(QObject::sender());
if (sender) {
int tabIndex = m_tabWidget->indexOf(sender);
......
......@@ -22,6 +22,7 @@
#include <KLocale>
#include <KMenu>
#include <KIcon>
#include <QWidgetAction>
......@@ -50,7 +51,6 @@ EmoticonTextEditAction::EmoticonTextEditAction( QObject * parent )
{
setMenu( d->emoticonMenu );
setIcon( KIcon( QLatin1String( "face-smile" ) ) );
setShortcutConfigurable( false );
setDelayed( false );
connect( d->selector, SIGNAL(itemSelected(QString)),
this, SIGNAL(emoticonActivated(QString)) );
......
......@@ -28,7 +28,7 @@
#include <QHBoxLayout>
// Use a static for this as calls to the KEmoticons constructor are expensive.
K_GLOBAL_STATIC( KEmoticons, sEmoticons )
Q_GLOBAL_STATIC( KEmoticons, sEmoticons )
EmoticonTextEditItem::EmoticonTextEditItem(const QString &emoticonText, const QString &pixmapPath, QListWidget *parent)
: QListWidgetItem( parent )
......
......@@ -21,7 +21,7 @@
#include "telepathy-chat-ui.h"
#include "defines.h"
#include "version.h"
#include "../ktptextui_version.h"
#include <TelepathyQt/ClientRegistrar>
#include <TelepathyQt/AccountFactory>
......@@ -35,20 +35,20 @@
#include <KTp/core.h>
#include <KTp/OTR/types.h>
#include <KAboutData>
#include <k4aboutdata.h>
#include <KCmdLineArgs>
int main(int argc, char *argv[])
{
KAboutData aboutData("ktp-text-ui", 0,
K4AboutData aboutData("ktp-text-ui", 0,
ki18n("Chat Application"),
KTP_TEXT_UI_VERSION);
KTP_TEXT_UI_VERSION_STRING);
aboutData.addAuthor(ki18n("David Edmundson"), ki18n("Developer"), "david@davidedmundson.co.uk");
aboutData.addAuthor(ki18n("Dominik Schmidt"), ki18n("Developer"), "kde@dominik-schmidt.de");
aboutData.addAuthor(ki18n("Francesco Nwokeka"), ki18n("Developer"), "francesco.nwokeka@gmail.com");
aboutData.addAuthor(ki18n("Marcin Ziemiński"), ki18n("Developer"), "zieminn@gmail.com");
aboutData.setProductName("telepathy/text-ui"); //set the correct name for bug reporting
aboutData.setLicense(KAboutData::License_GPL_V2);
aboutData.setLicense(K4AboutData::License_GPL_V2);
aboutData.setProgramIconName(QLatin1String("telepathy-kde"));
KCmdLineArgs::init(argc, argv, &aboutData);
......@@ -69,7 +69,7 @@ int main(int argc, char *argv[])
Tp::ClientRegistrarPtr registrar = Tp::ClientRegistrar::create(KTp::accountFactory(), KTp::connectionFactory(), channelFactory, KTp::contactFactory());
Tp::SharedPtr<TelepathyChatUi> app = Tp::SharedPtr<TelepathyChatUi>(new TelepathyChatUi);
Tp::SharedPtr<TelepathyChatUi> app(new TelepathyChatUi(argc, argv));
Tp::AbstractClientPtr handler = Tp::AbstractClientPtr(app);
registrar->registerClient(handler, QLatin1String(KTP_TEXTUI_CLIENT_NAME));
......
......@@ -47,8 +47,8 @@ inline Tp::ChannelClassSpecList channelClassList()
}
TelepathyChatUi::TelepathyChatUi()
: KTp::TelepathyHandlerApplication(true, -1, -1),
TelepathyChatUi::TelepathyChatUi(int &argc, char *argv[])
: KTp::TelepathyHandlerApplication(argc, argv, -1, -1),
AbstractClientHandler(channelClassList())
{
kDebug();
......
......@@ -41,7 +41,7 @@ class TelepathyChatUi : public KTp::TelepathyHandlerApplication, public Tp::Abst
{
Q_OBJECT
public:
TelepathyChatUi();
TelepathyChatUi(int& argc, char* argv[]);
~TelepathyChatUi();
virtual void handleChannels(const Tp::MethodInvocationContextPtr<> & context,
......
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions
are met:
1. Redistributions of source code must retain the copyright
notice, this list of conditions and the following disclaimer.
2. Redistributions in binary form must reproduce the copyright
notice, this list of conditions and the following disclaimer in the
documentation and/or other materials provided with the distribution.
3. The name of the author may not be used to endorse or promote products
derived from this software without specific prior written permission.
THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
# Try to find the KTp library
# KTP_FOUND
# KTP_INCLUDE_DIR
# KTP_LIBRARIES
# KTP_MODELS_LIBRARIES
# KTP_WIDGETS_LIBRARIES
# KTP_LOGGER_LIBRARIES
# KTP_OTR_LIBRARIES
# Copyright (c) 2011, Dario Freddi <drf@kde.org>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.
if (NOT IS_KTP_INTERNAL_MODULE)
message (FATAL_ERROR "KTp can be used just from internal components at this time")
endif (NOT IS_KTP_INTERNAL_MODULE)
SET (KTP_FIND_REQUIRED ${KTp_FIND_REQUIRED})
if (KTP_INCLUDE_DIRS AND KTP_LIBRARIES)
# Already in cache, be silent
set(KTP_FIND_QUIETLY TRUE)
endif (KTP_INCLUDE_DIRS AND KTP_LIBRARIES)
find_path(KTP_INCLUDE_DIR
NAMES KTp/presence.h
PATHS ${KDE4_INCLUDE_DIR}
)
find_library(KTP_LIBRARIES NAMES ktpcommoninternalsprivate )
find_library(KTP_MODELS_LIBRARIES NAMES ktpmodelsprivate )
find_library(KTP_WIDGETS_LIBRARIES NAMES ktpwidgetsprivate )
find_library(KTP_LOGGER_LIBRARIES NAMES ktploggerprivate )
find_library(KTP_OTR_LIBRARIES NAMES ktpotrprivate )
include(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(KTp DEFAULT_MSG
KTP_LIBRARIES
KTP_MODELS_LIBRARIES
KTP_INCLUDE_DIR)
mark_as_advanced(KTP_INCLUDE_DIRS KTP_LIBRARIES)
# Find QJSON - JSON handling library for Qt
#
# This module defines
# QJSON_FOUND - whether the qsjon library was found
# QJSON_LIBRARIES - the qjson library
# QJSON_INCLUDE_DIR - the include path of the qjson library
#
# Copyright (C) 2012 Raphael Kubo da Costa <rakuco@FreeBSD.org>
#
# Redistribution and use is allowed according to the terms of the BSD license.
# For details see the accompanying COPYING-CMAKE-SCRIPTS file.
# QJSON v0.7.2+ provides a QJSONConfig.cmake, which should be used if found.
find_package(QJSON QUIET NO_MODULE)
# QJSON <=0.7.1 provide variables with lower case prefix
# This happens only on some distribution, so we check if the lowercase
# variable is set, before setting the uppercase one.
if (${QJSON_VERSION} VERSION_LESS "0.7.2")
if (qjson_LIBRARIES)
set (QJSON_LIBRARIES ${qjson_LIBRARIES})
endif()
if (qjson_INCLUDE_DIR)
set (QJSON_INCLUDE_DIR ${qjson_INCLUDE_DIR})
endif()
endif()
if (QJSON_FOUND)
set(REQUIRED_LIBS QJSON_CONFIG)
else (QJSON_FOUND)
find_package(PkgConfig)
pkg_check_modules(PC_QJSON QJson>=0.5)
find_library(QJSON_LIBRARIES
NAMES qjson
HINTS ${PC_QJSON_LIBDIR} ${PC_QJSON_LIBRARY_DIRS}
)
find_path(QJSON_INCLUDE_DIR
NAMES qjson/parser.h
HINTS ${PC_QJSON_INCLUDEDIR} ${PC_QJSON_INCLUDE_DIRS}
)
set(REQUIRED_LIBS QJSON_LIBRARIES QJSON_INCLUDE_DIR)
endif (QJSON_FOUND)
include(FindPackageHandleStandardArgs)
find_package_handle_standard_args(QJSON DEFAULT_MSG ${REQUIRED_LIBS})
......@@ -10,45 +10,39 @@ set(kcm_ktp_chat_appearance_UI appearance-config.ui)
set(kcm_ktp_chat_behavior_UI behavior-config.ui)
set(kcm_ktp_chat_otr_UI otr-config.ui)
kde4_add_ui_files(kcm_ktp_chat_appearance_SRCS ${kcm_ktp_chat_appearance_UI})
kde4_add_ui_files(kcm_ktp_chat_behavior_SRCS ${kcm_ktp_chat_behavior_UI})
kde4_add_ui_files(kcm_ktp_chat_behavior_SRCS ${kcm_ktp_chat_behavior_UI})
kde4_add_ui_files(kcm_ktp_chat_otr_SRCS ${kcm_ktp_chat_otr_UI})
qt5_wrap_ui(kcm_ktp_chat_appearance_SRCS ${kcm_ktp_chat_appearance_UI})
qt5_wrap_ui(kcm_ktp_chat_behavior_SRCS ${kcm_ktp_chat_behavior_UI})
qt5_wrap_ui(kcm_ktp_chat_behavior_SRCS ${kcm_ktp_chat_behavior_UI})
qt5_wrap_ui(kcm_ktp_chat_otr_SRCS ${kcm_ktp_chat_otr_UI})
kde4_add_plugin(kcm_ktp_chat_appearance ${kcm_ktp_chat_appearance_SRCS})
kde4_add_plugin(kcm_ktp_chat_behavior ${kcm_ktp_chat_behavior_SRCS})
kde4_add_plugin(kcm_ktp_chat_messages ${kcm_ktp_chat_messages_SRCS})
kde4_add_plugin(kcm_ktp_chat_otr ${kcm_ktp_chat_otr_SRCS})
add_library(kcm_ktp_chat_appearance MODULE ${kcm_ktp_chat_appearance_SRCS})
add_library(kcm_ktp_chat_behavior MODULE ${kcm_ktp_chat_behavior_SRCS})
add_library(kcm_ktp_chat_messages MODULE ${kcm_ktp_chat_messages_SRCS})
add_library(kcm_ktp_chat_otr MODULE ${kcm_ktp_chat_otr_SRCS})
target_link_libraries(kcm_ktp_chat_appearance
${KDE4_KDECORE_LIBS}
${KDE4_KDEUI_LIBS}
${QT_QTWEBKIT_LIBRARY}
${KDE4_KCMUTILS_LIBS}
Qt5::WebKitWidgets
KF5::KCMUtils
KF5::KDELibs4Support
ktpchat
)
target_link_libraries(kcm_ktp_chat_behavior
${KDE4_KDECORE_LIBS}
${KDE4_KDEUI_LIBS}
${KDE4_KCMUTILS_LIBS}
KF5::KDELibs4Support
KF5::KCMUtils
ktpchat
ktpimagesharer
)
target_link_libraries(kcm_ktp_chat_messages
${KDE4_KDECORE_LIBS}
${KDE4_KDEUI_LIBS}
${KDE4_KUTILS_LIBS}
${KTP_LIBRARIES}
KF5::KDELibs4Support
KF5::KCMUtils
KTp::CommonInternals
ktpchat
)
target_link_libraries(kcm_ktp_chat_otr
${KDE4_KDECORE_LIBS}
${KDE4_KDEUI_LIBS}
${KDE4_KUTILS_LIBS}
${KTP_LIBRARIES}
${KTP_OTR_LIBRARIES}
${TELEPATHY_QT4_LIBRARIES}
KTp::CommonInternals
KTp::OTR
KF5::KDELibs4Support
ktpchat
)
......
......@@ -27,6 +27,9 @@
#include "adium-theme-status-info.h"
#include <KMessageBox>
#include <KLocalizedString>
#include <KIconLoader>
#include <KGlobalSettings>
AppearanceConfigTab::AppearanceConfigTab(QWidget *parent, TabMode mode)
: QWidget(parent),
......
......@@ -30,14 +30,17 @@
#include "adium-theme-status-info.h"
#include <KDebug>
#include <KDialog>
#include <KLocalizedString>
#include <KPluginFactory>
#include <KIcon>
#include <KSharedConfig>
K_PLUGIN_FACTORY(KCMTelepathyChatAppearanceConfigFactory, registerPlugin<AppearanceConfig>();)
K_EXPORT_PLUGIN(KCMTelepathyChatAppearanceConfigFactory("ktp_chat_appearance", "kcm_ktp_chat_appearance"))
AppearanceConfig::AppearanceConfig(QWidget *parent, const QVariantList &args)
: KCModule(KCMTelepathyChatAppearanceConfigFactory::componentData(), parent, args)
: KCModule(parent, args)
{
QVBoxLayout *topLayout = new QVBoxLayout(this);
topLayout->setMargin(0);
......@@ -89,3 +92,5 @@ void AppearanceConfig::save()
Q_EMIT reloadTheme();
}
#include "appearance-config.moc"