void AccountsManager::AddAccountImpl (Account_ptr account) { Accounts_ << account; const QList<QStandardItem*> row { new QStandardItem { account->GetName () }, new QStandardItem { account->GetServer () } }; AccountsModel_->appendRow (row); connect (account.get (), SIGNAL (accountChanged ()), this, SLOT (saveAccounts ())); connect (account->GetFolderManager (), SIGNAL (foldersUpdated ()), this, SLOT (saveAccounts ())); }
void Core::AddAccountImpl (Account_ptr account) { Accounts_ << account; QList<QStandardItem*> row; row << new QStandardItem (account->GetName ()); row << new QStandardItem (account->GetServer ()); row << new QStandardItem (account->GetType ()); AccountsModel_->appendRow (row); ProgressManager_->AddAccount (account.get ()); connect (account.get (), SIGNAL (accountChanged ()), this, SLOT (saveAccounts ())); connect (account->GetFolderManager (), SIGNAL (foldersUpdated ()), this, SLOT (saveAccounts ())); }