summaryrefslogtreecommitdiffstats
path: root/qmake/project.h
diff options
context:
space:
mode:
authorJoerg Bornemann <joerg.bornemann@digia.com>2012-12-17 11:57:13 (GMT)
committerThe Qt Project <gerrit-noreply@qt-project.org>2012-12-18 15:38:52 (GMT)
commit0deddff9c8ca7e1a1e9288a09bc015fd7ea0fd03 (patch)
tree4f2049ed1312b2cf6030616e920b80df6c25a490 /qmake/project.h
parent391aecea93a04aee710352b86a019b4f85893144 (diff)
downloadQt-0deddff9c8ca7e1a1e9288a09bc015fd7ea0fd03.zip
Qt-0deddff9c8ca7e1a1e9288a09bc015fd7ea0fd03.tar.gz
Qt-0deddff9c8ca7e1a1e9288a09bc015fd7ea0fd03.tar.bz2
accept hex/octal values for RC_LANG and RC_CODEPAGE
Task-number: QTBUG-28624 Change-Id: I6188045b05ebb8b9d285d1b30f8082a2fe46ff8b Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com> (cherry picked from commit f0f12ea5f1b6fdaf3e2e38bf8d814dfa41cbca5b)
Diffstat (limited to 'qmake/project.h')
-rw-r--r--qmake/project.h8
1 files changed, 7 insertions, 1 deletions
diff --git a/qmake/project.h b/qmake/project.h
index c9d2084..d87380b 100644
--- a/qmake/project.h
+++ b/qmake/project.h
@@ -189,12 +189,18 @@ inline QString QMakeProject::first(const QString &v)
return vals.first();
}
+/*!
+ * For variables that are supposed to contain a single int,
+ * this method returns the numeric value.
+ * Only the first value of the variable is taken into account.
+ * The string representation is assumed to look like a C int literal.
+ */
inline int QMakeProject::intValue(const QString &v, int defaultValue)
{
const QString str = first(v);
if (!str.isEmpty()) {
bool ok;
- int i = str.toInt(&ok);
+ int i = str.toInt(&ok, 0);
if (ok)
return i;
}