48 Form->ui.pageOptions->CBFrontendEffects->setChecked(frontendEffects); |
49 Form->ui.pageOptions->CBFrontendEffects->setChecked(frontendEffects); |
49 Form->ui.pageOptions->CBEnableSound->setChecked(value("audio/sound", true).toBool()); |
50 Form->ui.pageOptions->CBEnableSound->setChecked(value("audio/sound", true).toBool()); |
50 Form->ui.pageOptions->CBEnableMusic->setChecked(value("audio/music", true).toBool()); |
51 Form->ui.pageOptions->CBEnableMusic->setChecked(value("audio/music", true).toBool()); |
51 Form->ui.pageOptions->volumeBox->setValue(value("audio/volume", 100).toUInt()); |
52 Form->ui.pageOptions->volumeBox->setValue(value("audio/volume", 100).toUInt()); |
52 |
53 |
53 Form->ui.pageOptions->editNetNick->setText(value("net/nick", QLineEdit::tr("unnamed")).toString()); |
54 QString netNick = value("net/nick", "").toString(); |
|
55 if (netNick.isEmpty()) |
|
56 netNick = QInputDialog::getText(Form, |
|
57 QObject::tr("Nickname"), |
|
58 QObject::tr("Please, enter your nickname"), |
|
59 QLineEdit::Normal, |
|
60 QDir::home().dirName()); |
|
61 |
|
62 Form->ui.pageOptions->editNetNick->setText(netNick); |
54 |
63 |
55 delete netHost; |
64 delete netHost; |
56 netHost = new QString(value("net/ip", "").toString()); |
65 netHost = new QString(value("net/ip", "").toString()); |
57 netPort = value("net/port", 46631).toUInt(); |
66 netPort = value("net/port", 46631).toUInt(); |
58 |
67 |