diff --git a/kde/src/SFLPhoneapplication.cpp b/kde/src/SFLPhoneapplication.cpp index 75aec9e06f06eccb0e99bce01a97ebf873727686..a9515e13cbd2b50f76884a03a23d7f292189f988 100755 --- a/kde/src/SFLPhoneapplication.cpp +++ b/kde/src/SFLPhoneapplication.cpp @@ -68,8 +68,6 @@ SFLPhoneApplication::~SFLPhoneApplication() instance.connection().disconnectFromBus(instance.connection().baseService()); } - - /** * Return the sflphone window */ diff --git a/kde/src/SFLPhoneapplication.h b/kde/src/SFLPhoneapplication.h index 3c8d60f318168261c3126c820c8aefe7e980f5e1..5ccad384bc39efc182f52ffbc2b5a82cc2ff552d 100755 --- a/kde/src/SFLPhoneapplication.h +++ b/kde/src/SFLPhoneapplication.h @@ -38,7 +38,7 @@ public: SFLPhoneApplication(); // Destructor - virtual ~SFLPhoneApplication(); + virtual ~SFLPhoneApplication(); private: //Constructor diff --git a/kde/src/main.cpp b/kde/src/main.cpp index b979cc3368db62a55b627498dc3caddd8e910cd4..6e90c439e9213ea294025a94bdc10166b0e32e0d 100755 --- a/kde/src/main.cpp +++ b/kde/src/main.cpp @@ -21,6 +21,7 @@ //System #include <unistd.h> +#include <signal.h> //Qt #include <QtGui/QAction> @@ -54,6 +55,13 @@ static const char description[] = "A KDE 4 Client for SFLphone"; static const char version[] = "1.1.0"; +SFLPhoneApplication* app; +void quitOnSignal(int signal) +{ + Q_UNUSED(signal); + app->quit(); +} + int main(int argc, char **argv) { try @@ -81,20 +89,25 @@ int main(int argc, char **argv) //configuration dbus TreeWidgetCallModel::init(); - SFLPhoneApplication app; - + app = new SFLPhoneApplication(); + SFLPhone* sflphoneWindow_ = new SFLPhone(); if( ! sflphoneWindow_->initialize() ) { exit(1); return 1; }; + + signal(SIGINT , quitOnSignal); + signal(SIGTERM , quitOnSignal); + sflphoneWindow_->show(); - int retVal = app.exec(); + int retVal = app->exec(); ConfigurationSkeleton* conf = ConfigurationSkeleton::self(); conf->writeConfig(); delete sflphoneWindow_; + delete app; return retVal; } catch(const char * msg) diff --git a/kde/src/widgets/HistoryTreeItem.cpp b/kde/src/widgets/HistoryTreeItem.cpp index fbef5138ffed52e4e8dd3bddeab71d99e2106d6b..7f0fb67b3ea7afc456e94916f0e20e93d47f7534 100644 --- a/kde/src/widgets/HistoryTreeItem.cpp +++ b/kde/src/widgets/HistoryTreeItem.cpp @@ -244,6 +244,7 @@ void HistoryTreeItem::callAgain() } Call* call = SFLPhone::model()->addDialingCall(m_Name, SFLPhone::app()->model()->getCurrentAccountId()); call->setCallNumber(m_PhoneNumber); + call->setPeerName(m_pPeerNameL->text()); call->actionPerformed(CALL_ACTION_ACCEPT); }