mirror of
https://github.com/PrismLauncher/PrismLauncher.git
synced 2026-07-06 05:16:59 +03:00
Implement loading accounts from list.
This commit is contained in:
parent
cdca530139
commit
a9a0b65358
7 changed files with 141 additions and 7 deletions
|
|
@ -23,13 +23,16 @@
|
|||
#include <gui/dialogs/LoginDialog.h>
|
||||
#include <gui/dialogs/ProgressDialog.h>
|
||||
|
||||
#include <MultiMC.h>
|
||||
|
||||
AccountListDialog::AccountListDialog(QWidget *parent) :
|
||||
QDialog(parent),
|
||||
ui(new Ui::AccountListDialog)
|
||||
{
|
||||
ui->setupUi(this);
|
||||
|
||||
ui->listView->setModel(&m_accounts);
|
||||
m_accounts = MMC->accounts();
|
||||
ui->listView->setModel(m_accounts.get());
|
||||
}
|
||||
|
||||
AccountListDialog::~AccountListDialog()
|
||||
|
|
@ -84,7 +87,7 @@ void AccountListDialog::onLoginComplete()
|
|||
{
|
||||
// Add the authenticated account to the accounts list.
|
||||
MojangAccountPtr account = m_authTask->getMojangAccount();
|
||||
m_accounts.addAccount(account);
|
||||
m_accounts->addAccount(account);
|
||||
//ui->listView->update();
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue