Skip to content
Snippets Groups Projects
Commit 033b458d authored by Jérémy Quentin's avatar Jérémy Quentin
Browse files

[#1551] remove default mailbox number in wizard and disable mailbox button...

[#1551] remove default mailbox number in wizard and disable mailbox button when first account doesn't have mailbox number
[#1552] record icon on calls behaves an inverted way (active when not recording)
[#1553] account up, down, add and remove buttons should enable Apply button
parent ea764170
No related branches found
No related tags found
No related merge requests found
...@@ -233,7 +233,7 @@ void AccountWizard::accept() ...@@ -233,7 +233,7 @@ void AccountWizard::accept()
} }
if(createAccount) if(createAccount)
{ {
mailbox = ACCOUNT_MAILBOX_DEFAULT_VALUE; // mailbox = ACCOUNT_MAILBOX_DEFAULT_VALUE;
enabled = ACCOUNT_ENABLED_TRUE; enabled = ACCOUNT_ENABLED_TRUE;
ConfigurationManagerInterface & configurationManager = ConfigurationManagerInterfaceSingleton::getInstance(); ConfigurationManagerInterface & configurationManager = ConfigurationManagerInterfaceSingleton::getInstance();
QString accountId = configurationManager.addAccount(accountDetails); QString accountId = configurationManager.addAccount(accountDetails);
......
...@@ -530,9 +530,10 @@ void Call::switchRecord() ...@@ -530,9 +530,10 @@ void Call::switchRecord()
void Call::setRecord() void Call::setRecord()
{ {
CallManagerInterface & callManager = CallManagerInterfaceSingleton::getInstance(); CallManagerInterface & callManager = CallManagerInterfaceSingleton::getInstance();
qDebug() << "Setting record for call. callId : " << callId; qDebug() << "Setting record " << !recording << " for call. callId : " << callId;
callManager.setRecording(callId); callManager.setRecording(callId);
recording = !recording; recording = !recording;
updateItem();
} }
void Call::start() void Call::start()
...@@ -622,7 +623,7 @@ void Call::updateItem() ...@@ -622,7 +623,7 @@ void Call::updateItem()
setItemIcon(ICON_CURRENT_REC); setItemIcon(ICON_CURRENT_REC);
else else
{ {
QString str(callStateIcons[currentState]); QString str = QString(callStateIcons[currentState]);
setItemIcon(str); setItemIcon(str);
} }
bool transfer = currentState == CALL_STATE_TRANSFER || currentState == CALL_STATE_TRANSF_HOLD; bool transfer = currentState == CALL_STATE_TRANSFER || currentState == CALL_STATE_TRANSF_HOLD;
......
...@@ -678,6 +678,7 @@ void ConfigurationDialog::on_button_accountUp_clicked() ...@@ -678,6 +678,7 @@ void ConfigurationDialog::on_button_accountUp_clicked()
listWidget_accountList->insertItem(currentRow - 1 , item); listWidget_accountList->insertItem(currentRow - 1 , item);
listWidget_accountList->setItemWidget(item, widget); listWidget_accountList->setItemWidget(item, widget);
listWidget_accountList->setCurrentItem(item); listWidget_accountList->setCurrentItem(item);
changedAccountList();
} }
void ConfigurationDialog::on_button_accountDown_clicked() void ConfigurationDialog::on_button_accountDown_clicked()
...@@ -694,6 +695,7 @@ void ConfigurationDialog::on_button_accountDown_clicked() ...@@ -694,6 +695,7 @@ void ConfigurationDialog::on_button_accountDown_clicked()
listWidget_accountList->insertItem(currentRow + 1 , item); listWidget_accountList->insertItem(currentRow + 1 , item);
listWidget_accountList->setItemWidget(item, widget); listWidget_accountList->setItemWidget(item, widget);
listWidget_accountList->setCurrentItem(item); listWidget_accountList->setCurrentItem(item);
changedAccountList();
} }
void ConfigurationDialog::on_button_accountAdd_clicked() void ConfigurationDialog::on_button_accountAdd_clicked()
...@@ -708,6 +710,7 @@ void ConfigurationDialog::on_button_accountAdd_clicked() ...@@ -708,6 +710,7 @@ void ConfigurationDialog::on_button_accountAdd_clicked()
listWidget_accountList->setCurrentRow(r); listWidget_accountList->setCurrentRow(r);
frame2_editAccounts->setEnabled(true); frame2_editAccounts->setEnabled(true);
} }
changedAccountList();
} }
void ConfigurationDialog::on_button_accountRemove_clicked() void ConfigurationDialog::on_button_accountRemove_clicked()
...@@ -717,6 +720,7 @@ void ConfigurationDialog::on_button_accountRemove_clicked() ...@@ -717,6 +720,7 @@ void ConfigurationDialog::on_button_accountRemove_clicked()
QListWidgetItem * item = listWidget_accountList->takeItem(r); QListWidgetItem * item = listWidget_accountList->takeItem(r);
accountList->removeAccount(item); accountList->removeAccount(item);
listWidget_accountList->setCurrentRow( (r >= listWidget_accountList->count()) ? r-1 : r ); listWidget_accountList->setCurrentRow( (r >= listWidget_accountList->count()) ? r-1 : r );
changedAccountList();
} }
void ConfigurationDialog::on_toolButton_accountsApply_clicked() void ConfigurationDialog::on_toolButton_accountsApply_clicked()
......
...@@ -159,23 +159,13 @@ void sflphone_kdeView::addCallToCallList(Call * call) ...@@ -159,23 +159,13 @@ void sflphone_kdeView::addCallToCallList(Call * call)
void sflphone_kdeView::addCallToCallHistory(Call * call) void sflphone_kdeView::addCallToCallHistory(Call * call)
{ {
qDebug() << "addCallToCallHistory1";
QListWidgetItem * item = call->getHistoryItem(); QListWidgetItem * item = call->getHistoryItem();
qDebug() << "addCallToCallHistory2";
QWidget * widget = call->getHistoryItemWidget(); QWidget * widget = call->getHistoryItemWidget();
qDebug() << "addCallToCallHistory3";
if(item && widget) if(item && widget)
{ {
qDebug() << "addCallToCallHistory4";
listWidget_callHistory->addItem(item); listWidget_callHistory->addItem(item);
qDebug() << "addCallToCallHistory5";
qDebug() << "item = " << item;
qDebug() << "widget = " << widget;
qDebug() << "itemWidget(item) = " << listWidget_callHistory->itemWidget(item);
listWidget_callHistory->setItemWidget(item, widget); listWidget_callHistory->setItemWidget(item, widget);
qDebug() << "addCallToCallHistory6";
} }
qDebug() << "addCallToCallHistory7";
} }
void sflphone_kdeView::addContactToContactList(Contact * contact) void sflphone_kdeView::addContactToContactList(Contact * contact)
...@@ -417,7 +407,7 @@ void sflphone_kdeView::updateWindowCallState() ...@@ -417,7 +407,7 @@ void sflphone_kdeView::updateWindowCallState()
bool recordActivated = false; bool recordActivated = false;
//tells whether the call can be recorded in the state it is right now //tells whether the call can be recorded in the state it is right now
bool recordEnabled = false; bool recordEnabled = false;
enabledActions[5] = ! firstRegisteredAccount()->getAccountDetail(ACCOUNT_MAILBOX).isempty();
if(stackedWidget_screen->currentWidget() == page_callList) if(stackedWidget_screen->currentWidget() == page_callList)
{ {
item = listWidget_callList->currentItem(); item = listWidget_callList->currentItem();
...@@ -561,6 +551,7 @@ void sflphone_kdeView::updateWindowCallState() ...@@ -561,6 +551,7 @@ void sflphone_kdeView::updateWindowCallState()
enabledActions[1] = true; enabledActions[1] = true;
} }
} }
action_accept->setEnabled(enabledActions[0]); action_accept->setEnabled(enabledActions[0]);
action_refuse->setEnabled(enabledActions[1]); action_refuse->setEnabled(enabledActions[1]);
action_hold->setEnabled(enabledActions[2]); action_hold->setEnabled(enabledActions[2]);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment