Skip to content
Snippets Groups Projects
Commit 97c4c2dc authored by Olivier SOLDANO's avatar Olivier SOLDANO Committed by Anthony Léonard
Browse files

manage case of no account enabled for searchbar


hides the search bar in case of the user has disabled all
its accounts to avoid the case that searching anything
makes it a SIP contact method.

It also clears the ID field displayed in the welcome page.

Change-Id: I86e299a7dc35f65f8dc05761cd1afecb3f9d84c2
Reviewed-by: default avatarAnthony Léonard <anthony.leonard@savoirfairelinux.com>
parent 9b7e80d9
Branches
No related tags found
No related merge requests found
...@@ -690,6 +690,9 @@ CallWidget::selectedAccountChanged(const QModelIndex &current, const QModelIndex ...@@ -690,6 +690,9 @@ CallWidget::selectedAccountChanged(const QModelIndex &current, const QModelIndex
Q_UNUSED(previous) Q_UNUSED(previous)
if (current.isValid()) { if (current.isValid()) {
if (ui->selectBar->isHidden()){
ui->selectBar->show();
}
auto ac = current.data(static_cast<int>(Account::Role::Object)).value<Account*>(); auto ac = current.data(static_cast<int>(Account::Role::Object)).value<Account*>();
// First, we get back to the welcome view (except if in call) // First, we get back to the welcome view (except if in call)
...@@ -729,6 +732,9 @@ CallWidget::selectedAccountChanged(const QModelIndex &current, const QModelIndex ...@@ -729,6 +732,9 @@ CallWidget::selectedAccountChanged(const QModelIndex &current, const QModelIndex
// keep call on foreground // keep call on foreground
callStateToView(actualCall_); callStateToView(actualCall_);
} }
} else {
ui->selectBar->hide();
ui->ringIdLabel->setText("");
} }
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment