Now using a separate version/build number for the configuration, so INI settings don't get invalidated with each build.
This commit is contained in:
parent
614fbfac54
commit
c2db2acd20
@ -1,7 +1,8 @@
|
|||||||
// Microsoft Visual C++ generated resource script.
|
// Microsoft Visual C++ generated resource script.
|
||||||
//
|
//
|
||||||
#include "src/Resource.h"
|
#define LAMEXP_INC_CONFIG
|
||||||
#include "src/Config.h"
|
#include "src/Config.h"
|
||||||
|
#include "src/Resource.h"
|
||||||
|
|
||||||
#define APSTUDIO_READONLY_SYMBOLS
|
#define APSTUDIO_READONLY_SYMBOLS
|
||||||
/////////////////////////////////////////////////////////////////////////////
|
/////////////////////////////////////////////////////////////////////////////
|
||||||
|
11
src/Config.h
11
src/Config.h
@ -21,16 +21,21 @@
|
|||||||
|
|
||||||
#pragma once
|
#pragma once
|
||||||
|
|
||||||
|
#ifndef LAMEXP_INC_CONFIG
|
||||||
|
#error Please do *not* include CONFIG.H directly!
|
||||||
|
#endif
|
||||||
|
|
||||||
///////////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
// LameXP Version Info
|
// LameXP Version Info
|
||||||
///////////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
#define VER_LAMEXP_MAJOR 4
|
#define VER_LAMEXP_MAJOR 4
|
||||||
#define VER_LAMEXP_MINOR_HI 0
|
#define VER_LAMEXP_MINOR_HI 0
|
||||||
#define VER_LAMEXP_MINOR_LO 7
|
#define VER_LAMEXP_MINOR_LO 8
|
||||||
#define VER_LAMEXP_TYPE Final
|
#define VER_LAMEXP_TYPE Alpha
|
||||||
#define VER_LAMEXP_PATCH 1
|
#define VER_LAMEXP_PATCH 1
|
||||||
#define VER_LAMEXP_BUILD 1286
|
#define VER_LAMEXP_BUILD 1288
|
||||||
|
#define VER_LAMEXP_CONFG 1288
|
||||||
|
|
||||||
///////////////////////////////////////////////////////////////////////////////
|
///////////////////////////////////////////////////////////////////////////////
|
||||||
// LameXP Build Options
|
// LameXP Build Options
|
||||||
|
@ -50,6 +50,7 @@
|
|||||||
#include <QWriteLocker>
|
#include <QWriteLocker>
|
||||||
|
|
||||||
//LameXP includes
|
//LameXP includes
|
||||||
|
#define LAMEXP_INC_CONFIG
|
||||||
#include "Resource.h"
|
#include "Resource.h"
|
||||||
#include "Config.h"
|
#include "Config.h"
|
||||||
#include "LockedFile.h"
|
#include "LockedFile.h"
|
||||||
@ -124,14 +125,16 @@ static const struct
|
|||||||
unsigned int ver_major;
|
unsigned int ver_major;
|
||||||
unsigned int ver_minor;
|
unsigned int ver_minor;
|
||||||
unsigned int ver_build;
|
unsigned int ver_build;
|
||||||
|
unsigned int ver_confg;
|
||||||
char *ver_release_name;
|
char *ver_release_name;
|
||||||
}
|
}
|
||||||
g_lamexp_version =
|
g_lamexp_version =
|
||||||
{
|
{
|
||||||
VER_LAMEXP_MAJOR,
|
VER_LAMEXP_MAJOR,
|
||||||
VER_LAMEXP_MINOR,
|
(10 * VER_LAMEXP_MINOR_HI) + VER_LAMEXP_MINOR_LO,
|
||||||
VER_LAMEXP_BUILD,
|
VER_LAMEXP_BUILD,
|
||||||
VER_LAMEXP_RNAME
|
VER_LAMEXP_CONFG,
|
||||||
|
VER_LAMEXP_RNAME,
|
||||||
};
|
};
|
||||||
|
|
||||||
//Build date
|
//Build date
|
||||||
@ -349,6 +352,7 @@ const char* LAMEXP_DEFAULT_TRANSLATION = "LameXP_EN.qm";
|
|||||||
unsigned int lamexp_version_major(void) { return g_lamexp_version.ver_major; }
|
unsigned int lamexp_version_major(void) { return g_lamexp_version.ver_major; }
|
||||||
unsigned int lamexp_version_minor(void) { return g_lamexp_version.ver_minor; }
|
unsigned int lamexp_version_minor(void) { return g_lamexp_version.ver_minor; }
|
||||||
unsigned int lamexp_version_build(void) { return g_lamexp_version.ver_build; }
|
unsigned int lamexp_version_build(void) { return g_lamexp_version.ver_build; }
|
||||||
|
unsigned int lamexp_version_confg(void) { return g_lamexp_version.ver_confg; }
|
||||||
const char *lamexp_version_release(void) { return g_lamexp_version.ver_release_name; }
|
const char *lamexp_version_release(void) { return g_lamexp_version.ver_release_name; }
|
||||||
const char *lamexp_version_time(void) { return g_lamexp_version_raw_time; }
|
const char *lamexp_version_time(void) { return g_lamexp_version_raw_time; }
|
||||||
const char *lamexp_version_compiler(void) { return g_lamexp_version_compiler; }
|
const char *lamexp_version_compiler(void) { return g_lamexp_version_compiler; }
|
||||||
|
@ -96,6 +96,7 @@ lamexp_os_version_t;
|
|||||||
unsigned int lamexp_version_major(void);
|
unsigned int lamexp_version_major(void);
|
||||||
unsigned int lamexp_version_minor(void);
|
unsigned int lamexp_version_minor(void);
|
||||||
unsigned int lamexp_version_build(void);
|
unsigned int lamexp_version_build(void);
|
||||||
|
unsigned int lamexp_version_confg(void);
|
||||||
const QDate &lamexp_version_date(void);
|
const QDate &lamexp_version_date(void);
|
||||||
const char *lamexp_version_time(void);
|
const char *lamexp_version_time(void);
|
||||||
const char *lamexp_version_release(void);
|
const char *lamexp_version_release(void);
|
||||||
|
@ -176,7 +176,7 @@ SettingsModel::SettingsModel(void)
|
|||||||
}
|
}
|
||||||
|
|
||||||
m_settings = new QSettings(configPath, QSettings::IniFormat);
|
m_settings = new QSettings(configPath, QSettings::IniFormat);
|
||||||
const QString groupKey = QString().sprintf("LameXP_%u%02u%05u", lamexp_version_major(), lamexp_version_minor(), lamexp_version_build());
|
const QString groupKey = QString().sprintf("LameXP_%u%02u%05u", lamexp_version_major(), lamexp_version_minor(), lamexp_version_confg());
|
||||||
QStringList childGroups = m_settings->childGroups();
|
QStringList childGroups = m_settings->childGroups();
|
||||||
|
|
||||||
while(!childGroups.isEmpty())
|
while(!childGroups.isEmpty())
|
||||||
@ -187,7 +187,7 @@ SettingsModel::SettingsModel(void)
|
|||||||
{
|
{
|
||||||
bool ok = false;
|
bool ok = false;
|
||||||
unsigned int temp = filter.cap(3).toUInt(&ok) + 10;
|
unsigned int temp = filter.cap(3).toUInt(&ok) + 10;
|
||||||
if(ok && (temp >= lamexp_version_build()))
|
if(ok && (temp >= lamexp_version_confg()))
|
||||||
{
|
{
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user