From 19e8f2119d50e47475ac34efd3317199f356c2ce Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?J=C3=A9r=C3=A9my=20Quentin?=
 <jquentin@jquentin-laptop-kub2.(none)>
Date: Thu, 4 Jun 2009 12:36:01 -0400
Subject: [PATCH] [#1593] enable accounts apply button when account
 checked/unchecked [#1594] enable debug messages with "--with-debug" only
 [#1595] call back with call history should use the same account as the past
 call [#1596] crashes when typing enter in history or address book and no item
 selected [#1597] beautiful dialpad with letters [#1598] call history should
 display calls in anti-chronologic order

+set update-alternatives + corrected strings in french in ui files
---
 sflphone-client-kde/config.sh                 |  4 +-
 sflphone-client-kde/src/AccountItemWidget.cpp | 13 ++-
 sflphone-client-kde/src/AccountItemWidget.h   |  5 +
 sflphone-client-kde/src/AccountWizard.cpp     |  2 +-
 sflphone-client-kde/src/CMakeLists.txt        |  6 +-
 sflphone-client-kde/src/Call.cpp              | 16 +++-
 sflphone-client-kde/src/Call.h                |  3 +-
 sflphone-client-kde/src/CallList.cpp          |  4 +-
 sflphone-client-kde/src/CallList.h            |  2 +-
 sflphone-client-kde/src/ConfigDialog.cpp      |  2 +
 sflphone-client-kde/src/sflphone_kdeview.cpp  | 93 ++++++++++++++-----
 sflphone-client-kde/src/sflphone_kdeview.h    |  1 +
 sflphone-client-kde/src/ui/ConfigDialog.ui    |  8 +-
 .../src/ui/sflphone_kdeview_base.ui           | 71 +++++++++-----
 .../debian-sflphone-client-kde/postinst       |  2 +-
 15 files changed, 166 insertions(+), 66 deletions(-)

diff --git a/sflphone-client-kde/config.sh b/sflphone-client-kde/config.sh
index 6bb5513475..8c37d45a0d 100755
--- a/sflphone-client-kde/config.sh
+++ b/sflphone-client-kde/config.sh
@@ -26,9 +26,9 @@ options=`echo $@ | sed "s/--prefix=/-DCMAKE_INSTALL_PREFIX=/g" | sed "s/--with-d
 
 if `echo $@ | grep -q "\--with-debug"`
 then echo "Enable debug messages"
-options="$options -DCMAKE_BUILD_TYPE=\"Debug\""
+options="$options -DCMAKE_BUILD_TYPE=Debug"
 else echo "Disable debug messages"
-options="$options -DCMAKE_BUILD_TYPE=\"Release\""
+options="$options -DCMAKE_BUILD_TYPE=Release"
 fi
 
 echo "Passing argument  '$options'  to cmake"
diff --git a/sflphone-client-kde/src/AccountItemWidget.cpp b/sflphone-client-kde/src/AccountItemWidget.cpp
index dd895adde6..ab841e83a6 100644
--- a/sflphone-client-kde/src/AccountItemWidget.cpp
+++ b/sflphone-client-kde/src/AccountItemWidget.cpp
@@ -30,6 +30,7 @@ AccountItemWidget::AccountItemWidget(QWidget *parent)
  : QWidget(parent)
 {
 	checkBox = new QCheckBox(this);
+	checkBox->setObjectName("checkBox");
 	led = new QLabel();
 	led->setSizePolicy(QSizePolicy(QSizePolicy::Fixed, QSizePolicy::Fixed));
 	textLabel = new QLabel();
@@ -45,6 +46,11 @@ AccountItemWidget::AccountItemWidget(QWidget *parent)
 	state = Unregistered;
 	enabled = false;
 	updateDisplay();
+	
+// 	connect(checkBox, SIGNAL(stateChanged(int)),
+// 	        this,      SLOT(on_checkBox_stateChanged()));
+	
+	QMetaObject::connectSlotsByName(this);
 }
 
 
@@ -89,14 +95,12 @@ void AccountItemWidget::setState(int state)
 {
 	this->state = state;
 	updateStateDisplay();
-	//emit stateChanged;
 }
 
 void AccountItemWidget::setEnabled(bool enabled)
 {
 	this->enabled = enabled;
 	updateEnabledDisplay();
-	//emit enabledChanged;
 }
 
 void AccountItemWidget::setAccountText(QString text)
@@ -108,3 +112,8 @@ bool AccountItemWidget::getEnabled()
 {
 	return checkBox->checkState();
 }
+
+void AccountItemWidget::on_checkBox_stateChanged()
+{
+	emit checkStateChanged();
+}
diff --git a/sflphone-client-kde/src/AccountItemWidget.h b/sflphone-client-kde/src/AccountItemWidget.h
index 1c9c36c827..25c1a688dc 100644
--- a/sflphone-client-kde/src/AccountItemWidget.h
+++ b/sflphone-client-kde/src/AccountItemWidget.h
@@ -64,7 +64,12 @@ public:
 	void updateEnabledDisplay();
 	void updateDisplay();
 	
+private slots:	
+	void on_checkBox_stateChanged();
 	
+	
+signals:
+	void checkStateChanged();
 
 };
 
diff --git a/sflphone-client-kde/src/AccountWizard.cpp b/sflphone-client-kde/src/AccountWizard.cpp
index 40285de366..c799ab1490 100644
--- a/sflphone-client-kde/src/AccountWizard.cpp
+++ b/sflphone-client-kde/src/AccountWizard.cpp
@@ -505,7 +505,7 @@ WizardAccountStunPage::WizardAccountStunPage(QWidget *parent)
      : QWizardPage(parent)
 {
 	setTitle(tr2i18n("Network Address Translation (NAT)"));
-	setSubTitle(tr2i18n("You should probably enable this option if you're placed under a firewall :"));
+	setSubTitle(tr2i18n("You should probably enable this option if you're placed under a firewall"));
 
 	checkBox_enableStun = new QCheckBox(tr2i18n("Enable STUN"));
 	label_StunServer = new QLabel(tr2i18n("Stun Server"));
diff --git a/sflphone-client-kde/src/CMakeLists.txt b/sflphone-client-kde/src/CMakeLists.txt
index 73894ff7da..50a47b1b93 100644
--- a/sflphone-client-kde/src/CMakeLists.txt
+++ b/sflphone-client-kde/src/CMakeLists.txt
@@ -15,9 +15,9 @@ ADD_DEFINITIONS(${KDE4_DEFINITIONS} ${QT_DEFINITIONS} -fexceptions -DDATA_INSTAL
 MESSAGE("CMAKE_BUILD_TYPE = ${CMAKE_BUILD_TYPE}")
 
 IF(${CMAKE_BUILD_TYPE} MATCHES Release)
-MESSAGE("NO DEBUG OUTPUT")
-ADD_DEFINITIONS( -DQT_NO_DEBUG_OUTPUT )
-ENDIF(DEFINED DEBUG_DISABLED)
+	MESSAGE("NO DEBUG OUTPUT")
+	ADD_DEFINITIONS( -DQT_NO_DEBUG_OUTPUT )
+ENDIF(${CMAKE_BUILD_TYPE} MATCHES Release)
 
 SET ( KDE4_KABC_LIBS  -lkabc )
 
diff --git a/sflphone-client-kde/src/Call.cpp b/sflphone-client-kde/src/Call.cpp
index 1b640e0ff9..6dcbc48280 100644
--- a/sflphone-client-kde/src/Call.cpp
+++ b/sflphone-client-kde/src/Call.cpp
@@ -174,9 +174,9 @@ Call::~Call()
 	//delete historyItemWidget;
 }
 	
-Call * Call::buildDialingCall(QString callId, const QString & peerName)
+Call * Call::buildDialingCall(QString callId, const QString & peerName, QString account)
 {
-	Call * call = new Call(CALL_STATE_DIALING, callId, peerName);
+	Call * call = new Call(CALL_STATE_DIALING, callId, peerName, "", account);
 	call->historyState = NONE;
 	return call;
 }
@@ -390,6 +390,11 @@ bool Call::getRecording() const
 	return recording;
 }
 
+QString Call::getAccountId() const
+{
+	return account;
+}
+
 /*
 void Call::putRecording()
 {
@@ -467,7 +472,12 @@ void Call::call()
 {
 	CallManagerInterface & callManager = CallManagerInterfaceSingleton::getInstance();
 	QString number = labelCallNumber->text();
-	this->account = sflphone_kdeView::firstAccountId();
+	qDebug() << "account = " << account;
+	if(account.isEmpty())
+	{
+		qDebug() << "account is empty"; 
+		this->account = sflphone_kdeView::firstAccountId();
+	}
 	if(!account.isEmpty())
 	{
 		qDebug() << "Calling " << number << " with account " << account << ". callId : " << callId;
diff --git a/sflphone-client-kde/src/Call.h b/sflphone-client-kde/src/Call.h
index 9d2bea58a3..e9fff3fb2b 100644
--- a/sflphone-client-kde/src/Call.h
+++ b/sflphone-client-kde/src/Call.h
@@ -182,7 +182,7 @@ public:
 	//Constructors & Destructors
 	~Call();
 	void initCallItem();
-	static Call * buildDialingCall(QString callId, const QString & peerName);
+	static Call * buildDialingCall(QString callId, const QString & peerName, QString account = "");
 	static Call * buildIncomingCall(const QString & callId/*, const QString & from, const QString & account*/);
 	static Call * buildRingingCall(const QString & callId);
 	
@@ -199,6 +199,7 @@ public:
 	call_state getCurrentState() const;
 	history_state getHistoryState() const;
 	bool getRecording() const;
+	QString getAccountId() const;
 	
 	//Automate calls
 	call_state stateChanged(const QString & newState);
diff --git a/sflphone-client-kde/src/CallList.cpp b/sflphone-client-kde/src/CallList.cpp
index 3ee4851c2e..e98ab32e39 100644
--- a/sflphone-client-kde/src/CallList.cpp
+++ b/sflphone-client-kde/src/CallList.cpp
@@ -113,9 +113,9 @@ int CallList::size()
 	return calls->size();
 }
 
-Call * CallList::addDialingCall(const QString & peerName)
+Call * CallList::addDialingCall(const QString & peerName, QString account)
 {
-	Call * call = Call::buildDialingCall(getAndIncCallId(), peerName);
+	Call * call = Call::buildDialingCall(getAndIncCallId(), peerName, account);
 	calls->append(call);
 	return call;
 }
diff --git a/sflphone-client-kde/src/CallList.h b/sflphone-client-kde/src/CallList.h
index 9333abd037..16e3d89d80 100644
--- a/sflphone-client-kde/src/CallList.h
+++ b/sflphone-client-kde/src/CallList.h
@@ -51,7 +51,7 @@ public:
 	int size();
 
 	//Setters
-	Call * addDialingCall(const QString & peerName = "");
+	Call * addDialingCall(const QString & peerName = "", QString account = "");
 	Call * addIncomingCall(const QString & callId/*, const QString & from, const QString & account*/);
 	Call * addRingingCall(const QString & callId);
 
diff --git a/sflphone-client-kde/src/ConfigDialog.cpp b/sflphone-client-kde/src/ConfigDialog.cpp
index 16f04caca3..b3cce31cb0 100644
--- a/sflphone-client-kde/src/ConfigDialog.cpp
+++ b/sflphone-client-kde/src/ConfigDialog.cpp
@@ -485,6 +485,8 @@ void ConfigurationDialog::addAccountToAccountList(Account * account)
 	qDebug() << "addAccountToAccountList";
 	QListWidgetItem * item = account->getItem();
 	QWidget * widget = account->getItemWidget();
+	connect(widget, SIGNAL(checkStateChanged()),
+	        this,   SLOT(changedAccountList()));
 	listWidget_accountList->addItem(item);
 	listWidget_accountList->setItemWidget(item, widget);
 }
diff --git a/sflphone-client-kde/src/sflphone_kdeview.cpp b/sflphone-client-kde/src/sflphone_kdeview.cpp
index 5de096389c..c4e3752ac3 100644
--- a/sflphone-client-kde/src/sflphone_kdeview.cpp
+++ b/sflphone-client-kde/src/sflphone_kdeview.cpp
@@ -85,7 +85,6 @@ sflphone_kdeView::sflphone_kdeView(QWidget *parent)
 	
 	loadWindow();
 	
-	
 } 
 
 sflphone_kdeView::~sflphone_kdeView()
@@ -97,7 +96,41 @@ sflphone_kdeView::~sflphone_kdeView()
 }
 
 
-
+void sflphone_kdeView::buildDialPad()
+{
+	QHBoxLayout * layout;
+	QLabel * number;
+	QLabel * text;
+	int spacing = 5;
+	int numberSize = 14;
+	int textSize = 8;
+	
+	QPushButton * buttons[12] = 
+	    {pushButton_1,      pushButton_2,   pushButton_3, 
+	     pushButton_4,      pushButton_5,   pushButton_6, 
+	     pushButton_7,      pushButton_8,   pushButton_9, 
+	     pushButton_etoile, pushButton_0,   pushButton_diese};
+	     
+	QString numbers[12] = {"1", "2", "3", "4", "5", "6", "7", "8", "9", "*", "0", "#"};
+	
+	QString texts[12] = {"", "abc", "def", "ghi", "jkl", "mno", "pqrs", "tuv", "wxyz", "", "", ""};
+	
+	for(int i = 0 ; i < 12 ; i++)
+	{
+		layout = new QHBoxLayout();
+		layout->setSpacing(spacing);
+		number = new QLabel(numbers[i]);
+		number->setFont(QFont("", numberSize));
+		layout->addWidget(number);
+		number->setAlignment(Qt::AlignRight | Qt::AlignVCenter);
+		text = new QLabel(texts[i]);
+		text->setFont(QFont("", textSize));
+		layout->addWidget(text);
+		buttons[i]->setLayout(layout);
+		buttons[i]->setMinimumHeight(30);
+		buttons[i]->setText("");
+	}
+}
 
 void sflphone_kdeView::loadWindow()
 {
@@ -105,6 +138,7 @@ void sflphone_kdeView::loadWindow()
 	ConfigurationManagerInterface & configurationManager = ConfigurationManagerInterfaceSingleton::getInstance();
 	action_displayVolumeControls->setChecked(configurationManager.getVolumeControls());
 	action_displayDialpad->setChecked(configurationManager.getDialpad());
+	buildDialPad();
 	updateWindowCallState();
 	updateRecordButton();
 	updateVolumeButton();
@@ -335,27 +369,44 @@ void sflphone_kdeView::enter()
 	if(stackedWidget_screen->currentWidget() == page_callHistory)
 	{
 		qDebug() << "In call history.";
-		action_history->setChecked(false);
-		stackedWidget_screen->setCurrentWidget(page_callList);
-		
-		Call * pastCall = callList->findCallByHistoryItem(listWidget_callHistory->currentItem());
-		Call * call = callList->addDialingCall(pastCall->getPeerName());
-		call->appendItemText(pastCall->getPeerPhoneNumber());
-		addCallToCallList(call);
-		listWidget_callList->setCurrentRow(listWidget_callList->count() - 1);
-		actionb(call, CALL_ACTION_ACCEPT);
+		QListWidgetItem * item = listWidget_callHistory->currentItem();
+		if(!item)
+		{
+			qDebug() << "Enter when no item is selected. Doing nothing.";
+		}
+		else
+		{
+			action_history->setChecked(false);
+			stackedWidget_screen->setCurrentWidget(page_callList);
+			
+			Call * pastCall = callList->findCallByHistoryItem(item);
+			if (!pastCall) qDebug() << "pastCall null";
+			Call * call = callList->addDialingCall(pastCall->getPeerName(), pastCall->getAccountId());
+			call->appendItemText(pastCall->getPeerPhoneNumber());
+			addCallToCallList(call);
+			listWidget_callList->setCurrentRow(listWidget_callList->count() - 1);
+			actionb(call, CALL_ACTION_ACCEPT);
+		}
 	}
 	if(stackedWidget_screen->currentWidget() == page_addressBook)
 	{
 		qDebug() << "In address book.";
-		action_addressBook->setChecked(false);
-		stackedWidget_screen->setCurrentWidget(page_callList);
-		ContactItemWidget * w = (ContactItemWidget *) (listWidget_addressBook->itemWidget(listWidget_addressBook->currentItem()));
-		Call * call = callList->addDialingCall(w->getContactName());
-		call->appendItemText(w->getContactNumber());
-		addCallToCallList(call);
-		listWidget_callList->setCurrentRow(listWidget_callList->count() - 1);
-		actionb(call, CALL_ACTION_ACCEPT);
+		QListWidgetItem * item = listWidget_addressBook->currentItem();
+		if(!item)
+		{
+			qDebug() << "Enter when no item is selected. Doing nothing.";
+		}
+		else
+		{
+			action_addressBook->setChecked(false);
+			stackedWidget_screen->setCurrentWidget(page_callList);
+			ContactItemWidget * w = (ContactItemWidget *) (listWidget_addressBook->itemWidget(item));
+			Call * call = callList->addDialingCall(w->getContactName());
+			call->appendItemText(w->getContactNumber());
+			addCallToCallList(call);
+			listWidget_callList->setCurrentRow(listWidget_callList->count() - 1);
+			actionb(call, CALL_ACTION_ACCEPT);
+		}
 	}
 }
 
@@ -595,7 +646,7 @@ void sflphone_kdeView::updateCallHistory()
 		qDebug() << "take item " << item->text() << " ; widget = " << callList->findCallByHistoryItem(item);
 	}
 	QString textSearched = lineEdit_searchHistory->text();
-	for(int i = 0 ; i < callList->size() ; i++)
+	for(int i = callList->size() - 1 ; i >= 0 ; i--)
 	{
 		Call * call = (*callList)[i];
 		qDebug() << "" << call->getCallId();
@@ -969,7 +1020,7 @@ void sflphone_kdeView::on_listWidget_callHistory_itemDoubleClicked(QListWidgetIt
 	action_history->setChecked(false);
 	stackedWidget_screen->setCurrentWidget(page_callList);
 	Call * pastCall = callList->findCallByHistoryItem(item);
-	Call * call = callList->addDialingCall(pastCall->getPeerName());
+	Call * call = callList->addDialingCall(pastCall->getPeerName(), pastCall->getAccountId());
 	call->appendItemText(pastCall->getPeerPhoneNumber());
 	addCallToCallList(call);
 	listWidget_callList->setCurrentRow(listWidget_callList->count() - 1);
diff --git a/sflphone-client-kde/src/sflphone_kdeview.h b/sflphone-client-kde/src/sflphone_kdeview.h
index 3d7fadab15..9c92eb67a0 100644
--- a/sflphone-client-kde/src/sflphone_kdeview.h
+++ b/sflphone-client-kde/src/sflphone_kdeview.h
@@ -80,6 +80,7 @@ public:
 	 * 
 	 */
 	void loadWindow();
+	void buildDialPad();
 	
 	//Getters
 	static QString firstAccountId();
diff --git a/sflphone-client-kde/src/ui/ConfigDialog.ui b/sflphone-client-kde/src/ui/ConfigDialog.ui
index f0e4585fb6..9a5a98aed5 100644
--- a/sflphone-client-kde/src/ui/ConfigDialog.ui
+++ b/sflphone-client-kde/src/ui/ConfigDialog.ui
@@ -179,7 +179,7 @@
      <item>
       <widget class="QStackedWidget" name="stackedWidget_options">
        <property name="currentIndex">
-        <number>0</number>
+        <number>3</number>
        </property>
        <widget class="QWidget" name="page_general">
         <layout class="QVBoxLayout" name="verticalLayout_18">
@@ -1047,7 +1047,7 @@
             </sizepolicy>
            </property>
            <property name="currentIndex">
-            <number>0</number>
+            <number>1</number>
            </property>
            <widget class="QWidget" name="page1_alsa">
             <layout class="QVBoxLayout" name="verticalLayout_20">
@@ -1136,7 +1136,7 @@
                 </sizepolicy>
                </property>
                <property name="title">
-                <string>Paramètres PulseAudio</string>
+                <string>PulseAudio settings</string>
                </property>
                <layout class="QFormLayout" name="formLayout_11">
                 <property name="fieldGrowthPolicy">
@@ -1145,7 +1145,7 @@
                 <item row="0" column="0">
                  <widget class="QCheckBox" name="checkBox_pulseAudioVolumeAlter">
                   <property name="text">
-                   <string>Autoriser à &amp;modifier le volume des autres applications</string>
+                   <string>Mute other applications during a call</string>
                   </property>
                  </widget>
                 </item>
diff --git a/sflphone-client-kde/src/ui/sflphone_kdeview_base.ui b/sflphone-client-kde/src/ui/sflphone_kdeview_base.ui
index 492893ebb3..af9119a07d 100644
--- a/sflphone-client-kde/src/ui/sflphone_kdeview_base.ui
+++ b/sflphone-client-kde/src/ui/sflphone_kdeview_base.ui
@@ -6,8 +6,8 @@
    <rect>
     <x>0</x>
     <y>0</y>
-    <width>655</width>
-    <height>487</height>
+    <width>337</width>
+    <height>411</height>
    </rect>
   </property>
   <property name="windowTitle">
@@ -174,6 +174,12 @@
              <verstretch>0</verstretch>
             </sizepolicy>
            </property>
+           <property name="minimumSize">
+            <size>
+             <width>0</width>
+             <height>0</height>
+            </size>
+           </property>
            <property name="text">
             <string>1</string>
            </property>
@@ -187,8 +193,15 @@
              <verstretch>0</verstretch>
             </sizepolicy>
            </property>
+           <property name="minimumSize">
+            <size>
+             <width>0</width>
+             <height>0</height>
+            </size>
+           </property>
            <property name="text">
-            <string>2</string>
+            <string>2
+abc</string>
            </property>
            <property name="shortcut">
             <string>2</string>
@@ -204,7 +217,8 @@
             </sizepolicy>
            </property>
            <property name="text">
-            <string>3</string>
+            <string>3
+def</string>
            </property>
           </widget>
          </item>
@@ -217,7 +231,8 @@
             </sizepolicy>
            </property>
            <property name="text">
-            <string>4</string>
+            <string>4
+ghi</string>
            </property>
           </widget>
          </item>
@@ -230,7 +245,8 @@
             </sizepolicy>
            </property>
            <property name="text">
-            <string>5</string>
+            <string>5
+jkl</string>
            </property>
           </widget>
          </item>
@@ -243,7 +259,8 @@
             </sizepolicy>
            </property>
            <property name="text">
-            <string>6</string>
+            <string>6
+mno</string>
            </property>
           </widget>
          </item>
@@ -256,7 +273,8 @@
             </sizepolicy>
            </property>
            <property name="text">
-            <string>7</string>
+            <string>7
+pqrs</string>
            </property>
           </widget>
          </item>
@@ -269,7 +287,8 @@
             </sizepolicy>
            </property>
            <property name="text">
-            <string>8</string>
+            <string>8
+tuv</string>
            </property>
           </widget>
          </item>
@@ -282,7 +301,8 @@
             </sizepolicy>
            </property>
            <property name="text">
-            <string>9</string>
+            <string>9
+wxyz</string>
            </property>
           </widget>
          </item>
@@ -308,7 +328,8 @@
             </sizepolicy>
            </property>
            <property name="text">
-            <string>0</string>
+            <string>0
+</string>
            </property>
           </widget>
          </item>
@@ -463,7 +484,7 @@
   </layout>
   <action name="action_accept">
    <property name="icon">
-    <iconset resource="resources.qrc">
+    <iconset resource="../qrc/resources.qrc">
      <normaloff>:/images/icons/call.svg</normaloff>:/images/icons/call.svg</iconset>
    </property>
    <property name="text">
@@ -472,7 +493,7 @@
   </action>
   <action name="action_refuse">
    <property name="icon">
-    <iconset resource="resources.qrc">
+    <iconset resource="../qrc/resources.qrc">
      <normaloff>:/images/icons/hang_up.svg</normaloff>:/images/icons/hang_up.svg</iconset>
    </property>
    <property name="text">
@@ -481,7 +502,7 @@
   </action>
   <action name="action_hold">
    <property name="icon">
-    <iconset resource="resources.qrc">
+    <iconset resource="../qrc/resources.qrc">
      <normaloff>:/images/icons/hold.svg</normaloff>:/images/icons/hold.svg</iconset>
    </property>
    <property name="text">
@@ -493,7 +514,7 @@
     <bool>true</bool>
    </property>
    <property name="icon">
-    <iconset resource="resources.qrc">
+    <iconset resource="../qrc/resources.qrc">
      <normaloff>:/images/icons/transfert.svg</normaloff>:/images/icons/transfert.svg</iconset>
    </property>
    <property name="text">
@@ -505,7 +526,7 @@
     <bool>true</bool>
    </property>
    <property name="icon">
-    <iconset resource="resources.qrc">
+    <iconset resource="../qrc/resources.qrc">
      <normaloff>:/images/icons/history2.svg</normaloff>:/images/icons/history2.svg</iconset>
    </property>
    <property name="text">
@@ -514,7 +535,7 @@
   </action>
   <action name="action_mailBox">
    <property name="icon">
-    <iconset resource="resources.qrc">
+    <iconset resource="../qrc/resources.qrc">
      <normaloff>:/images/icons/mailbox.svg</normaloff>:/images/icons/mailbox.svg</iconset>
    </property>
    <property name="text">
@@ -523,7 +544,7 @@
   </action>
   <action name="action_configureAccounts">
    <property name="icon">
-    <iconset resource="resources.qrc">
+    <iconset resource="../qrc/resources.qrc">
      <normaloff>:/images/icons/stock_person.svg</normaloff>:/images/icons/stock_person.svg</iconset>
    </property>
    <property name="text">
@@ -532,7 +553,7 @@
   </action>
   <action name="action_configureAudio">
    <property name="icon">
-    <iconset resource="resources.qrc">
+    <iconset resource="../qrc/resources.qrc">
      <normaloff>:/images/icons/icon_volume.svg</normaloff>:/images/icons/icon_volume.svg</iconset>
    </property>
    <property name="text">
@@ -541,7 +562,7 @@
   </action>
   <action name="action_configureSflPhone">
    <property name="icon">
-    <iconset resource="resources.qrc">
+    <iconset resource="../qrc/resources.qrc">
      <normaloff>:/images/icons/sflphone.svg</normaloff>:/images/icons/sflphone.svg</iconset>
    </property>
    <property name="text">
@@ -556,7 +577,7 @@
     <bool>true</bool>
    </property>
    <property name="icon">
-    <iconset resource="resources.qrc">
+    <iconset resource="../qrc/resources.qrc">
      <normaloff>:/images/icons/icon_volume_off.svg</normaloff>:/images/icons/icon_volume_off.svg</iconset>
    </property>
    <property name="text">
@@ -576,7 +597,7 @@
     <bool>true</bool>
    </property>
    <property name="icon">
-    <iconset resource="resources.qrc">
+    <iconset resource="../qrc/resources.qrc">
      <normaloff>:/images/icons/icon_dialpad.svg</normaloff>:/images/icons/icon_dialpad.svg</iconset>
    </property>
    <property name="text">
@@ -588,7 +609,7 @@
     <bool>true</bool>
    </property>
    <property name="icon">
-    <iconset resource="resources.qrc">
+    <iconset>
      <normaloff>:/images/icons/del_off.png</normaloff>:/images/icons/del_off.png</iconset>
    </property>
    <property name="text">
@@ -605,7 +626,7 @@
     <bool>true</bool>
    </property>
    <property name="icon">
-    <iconset resource="resources.qrc">
+    <iconset resource="../qrc/resources.qrc">
      <normaloff>:/images/icons/x-office-address-book.png</normaloff>:/images/icons/x-office-address-book.png</iconset>
    </property>
    <property name="text">
@@ -614,7 +635,7 @@
   </action>
  </widget>
  <resources>
-  <include location="resources.qrc"/>
+  <include location="../qrc/resources.qrc"/>
  </resources>
  <connections>
   <connection>
diff --git a/tools/build-system/distributions/ubuntu/debian-sflphone-client-kde/postinst b/tools/build-system/distributions/ubuntu/debian-sflphone-client-kde/postinst
index 4598415bee..20a15b4f8f 100644
--- a/tools/build-system/distributions/ubuntu/debian-sflphone-client-kde/postinst
+++ b/tools/build-system/distributions/ubuntu/debian-sflphone-client-kde/postinst
@@ -4,6 +4,6 @@ update-alternatives --install /usr/bin/sflphone sflphone /usr/bin/sflphone-clien
                     --slave /usr/share/man/man1/sflphone.1.gz  sflphone.1.gz \
                             /usr/share/man/man1/sflphone-client-kde.1
                             
-# update-alternatives --set sflphone /usr/bin/sflphone-client-kde
+update-alternatives --set sflphone /usr/bin/sflphone-client-kde
 
 exit 0
-- 
GitLab