forked from blue/squawk
minor fixes, form to join MUC
This commit is contained in:
parent
5f8d38bd9a
commit
c295fa1c1d
23 changed files with 385 additions and 34 deletions
|
@ -90,15 +90,17 @@ void Models::Accounts::addAccount(Account* account)
|
|||
|
||||
void Models::Accounts::onAccountChanged(Item* item, int row, int col)
|
||||
{
|
||||
Account* acc = getAccount(row);
|
||||
if (item != acc) {
|
||||
return; //it means the signal is emitted by one of accounts' children, not exactly him, this model has no interest in that
|
||||
if (row < accs.size()) {
|
||||
Account* acc = getAccount(row);
|
||||
if (item != acc) {
|
||||
return; //it means the signal is emitted by one of accounts' children, not exactly him, this model has no interest in that
|
||||
}
|
||||
|
||||
if (col < columnCount(QModelIndex())) {
|
||||
emit dataChanged(createIndex(row, col, this), createIndex(row, col, this));
|
||||
}
|
||||
emit changed();
|
||||
}
|
||||
|
||||
if (col < columnCount(QModelIndex())) {
|
||||
emit dataChanged(createIndex(row, col, this), createIndex(row, col, this));
|
||||
}
|
||||
emit changed();
|
||||
}
|
||||
|
||||
Models::Account * Models::Accounts::getAccount(int index)
|
||||
|
|
|
@ -153,7 +153,7 @@ QVariant Models::Roster::data (const QModelIndex& index, int role) const
|
|||
if (mc > 0) {
|
||||
str += QString("New messages: ") + std::to_string(mc).c_str() + "\n";
|
||||
}
|
||||
str += "Jabber ID: " + contact->getJid();
|
||||
str += "Jabber ID: " + contact->getJid() + "\n";
|
||||
Shared::SubscriptionState ss = contact->getState();
|
||||
if (ss == Shared::both) {
|
||||
Shared::Availability av = contact->getAvailability();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue