profile/ivi/qtbase.git
11 years agoRemove old troll test servers' references.
Leonard Lee [Fri, 7 Sep 2012 11:31:24 +0000 (13:31 +0200)]
Remove old troll test servers' references.

Replaced with qt-project.org test domain.
The connectToMultiIP auto test is still disabled due to lack of test infrastructure.

Task-number: QTBUG-23294

Change-Id: Icf01aabb0ae503291abdda4e8f773f8e0a08931a
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
11 years agoRename QPaintDevice::init() to initPainter()
Richard Moore [Wed, 5 Sep 2012 08:24:22 +0000 (09:24 +0100)]
Rename QPaintDevice::init() to initPainter()

The old name was too generic and was likely to cause warnings in user
code.

Change-Id: I7126d8fe89a394cd8388af5a030961af7b69c741
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
11 years agoin non-verbose mode, suppress qmake output as well
Oswald Buddenhagen [Mon, 3 Sep 2012 10:35:33 +0000 (12:35 +0200)]
in non-verbose mode, suppress qmake output as well

otherwise missing pkg-config requirements, etc. will be visible.

Change-Id: I5a5c0f35cf75e1fcc09ddbc7fcc54cef6bfec8b5
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: J-P Nurmi <j-p.nurmi@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
11 years agoUse QStringList::join(QChar) overload where applicable [QtDBus]
Marc Mutz [Fri, 18 May 2012 18:00:23 +0000 (20:00 +0200)]
Use QStringList::join(QChar) overload where applicable [QtDBus]

This is an automated change performing the following replacements:
                    join\("(.)"\) -> join('\1')
  join\(QLatin1String\("(.)"\)\)  -> join(QLatin1Char('\1'))
  join\(QStringLiteral\("(.)"\)\) -> join(QLatin1Char('\1'))

Change-Id: I807b0e88ac71a0cb367fb4170cca8f2cb0ad43f3
Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
11 years agoMove the non-C++ parts of qglobal.h outside of __cplusplus
Thiago Macieira [Wed, 29 Aug 2012 09:39:37 +0000 (11:39 +0200)]
Move the non-C++ parts of qglobal.h outside of __cplusplus

This allows some more goodies to be available in C mode.

Change-Id: I5c8a19b6150081a20aae8d3d9d8d7cb30d750536
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
11 years agoMove the constructor and destruction function macros to the C++ part
Thiago Macieira [Wed, 29 Aug 2012 09:25:22 +0000 (11:25 +0200)]
Move the constructor and destruction function macros to the C++ part

These macros expand to C++ code, so there's no point in having them
defined in the non-C++ part of qglobal.h.

Change-Id: Ic5763196391798e362d33466114969818e7e6793
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
11 years agoUse the same hash for 8 bit strings as in QByteArray
Lars Knoll [Fri, 7 Sep 2012 13:11:36 +0000 (15:11 +0200)]
Use the same hash for 8 bit strings as in QByteArray

Moc still used a different and quite a bit more complicated
algorithm to hash 8bit strings then QByteArray.

Change-Id: I86efb08d5ab7de1863fc168dcfc73399e72e1331
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
11 years agoQNX: Add some optional debug output to event dispatcher
Sean Harmer [Wed, 29 Aug 2012 13:14:20 +0000 (14:14 +0100)]
QNX: Add some optional debug output to event dispatcher

Change-Id: I4353619f2dc889f50a139dd5e224a79b780fb316
Reviewed-by: Fabian Bumberger <fbumberger@rim.com>
Reviewed-by: Thomas McGuire <thomas.mcguire@kdab.com>
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
11 years agoRemove temporary constructor used to make qreal->float change
Sean Harmer [Fri, 7 Sep 2012 18:00:21 +0000 (19:00 +0100)]
Remove temporary constructor used to make qreal->float change

The constructor being removed was needed to allow the CI to work until
commit e88f56afc2c889eede8c719b9ce7b621f49a96f9 in qtdeclarative was
merged.

This completes the move from qreal->float in QtGui/math3d.

Change-Id: I2afd108bd9398a1e6925b2885a90dbbad4d25669
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
11 years agoRemoving duplicate includes
Sergio Ahumada [Wed, 5 Sep 2012 13:07:42 +0000 (15:07 +0200)]
Removing duplicate includes

Do not include a header more than once

Change-Id: Ia2e5d66e72988ad833cf5177a3f8aa988bf510e9
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
11 years agotest: QFtp tests require `private_tests' set
Sergio Ahumada [Thu, 6 Sep 2012 10:53:33 +0000 (12:53 +0200)]
test: QFtp tests require `private_tests' set

Also fixing some includes and re-enabling the test

Change-Id: I4a061e106c2e55db39b8000729737a93e3d7714a
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
11 years agoFix missing or improper include guard in headers
Sergio Ahumada [Wed, 5 Sep 2012 10:40:51 +0000 (12:40 +0200)]
Fix missing or improper include guard in headers

Use an include guard in headers to ensure the header is not included
more than once. Make the header guard match its file name.

Change-Id: Icf7d7d4bed91443b3b21ef5d4219dbd260dffef3
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
11 years agoMove tutorials to widgets.
Frederik Gladhorn [Fri, 24 Aug 2012 16:22:44 +0000 (18:22 +0200)]
Move tutorials to widgets.

All of these are very QWidget centric.
They cannot properly refer to the
sources without being part of the widget module.

This fixes around 300 qdoc errors.

Change-Id: I5a7c2dbc10f7913f7b088d6a0ac81323b3c287ac
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
11 years agoqdoc: Renaming include guard in qmlmarkupvisitor.h header
Sergio Ahumada [Wed, 5 Sep 2012 11:08:40 +0000 (13:08 +0200)]
qdoc: Renaming include guard in qmlmarkupvisitor.h header

This header guard is duplicated with qmlvisitor.h

Change-Id: I11787dd8af2834e446eabd219f93b74c0b52428d
Reviewed-by: Martin Smith <martin.smith@nokia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
11 years agoprintsupport: Fix missing or improper include guard in headers
Sergio Ahumada [Wed, 5 Sep 2012 11:35:13 +0000 (13:35 +0200)]
printsupport: Fix missing or improper include guard in headers

Use an include guard in headers to ensure the header is not included
more than once. Make the header guard match its file name.

Change-Id: Iefc02181fe235ede51c567fb54997531e5cd08a3
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
11 years agoAdd support for the Intel Composer XE 2013.
Thiago Macieira [Sat, 8 Sep 2012 14:30:28 +0000 (16:30 +0200)]
Add support for the Intel Composer XE 2013.

ICC 13.0 adds some new C++11 features that we can now support.

Change-Id: Ia870a3bb0172ff124983725300e8f9bf2e325ec6
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
11 years agoMake the default Qt API be Qt 5.0's
Thiago Macieira [Mon, 30 Apr 2012 14:03:18 +0000 (16:03 +0200)]
Make the default Qt API be Qt 5.0's

This means user applications will default to Qt 5.0's API. Higher
versions or Qt 4 compatibility are opt-in.

Also set the default for Qt's own build to be 5.0 on all platforms
except Windows. On Windows, we need to set it to 4.9.

Task-number: QTBUG-25053
Change-Id: I603e0fda4785e64e1413cd82153a89e48005aa40
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
11 years agodon't use QT_{BEGIN,END}_INCLUDE_NAMESPACE needlessly
Oswald Buddenhagen [Mon, 3 Sep 2012 14:56:48 +0000 (16:56 +0200)]
don't use QT_{BEGIN,END}_INCLUDE_NAMESPACE needlessly

these macros behave counter-intuitively, so don't use them unless the code
structure really suggests their use.

Change-Id: I58213b39f8a98e4368901217fac14ca49c28b8cf
Reviewed-by: hjk <qthjk@ovi.com>
11 years agocentralize initialization of CONFIG in mkspecs
Oswald Buddenhagen [Mon, 3 Sep 2012 13:38:31 +0000 (15:38 +0200)]
centralize initialization of CONFIG in mkspecs

"CONFIG += qt warn_on release link_prl" is in every single spec (though
for link_prl there is one genuine exception and two apparent omissions).

Change-Id: I72e1e315586af828eefa3b0b70998ab892ec3c1a
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
11 years agocentralize initialization of QT in specs
Oswald Buddenhagen [Mon, 3 Sep 2012 13:12:07 +0000 (15:12 +0200)]
centralize initialization of QT in specs

there is no reason whatsoever to duplicate this so many times, and even
less reason to have specs with a deviating default.

Change-Id: Ia25836c079580adebc373697b8bd03598f79c69b
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
11 years agoremove useless TEMPLATE assignments from specs
Oswald Buddenhagen [Mon, 3 Sep 2012 13:08:05 +0000 (15:08 +0200)]
remove useless TEMPLATE assignments from specs

"app" is the built-in default anyway

Change-Id: I4f581ee5b81aee08860dbdda5d863943bceafb1b
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
11 years agoadjust specs to the new target mode handling
Oswald Buddenhagen [Mon, 3 Sep 2012 11:11:16 +0000 (13:11 +0200)]
adjust specs to the new target mode handling

not strictly necessary, but nicer.

QMAKE_PLATFORM (and thus CONFIG) now also contains the name of the OS, and
its family (if applicable, e.g., bsd). this also adds more feature search
paths.

Change-Id: I3ab971e6e3b2b32cae53b95e4bc67a86688bc5cb
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
11 years agoenable depend_includepath by default
Oswald Buddenhagen [Mon, 3 Sep 2012 09:31:55 +0000 (11:31 +0200)]
enable depend_includepath by default

DEPENDPATH is hard to get right, and consequently most projects have
broken dependencies.
the easy way out is just adding everying in INCLUDEPATH to DEPENDPATH,
like we do ourselves in qt. if somebody wants to optimize, he can
opt-out.

Change-Id: I7fb56010728fd2b0d2b7d4d26386f366d414ba04
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
11 years agoCheck for C++ operators that should be 'const'
Sergio Ahumada [Tue, 4 Sep 2012 19:10:05 +0000 (21:10 +0200)]
Check for C++ operators that should be 'const'

Make sure all C++ class comparison operators are const.

Change-Id: Ib4a66f2afe6c62f437dae1ecde94287d3db8442d
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: David Faure <faure@kde.org>
11 years agoFix QTest::qExec crash with no command line arguments
Jeremy Lainé [Tue, 4 Sep 2012 14:04:19 +0000 (16:04 +0200)]
Fix QTest::qExec crash with no command line arguments

The documentation for QTest::qExec states that command line arguments
are optional and gives the following example:

 MyTestObject test1;
 QTest::qExec(&test1);

However, running this example leads to crash as argv[0] is accessed
without testing argc. This change fixes this bug.

Change-Id: I2ec016e02869d21b24bc11f1851a760036640191
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Jason McDonald <macadder1@gmail.com>
11 years agoQDBusIntegrator: fix unprotected QDBusPendingCallPrivate::waitingForFinished call
Marc Mutz [Wed, 29 Aug 2012 16:12:28 +0000 (18:12 +0200)]
QDBusIntegrator: fix unprotected QDBusPendingCallPrivate::waitingForFinished call

There probably is a happens-before relation to all the writes of the bool elsewhere,
but the comment in QDBusPendingCallPrivate says waitingForFinsihed is one of the
variables protected by the mutex, so don't make every reader of the code re-establish
the safety (if indeed, it is safe) oneself again, but just wrap the access in a
mutex lock.

To be able to compile the mutex locking out of release builds, wrap the access
in a function. Make the function static _inline_ so compilers won't complain
about it being unused in release builds.

Change-Id: I914ce91e64e776450c697a3243b35716390a218c
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
11 years agoMention logging related changes in changes-5.0.0 file
Kai Koehne [Wed, 5 Sep 2012 11:28:21 +0000 (13:28 +0200)]
Mention logging related changes in changes-5.0.0 file

Change-Id: I6798a2b09fb0f832c32bac325fa0bcf40dbb854e
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
11 years agoFix warning about not enough actual parameters for macro.
Jędrzej Nowacki [Wed, 5 Sep 2012 11:47:27 +0000 (13:47 +0200)]
Fix warning about not enough actual parameters for macro.

QT_METATYPE_INTERFACE_INIT_EMPTY_DATASTREAM_IMPL ignores arguments
anyway so it is not a problem to give a void type.

Change-Id: I66109cc9ae43b48d5cacbd11bebe135a71e10ed7
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
11 years agofix c string comparison
Oswald Buddenhagen [Fri, 31 Aug 2012 14:21:01 +0000 (16:21 +0200)]
fix c string comparison

Change-Id: If9cc96e240047cfe301804d57a33b937afadef72
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: J-P Nurmi <j-p.nurmi@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
11 years agode-duplicate MODULE_DEPENDS
Oswald Buddenhagen [Mon, 3 Sep 2012 10:19:39 +0000 (12:19 +0200)]
de-duplicate MODULE_DEPENDS

in modules which conditionally add dependencies it is hard to keep $$QT
free of duplicates at definition time, so clean it up when we use it.

Change-Id: Ia711e23bec3683525dfca80df4834e20b007ba1f
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
11 years agouse each module's lib_bundle setting
Oswald Buddenhagen [Fri, 1 Jun 2012 06:25:15 +0000 (08:25 +0200)]
use each module's lib_bundle setting

... instead of relying on the global qt_framework flag.

Change-Id: Ie23f55788c26d732ada87aab7284c0a1fe0bfa28
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
11 years agogeneralize environment additions to tool invocation
Oswald Buddenhagen [Thu, 6 Sep 2012 17:08:28 +0000 (19:08 +0200)]
generalize environment additions to tool invocation

foo.name = VAR
foo.value = baz bar
foo.CONFIG = prepend
QT_TOOL_ENV += foo

will add the respective environment assignment to the generated command
line.
if value is a list, the elements are joined with the shell's path list
separator.
the value must be in the final form (correct path separators and
shell-escaped).
if .CONFIG prepend is set, the generated command will prepend the
new value to a pre-existing one.

Change-Id: I62c6dfb3ec50ce73d3a85a2099275f92b57a52dc
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
11 years agocache the right variable
Oswald Buddenhagen [Thu, 6 Sep 2012 17:05:22 +0000 (19:05 +0200)]
cache the right variable

binary+depends is outdated; it's just command now

Change-Id: Ic4617d760585e53a485920e843627d3f9707d6a9
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
11 years agoQVariant: prevent QVariant(QMetaType::Type) from compiling
Marc Mutz [Tue, 21 Aug 2012 08:05:41 +0000 (10:05 +0200)]
QVariant: prevent QVariant(QMetaType::Type) from compiling

Reported-by: Stephen Chu <stephen@ju-ju.com>
Change-Id: I298973174ff10f4462f04f3358c974c04dfd3383
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
Reviewed-by: Stephen Chu <stephen@ju-ju.com>
11 years agoUse QStringList::join(QChar) overload where applicable [QtNetwork]
Marc Mutz [Fri, 18 May 2012 18:00:23 +0000 (20:00 +0200)]
Use QStringList::join(QChar) overload where applicable [QtNetwork]

This is an automated change performing the following replacements:
                    join\("(.)"\) -> join('\1')
  join\(QLatin1String\("(.)"\)\)  -> join(QLatin1Char('\1'))
  join\(QStringLiteral\("(.)"\)\) -> join(QLatin1Char('\1'))

Change-Id: I5b75877ba192fa1357e67fee70dff7c0475991e8
Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
11 years agoUse QStringList::join(QChar) overload where applicable [QtWidgets]
Marc Mutz [Fri, 18 May 2012 18:00:23 +0000 (20:00 +0200)]
Use QStringList::join(QChar) overload where applicable [QtWidgets]

This is an automated change performing the following replacements:
                    join\("(.)"\) -> join('\1')
  join\(QLatin1String\("(.)"\)\)  -> join(QLatin1Char('\1'))
  join\(QStringLiteral\("(.)"\)\) -> join(QLatin1Char('\1'))

Change-Id: Ia30048e0c40967dc86a4e4ad26ac02ab67519096
Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
11 years agoUse QStringList::join(QChar) overload where applicable [QtGui]
Marc Mutz [Fri, 18 May 2012 18:00:23 +0000 (20:00 +0200)]
Use QStringList::join(QChar) overload where applicable [QtGui]

This is an automated change performing the following replacements:
                    join\("(.)"\) -> join('\1')
  join\(QLatin1String\("(.)"\)\)  -> join(QLatin1Char('\1'))
  join\(QStringLiteral\("(.)"\)\) -> join(QLatin1Char('\1'))

Change-Id: Id8d43c1b1ca9cd3aa0b4eedca6709b6287a9bc98
Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
11 years agoQNX: Enable support for hardware buttons in QPA plugin
Sean Harmer [Tue, 4 Sep 2012 18:58:27 +0000 (19:58 +0100)]
QNX: Enable support for hardware buttons in QPA plugin

Change-Id: I3de18c3fdcfdacddc375b70800b34b6a8d16ac41
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
Reviewed-by: Thomas McGuire <thomas.mcguire@kdab.com>
Reviewed-by: Kevin Krammer <kevin.krammer@kdab.com>
11 years agoEnable autodetecting of EGL event for desktop GL
Jorgen Lind [Fri, 7 Sep 2012 14:36:49 +0000 (16:36 +0200)]
Enable autodetecting of EGL event for desktop GL

And only use the QT_CONFIG,egl syntax in eglconvenience

Change-Id: I81c0602334714f4b27a7e90e7b5859c989e6bd63
Reviewed-by: Paul Olav Tvete <paul.tvete@nokia.com>
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
11 years agodoc: Clean up QAbstractItemModel documentation
Eskil Abrahamsen Blomfeldt [Wed, 5 Sep 2012 11:32:48 +0000 (13:32 +0200)]
doc: Clean up QAbstractItemModel documentation

Mention QML as an alternative to widgets in the documentation,
and fix a typo

Change-Id: Ia6aaef9ec73d5112ff45c22b0bf57f1f9c7d31a3
Reviewed-by: Paul Olav Tvete <paul.tvete@nokia.com>
11 years agoUse setenv in qputenv if possible, since it won't leak
Thiago Macieira [Fri, 7 Sep 2012 14:13:36 +0000 (16:13 +0200)]
Use setenv in qputenv if possible, since it won't leak

putenv(3) is evil: SUSv2 requires that the pointer passed to it be added
to the environment and that modifying the contents of that pointer later
will also cause the environment to change. That means we needed to
strdup before calling it and that memory was never freed.

This shows up all the time in valgrind's leak check.

Instead, let's use the 4.3BSD & POSIX.1-2001 setenv(3) function, which
does copy. That means there are either no leaks or, if there are,
they're not our fault.

Change-Id: I4576f91cc718b6b3cae790c4f2854c4976dded37
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
11 years agoLogging: Fix mingw32-gcc compiler warning about unused variable
Kai Koehne [Thu, 30 Aug 2012 12:25:35 +0000 (14:25 +0200)]
Logging: Fix mingw32-gcc compiler warning about unused variable

Change-Id: I985c2096e604a3cb14eb3a41c4f12aa28f0ea681
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
11 years agoFix performance regression when appending one vector to another
Lars Knoll [Fri, 7 Sep 2012 08:02:04 +0000 (10:02 +0200)]
Fix performance regression when appending one vector to another

When appending a QVector to an existing vector the code would
unconditionally realloc the vector instead of first checking
whether we can do without. This gives a quadratic behaviour when
repeatedly appending a vector to another.

Change-Id: I2cd81253e6a8aec0bc4402e6fbda262435080966
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Simon Hausmann <simon.hausmann@nokia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
11 years agoQtNetwork: bypass proxy for local connections
Julien Brianceau [Mon, 3 Sep 2012 11:56:09 +0000 (13:56 +0200)]
QtNetwork: bypass proxy for local connections

According to Qt doc, "Network proxy is not used if the address used in
connectToHost(), bind() or listen() is equivalent to
QHostAddress::LocalHost or QHostAddress::LocalHostIPv6. This is not the
case in current implementation.

Change-Id: I6b8a40c1e8bd8aad9504d8f939b87eda6e93337c
Reviewed-by: Richard J. Moore <rich@kde.org>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
11 years agoQWeakPointer use for tracking QObjects is deprecated.
Thiago Macieira [Wed, 5 Sep 2012 11:02:56 +0000 (13:02 +0200)]
QWeakPointer use for tracking QObjects is deprecated.

Use QPointer.

Change-Id: Ife3cbec620ec83a9148d274d15e44016a3f5d7d0
Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
11 years agoAdded API Reference Style Guidelines
Jerome Pasion [Mon, 13 Aug 2012 10:01:05 +0000 (12:01 +0200)]
Added API Reference Style Guidelines

-added C++ and QML language guidelines as part of QDoc Guide
    -included snippets
-fixed links in the HTML template of the QDoc Guide
-compiles when the main QDoc manual is compiled

Change-Id: Iadd799712eef80e905d092396cb7a1e25a863b43
Reviewed-by: Geir Vattekar <geir.vattekar@nokia.com>
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Martin Smith <martin.smith@nokia.com>
11 years agointroduce qmake variable abstractions
Oswald Buddenhagen [Thu, 6 Sep 2012 10:21:38 +0000 (12:21 +0200)]
introduce qmake variable abstractions

this is preparation for adapting to a new evaluator.

Change-Id: I6fc59f5525735754a00afa6629fbfe257e84db97
Reviewed-by: Daniel Teske <daniel.teske@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
11 years agoAdd a way to benchmark sem_t on Unix too
Thiago Macieira [Tue, 28 Aug 2012 11:46:16 +0000 (13:46 +0200)]
Add a way to benchmark sem_t on Unix too

It's closer to what we do with in QMutex than pthread_mutex_lock.

Change-Id: I86498a800b69b684bf096912e911bc5bca219727
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
11 years agoUpdate the git-archive export options
Thiago Macieira [Wed, 29 Aug 2012 14:05:10 +0000 (16:05 +0200)]
Update the git-archive export options

The .gitattributes, .gitignore, .commit-template files do not need to be
present in packaged sources, as they are for people using the Git
repository.  People who download tarballs usually don't reimport into
Git -- they should just download the actual repositories.

Meanwhile, the .tag file is quite useful. Instead of making Git extract
to the useless SHA-1 of the "$Id$\n" string, ask git-archive to store
the SHA-1 of the commit being packaged.

Change-Id: I9a24a526e66f58ef2ebd9a2319bf96cf43e3e6f7
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
Reviewed-by: Simo Fält <simo.falt@nokia.com>
11 years agoQtGlobal: mark qVersion() and qSharedBuild() as nothrow
Marc Mutz [Tue, 7 Aug 2012 08:54:00 +0000 (10:54 +0200)]
QtGlobal: mark qVersion() and qSharedBuild() as nothrow

Change-Id: Id9dcf71363754cf6aae94012b22d144455e213eb
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
11 years agoDocument how opacity affects QGraphicsScene item queries.
Mitch Curtis [Fri, 7 Sep 2012 08:17:54 +0000 (10:17 +0200)]
Document how opacity affects QGraphicsScene item queries.

Currently, QGraphicsScene::items() and related functions only return
items that are visible. The definition of visible effectively means
any item for whom isVisible() returns false or opacity() returns 0.0.
However, this is not documented anywhere.

Also fixed some typos/grammatical errors.

Change-Id: Ia6d1f7d63024dc9412438fe97748d7a69ee8225b
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Thomas McGuire <thomas.mcguire@kdab.com>
Reviewed-by: Andreas Aardal Hanssen <andreas@hanssen.name>
Reviewed-by: Geir Vattekar <geir.vattekar@nokia.com>
11 years agoTest: Replace QSKIP by XFAIL
Caroline Chao [Thu, 6 Sep 2012 10:47:50 +0000 (12:47 +0200)]
Test: Replace QSKIP by XFAIL

For tst_QtConcurrentThreadEngine::threadCount

Change-Id: I14b904a26900a01d5d04245ad60d9752f5645e68
Reviewed-by: Sergio Ahumada <sergio.ahumada@nokia.com>
11 years agoTest: Remove QSKIP for tst_QXmlSimpleReader::inputFromSocket
Caroline Chao [Thu, 6 Sep 2012 07:46:08 +0000 (09:46 +0200)]
Test: Remove QSKIP for tst_QXmlSimpleReader::inputFromSocket

The test is now passing. Tested with intel compiler and vs2008.

Task-number: QTBUG-22285

Change-Id: I728919833d9bcbf71bef68c06baef92667ff074b
Reviewed-by: J-P Nurmi <j-p.nurmi@nokia.com>
11 years agoFix QRegularExpression* docs
Giuseppe D'Angelo [Thu, 6 Sep 2012 16:52:05 +0000 (17:52 +0100)]
Fix QRegularExpression* docs

A couple of runaway backslashes resulted in illegal code in the
examples.

Change-Id: Ib00d4e1d792e44bb73dafdd84c3a1843dcb34e27
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
11 years agoMark plugin class docs as internal.
Frederik Gladhorn [Wed, 5 Sep 2012 14:23:23 +0000 (16:23 +0200)]
Mark plugin class docs as internal.

Change-Id: I2eb0a6ce4108774377df1296de4152715b65de6e
Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
11 years agoFix a bug in qdoc where to look for index files.
Jan-Arve Saether [Mon, 3 Sep 2012 08:25:01 +0000 (10:25 +0200)]
Fix a bug in qdoc where to look for index files.

This was only a problem if the qdocconf file was in the same
directory as the current directory (QDir::relativeFilePath()
returns an empty string in that case), so if the documentation was
generated with the makefile rules, this problem did not reveal itself.

Change-Id: I9c8956fdb46c4f307df7ab297dc94e8d3ef93fb4
Reviewed-by: Martin Smith <martin.smith@nokia.com>
11 years agoMake gui/math3d classes use float rather than qreal
Sean Harmer [Mon, 20 Aug 2012 19:55:40 +0000 (20:55 +0100)]
Make gui/math3d classes use float rather than qreal

This corrects the mismatch between using floats for internal storage
and qreal in the API of QVector*D which leads to lots of implicit
casts between double and float.

This change also stops users from being surprised by the loss of
precision when using these classes on desktop platforms and removes
the need for the private constructors taking a dummy int as the final
argument.

The QMatrix4x4 and QQuaternion classes have been changed to use float
for their internal storage since these are meant to be used in
conjunction with the QVector*D classes. This is to prevent unexpected
loss of precision and to improve performance.

The on-disk format has also been changed from double to float thereby
reducing the storage required when streaming vectors and matrices. This
is potentially a large saving when working with complex 3D meshes etc.

This also has a significant performance improvement when passing
matrices to QOpenGLShaderProgram (and QGLShaderProgram) as we no
longer have to iterate and convert the data to floats. This is
an operation that could easily be needed many times per frame.

This change also opens the door for further optimisations of these
classes to be implemented by using SIMD intrinsics.

This needs to be applied in conjunction with

https://codereview.qt-project.org/#change,33548

Task-number: QTBUG-21035
Task-number: QTBUG-20661
Change-Id: I9321b06040ffb93ae1cbd72fd2013267ac901b2e
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
11 years agoFix compilation error of qcursor_qpa.cpp with QT_NO_CURSOR.
Sergio Martins [Tue, 4 Sep 2012 10:33:36 +0000 (11:33 +0100)]
Fix compilation error of qcursor_qpa.cpp with QT_NO_CURSOR.

ChangeId Ia69f37343f95772e934eab1cd806bd54cbdbbe51 added two new
methods to QCursor but didn't update the fake cursor.

Qt5's build still fails with QT_NO_CURSOR somewhere in
QT_METATYPE_INTERFACE_INIT(Type), but that's another story.

Change-Id: Ib0c706faf78e547d93a1128085e440fe5d1a5e9b
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
11 years agolinuxfb: use linux/kd.h instead of the glibc dummy
Arvid Picciani [Fri, 7 Sep 2012 08:11:32 +0000 (10:11 +0200)]
linuxfb: use linux/kd.h instead of the glibc dummy

Change-Id: I0f2e35dd82b3353f5ab5e79ba2fc654dd3b4afed
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
11 years agoFixed behaviour of mouse clicks for menu bars on Windows
Oliver Wolff [Mon, 3 Sep 2012 12:34:15 +0000 (14:34 +0200)]
Fixed behaviour of mouse clicks for menu bars on Windows

As the behaviour described in the style hint seems to
be default and working, it can be removed.

Change-Id: Ia8d47cf187597ae48b9e42c3f98ef3d4c390db34
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
11 years agoFix crash when QTextLayout::setAdditionalFormats is called with ranges with negative...
Olivier Goffart [Wed, 5 Sep 2012 18:42:28 +0000 (20:42 +0200)]
Fix crash when QTextLayout::setAdditionalFormats is called with ranges with negative length

That can be reproduced in Qt Creator when deleting code.

Task-number: QTBUG-27140
Change-Id: Ida7177612653f10e5d866bf9a422c71c632f4eb3
Reviewed-by: Simon Hausmann <simon.hausmann@nokia.com>
11 years agoAdd example to test widget grab.
Friedemann Kleint [Wed, 5 Sep 2012 14:50:46 +0000 (16:50 +0200)]
Add example to test widget grab.

Compiles against Qt 4.8 and Qt 5.

Change-Id: Ic246aeb38171361a8338f38f9b92e5cf3b54b368
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
Reviewed-by: Sergio Ahumada <sergio.ahumada@nokia.com>
11 years agoStabilize test of QSpinBox.
Friedemann Kleint [Fri, 7 Sep 2012 08:32:26 +0000 (10:32 +0200)]
Stabilize test of QSpinBox.

The test shows spurious failures in editingFinished() on some Mac
platforms (QTest::qWaitForWindowActive(testFocusWidget)).
This is apparently caused by the widget testFocusWidget (member
variable) interfering with the other tests widgets.
As it is used in one test only, instantiate it on the stack there.

Change-Id: I688cd21a2668d072660658302cf59197abe0b4d8
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Sergio Ahumada <sergio.ahumada@nokia.com>
11 years agoRevert "Implement automatic mouse grabbing on mouse button press."
Friedemann Kleint [Thu, 6 Sep 2012 12:37:59 +0000 (14:37 +0200)]
Revert "Implement automatic mouse grabbing on mouse button press."

This reverts commit 6b5bbc531b30d8ece25425e39843c6ae1af1d045.

Autograbbing mouse shouldn't be done in crossplatform code, as
X11 does this automatically. Windows needs platform specific
solution.

Task-number: QTBUG-26962
Task-number: QTBUG-27039
Task-number: QTBUG-23699

Change-Id: I911df92c4a34deb50b729f50681497046657948b
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
11 years agoRemove declarative_debug feature (qmake)
Kai Koehne [Wed, 5 Sep 2012 10:32:51 +0000 (12:32 +0200)]
Remove declarative_debug feature (qmake)

declarative_debug got superseded by qml_debug and quick1_debug.

Change-Id: Id4c593d86a011223d2a735fb2a8c25e4ec70f53e
Reviewed-by: Christiaan Janssen <christiaan.janssen@nokia.com>
11 years agoconfigure: Unify order of options in help
Kai Koehne [Wed, 5 Sep 2012 07:34:57 +0000 (09:34 +0200)]
configure: Unify order of options in help

The -developer-build option in the configure shell script is right after
-force-debug-info, move it to the same place in the Windows version.

Change-Id: I9b944f8591011ce9987a4fb98f7d02d88160d9e8
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
11 years agoMove enums that was part of the Qt namespace to qnamespace.h
Jan-Arve Saether [Thu, 6 Sep 2012 13:08:40 +0000 (15:08 +0200)]
Move enums that was part of the Qt namespace to qnamespace.h

This caused some headache wrt documentation, since in order to
generate the proper documentation for the qt namespace
qdoc also needed to parse the headers of gui, which breaks
cross-module linking. (This is because qdoc will actually
generate two almost identical nodes in the code tree; one
from the header files from gui and another from the index file
of gui).

The best fix would maybe be to make it part of
QAbstractTextDocumentLayout, but that will break source compat.

Change-Id: I34e94d05fa4bec3034778d1f1cc0e53d0625e1ab
Reviewed-by: Simon Hausmann <simon.hausmann@nokia.com>
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
11 years agoRevert "Use true and false in preference to TRUE and FALSE"
Sergio Ahumada [Thu, 6 Sep 2012 08:54:50 +0000 (10:54 +0200)]
Revert "Use true and false in preference to TRUE and FALSE"

Even though I really think the change was the right thing to do, it seems
like Windows people don't like this change because of some Windows Data Types
specific rules.

This reverts parts of the commit 56d5c909af6473be64a1ae487b45bd444a9a8553.

Change-Id: I2c67d9b1bab36fc63937ef386aef56d2a4472a04
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
11 years agoFix g++ compiler warnings.
Friedemann Kleint [Wed, 5 Sep 2012 13:24:35 +0000 (15:24 +0200)]
Fix g++ compiler warnings.

Unused variables, unsigned comparison DWORD >= 0 is always
true, format string.

Change-Id: I9f0a20392e262b2542fb23ea4f513e4c4e354b68
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
11 years agoFix QDateEdit displaying day as a number for short and long day formats
Mitch Curtis [Wed, 29 Aug 2012 10:58:35 +0000 (12:58 +0200)]
Fix QDateEdit displaying day as a number for short and long day formats

When 2 (February) is entered as the month for (e.g.) 31/Jan/2000 (which
is following the format: "dd/MMM/yyyy"), the day is corrected to 29 but
displayed as its numerical value instead of its short (or long) name.

Task-number: QTBUG-27036 QTBUG-19091
Change-Id: I558ee13b224707d22b26c2ec2c045f96118bd5a1
Reviewed-by: Mitch Curtis <mitch.curtis@nokia.com>
Reviewed-by: aavit <qt_aavit@ovi.com>
11 years agoFix 3 digit day being displayed by QDateEdit.
Mitch Curtis [Tue, 21 Aug 2012 12:46:42 +0000 (14:46 +0200)]
Fix 3 digit day being displayed by QDateEdit.

When a QDateEdit has its display format set to "yyyy/MM/dd", its day
set to 31 and its month set to 2, it will display 291 as the day until
the cursor is moved or the focus changed. This is because
QDateTimeParser::parse calls sectionSize() for the day section, which
will sometimes return an incorrect size. There are also other display
formats affected by this bug (e.g. long day names).

For example, (in the context of sectionSize()) when text is
"2000/01/31" and displayText() is "2000/2/31", there is a difference
between displayText() and text - text is the previous value and
displayText() is the new value. The size difference is always due to
leading zeroes.

This patch makes QDateTimeParser keep track of the quantity of zeroes
added to each section and then factors this value into the result of
sectionSize() if there is a size difference between text and
displayText().

Task-number: QTBUG-26847
Change-Id: I3823cc41167ec920f742cb6a20d39fc5f433c915
Reviewed-by: Mitch Curtis <mitch.curtis@nokia.com>
Reviewed-by: Gabriel de Dietrich <gabriel.dietrich-de@nokia.com>
Reviewed-by: aavit <qt_aavit@ovi.com>
11 years agoDoc: Missing documentation added and doc errors fixed.
aavit [Wed, 5 Sep 2012 09:34:16 +0000 (11:34 +0200)]
Doc: Missing documentation added and doc errors fixed.

Change-Id: I573bf9622e38b54f2cb8c32fd402d477a1deb5c2
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Kim M. Kalland <kim.kalland@nokia.com>
11 years agoDon't use string comparison to figure out how to use the clipboard
Jorgen Lind [Tue, 4 Sep 2012 13:01:54 +0000 (15:01 +0200)]
Don't use string comparison to figure out how to use the clipboard

Change-Id: I36738b3808ebed0d108882ebdc74ee7dd1899bfd
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
11 years agoMove assignment of mousePressed variable in QWidgetTextControl
Jorgen Lind [Tue, 4 Sep 2012 13:03:53 +0000 (15:03 +0200)]
Move assignment of mousePressed variable in QWidgetTextControl

Or else we never hit the path where middle button click pasts selection
on X11. This is also how it worked in Qt 4.

Change-Id: Ia090c465db0e5e8cb249f5d752e0bb86951e2eb0
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
11 years agorestore support for QMAKE_LIBDIR_FLAGS
Oswald Buddenhagen [Thu, 30 Aug 2012 14:55:31 +0000 (16:55 +0200)]
restore support for QMAKE_LIBDIR_FLAGS

unexpectedly, this internal variable is documented. grumble.

Change-Id: I272c1f553b56f253d2f59f875de78d5bc279186a
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
Reviewed-by: Daniel Teske <daniel.teske@nokia.com>
11 years agobypass configure bootstrap for non-git builds
Oswald Buddenhagen [Thu, 30 Aug 2012 10:37:01 +0000 (12:37 +0200)]
bypass configure bootstrap for non-git builds

Change-Id: Ifa56297db0c5f198080a728f033393ab60eb1b74
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
11 years agoremove pretenses of supporting projects on stdin
Oswald Buddenhagen [Tue, 28 Aug 2012 08:12:36 +0000 (10:12 +0200)]
remove pretenses of supporting projects on stdin

this may have worked a decade ago, but now it only produces funny
Makefiles (and needs hacking main.cpp). the feature doesn't seem *too*
important, so just clean it out.

Change-Id: I50a60b0e30341f0b523e4a5731c770c9c1013f8b
Reviewed-by: Daniel Teske <daniel.teske@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
11 years agomake QMakeMetaInfo a little less inefficient with libtool .la files
Oswald Buddenhagen [Wed, 22 Aug 2012 12:10:35 +0000 (14:10 +0200)]
make QMakeMetaInfo a little less inefficient with libtool .la files

don't read the spec from scratch for every library just to get
QMAKE_LFLAGS_RPATH. we can perfectly use our current project for that
purpose.

Change-Id: I4e408b3fd5de81652181df032aa53cd8f2f8f806
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
11 years agopre-initialize more invariant properties
Oswald Buddenhagen [Tue, 21 Aug 2012 12:47:08 +0000 (14:47 +0200)]
pre-initialize more invariant properties

Change-Id: I0add2e7ead5a3d63124ef7ff85362895dd64bd23
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
11 years agoremove QMAKE_MKSPECS property from qmake -query's view
Oswald Buddenhagen [Tue, 21 Aug 2012 12:36:20 +0000 (14:36 +0200)]
remove QMAKE_MKSPECS property from qmake -query's view

it's a dynamic property which is something between meaningless and
misleading when used outside a project file.
also, experience from creator shows that people would consistently
abuse it (not handling it as the list it is).

Change-Id: Id52cd40da5c38c0c74535d0701fdae53dfa39cad
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
11 years agoUse true and false in preference to TRUE and FALSE
Sergio Ahumada [Tue, 4 Sep 2012 17:39:07 +0000 (19:39 +0200)]
Use true and false in preference to TRUE and FALSE

The TRUE and FALSE macros are obsolete and should be replaced with
true and false (all lower case) respectively.

Change-Id: Iee352e8173500683e6319be0abbf5bacf29016e0
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
11 years agotest: Check for null string comparison
Sergio Ahumada [Tue, 4 Sep 2012 18:32:33 +0000 (20:32 +0200)]
test: Check for null string comparison

Do not compare a QString to QString(). Instead use the .isEmpty() method.

Change-Id: I8bb5e64563bf173abe7288bb9e35375bee1fe445
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
11 years agoOptimize QTextLayout/QTextEngine usage outside of QTextDocument.
Milian Wolff [Mon, 3 Sep 2012 16:06:17 +0000 (18:06 +0200)]
Optimize QTextLayout/QTextEngine usage outside of QTextDocument.

When QTextLayout is used in a QTextDocument, many code paths use
special caches and thus greatly outperform the raw QTextLayout version
that operates directly on a QString.

This patch brings some of these optimizations also to the raw version.
We now also use a QFormatCollection in such cases and enable the
functionality of QTextEngine::indexAdditionalFormats() and
QTextEngine::resolveAdditionalFormats(). Thanks to that, we can greatly
speed up QTextEngine::format(), which now uses an amort O(1) hash table
lookup instead of a O(N) linear search.

The added benchmark shows a gain in the order of one magnitude:

./tst_bench_QText formattedLayout:long-many

before applying the patch:
378.19 msecs per iteration (total: 37,820, iterations: 100)
after applying the patch:
25.80 msecs per iteration (total: 2,580, iterations: 100)

Note: This change is source-incompatible for applications using the private
QTextEngine API.

Task-number: QTBUG-8389
Change-Id: Ifcf7a8902a394428979ea06a6d955f886ee739c7
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
11 years agoFix Windows platform plugin narrowing conversion compile errors
Jonathan Liu [Tue, 4 Sep 2012 09:40:17 +0000 (19:40 +1000)]
Fix Windows platform plugin narrowing conversion compile errors

Implicit conversions from int to BYTE (unsigned char) result in
compile errors when compiling with the GCC -std=c++0x option.

Change-Id: Iaf8190426207bf15ab4b337300510596d70659ed
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
11 years agoRemove custom sort implementation in QTriangulator in favour of std::sort.
Robin Burchell [Sun, 2 Sep 2012 09:58:36 +0000 (11:58 +0200)]
Remove custom sort implementation in QTriangulator in favour of std::sort.

qSort has terrible performance, especially on mostly-sorted input, which is
presumably why a custom implementation was created. However, std::sort has much
better performance than qSort in many cases.

Benchmarking shows that std::sort beats out the custom sort by a very narrow
margin (21-22ms for qSort, 14-15ms for sort, 14ms for std::sort) in a simple
benchmark of sorting.

Change-Id: If7e57fdfaf98e741d1621969461537c82f9169fe
Reviewed-by: Kim M. Kalland <kim.kalland@nokia.com>
Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
11 years agoCorrect the QFileDialog's delete warning message.
Mitch Curtis [Tue, 4 Sep 2012 10:14:11 +0000 (12:14 +0200)]
Correct the QFileDialog's delete warning message.

"Are sure you want to delete '%1'?" should be:
"Are you sure you want to delete '%1'?"

Title of the message box should be Delete, not Open.

Task-number: QTBUG-26851
Change-Id: I40933c5e1b231d3d2e3274b4d669267d26ba8cfc
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com>
11 years agoClarify QDateTime::secsTo and QDateTime::msecsTo documentation.
Mitch Curtis [Fri, 17 Aug 2012 13:30:55 +0000 (15:30 +0200)]
Clarify QDateTime::secsTo and QDateTime::msecsTo documentation.

Changed:
"Returns 0 if either time is invalid."
to:
"Returns 0 if either datetime is invalid."

