src/hbservers/hbsplashgenerator/hbsplashgenerator.cpp
changeset 7 923ff622b8b9
parent 5 627c4a0fd0e7
child 21 4633027730f5
child 34 ed14f46c0e55
equal deleted inserted replaced
6:c3690ec91ef8 7:923ff622b8b9
    72     CCoeEnv::Static()->FsSession().CreatePrivatePath(EDriveC);
    72     CCoeEnv::Static()->FsSession().CreatePrivatePath(EDriveC);
    73     QString iniFileName = QString("c:/private/%1/hbsplashgen.ini")
    73     QString iniFileName = QString("c:/private/%1/hbsplashgen.ini")
    74                           .arg(QString::number(hbsplash_server_uid3.iUid, 16));
    74                           .arg(QString::number(hbsplash_server_uid3.iUid, 16));
    75     mSettings = new QSettings(iniFileName, QSettings::IniFormat, this);
    75     mSettings = new QSettings(iniFileName, QSettings::IniFormat, this);
    76 #else
    76 #else
    77     mSettings = new QSettings("Nokia", "HbSplash", this);
    77     mSettings = new QSettings("Nokia", "Hb", this);
       
    78     mSettings->beginGroup("Splash");
    78 #endif
    79 #endif
    79     // Effects on decorators (started when they are shown) would ruin
    80     // Effects on decorators (started when they are shown) would ruin
    80     // the screenshot. So disable everything (except the orientation
    81     // the screenshot. So disable everything (except the orientation
    81     // switch effect which is needed for a proper rotated image).
    82     // switch effect which is needed for a proper rotated image).
    82     HbEffectInternal::setEffectsEnabled(false);
    83     HbEffectInternal::setEffectsEnabled(false);
   156     QString currentOutputDir = hbsplash_output_dir();
   157     QString currentOutputDir = hbsplash_output_dir();
   157     int currentFileCount = updateOutputDirContents(currentOutputDir);
   158     int currentFileCount = updateOutputDirContents(currentOutputDir);
   158     qDebug() << PRE << "last regen:" << lastTheme << lastLang << lastFileCount << lastOutputDir
   159     qDebug() << PRE << "last regen:" << lastTheme << lastLang << lastFileCount << lastOutputDir
   159              << "current:" << currentTheme << currentLang << currentFileCount << currentOutputDir;
   160              << "current:" << currentTheme << currentLang << currentFileCount << currentOutputDir;
   160     if (mForceRegen
   161     if (mForceRegen
       
   162             || currentFileCount == 0 // not having any files is wrong for sure
   161             || currentTheme != lastTheme
   163             || currentTheme != lastTheme
   162             || currentLang != lastLang
   164             || currentLang != lastLang
   163             || currentFileCount != lastFileCount
   165             || currentFileCount != lastFileCount
   164             || currentOutputDir != lastOutputDir) {
   166             || currentOutputDir != lastOutputDir) {
   165         QMetaObject::invokeMethod(this, "regenerate", Qt::QueuedConnection);
   167         QMetaObject::invokeMethod(this, "regenerate", Qt::QueuedConnection);