QTfrontend/hwform.cpp
changeset 7313 162bc562335b
parent 7122 fa2d09868ac6
child 7347 88685fbb2679
child 7411 efc75c2d3be9
child 7551 c212247065e3
equal deleted inserted replaced
7311:06b31a1b333c 7313:162bc562335b
   126 #ifdef USE_XFIRE
   126 #ifdef USE_XFIRE
   127     xfire_init();
   127     xfire_init();
   128 #endif
   128 #endif
   129     gameSettings = new QSettings(cfgdir->absolutePath() + "/hedgewars.ini", QSettings::IniFormat);
   129     gameSettings = new QSettings(cfgdir->absolutePath() + "/hedgewars.ini", QSettings::IniFormat);
   130     frontendEffects = gameSettings->value("frontend/effects", true).toBool();
   130     frontendEffects = gameSettings->value("frontend/effects", true).toBool();
   131     playerHash = QString(QCryptographicHash::hash(gameSettings->value("net/nick","").toString().toLatin1(), QCryptographicHash::Md5).toHex());
   131     playerHash = QString(QCryptographicHash::hash(gameSettings->value("net/nick","").toString().toUtf8(), QCryptographicHash::Md5).toHex());
   132 
   132 
   133     this->setStyleSheet(styleSheet);
   133     this->setStyleSheet(styleSheet);
   134     ui.setupUi(this);
   134     ui.setupUi(this);
   135     setMinimumSize(760, 580);
   135     setMinimumSize(760, 580);
   136     //setFocusPolicy(Qt::StrongFocus);
   136     //setFocusPolicy(Qt::StrongFocus);
   966             delete hpd;
   966             delete hpd;
   967             return;
   967             return;
   968         }
   968         }
   969 
   969 
   970         QString password = hpd->lePassword->text();
   970         QString password = hpd->lePassword->text();
   971         hash = QCryptographicHash::hash(password.toLatin1(), QCryptographicHash::Md5).toHex();
   971         hash = QCryptographicHash::hash(password.toUtf8(), QCryptographicHash::Md5).toHex();
   972 
   972 
   973         bool save = hpd->cbSave->isChecked();
   973         bool save = hpd->cbSave->isChecked();
   974         config->setValue("net/savepassword", save);
   974         config->setValue("net/savepassword", save);
   975         if (save) // user wants to save password
   975         if (save) // user wants to save password
   976         {
   976         {