[SCM] ktp-accounts-kcm packaging branch, master, updated. debian/15.12.1-1-1157-gc4589c5
Maximiliano Curia
maxy at moszumanska.debian.org
Sat May 28 00:04:43 UTC 2016
Gitweb-URL: http://git.debian.org/?p=pkg-kde/applications/ktp-accounts-kcm.git;a=commitdiff;h=6b05a5f
The following commit has been merged in the master branch:
commit 6b05a5f9dfd375715e62838cbc9e978ab1ee5c82
Author: Dan Vrátil <dvratil at redhat.com>
Date: Mon Aug 26 15:31:27 2013 +0200
Port to KTp Logger
---
CMakeLists.txt | 9 ---------
cmake/modules/FindKTp.cmake | 2 ++
src/CMakeLists.txt | 2 +-
src/kcm-telepathy-accounts.cpp | 21 +++------------------
4 files changed, 6 insertions(+), 28 deletions(-)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index d10706e..f3c758f 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -11,12 +11,8 @@ set(IS_KTP_INTERNAL_MODULE TRUE)
set(KDE_MIN_VERSION "4.7.0")
find_package (KDE4 REQUIRED)
find_package (TelepathyQt4 0.8.9 REQUIRED)
-find_package (TelepathyLoggerQt4 QUIET)
find_package (KTp REQUIRED)
-macro_log_feature(TELEPATHY_LOGGER_QT4_FOUND "TelepatyLoggerQt4" "Qt bindings for TelepathyLogger. This is needed to provide access to chat logs. HIGHLY recommended" "http://projects.kde.org/telepathy-logger-qt" FALSE "" "")
-macro_display_feature_log()
-
# set some default settings
include (KDE4Defaults)
@@ -34,11 +30,6 @@ include_directories (${KDE4_INCLUDES}
${CMAKE_CURRENT_SOURCE_DIR}/src
)
-if (TELEPATHY_LOGGER_QT4_FOUND)
- add_definitions(${TELEPATHY_LOGGER_QT4_DEFINITIONS} -DHAVE_TPLOGGERQT)
- include_directories(${TELEPATHY_LOGGER_QT4_INCLUDE_DIRS})
-endif (TELEPATHY_LOGGER_QT4_FOUND)
-
add_subdirectory (src)
add_subdirectory (data)
add_subdirectory (plugins)
diff --git a/cmake/modules/FindKTp.cmake b/cmake/modules/FindKTp.cmake
index 8facd12..4c6f7a6 100644
--- a/cmake/modules/FindKTp.cmake
+++ b/cmake/modules/FindKTp.cmake
@@ -4,6 +4,7 @@
# KTP_LIBRARIES
# KTP_MODELS_LIBRARIES
# KTP_WIDGETS_LIBRARIES
+# KTP_LOGGER_LIBRARIES
# Copyright (c) 2011, Dario Freddi <drf at kde.org>
#
@@ -28,6 +29,7 @@ find_path(KTP_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 )
include(FindPackageHandleStandardArgs)
FIND_PACKAGE_HANDLE_STANDARD_ARGS(KTp DEFAULT_MSG
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
index d27c7c0..cf7998e 100644
--- a/src/CMakeLists.txt
+++ b/src/CMakeLists.txt
@@ -39,8 +39,8 @@ target_link_libraries (kcm_ktp_accounts
${TELEPATHY_QT4_LIBRARIES}
${KTP_LIBRARIES}
${KTP_MODELS_LIBRARIES}
+ ${KTP_LOGGER_LIBRARIES}
${KDE4_KIO_LIBS}
- ${TELEPATHY_LOGGER_QT4_LIBRARIES}
)
# Install:
diff --git a/src/kcm-telepathy-accounts.cpp b/src/kcm-telepathy-accounts.cpp
index 9d6cc9a..c8b837b 100644
--- a/src/kcm-telepathy-accounts.cpp
+++ b/src/kcm-telepathy-accounts.cpp
@@ -60,11 +60,7 @@
#include <TelepathyQt/PendingComposite>
#include <TelepathyQt/ConnectionManager>
-#ifdef HAVE_TPLOGGERQT
-#include <TelepathyLoggerQt4/LogManager>
-#include <TelepathyLoggerQt4/Init>
-#include <TelepathyLoggerQt4/PendingOperation>
-#endif
+#include <KTp/Logger/log-manager.h>
K_PLUGIN_FACTORY(KCMTelepathyAccountsFactory, registerPlugin<KCMTelepathyAccounts>();)
K_EXPORT_PLUGIN(KCMTelepathyAccountsFactory("kcm_ktp_accounts", "kcm_ktp_accounts"))
@@ -91,9 +87,6 @@ KCMTelepathyAccounts::KCMTelepathyAccounts(QWidget *parent, const QVariantList&
// The first thing we must do is register Telepathy DBus Types.
Tp::registerTypes();
-#ifdef HAVE_TPLOGGERQT
- Tpl::init();
-#endif
// Start setting up the Telepathy AccountManager.
Tp::AccountFactoryPtr accountFactory = Tp::AccountFactory::create(QDBusConnection::sessionBus(),
@@ -413,13 +406,7 @@ void KCMTelepathyAccounts::onRemoveAccountClicked()
dialog->setButtonGuiItem(KDialog::Yes, KGuiItem(i18n("Remove Account"), QLatin1String("edit-delete")));
bool removeLogs = false;
- // Don't show the 'Remove logs' checkbox when we don't support TpLogger
-#ifdef HAVE_TPLOGGERQT
const QString msg = i18n("Remove conversations logs");
-#else
- const QString msg;
-#endif
-
if (KMessageBox::createKMessageBox(dialog, QMessageBox::Warning, i18n("Are you sure you want to remove the account \"%1\"?", accountName),
QStringList(), msg , &removeLogs,
KMessageBox::Dangerous | KMessageBox::Notify) == KDialog::Yes) {
@@ -429,12 +416,10 @@ void KCMTelepathyAccounts::onRemoveAccountClicked()
return;
}
-#ifdef HAVE_TPLOGGERQT
if (removeLogs) {
- Tpl::LogManagerPtr logManager = Tpl::LogManager::instance();
- logManager->clearAccountHistory(account);
+ KTp::LogManager *logManager = KTp::LogManager::instance();
+ logManager->clearAccountLogs(account);
}
-#endif
QList<Tp::PendingOperation*> ops;
ops.append(KTp::WalletUtils::removeAccountPassword(account));
--
ktp-accounts-kcm packaging
More information about the pkg-kde-commits
mailing list