[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:00:19 UTC 2016


Gitweb-URL: http://git.debian.org/?p=pkg-kde/applications/ktp-accounts-kcm.git;a=commitdiff;h=f87fec6

The following commit has been merged in the master branch:
commit f87fec6d98b7ea5593ef3c242f893dfcfdb4d7a6
Author: Francesco Nwokeka <francesco.nwokeka at gmail.com>
Date:   Sun Oct 9 16:25:54 2011 +0200

    Create haze plugin
    
    REVIEW: 102812
    BUG: 283575
    Reviewed By: David Edmundson
    
    This patch creates a basic setup (login password) in order to use Haze msn
---
 plugins/haze/CMakeLists.txt                        |  3 ++
 plugins/haze/haze-account-ui-plugin.cpp            | 22 +++++++------
 .../haze-msn-account.cpp}                          | 36 ++++++++++------------
 .../{haze-aim-account.h => haze-msn-account.h}     | 25 ++++++---------
 .../msn-main-options-widget.cpp}                   | 19 +++++-------
 .../msn-main-options-widget.h}                     | 23 +++++++-------
 .../msn-main-options-widget.ui}                    |  4 +--
 7 files changed, 63 insertions(+), 69 deletions(-)

diff --git a/plugins/haze/CMakeLists.txt b/plugins/haze/CMakeLists.txt
index 7460936..dfedda5 100644
--- a/plugins/haze/CMakeLists.txt
+++ b/plugins/haze/CMakeLists.txt
@@ -21,6 +21,8 @@ set (kcmtelepathyaccounts_plugin_haze_SRCS
      aim-main-options-widget.cpp
      haze-aim-account.cpp
      aim-server-settings-widget.cpp
+     msn-main-options-widget.cpp
+     haze-msn-account.cpp
 )
 
 kde4_add_ui_files (kcmtelepathyaccounts_plugin_haze_SRCS
@@ -34,6 +36,7 @@ kde4_add_ui_files (kcmtelepathyaccounts_plugin_haze_SRCS
                    yahoo-server-settings-widget.ui
                    aim-main-options-widget.ui
                    aim-server-settings-widget.ui
+                   msn-main-options-widget.ui
 )
 
 kde4_add_plugin (kcmtelepathyaccounts_plugin_haze
diff --git a/plugins/haze/haze-account-ui-plugin.cpp b/plugins/haze/haze-account-ui-plugin.cpp
index e05ae07..e7667cb 100644
--- a/plugins/haze/haze-account-ui-plugin.cpp
+++ b/plugins/haze/haze-account-ui-plugin.cpp
@@ -25,6 +25,7 @@
 #include "haze-skype-account-ui.h"
 #include "haze-yahoo-account.h"
 #include "haze-aim-account.h"
+#include "haze-msn-account.h"
 
 #include <KDebug>
 #include <KGenericFactory>
@@ -42,6 +43,7 @@ HazeAccountUiPlugin::HazeAccountUiPlugin(QObject *parent, const QVariantList &)
     registerProvidedProtocol("haze", "bigbrownchunx-skype-dbus");
     registerProvidedProtocol("haze", "yahoo");
     registerProvidedProtocol("haze", "aim");
+    registerProvidedProtocol("haze", "msn");
 }
 
 HazeAccountUiPlugin::~HazeAccountUiPlugin()
@@ -57,15 +59,17 @@ AbstractAccountUi* HazeAccountUiPlugin::accountUi(const QString &connectionManag
 
     if (connectionManager == QLatin1String("haze")) {
         if (protocol == QLatin1String("icq")) {
-                return new HazeIcqAccountUi;
-        } else if (protocol == QLatin1String("myspace")){
-                return new HazeMySpaceIMAccountUi;
-        } else if (protocol == QLatin1String("bigbrownchunx-skype-dbus")){
-                return new HazeSkypeAccountUi;
-        } else if (protocol == QLatin1String("yahoo")){
-                return new HazeYahooAccount;
-        } else if (protocol == QLatin1String("aim")){
-               return new HazeAimAccount;
+            return new HazeIcqAccountUi;
+        } else if (protocol == QLatin1String("myspace")) {
+            return new HazeMySpaceIMAccountUi;
+        } else if (protocol == QLatin1String("bigbrownchunx-skype-dbus")) {
+            return new HazeSkypeAccountUi;
+        } else if (protocol == QLatin1String("yahoo")) {
+            return new HazeYahooAccount;
+        } else if (protocol == QLatin1String("aim")) {
+            return new HazeAimAccount;
+        } else if (protocol == QLatin1String("msn")) {
+            return new HazeMsnAccountUi;
         }
     }
 
diff --git a/plugins/butterfly/butterfly-account-ui.cpp b/plugins/haze/haze-msn-account.cpp
similarity index 57%
copy from plugins/butterfly/butterfly-account-ui.cpp
copy to plugins/haze/haze-msn-account.cpp
index fff3ddd..551478d 100644
--- a/plugins/butterfly/butterfly-account-ui.cpp
+++ b/plugins/haze/haze-msn-account.cpp
@@ -1,7 +1,7 @@
 /*
  * This file is part of telepathy-accounts-kcm
  *
- * Copyright (C) 2009 Collabora Ltd. <http://www.collabora.co.uk/>
+ * Copyright (C) 2011 Francesco Nwokeka <francesco.nwokeka at gmail.com>
  *
  * This library is free software; you can redistribute it and/or
  * modify it under the terms of the GNU Lesser General Public
@@ -18,36 +18,34 @@
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
  */
 
-#include "butterfly-account-ui.h"
-#include "main-options-widget.h"
+#include "haze-msn-account.h"
+#include "msn-main-options-widget.h"
 
 #include <KCMTelepathyAccounts/AbstractAccountParametersWidget>
 
-#include <KDebug>
-
-ButterflyAccountUi::ButterflyAccountUi(QObject *parent)
- : AbstractAccountUi(parent)
+HazeMsnAccountUi::HazeMsnAccountUi(QObject* parent)
 {
-    kDebug();
-
     // Register supported parameters
     registerSupportedParameter("account", QVariant::String);
     registerSupportedParameter("password", QVariant::String);
 }
 
-ButterflyAccountUi::~ButterflyAccountUi()
+HazeMsnAccountUi::~HazeMsnAccountUi()
 {
-    kDebug();
 }
 
-AbstractAccountParametersWidget *ButterflyAccountUi::mainOptionsWidget(
-        ParameterEditModel *model,
-        QWidget *parent) const
-{
-    kDebug();
+// AbstractAccountParametersWidget *HazeMsnAccountUi::advancedOptionsWidget(ParameterEditModel *model, QWidget *parent) const
+// {
+//     AbstractAccountParametersWidget *msnServerSettingsWidget = new MsnServerSettingsWidget(model, parent);
+//     return msnServerSettingsWidget;
+// }
 
-    return new MainOptionsWidget(model, parent);
+bool HazeMsnAccountUi::hasAdvancedOptionsWidget() const
+{
+    return false;
 }
 
-#include "butterfly-account-ui.moc"
-
+AbstractAccountParametersWidget *HazeMsnAccountUi::mainOptionsWidget(ParameterEditModel *model, QWidget *parent) const
+{
+    return new MsnMainOptionsWidget(model, parent);
+}
diff --git a/plugins/haze/haze-aim-account.h b/plugins/haze/haze-msn-account.h
similarity index 57%
copy from plugins/haze/haze-aim-account.h
copy to plugins/haze/haze-msn-account.h
index c20315e..7721d30 100644
--- a/plugins/haze/haze-aim-account.h
+++ b/plugins/haze/haze-msn-account.h
@@ -1,7 +1,7 @@
 /*
  * This file is part of telepathy-accounts-kcm
  *
- * Copyright (C) 2011 Lasath Fernando <kde at lasath.org>
+ * Copyright (C) 2011 Francesco Nwokeka <francesco.nwokeka at gmail.com>
  *
  * This library is free software; you can redistribute it and/or
  * modify it under the terms of the GNU Lesser General Public
@@ -18,30 +18,25 @@
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
  */
 
-#ifndef KCMTELEPATHYACCOUNTS_PLUGIN_AIM_ACCOUNT_H
-#define KCMTELEPATHYACCOUNTS_PLUGIN_AIM_ACCOUNT_H
+#ifndef KCMTELEPATHYACCOUNTS_PLUGIN_HAZE_MSN_ACCOUNT_H
+#define KCMTELEPATHYACCOUNTS_PLUGIN_HAZE_MSN_ACCOUNT_H
 
 #include <KCMTelepathyAccounts/AbstractAccountUi>
 
-class HazeAimAccount : public AbstractAccountUi
+class HazeMsnAccountUi: public AbstractAccountUi
 {
     Q_OBJECT
 
 public:
-    explicit HazeAimAccount(QObject *parent = 0);
-    virtual ~HazeAimAccount();
+    explicit HazeMsnAccountUi(QObject *parent = 0);
+    virtual ~HazeMsnAccountUi();
 
-    virtual AbstractAccountParametersWidget
-              *mainOptionsWidget(ParameterEditModel *model,
-                                 QWidget *parent = 0) const;
+//     virtual AbstractAccountParametersWidget *advancedOptionsWidget(ParameterEditModel *model, QWidget *parent = 0) const;
+    virtual AbstractAccountParametersWidget *mainOptionsWidget(ParameterEditModel *model, QWidget *parent = 0) const;
     virtual bool hasAdvancedOptionsWidget() const;
-    virtual AbstractAccountParametersWidget
-              *advancedOptionsWidget(ParameterEditModel *model,
-                                     QWidget *parent = 0) const;
 
 private:
-    Q_DISABLE_COPY(HazeAimAccount);
+    Q_DISABLE_COPY(HazeMsnAccountUi);
 };
 
-#endif // header guard
-
+#endif // KCMTELEPATHYACCOUNTS_PLUGIN_HAZE_MSN_ACCOUNT_H
\ No newline at end of file
diff --git a/plugins/butterfly/main-options-widget.cpp b/plugins/haze/msn-main-options-widget.cpp
similarity index 73%
copy from plugins/butterfly/main-options-widget.cpp
copy to plugins/haze/msn-main-options-widget.cpp
index 81fd2c8..ffb2145 100644
--- a/plugins/butterfly/main-options-widget.cpp
+++ b/plugins/haze/msn-main-options-widget.cpp
@@ -1,7 +1,7 @@
 /*
  * This file is part of telepathy-accounts-kcm
  *
- * Copyright (C) 2009 Collabora Ltd. <http://www.collabora.co.uk/>
+ * Copyright (C) 2011 Francesco Nwokeka <francesco.nwokeka at gmail.com>
  *
  * This library is free software; you can redistribute it and/or
  * modify it under the terms of the GNU Lesser General Public
@@ -18,18 +18,15 @@
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
  */
 
-#include "main-options-widget.h"
+#include "msn-main-options-widget.h"
 
 #include <KDebug>
 
-MainOptionsWidget::MainOptionsWidget(ParameterEditModel *model,
-                                     QWidget *parent)
- : AbstractAccountParametersWidget(model, parent)
+MsnMainOptionsWidget::MsnMainOptionsWidget(ParameterEditModel *model, QWidget *parent)
+    : AbstractAccountParametersWidget(model, parent)
 {
-    kDebug();
-
     // Set up the UI.
-    m_ui = new Ui::MainOptionsWidget;
+    m_ui = new Ui::MsnMainOptionsWidget;
     m_ui->setupUi(this);
 
     handleParameter("account", QVariant::String, m_ui->accountLineEdit, m_ui->accountLabel);
@@ -38,12 +35,10 @@ MainOptionsWidget::MainOptionsWidget(ParameterEditModel *model,
     QTimer::singleShot(0, m_ui->accountLineEdit, SLOT(setFocus()));
 }
 
-MainOptionsWidget::~MainOptionsWidget()
+MsnMainOptionsWidget::~MsnMainOptionsWidget()
 {
-    kDebug();
-
     delete m_ui;
 }
 
-#include "main-options-widget.moc"
+#include "msn-main-options-widget.moc"
 
diff --git a/plugins/gabble/server-settings-widget.h b/plugins/haze/msn-main-options-widget.h
similarity index 61%
copy from plugins/gabble/server-settings-widget.h
copy to plugins/haze/msn-main-options-widget.h
index 1237c9e..56ffc30 100644
--- a/plugins/gabble/server-settings-widget.h
+++ b/plugins/haze/msn-main-options-widget.h
@@ -1,7 +1,7 @@
 /*
  * This file is part of telepathy-accounts-kcm
  *
- * Copyright (C) 2009 Collabora Ltd. <http://www.collabora.co.uk/>
+ * Copyright (C) 2011 Francesco Nwokeka <francesco.nwokeka at gmail.com>
  *
  * This library is free software; you can redistribute it and/or
  * modify it under the terms of the GNU Lesser General Public
@@ -18,27 +18,26 @@
  * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
  */
 
-#ifndef KCMTELEPATHYACCOUNTS_PLUGIN_GABBLE_SERVER_SETTINGS_WIDGET_H
-#define KCMTELEPATHYACCOUNTS_PLUGIN_GABBLE_SERVER_SETTINGS_WIDGET_H
-
-#include "ui_server-settings-widget.h"
+#ifndef KCMTELEPATHYACCOUNTS_PLUGIN_MSN_ACCOUNT_PARAMETERS_WIDGET_H
+#define KCMTELEPATHYACCOUNTS_PLUGIN_MSN_ACCOUNT_PARAMETERS_WIDGET_H
 
 #include <KCMTelepathyAccounts/AbstractAccountParametersWidget>
 
-class ServerSettingsWidget : public AbstractAccountParametersWidget
+#include "ui_msn-main-options-widget.h"
+
+class MsnMainOptionsWidget : public AbstractAccountParametersWidget
 {
     Q_OBJECT
 
 public:
-    explicit ServerSettingsWidget(ParameterEditModel *model,
-                                       QWidget *parent = 0);
-    virtual ~ServerSettingsWidget();
+    explicit MsnMainOptionsWidget(ParameterEditModel *model, QWidget *parent = 0);
+    virtual ~MsnMainOptionsWidget();
 
 private:
-    Q_DISABLE_COPY(ServerSettingsWidget);
-    Ui::ServerSettingsWidget *m_ui;
+    Q_DISABLE_COPY(MsnMainOptionsWidget);
+    Ui::MsnMainOptionsWidget *m_ui;
 };
 
 
-#endif // header guard
+#endif // KCMTELEPATHYACCOUNTS_PLUGIN_MSN_ACCOUNT_PARAMETERS_WIDGET_H
 
diff --git a/plugins/butterfly/main-options-widget.ui b/plugins/haze/msn-main-options-widget.ui
similarity index 96%
copy from plugins/butterfly/main-options-widget.ui
copy to plugins/haze/msn-main-options-widget.ui
index e3df55b..b2b6f9c 100644
--- a/plugins/butterfly/main-options-widget.ui
+++ b/plugins/haze/msn-main-options-widget.ui
@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="UTF-8"?>
 <ui version="4.0">
- <class>MainOptionsWidget</class>
- <widget class="QWidget" name="MainOptionsWidget">
+ <class>MsnMainOptionsWidget</class>
+ <widget class="QWidget" name="MsnMainOptionsWidget">
   <property name="geometry">
    <rect>
     <x>0</x>

-- 
ktp-accounts-kcm packaging



More information about the pkg-kde-commits mailing list