Change-Id: I52d291459f215c1bb7fc78e70eaac90b2498158b
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com>
11 years agoQNX: Move qpa-based mkspecs out of the unsupported directory
Sean Harmer [Tue, 4 Sep 2012 09:42:23 +0000 (10:42 +0100)]
QNX: Move qpa-based mkspecs out of the unsupported directory

RIM is committed to supporting Qt on its platforms and the port works
well.

Change-Id: Id6bfea2dbc178800adad89d436ce31c40d3eb652
Reviewed-by: Nicolas Arnaud-Cormos <nicolas@kdab.com>
Reviewed-by: Andreas Holzammer <andreas.holzammer@kdab.com>
Reviewed-by: Thomas McGuire <thomas.mcguire@kdab.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
11 years agofix QT_{BEGIN,END}_INCLUDE_NAMESPACE mixup
Oswald Buddenhagen [Mon, 3 Sep 2012 14:50:53 +0000 (16:50 +0200)]
fix QT_{BEGIN,END}_INCLUDE_NAMESPACE mixup

Change-Id: Id25b6aa56681b5bb5989472a96128789c0c4e73a
Reviewed-by: hjk <qthjk@ovi.com>
11 years agoAuto test for 'qmake -project' use case.
Rafael Roquetto [Fri, 10 Aug 2012 15:21:30 +0000 (17:21 +0200)]
Auto test for 'qmake -project' use case.

Change-Id: Ifb6d64828ba1cb42fd64299438b7eec302112edf
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
11 years agoFix indentation.
Morten Sorvig [Wed, 15 Aug 2012 11:27:32 +0000 (13:27 +0200)]
Fix indentation.

Change-Id: I0e53df9e1903c8cdc79d50c16cfe7f90ae6e1d6f
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
11 years agoQWizard/Win: Fix vista helper cache state invalidation
Jonathan Liu [Tue, 4 Sep 2012 05:30:21 +0000 (15:30 +1000)]
QWizard/Win: Fix vista helper cache state invalidation

If the cached state is not dirty and the instanceCount is zero, when the
instanceCount is incremented the cached state will not be correct. To
fix this, reset the cached state to dirty if the instanceCount is
incremented from zero.

Change-Id: Ic49eef7f83b1289a939f998817b1b2b5f5a2a45f
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
11 years agographicsview: use std::sort instead of qSort
Robin Burchell [Sun, 2 Sep 2012 10:18:14 +0000 (12:18 +0200)]
graphicsview: use std::sort instead of qSort

In almost all cases, std::sort is wildly faster than qSort - but especially in
the case where the input data is already sorted. in some stress tests which ran
through the index with a lot of items, this commit provides huge speedup (684ms
down to 10ms for painting 15001 empty items on the provided benchmark), for me.

Task-number: QTBUG-11022
Change-Id: I5551f8e320c33ba13d464bf22047a665c81f3b74
Reviewed-by: Peter Kümmel <syntheticpp@gmx.net>
Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
11 years agoDoc: fix yet more errors reported by qdoc
aavit [Mon, 3 Sep 2012 11:45:33 +0000 (13:45 +0200)]
Doc: fix yet more errors reported by qdoc

Change-Id: I67ac081ce95235912784bbbc347dd8f80fdebbde
Reviewed-by: Kim M. Kalland <kim.kalland@nokia.com>
11 years agoQNX: Tidy up QMAKE_LFLAGS in qnx mkspecs
Sean Harmer [Mon, 3 Sep 2012 13:50:33 +0000 (14:50 +0100)]
QNX: Tidy up QMAKE_LFLAGS in qnx mkspecs

We do not need to include -lang-c++ more than once in QMAKE_LFLAGS*
variables. The fact that this was not appearing more than once was due
to QMAKE_LFLAGS being overwritten (rather than appended to) in
qcc-base-qnx.conf and a weird coincindence in qmake's code to dedupe
libraries passed in to QMAKE_LFLAGS. The deduping was working based
upon options beginning with "-l", including the -lang-c++ option here.

Change-Id: I983f216c0e362a9fe6a924074c5d84aaa659a14f
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
11 years agoGenerate includes for Qt containers used as auto-metatypes.
Stephen Kelly [Mon, 3 Sep 2012 10:55:38 +0000 (12:55 +0200)]
Generate includes for Qt containers used as auto-metatypes.

Otherwise the containers might be forward declared in the moc file,
and when the moc file is compiled in a standalone translation unit,
the full definition of it would not be available. This results in
odd compile errors, so instead generate the includes if required.

Change-Id: Ie01c5a5d45314daad0b00dec03b3e1e18cdbae64
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Volker Krause <volker.krause@kdab.com>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
11 years agoremove handling of QMAKE_FILETAGS
Oswald Buddenhagen [Thu, 16 Aug 2012 19:20:02 +0000 (21:20 +0200)]
remove handling of QMAKE_FILETAGS

it was unused for a decade. and broken, of course.

Change-Id: I9713d595d95c5b074ef96dfe9b1c314b9198bd7e
Reviewed-by: Daniel Teske <daniel.teske@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
11 years agoremove unnecessary QMAKESPEC fallback code
Oswald Buddenhagen [Thu, 16 Aug 2012 09:43:48 +0000 (11:43 +0200)]
remove unnecessary QMAKESPEC fallback code

QMAKESPEC is now always set

Change-Id: Ib3f7356a9260d42315747095e28db6604b2dcfe9
Reviewed-by: Daniel Teske <daniel.teske@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
11 years agoremove pretenses of manual dependencies
Oswald Buddenhagen [Tue, 28 Aug 2012 13:28:44 +0000 (15:28 +0200)]
remove pretenses of manual dependencies

now that "make depend" actually works again, just clean out the gunk.

Change-Id: Ia1858a2474c9a4544ae16c53349aa7ae09e0c685
Reviewed-by: Daniel Teske <daniel.teske@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
11 years agounbreak "make depend" for shadow builds
Oswald Buddenhagen [Tue, 28 Aug 2012 13:27:31 +0000 (15:27 +0200)]
unbreak "make depend" for shadow builds

Change-Id: Ib79ba79e41cfeac9350852395b03c331dc4fe2a3
Reviewed-by: Daniel Teske <daniel.teske@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>