- : SettingsPage(tr("IRC"), tr("Identities"), parent),
- _editSsl(false)
+ : SettingsPage(tr("IRC"), tr("Identities"), parent)
- ui.renameIdentity->setIcon(BarIcon("edit-rename"));
- ui.addIdentity->setIcon(BarIcon("list-add-user"));
- ui.deleteIdentity->setIcon(BarIcon("list-remove-user"));
+ ui.renameIdentity->setIcon(icon::get("edit-rename"));
+ ui.addIdentity->setIcon(icon::get("list-add-user"));
+ ui.deleteIdentity->setIcon(icon::get("list-remove-user"));
coreConnectionStateChanged(Client::isConnected()); // need a core connection!
connect(Client::instance(), SIGNAL(coreConnectionStateChanged(bool)), this, SLOT(coreConnectionStateChanged(bool)));
coreConnectionStateChanged(Client::isConnected()); // need a core connection!
connect(Client::instance(), SIGNAL(coreConnectionStateChanged(bool)), this, SLOT(coreConnectionStateChanged(bool)));
if (currentId != 0) {
changedIdentities.removeAll(currentId);
CertIdentity temp(currentId, this);
if (currentId != 0) {
changedIdentities.removeAll(currentId);
CertIdentity temp(currentId, this);
// we need to set the cert and key manually, as they aren't synced
CertIdentity *old = identities[currentId];
temp.setSslKey(old->sslKey());
temp.setSslCert(old->sslCert());
// we need to set the cert and key manually, as they aren't synced
CertIdentity *old = identities[currentId];
temp.setSslKey(old->sslKey());
temp.setSslCert(old->sslCert());
ui.identityEditor->saveToIdentity(&temp);
temp.setIdentityName(identities[currentId]->identityName());
if (temp != *Client::identity(currentId) || temp.isDirty())
ui.identityEditor->saveToIdentity(&temp);
temp.setIdentityName(identities[currentId]->identityName());
if (temp != *Client::identity(currentId) || temp.isDirty())
if (currentId != 0 && identities.contains(currentId))
previousIdentity = identities[currentId];
if (index < 0) {
//ui.identityList->setEditable(false);
if (currentId != 0 && identities.contains(currentId))
previousIdentity = identities[currentId];
if (index < 0) {
//ui.identityList->setEditable(false);
-NickEditDlg::NickEditDlg(const QString &old, const QStringList &exist, QWidget *parent)
- : QDialog(parent), oldNick(old), existing(exist)
+NickEditDlg::NickEditDlg(const QString &old, QStringList exist, QWidget *parent)
+ : QDialog(parent), oldNick(old), existing(std::move(exist))
{
ui.setupUi(this);
// define a regexp for valid nicknames
// TODO: add max nicklength according to ISUPPORT
QString letter = "A-Za-z";
{
ui.setupUi(this);
// define a regexp for valid nicknames
// TODO: add max nicklength according to ISUPPORT
QString letter = "A-Za-z";
QRegExp rx(QString("[%1%2][%1%2\\d-]*").arg(letter, special));
ui.nickEdit->setValidator(new QRegExpValidator(rx, ui.nickEdit));
if (old.isEmpty()) {
QRegExp rx(QString("[%1%2][%1%2\\d-]*").arg(letter, special));
ui.nickEdit->setValidator(new QRegExpValidator(rx, ui.nickEdit));
if (old.isEmpty()) {