QTfrontend/gameuiconfig.cpp
changeset 5390 f41e87de8989
parent 5262 505a90cfa377
child 6583 4218782d8ca0
--- a/QTfrontend/gameuiconfig.cpp	Mon Jul 04 10:26:16 2011 +0400
+++ b/QTfrontend/gameuiconfig.cpp	Mon Jul 04 12:28:58 2011 +0200
@@ -66,13 +66,6 @@
     Form->ui.pageOptions->volumeBox->setValue(value("audio/volume", 100).toUInt());
 
     QString netNick = value("net/nick", "").toString();
-    if (netNick.isEmpty())
-        netNick = QInputDialog::getText(Form,
-                QObject::tr("Nickname"),
-                QObject::tr("Please enter your nickname"),
-                QLineEdit::Normal,
-                QDir::home().dirName());
-
     Form->ui.pageOptions->editNetNick->setText(netNick);
     
     Form->ui.pageOptions->editNetPassword->installEventFilter(this);
@@ -314,6 +307,11 @@
     return Form->ui.pageOptions->editNetNick->text();
 }
 
+void GameUIConfig::updNetNick()
+{
+    Form->ui.pageOptions->editNetNick->setText(value("net/nick", "").toString());
+}
+
 QByteArray GameUIConfig::netPasswordHash()
 {
     return QCryptographicHash::hash(Form->ui.pageOptions->editNetPassword->text().toLatin1(), QCryptographicHash::Md5).toHex();