[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    KDE/kdenetwork/krfb/krfb
From:       George Kiagiadakis <kiagiadakis.george () gmail ! com>
Date:       2010-11-10 17:48:57
Message-ID: 20101110174857.6A5ADAC8A1 () svn ! kde ! org
[Download RAW message or body]

SVN commit 1195265 by gkiagia:

Remove more unused stuff from the TrayIcon.

 M  +2 -18     trayicon.cpp  
 M  +0 -8      trayicon.h  


--- trunk/KDE/kdenetwork/krfb/krfb/trayicon.cpp #1195264:1195265
@@ -30,8 +30,7 @@
 #include <KStandardAction>
 
 TrayIcon::TrayIcon(KDialog *d)
-    : KStatusNotifierItem(d),
-      quitting(false)
+    : KStatusNotifierItem(d)
 {
     setIconByPixmap(KIcon("krfb").pixmap(22, 22, KIcon::Disabled));
 
@@ -41,31 +40,20 @@
     enableControlAction = new KToggleAction(i18n("Enable Remote Control"), actionCollection());
     enableControlAction->setCheckedState(KGuiItem(i18n("Disable Remote Control")));
     enableControlAction->setEnabled(false);
-    actionCollection()->addAction("enable_control", enableControlAction);
     connect(enableControlAction, SIGNAL(toggled(bool)), SIGNAL(enableDesktopControl(bool)));
-    contextMenu()->addAction(actionCollection()->action("enable_control"));
+    contextMenu()->addAction(enableControlAction);
 
     contextMenu()->addSeparator();
     contextMenu()->addAction(KStandardAction::aboutApp(this, SLOT(showAbout()), actionCollection()));
 }
 
-TrayIcon::~TrayIcon()
-{
-}
-
 void TrayIcon::showAbout()
 {
     KAboutApplicationDialog(KGlobal::mainComponent().aboutData()).exec();
 }
 
-void TrayIcon::prepareQuit()
-{
-    quitting = true;
-}
-
 void TrayIcon::showConnectedMessage(const QString &host)
 {
-
     setIconByPixmap(KIcon("krfb"));
     KNotification::event("UserAcceptsConnection",
                          i18n("The remote user %1 is now connected.",
@@ -77,10 +65,6 @@
 
 void TrayIcon::showDisconnectedMessage()
 {
-    if (quitting) {
-        return;
-    }
-
     setToolTipTitle(i18n("Desktop Sharing - disconnected"));
     setIconByPixmap(KIcon("krfb").pixmap(22, 22, KIcon::Disabled));
     KNotification::event("ConnectionClosed", i18n("The remote user has closed the connection."));
--- trunk/KDE/kdenetwork/krfb/krfb/trayicon.h #1195264:1195265
@@ -18,8 +18,6 @@
 #ifndef TRAYICON_H
 #define TRAYICON_H
 
-#include <KActionCollection>
-#include <KPassivePopup>
 #include <KStatusNotifierItem>
 #include <KToggleAction>
 
@@ -35,16 +33,12 @@
     Q_OBJECT
 public:
     TrayIcon(KDialog *);
-    ~TrayIcon();
 
 signals:
-
     void disconnectedMessageDisplayed();
     void enableDesktopControl(bool);
-    void quitApp();
 
 public Q_SLOTS:
-    void prepareQuit();
     void showConnectedMessage(const QString &host);
     void showDisconnectedMessage();
     void setDesktopControlSetting(bool);
@@ -53,8 +47,6 @@
 private:
     KAction *aboutAction;
     KToggleAction *enableControlAction;
-    bool quitting;
-
 };
 
 #endif
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic