Lock producing random attribute order in XML

--HG--
branch : feature
This commit is contained in:
Roman Telezhynskyi 2015-07-26 10:17:53 +03:00
parent 3346bd96f2
commit fff806e110
3 changed files with 15 additions and 0 deletions

View File

@ -31,6 +31,10 @@
#include <QMessageBox> // For QT_REQUIRE_VERSION
// Lock producing random attribute order in XML
// https://stackoverflow.com/questions/27378143/qt-5-produce-random-attribute-order-in-xml
extern Q_CORE_EXPORT QBasicAtomicInt qt_qhash_seed;
int main(int argc, char *argv[])
{
Q_INIT_RESOURCE(tapeicon);
@ -40,6 +44,8 @@ int main(int argc, char *argv[])
QT_REQUIRE_VERSION(argc, argv, "5.0.0");
qt_qhash_seed.store(0); // Lock producing random attribute order in XML
MApplication app(argc, argv);
if (not app.IsTheOnly())
{

View File

@ -37,6 +37,10 @@
# include <QCommandLineParser>
#endif
// Lock producing random attribute order in XML
// https://stackoverflow.com/questions/27378143/qt-5-produce-random-attribute-order-in-xml
extern Q_CORE_EXPORT QBasicAtomicInt qt_qhash_seed;
//---------------------------------------------------------------------------------------------------------------------
int main(int argc, char *argv[])
{
@ -50,6 +54,8 @@ int main(int argc, char *argv[])
QT_REQUIRE_VERSION(argc, argv, "5.0.0");
qt_qhash_seed.store(0); // Lock producing random attribute order in XML
VApplication app(argc, argv);
app.InitOptions();

View File

@ -118,6 +118,9 @@ public:
static QString GenderToStr(const SexType &sex);
static SexType StrToGender(const QString &sex);
QStringList ListAll() const;
QStringList ListKnown() const;
private:
Q_DISABLE_COPY(VMeasurements)