profile/ivi/qtbase.git
12 years agoRemove obsolete code from QStateMachine test.
Jason McDonald [Fri, 18 Nov 2011 07:36:43 +0000 (17:36 +1000)]
Remove obsolete code from QStateMachine test.

The removed code was already disabled because it tested API that never
made into an official Qt release -- see commit ad1441fc in the Qt 4.x
history.

Change-Id: I7dbfb83c82bdb79e8d3f7f6c7043d76913dea589
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agotst_qsslsocket: don't run SSLv2 tests when SSLv2 has been disabled
Rohan McGovern [Fri, 18 Nov 2011 04:15:11 +0000 (14:15 +1000)]
tst_qsslsocket: don't run SSLv2 tests when SSLv2 has been disabled

SSLv2 may be disabled in openssl at compile time.
If so, do not attempt to test it.

Change-Id: I189c8fde5b5dc8e739d54cc1adde1d3e3e217391
Reviewed-by: Richard J. Moore <rich@kde.org>
Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
12 years agoFix sporadic hang in QLocalServer::close() in OS X 10.7
Robert Knight [Fri, 18 Nov 2011 17:07:21 +0000 (18:07 +0100)]
Fix sporadic hang in QLocalServer::close() in OS X 10.7

There is a bug in CFSocket/CFRunLoopSource in OS X 10.7 which can lead to a deadlock
in CFRunLoopRemoveSource or CFRunLoopSourceInvalidate if the CFSocket manager thread
is concurrently calling CFSocketInvalidate as a result of the socket's file descriptor
having been closed.

QLocalServer::close() triggers this race by closing the socket fd before unregistering
the QSocketNotifier, which internally uses CFSocket.

This commit fixes the problem by changing the ordering in close() so that the socket notifier
is disabled before closing the file descriptor.  This change also makes QLocalServer::close()
perform operations in reverse order to QLocalServer::listen(), as would be expected.

Task-number: QTBUG-22789
Merge-request: 1470
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
(cherry picked from commit a9c3f7169faf4621d39714f753d6e8b376c5d6e5)
Change-Id: Ia9c3f7169faf4621d39714f753d6e8b376c5d6e5

12 years agoCompile fix for Mac OS X 10.7 with 10.6 sdk
Andy Shaw [Thu, 10 Nov 2011 10:36:04 +0000 (11:36 +0100)]
Compile fix for Mac OS X 10.7 with 10.6 sdk

Since it is an example it is cleaner to just include the header file
as it will be available on other platforms anyway.  Also ensured that
the Qt includes were first before the system ones.

Task-number: QTBUG-22641

Merge-request: 1462
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
(cherry picked from commit 4fffdabc948ff6afc6008d4cb723a6a2e10eef79)
Change-Id: I4fffdabc948ff6afc6008d4cb723a6a2e10eef79

12 years agoGive better error message when using unsupported lookbehinds in QRegExp
Kjell Rune Skaaraas [Mon, 7 Nov 2011 15:18:33 +0000 (16:18 +0100)]
Give better error message when using unsupported lookbehinds in QRegExp

Merge-request: 1456
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
(cherry picked from commit e0383c9b8bd6f4e3d445d69690f84209cad42bb5)
Change-Id: Ie0383c9b8bd6f4e3d445d69690f84209cad42bb5

12 years agoFix QFile::copy() returning false but error() being NoError
xiechyong [Fri, 28 Oct 2011 04:07:26 +0000 (21:07 -0700)]
Fix QFile::copy() returning false but error() being NoError

Calling close() after setError() will unset the error.

Task-number: QTBUG-11982
Merge-request: 2712
Reviewed-by: ossi
(cherry picked from commit 16f67b49ae5232d4d0fb19e0333f5e2ef2a65449)
Change-Id: I16f67b49ae5232d4d0fb19e0333f5e2ef2a65449
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agoHarfbuzz shaper: kerning adjustment does not need to be modified by RTL
John Tapsell [Thu, 27 Oct 2011 18:52:03 +0000 (20:52 +0200)]
Harfbuzz shaper: kerning adjustment does not need to be modified by RTL

Merge-request: 1435
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
(cherry picked from commit 1b928f5e41888150c4d85ff4df8a9fcab9b06d90)
Change-Id: I1b928f5e41888150c4d85ff4df8a9fcab9b06d90

12 years agoAdd -nn for .cpp MOC preprocessing for INTEGRITY
Rolland Dudemaine [Wed, 12 Oct 2011 18:38:10 +0000 (20:38 +0200)]
Add -nn for .cpp MOC preprocessing for INTEGRITY

qmake generates .gpj project files for INTEGRITY.
Calls to moc on headers or code that do not produce actual output cause
a Note to be generated. This is considered as an error during build by
the Green Hills gbuild build tool.
-nn can be added to not generate that note when no output is generated.
This was already done for headers in util/integrity/qt.bod, but it was
not there yet for .cpp files.

Merge-request: 2693
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
(cherry picked from commit 480b2f4c79160afaac7934936d3ae6ea382ae2bb)
Change-Id: I480b2f4c79160afaac7934936d3ae6ea382ae2bb

12 years agoRemove commented out code.
Rolland Dudemaine [Wed, 12 Oct 2011 18:38:09 +0000 (20:38 +0200)]
Remove commented out code.

Merge-request: 2693
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
(cherry picked from commit c37ba1319c5789b82e14b84e9bc85ceff7cc6b5e)
Change-Id: Ic37ba1319c5789b82e14b84e9bc85ceff7cc6b5e

12 years agoBuild fix for WINCE to qfilesystemengine_win.cpp
jaanttil [Wed, 5 Oct 2011 19:28:19 +0000 (21:28 +0200)]
Build fix for WINCE to qfilesystemengine_win.cpp

Merge-request: 2662
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
(cherry picked from commit f4f1b712e1389987e045bb8f6ba654ea9e11d24e)
Change-Id: If4f1b712e1389987e045bb8f6ba654ea9e11d24e

12 years agoFixed typo in QSettings documentation.
Sam Protsenko [Wed, 5 Oct 2011 17:42:21 +0000 (19:42 +0200)]
Fixed typo in QSettings documentation.

Merge-request: 1411
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
(cherry picked from commit af448ba50d1c89548d41b7aebdf6047e8f2aabf2)
Change-Id: Iaf448ba50d1c89548d41b7aebdf6047e8f2aabf2

12 years agoQNetworkAccessBackend::start() is used although QT_NO_BEARERMANAGEMENT is defined.
shkim [Thu, 29 Sep 2011 14:14:05 +0000 (16:14 +0200)]
QNetworkAccessBackend::start() is used although QT_NO_BEARERMANAGEMENT is defined.

Merge-request: 2690
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
(cherry picked from commit 4245a82a3eed3ec21b6affc5836af5b2ad2d42e4)
Change-Id: I4245a82a3eed3ec21b6affc5836af5b2ad2d42e4

12 years agoFix broken Solaris build (getpwnam_r usage)
Iikka Eklund [Thu, 22 Sep 2011 13:11:42 +0000 (15:11 +0200)]
Fix broken Solaris build (getpwnam_r usage)

Added ifdef inside qt_tildeExpansion function to use correct
version of getpwnam_r depending on _C_POSIX_SOURCE version
on Solaris platform.

Task-number: QTBUG-21451
Merge-request: 1380
Reviewed-by: ossi
(cherry picked from commit 48f64fc7ae9f0e9e8ab07ab60ccd55d3b053dfab)
Change-Id: I48f64fc7ae9f0e9e8ab07ab60ccd55d3b053dfab
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agoadding a getter cubicBezierSpline() to QEasingCurve
Thomas Hartmann [Fri, 18 Nov 2011 16:32:47 +0000 (17:32 +0100)]
adding a getter cubicBezierSpline() to QEasingCurve

Change-Id: Ida722f013613d8633867a902660da30d28aeb918
Reviewed-by: Aaron Kennedy <aaron.kennedy@nokia.com>
12 years agoconfigure.exe: Reduce size by using -O1 instead of -O2.
Friedemann Kleint [Fri, 18 Nov 2011 15:18:41 +0000 (16:18 +0100)]
configure.exe: Reduce size by using -O1 instead of -O2.

Change-Id: Ica4d19364415180411cd74df7c3fb92d0100bfba
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agomkspecs: Case-insensitive check of paths on Windows.
Friedemann Kleint [Thu, 17 Nov 2011 15:00:12 +0000 (16:00 +0100)]
mkspecs: Case-insensitive check of paths on Windows.

Change-Id: I2b46bce79774ed9e5b5f6d73cc6e62ae50e35a5e
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
12 years agoWindows: Adapt mkspec for MinGW / gcc 4.6.
Friedemann Kleint [Thu, 17 Nov 2011 08:18:05 +0000 (09:18 +0100)]
Windows: Adapt mkspec for MinGW / gcc 4.6.

gcc 4.6 becomes the minimum required version in Qt 5.

See also d4150975af620e2889cc58bd476bac6b4d101db3
in Qt 4.8.

Change-Id: If66ce0be755263c20b0a4371523c6590592d962d
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
12 years agoDocument new input method hints introduced in Qt 5
Joona Petrell [Wed, 16 Nov 2011 13:42:20 +0000 (15:42 +0200)]
Document new input method hints introduced in Qt 5

Change-Id: Ic6aa77b410ed8189c2b100ca527a7019cdaf3b8b
Reviewed-by: Pekka Vuorela <pekka.ta.vuorela@nokia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
12 years agoResolve a number of compilation issues with INTEGRITY
Rolland Dudemaine [Mon, 19 Sep 2011 15:03:22 +0000 (17:03 +0200)]
Resolve a number of compilation issues with INTEGRITY

First, #ifdef'ed out getpwuid_r() and getpwgid_r() usage since users/groups support is not in in single-process Posix mode.
Also, correct a typo and add missing files to io.pri.
Update documentation to disable libtiff which won't compile until ibtiff itself is updated, and add back -no-exceptions in the sample command line. And add a line to compile host tools.
Add a dummy QT_OPEN_LARGEFILE definition in qplatformdefs.h since there is code that requires it.
Move definition of getGlyph() after the definition of qHash(GlyphAndSubPixelPosition).

Merge-request: 2686
Reviewed-by: ossi
(cherry picked from commit 8fe04a14b1f3688c9ce0933ebec0c28616595d93)
Change-Id: I8fe04a14b1f3688c9ce0933ebec0c28616595d93
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agofix doc typo
Oswald Buddenhagen [Mon, 5 Sep 2011 15:33:33 +0000 (17:33 +0200)]
fix doc typo

(cherry picked from commit 9c86b3b0028d79cbca129afafa33d72d624d65c3)
Change-Id: I9c86b3b0028d79cbca129afafa33d72d624d65c3
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agoEnsure that the corewlan plugin can be built with the Mac OS X 10.7 sdk
Oswald Buddenhagen [Mon, 5 Sep 2011 15:23:53 +0000 (17:23 +0200)]
Ensure that the corewlan plugin can be built with the Mac OS X 10.7 sdk

When the 10.7 SDK was specified explicitly then it would fail the check
inside the pro file.  So this ensures that this is accounted for.

Task-number: QTBUG-20516

Merge-request: 2657
Reviewed-by: ossi
(cherry picked from commit ce1a25fc692abcaa1c825f465d6a158efa953b06)
Change-Id: Ice1a25fc692abcaa1c825f465d6a158efa953b06
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agoremove obsolete define
Oswald Buddenhagen [Mon, 5 Sep 2011 15:24:07 +0000 (17:24 +0200)]
remove obsolete define

(cherry picked from commit 85cd78b01812d108f381e42b044abaa888c4146e)
Change-Id: I85cd78b01812d108f381e42b044abaa888c4146e
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agoFix a memory leak in QXcbConnection.
Jędrzej Nowacki [Thu, 17 Nov 2011 15:58:38 +0000 (16:58 +0100)]
Fix a memory leak in QXcbConnection.

Change-Id: I2307bf434c53d9321c71609eeacc1f3883bbbb13
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
12 years agoqtbase: Warnings fixes.
Friedemann Kleint [Thu, 17 Nov 2011 16:09:32 +0000 (17:09 +0100)]
qtbase: Warnings fixes.

Change-Id: Ie97e36bc168b3de3cae2d0eb615e777884529a06
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
12 years agoImprove diagnostics of QPluginLoader test.
Jason McDonald [Fri, 18 Nov 2011 07:24:38 +0000 (17:24 +1000)]
Improve diagnostics of QPluginLoader test.

Use QVERIFY2 so that the test output shows the full error string when it
does not contain the expected sub-string.

Change-Id: I31f91bd5c47c082aacabd2333bc12137bc4d24a6
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoFix indentation of QPluginLoader test.
Jason McDonald [Fri, 18 Nov 2011 07:20:50 +0000 (17:20 +1000)]
Fix indentation of QPluginLoader test.

Change-Id: I4c6957d2a67ac387232226098b4490e3d5a86d51
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoImprove QPluginLoader autotest diagnostics.
Jason McDonald [Fri, 18 Nov 2011 07:12:09 +0000 (17:12 +1000)]
Improve QPluginLoader autotest diagnostics.

Previously, the user had to recompile the test with an additional define
to see the plugin loader error string.  By re-ordering the verification
statements, we can ensure that the error string is visible in the test
results whenever its value is not the expected value, thus eliminating
the need for conditional diagnostics.

Change-Id: Iae9ef0b7cbad551fd56f0e0439eaad034f2420e3
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoRemove disabled code from QLibrary autotest
Jason McDonald [Fri, 18 Nov 2011 06:45:09 +0000 (16:45 +1000)]
Remove disabled code from QLibrary autotest

The removed code was already commented-out when it was first added in
2007, and would not form a useful test as it was not followed by any
verification steps.  QLibrary::setLoadHints() is tested elsewhere, so
this code can vanish.

Change-Id: I1c4dcaacaf31b0f38136336414cfbe3de1a406f3
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoRemove disabled test data from QVariant test.
Jason McDonald [Fri, 18 Nov 2011 06:35:07 +0000 (16:35 +1000)]
Remove disabled test data from QVariant test.

The removed data duplicated the first row of test data in the same
function.

Change-Id: I5d55b970d072d58c170b3ed3004c1661c6d0d13c
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoRemove obsolete code from QVariant test.
Jason McDonald [Fri, 18 Nov 2011 06:25:42 +0000 (16:25 +1000)]
Remove obsolete code from QVariant test.

Change-Id: If609ddbef7002cb48f4459efd8f2c6edb02c8677
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoRemove obsolete code from QTimer test.
Jason McDonald [Fri, 18 Nov 2011 06:14:14 +0000 (16:14 +1000)]
Remove obsolete code from QTimer test.

The removed code was for Windows versions <= 2000, which are not
supported by Qt5.

Change-Id: I779ffb8427035b7eb97d8d0af403d03065bc779c
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoChange confusing test function name.
Jason McDonald [Fri, 18 Nov 2011 04:09:05 +0000 (14:09 +1000)]
Change confusing test function name.

Naming a test function "_data" is potentially confusing as that string
is a suffix reserved for functions that create data tables for
data-driven tests.  Presumably this function was accidentally caught in
a search and replace at some point before the tests were imported into
the Qt repository in 2006.

Change-Id: I451c0400a1580233ee90b75dd5ad489ee3d3788e
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoFix typo in QUrl autotest.
Jason McDonald [Fri, 18 Nov 2011 04:00:48 +0000 (14:00 +1000)]
Fix typo in QUrl autotest.

Change-Id: Id85ad5c16e3a5b7a1614affa041d19f5062073fd
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoRemove obsolete test data from QFileInfo test.
Jason McDonald [Fri, 18 Nov 2011 00:45:02 +0000 (10:45 +1000)]
Remove obsolete test data from QFileInfo test.

The removed data relied on the test's own source file having no write
permissions, but that is not a valid assumption -- in a source package
the file wouldn't have had write permissions, in Perforce it would have
depended on whether the file had been checked-out for editing and in git
the file would always have write permission.

Change-Id: I000596f122f2765f97a09a08074938c90e2e9f95
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoRemove obsolete test data from QFile test.
Jason McDonald [Fri, 18 Nov 2011 01:14:16 +0000 (11:14 +1000)]
Remove obsolete test data from QFile test.

The removed data relied on the test's own source file having no write
permissions, but that is not a valid assumption -- in a source package
the file wouldn't have had write permissions, in Perforce it would have
depended on whether the file had been checked-out for editing and in git
the file would always have write permission.

Change-Id: I3b6100429120137095a210189961c8b97f06e50a
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoRemove obsolete test data from QFile test.
Jason McDonald [Fri, 18 Nov 2011 01:14:16 +0000 (11:14 +1000)]
Remove obsolete test data from QFile test.

The removed data relied on the test's own source file having no write
permissions, but that is not a valid assumption -- in a source package
the file wouldn't have had write permissions, in Perforce it would have
depended on whether the file had been checked-out for editing and in git
the file would always have write permission.

Change-Id: I3b6100429120137095a210189961c8b97f06e50a
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoRemove obsolete test data from QFileInfo test.
Jason McDonald [Fri, 18 Nov 2011 00:45:02 +0000 (10:45 +1000)]
Remove obsolete test data from QFileInfo test.

The removed data relied on the test's own source file having no write
permissions, but that is not a valid assumption -- in a source package
the file wouldn't have had write permissions, in Perforce it would have
depended on whether the file had been checked-out for editing and in git
the file would always have write permission.

Change-Id: I000596f122f2765f97a09a08074938c90e2e9f95
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoImprove QBuffer autotest.
Jason McDonald [Thu, 17 Nov 2011 06:11:59 +0000 (16:11 +1000)]
Improve QBuffer autotest.

This commit fixes several issues found in the readLineBoundaries() test
function.

First, the test performed some test actions but did not perform any
verification steps to check that the outcome of those actions was
acceptable.

Second, the test didn't need to write the buffered data to a file to
verify line-by-line reading.

Third, the get/unget action was unrelated to the readLineBoundaries()
test and has been moved to a separate test function.  That test function
now tests that get/unget works at every position in a buffer, not just
at position 0.

Change-Id: Icad52ed598e94b6e05a194b9ab301d099bfc094c
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoRemove obsolete comment from QDataStream test.
Jason McDonald [Fri, 18 Nov 2011 00:19:11 +0000 (10:19 +1000)]
Remove obsolete comment from QDataStream test.

The removed comment was introduced before the tests were imported into
the Qt repository in 2006 and seems to relate to code that no longer
exists.

Change-Id: Ic21e46fe0157adf5be9dc62de098517b7b27c310
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoRemove obsolete comment from QDataStream test.
Jason McDonald [Fri, 18 Nov 2011 00:31:12 +0000 (10:31 +1000)]
Remove obsolete comment from QDataStream test.

The removed comment was introduced before the tests were imported into
the Qt repository in 2006 and seems to relate to a test failure that no
longer occurs.

Change-Id: I01f372f6a4f48110711f4f2a86e73acfb7134e24
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoRemove obsolete comment from QDataStream test.
Jason McDonald [Fri, 18 Nov 2011 00:31:12 +0000 (10:31 +1000)]
Remove obsolete comment from QDataStream test.

The removed comment was introduced before the tests were imported into
the Qt repository in 2006 and seems to relate to a test failure that no
longer occurs.

Change-Id: I01f372f6a4f48110711f4f2a86e73acfb7134e24
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoRemove obsolete comment from QDataStream test.
Jason McDonald [Fri, 18 Nov 2011 00:19:11 +0000 (10:19 +1000)]
Remove obsolete comment from QDataStream test.

The removed comment was introduced before the tests were imported into
the Qt repository in 2006 and seems to relate to code that no longer
exists.

Change-Id: Ic21e46fe0157adf5be9dc62de098517b7b27c310
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoImprove QBuffer autotest.
Jason McDonald [Thu, 17 Nov 2011 06:11:59 +0000 (16:11 +1000)]
Improve QBuffer autotest.

This commit fixes several issues found in the readLineBoundaries() test
function.

First, the test performed some test actions but did not perform any
verification steps to check that the outcome of those actions was
acceptable.

Second, the test didn't need to write the buffered data to a file to
verify line-by-line reading.

Third, the get/unget action was unrelated to the readLineBoundaries()
test and has been moved to a separate test function.  That test function
now tests that get/unget works at every position in a buffer, not just
at position 0.

Change-Id: Icad52ed598e94b6e05a194b9ab301d099bfc094c
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoFixed crashes from tests using xcb plugin with -qtnamespace.
Rohan McGovern [Fri, 18 Nov 2011 01:49:45 +0000 (11:49 +1000)]
Fixed crashes from tests using xcb plugin with -qtnamespace.

Use QT_BEGIN_NAMESPACE/QT_END_NAMESPACE consistently in xcb plugin.
Some, but not all, of the sources were already using QT_BEGIN_NAMESPACE.

Change-Id: I23b83cc88870fd4039437b733084ab86dd807356
Reviewed-by: Toby Tomkins <toby.tomkins@nokia.com>
12 years agoFixed crashes from tests using xcb plugin with -qtnamespace.
Rohan McGovern [Fri, 18 Nov 2011 01:49:45 +0000 (11:49 +1000)]
Fixed crashes from tests using xcb plugin with -qtnamespace.

Use QT_BEGIN_NAMESPACE/QT_END_NAMESPACE consistently in xcb plugin.
Some, but not all, of the sources were already using QT_BEGIN_NAMESPACE.

Change-Id: I23b83cc88870fd4039437b733084ab86dd807356
Reviewed-by: Toby Tomkins <toby.tomkins@nokia.com>
12 years agoDon't depend on moc to disable test functions.
Jason McDonald [Tue, 15 Nov 2011 01:36:18 +0000 (11:36 +1000)]
Don't depend on moc to disable test functions.

The moc tool is not aware of all defines (particularly those that are
compiler builtins) and does not correctly evaluate others that depend
on compiler builtins, such as Q_OS_FOO.

This commit reverts parts of the following commits, but is not a
complete fix as there were many instances of this problem in the tests
prior to those commits:
    924d810dbdcd5b5b0fa860922b2487ea9062d002
    8aaff6751038b88d17e23be6fcee945771297c5b
    338d3f11973412047c2c9cd41cbd0c961d738ef3
    a55034062ba2bf73a9f1ed3d9cf31745b38149e3
    253497b7446c7d723aa3bdd7152e25d6852f2604
    7cfad460c56319ba89c4a3a0bbcb2e54ab1cdbc6
    9d2ff58f3642828e494e7e9b2df7dbb8e2cd408f
    0cf6baa2d61ebaad2a2a0530c37f27e719b68f4b

Change-Id: I947d797fe3ec76139ba1b55561cea569895662c5
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoconfigure: clean up whitespace, comments.
Rohan McGovern [Thu, 17 Nov 2011 23:22:20 +0000 (09:22 +1000)]
configure: clean up whitespace, comments.

Make the indentation sensible.

Remove comments which merely repeat the name of a variable on the next
line.

Change-Id: Ic3ecaaaba61795aeee10299ee44523eb725ecad9
Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
12 years agoconfigure: clean up whitespace, comments.
Rohan McGovern [Thu, 17 Nov 2011 23:22:20 +0000 (09:22 +1000)]
configure: clean up whitespace, comments.

Make the indentation sensible.

Remove comments which merely repeat the name of a variable on the next
line.

Change-Id: Ic3ecaaaba61795aeee10299ee44523eb725ecad9
Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
12 years agoDon't depend on moc to disable test functions.
Jason McDonald [Tue, 15 Nov 2011 01:36:18 +0000 (11:36 +1000)]
Don't depend on moc to disable test functions.

The moc tool is not aware of all defines (particularly those that are
compiler builtins) and does not correctly evaluate others that depend
on compiler builtins, such as Q_OS_FOO.

This commit reverts parts of the following commits, but is not a
complete fix as there were many instances of this problem in the tests
prior to those commits:
    924d810dbdcd5b5b0fa860922b2487ea9062d002
    8aaff6751038b88d17e23be6fcee945771297c5b
    338d3f11973412047c2c9cd41cbd0c961d738ef3
    a55034062ba2bf73a9f1ed3d9cf31745b38149e3
    253497b7446c7d723aa3bdd7152e25d6852f2604
    7cfad460c56319ba89c4a3a0bbcb2e54ab1cdbc6
    9d2ff58f3642828e494e7e9b2df7dbb8e2cd408f
    0cf6baa2d61ebaad2a2a0530c37f27e719b68f4b

Change-Id: I947d797fe3ec76139ba1b55561cea569895662c5
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoFixed compile of autotests with -qtnamespace.
Rohan McGovern [Thu, 17 Nov 2011 22:48:07 +0000 (08:48 +1000)]
Fixed compile of autotests with -qtnamespace.

Make sure to use the Qt namespace for qGlobalPostedEventsCount.

Change-Id: I558a0b0fba1e22a2edd96f9499a2bab82046c4a4
Reviewed-by: Toby Tomkins <toby.tomkins@nokia.com>
12 years agoFixed compile of autotests with -qtnamespace.
Rohan McGovern [Thu, 17 Nov 2011 22:48:07 +0000 (08:48 +1000)]
Fixed compile of autotests with -qtnamespace.

Make sure to use the Qt namespace for qGlobalPostedEventsCount.

Change-Id: I558a0b0fba1e22a2edd96f9499a2bab82046c4a4
Reviewed-by: Toby Tomkins <toby.tomkins@nokia.com>
12 years agoCall invalidateResource() on QOpenGLMultiGroupSharedResource-owned resources
Kent Hansen [Thu, 17 Nov 2011 15:06:27 +0000 (16:06 +0100)]
Call invalidateResource() on QOpenGLMultiGroupSharedResource-owned resources

Commit 202127f860208c21145e05685bc54219e1655dbd ensured that
QOpenGLMultiGroupSharedResource-owned resources are deleted,
but it was missing a call to invalidateResource().

Change-Id: I166ce8a7298772408081331fe1a91bd2cd88aebb
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
12 years agoUpdate V8
Kai Koehne [Thu, 17 Nov 2011 15:33:41 +0000 (16:33 +0100)]
Update V8

Change-Id: Ie6157e0baa55271707b3e00ed80b67ab79f4f570
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
12 years agoUpdate V8
Kai Koehne [Thu, 17 Nov 2011 15:33:41 +0000 (16:33 +0100)]
Update V8

Change-Id: Ie6157e0baa55271707b3e00ed80b67ab79f4f570
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
12 years agoCall invalidateResource() on QOpenGLMultiGroupSharedResource-owned resources
Kent Hansen [Thu, 17 Nov 2011 15:06:27 +0000 (16:06 +0100)]
Call invalidateResource() on QOpenGLMultiGroupSharedResource-owned resources

Commit 202127f860208c21145e05685bc54219e1655dbd ensured that
QOpenGLMultiGroupSharedResource-owned resources are deleted,
but it was missing a call to invalidateResource().

Change-Id: I166ce8a7298772408081331fe1a91bd2cd88aebb
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
12 years agoFix tst_Moc::oldStyleCasts
Olivier Goffart [Wed, 16 Nov 2011 08:07:24 +0000 (09:07 +0100)]
Fix tst_Moc::oldStyleCasts

This tests that the moc generated file produces no warnings with very
pedentic compilation flags.
In that case, there was a warning because of the use of the C casts

Change-Id: Ie79c6d053ff35c55276a07212c5d60f759f693ee
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
12 years agoFix tst_Moc::oldStyleCasts
Olivier Goffart [Wed, 16 Nov 2011 08:07:24 +0000 (09:07 +0100)]
Fix tst_Moc::oldStyleCasts

This tests that the moc generated file produces no warnings with very
pedentic compilation flags.
In that case, there was a warning because of the use of the C casts

Change-Id: Ie79c6d053ff35c55276a07212c5d60f759f693ee
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
12 years agoReimplement QMetaType::typeName.
Jędrzej Nowacki [Mon, 7 Nov 2011 13:23:05 +0000 (14:23 +0100)]
Reimplement QMetaType::typeName.

New implementation is slightly faster (~30%) and it is not dependent
on order of definitions in QMetType::Type. Which means that we do not
have to maintain a separate type list.

Change-Id: I0ceb8c919c08afaa55146fbc3f021b78ffc2c063
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoReimplement some QMetaType methods.
Jędrzej Nowacki [Tue, 1 Nov 2011 11:58:42 +0000 (12:58 +0100)]
Reimplement some QMetaType methods.

Methods of QMetaType; sizeOf, construct and destruct were reimplement
using QMetaTypeSwitcher. The change should have impact only on
maintenance (by removing 3 type switches).

Change-Id: Iac3eb52de75d46f12ac32f229a26aec5b5bc7af2
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoFix sliders style issues.
Pierre Rossi [Wed, 16 Nov 2011 15:45:28 +0000 (16:45 +0100)]
Fix sliders style issues.

Due to their widget heritage,some styles' logic for drawing sliders
incorrectly assumed a rect with a top left point at (0,0).

Change-Id: I02d9c32d925650ccb36e2b917dd890e5d2bbf925
Reviewed-by: Jens Bache-Wiig
12 years agoFix sliders style issues.
Pierre Rossi [Wed, 16 Nov 2011 15:45:28 +0000 (16:45 +0100)]
Fix sliders style issues.

Due to their widget heritage,some styles' logic for drawing sliders
incorrectly assumed a rect with a top left point at (0,0).

Change-Id: I02d9c32d925650ccb36e2b917dd890e5d2bbf925
Reviewed-by: Jens Bache-Wiig
12 years agoReimplement some QMetaType methods.
Jędrzej Nowacki [Tue, 1 Nov 2011 11:58:42 +0000 (12:58 +0100)]
Reimplement some QMetaType methods.

Methods of QMetaType; sizeOf, construct and destruct were reimplement
using QMetaTypeSwitcher. The change should have impact only on
maintenance (by removing 3 type switches).

Change-Id: Iac3eb52de75d46f12ac32f229a26aec5b5bc7af2
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoReimplement QMetaType::typeName.
Jędrzej Nowacki [Mon, 7 Nov 2011 13:23:05 +0000 (14:23 +0100)]
Reimplement QMetaType::typeName.

New implementation is slightly faster (~30%) and it is not dependent
on order of definitions in QMetType::Type. Which means that we do not
have to maintain a separate type list.

Change-Id: I0ceb8c919c08afaa55146fbc3f021b78ffc2c063
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoImprove the testability of QSslOptions.
Richard Moore [Tue, 15 Nov 2011 21:58:05 +0000 (21:58 +0000)]
Improve the testability of QSslOptions.

The handling of QSslOptions is complicated not only by the subject, but
also by the fact that some of the openssl directives are negatives. This
commit tries to separate the inherent complexity from the complexity of
the api by allowing us to test them independently.

Change-Id: Ieb9386c69dd9b0b49dc42e26b2878a301f26ded1
Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
12 years agoImprove the testability of QSslOptions.
Richard Moore [Tue, 15 Nov 2011 21:58:05 +0000 (21:58 +0000)]
Improve the testability of QSslOptions.

The handling of QSslOptions is complicated not only by the subject, but
also by the fact that some of the openssl directives are negatives. This
commit tries to separate the inherent complexity from the complexity of
the api by allowing us to test them independently.

Change-Id: Ieb9386c69dd9b0b49dc42e26b2878a301f26ded1
Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
12 years agoFixed compile of QtPlatformSupport with -qtnamespace.
Rohan McGovern [Thu, 17 Nov 2011 07:47:01 +0000 (17:47 +1000)]
Fixed compile of QtPlatformSupport with -qtnamespace.

Change-Id: Iba411d35abe85ecf29a44d99113954a0561ae286
Reviewed-by: Toby Tomkins <toby.tomkins@nokia.com>
Reviewed-by: hjk <qthjk@ovi.com>
12 years agoFixed compile of QtGui with -qtnamespace.
Rohan McGovern [Thu, 17 Nov 2011 07:39:52 +0000 (17:39 +1000)]
Fixed compile of QtGui with -qtnamespace.

GL headers should not be included inside of the Qt namespace.

Change-Id: Ib19cbd3ab7b071a96e0816798f8ebc3fd4e28448
Reviewed-by: Toby Tomkins <toby.tomkins@nokia.com>
Reviewed-by: hjk <qthjk@ovi.com>
12 years agoFix compilation with -force-asserts.
Friedemann Kleint [Thu, 17 Nov 2011 09:49:42 +0000 (10:49 +0100)]
Fix compilation with -force-asserts.

Change-Id: I2f697ba9ab9a5a8393e778abad4da18c7f232d7f
Reviewed-by: Harald Fernengel <harald.fernengel@nokia.com>
12 years agoWindows: Rebuild configure with support for V8 and -force-asserts.
Friedemann Kleint [Thu, 17 Nov 2011 09:44:31 +0000 (10:44 +0100)]
Windows: Rebuild configure with support for V8 and -force-asserts.

Change-Id: I52f4c842f0604d14a0fed8ebdc7a33938d977ec4
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
12 years agoWindows: Add -force-asserts to configure.exe
Friedemann Kleint [Thu, 17 Nov 2011 09:37:24 +0000 (10:37 +0100)]
Windows: Add -force-asserts to configure.exe

Change-Id: I678011f0e60d74a1b2d63a18570778e1f686f123
Reviewed-by: Harald Fernengel <harald.fernengel@nokia.com>
12 years agoRemove commented code from QBuffer autotest.
Jason McDonald [Thu, 17 Nov 2011 03:44:53 +0000 (13:44 +1000)]
Remove commented code from QBuffer autotest.

The removed code was commented-out before the tests were imported into
the Qt repository in June 2006.  This code is no longer valid as the
warning messages it relates to are not produced by any code in qtbase.

Change-Id: Iac63b27387b51a71c567386ca61faf5fb00c3364
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoImprove Q_FUNC_INFO autotest.
Jason McDonald [Thu, 17 Nov 2011 03:29:36 +0000 (13:29 +1000)]
Improve Q_FUNC_INFO autotest.

The availableWithoutDebug() test was trying to force QT_NO_DEBUG to be
defined, but was actually doing the opposite.  While I'm not satisfied
with the way this test works (it would be better to test with
QT_NO_DEBUG already defined when Q_FUNC_INFO is included). at least this
test now does what it says it does.

Additionally, the test has been improved by checking that Q_FUNC_INFO
returns a non-empty string, as opposed to just compiling.

Change-Id: I9175e3a7406152b6250b507a61b5062e3cfabeb8
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoBuild all tests on Mac OS X, but do not run them yet.
Bradley T. Hughes [Mon, 14 Nov 2011 13:43:32 +0000 (14:43 +0100)]
Build all tests on Mac OS X, but do not run them yet.

Previously, autotests and benchmarks were disabled on Mac OS X. This is
wrong, and needs to be corrected. The 'make check' target is disabled
for the autotests on Mac OS X for now, but all tests will now be built.
The check target does not actually run the benchmarks, so this can be
safely re-enabled without breaking the CI system.

There will be commits to follow which re-enable the 'make check' target
on Mac OS X for each module.

Change-Id: I1347da46e3688b48e8cc5d933ee5188ea3723639
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoDon't directly access QList contents
Alberto Mardegan [Fri, 11 Nov 2011 11:10:22 +0000 (12:10 +0100)]
Don't directly access QList contents

The existing code doesn't work on 64bit machines. We must first convert
the list into a QVector, which guarantees that elements are laid out
correctly as an array.

Merge-request: 1467
Reviewed-by: thiago
(cherry picked from commit 00020eed3fa948f69cfa776e92121edec6f975cc)
Change-Id: I00020eed3fa948f69cfa776e92121edec6f975cc
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoAllow overriding the output dir when running syncqt
Tor Arne Vestbø [Mon, 14 Nov 2011 12:18:08 +0000 (13:18 +0100)]
Allow overriding the output dir when running syncqt

This feature is only available to advanced qmake clients who have their
own defaults_pre.prf, where QMAKE_SYNCQT_OUTDIR is set before loading
Qt's own default_pre.

This is useful to be able to put the sync.profile file in a different
level in the source tree than where you want the output in the build
tree.

An alternate/complimenting solution would be to allow the output path
to be overriden from within the sync.profile file.

Change-Id: I3cdef82dbe492877507e269e18571456beeb2b7d
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
12 years agoRevert logic when building with --force-asserts
Harald Fernengel [Wed, 16 Nov 2011 10:56:48 +0000 (11:56 +0100)]
Revert logic when building with --force-asserts

This reverts commit f109f5b8a9c7e6939dfd6c6f72a3b67548f5483c.

Instead of disabling the asserts, rather enable the debug code
so the asserts actually trigger.

Change-Id: I6f62588d836de5c926294241e8d7196a963e4aac
Reviewed-by: Eckhart Koppen <eckhart.koppen@nokia.com>
12 years agoSSL: fix compilation warning with gcc 4.6.1
Peter Hartmann [Wed, 16 Nov 2011 11:17:38 +0000 (12:17 +0100)]
SSL: fix compilation warning with gcc 4.6.1

"qsslconfiguration.cpp:204:73: warning: suggest parentheses around
comparison in operand of ‘|’ [-Wparentheses]"

Change-Id: I887ffdf3ef8263c35a8f391b3fc97faee41b7dab
Reviewed-by: Martin Petersson <Martin.Petersson@nokia.com>
12 years agoFixes: unwanted gcc export of symbols from bundled libpng
aavit [Tue, 15 Nov 2011 08:13:46 +0000 (09:13 +0100)]
Fixes: unwanted gcc export of symbols from bundled libpng

This removes a change to libpng that was only relevant for building
a certain Qt 4 tool in certain environements without system libpng.
This is no longer relevant, so this kludge should now be removed.

Change-Id: I9a04ab0224f9e84ccab3ec27762582be439fe3ef
Reviewed-by: Kim M. Kalland <kim.kalland@nokia.com>
12 years agoFix Qt namespace compilation.
Toby Tomkins [Tue, 15 Nov 2011 01:23:33 +0000 (11:23 +1000)]
Fix Qt namespace compilation.

Change-Id: I259b5fde8e4d75d28def8650c4c9208accdf0bbe
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoSSL namespace: rename TlsV1 to TlsV1_0
Peter Hartmann [Mon, 14 Nov 2011 11:33:55 +0000 (12:33 +0100)]
SSL namespace: rename TlsV1 to TlsV1_0

This is a source-incompatible change.

TlsV1 is ambiguous; what is actually meant is TLS version 1.0. There are
also TLS versions 1.1 and 1.2; we might want to add options for these
once OpenSSL supports them (apparently they will be with OpenSSL version
1.0.1).

Change-Id: I940d020b181b5fa528788ef0c3c47e8ef873796a
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
12 years agoMake it possible to disable the 'check' target
Bradley T. Hughes [Mon, 14 Nov 2011 13:38:38 +0000 (14:38 +0100)]
Make it possible to disable the 'check' target

If subdir.CONFIG contains no_check_target, we do not recurse into
that subdir when generating the 'check' target.

This will be used to selectively disable crashing tests on Mac OS X.
Currently, all autotests are disabled on Mac OS X. The goal is to re-
enable them, but not all at once.  This approach allows us to get each
change through the CI system individually.

The first step is get all tests to build, but not run, then we will
re-enable the tests for each module, possibly disabling individual
tests at the same time.

Change-Id: I69f62c238f381ae0315d414cd71d76bc88b088dd
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
12 years agoRemove warnings from deprecated atomic operators in autotests
Bradley T. Hughes [Mon, 7 Nov 2011 12:39:35 +0000 (13:39 +0100)]
Remove warnings from deprecated atomic operators in autotests

Use QAtomic*::load() and ::store() instead of the deprecated
cast, assignment, and comparison operators. These will be removed
in the near future.

The tests for these particular operators have not been changed,
though, as the change to remove the operators will also remove
the respective tests.

Change-Id: I2f24d18992af0c6e0f487d707218e4e84f4bdd12
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
12 years agoMake QTest::newRow a bit more verbose if a data tag is null.
Jędrzej Nowacki [Wed, 9 Nov 2011 12:15:26 +0000 (13:15 +0100)]
Make QTest::newRow a bit more verbose if a data tag is null.

Currently QTest::newRow function expects to have correct tag string for
each test data. This was enforced by a simple assert. By adding a
an assert with message we might simplify debugging of a test that
generates test cases.

Change-Id: I84ebb397264c99e7bb46d281fd38583dd2d6964c
Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
12 years agoFix Q_ASSERT usage in case -force-asserts is enabled
Eckhart Koppen [Wed, 16 Nov 2011 07:47:45 +0000 (09:47 +0200)]
Fix Q_ASSERT usage in case -force-asserts is enabled

Certain Q_ASSERT usages are not compiling with -force-asserts since they
are checking for instance variables or other items which are not
available in release mode.

This fix guards the asserts to only be enabled in debug mode.

Change-Id: I2ed74e3d5118608361e8c924e93d8ff0efdc8eab
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
12 years agoAdd correct event mask for Qt::WindowTransparentForInput in xcb plugin
Jørgen Lind [Tue, 15 Nov 2011 14:05:52 +0000 (15:05 +0100)]
Add correct event mask for Qt::WindowTransparentForInput in xcb plugin

Change-Id: I4c683c08876cc6fa934971399af7e48b160168fc
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
12 years agoAdding a "helper assert" for when you can create QWindow
Jørgen Lind [Tue, 15 Nov 2011 14:02:03 +0000 (15:02 +0100)]
Adding a "helper assert" for when you can create QWindow

maybe if your trying to instansiate a QWindow before the QApplication has
been instansiated.

Change-Id: I68ed4ad1dbdfedc242a7cb27c1381d50a3d3dfa4
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
12 years agoFix QDockWidget titlebar button positioning on Mac OS X
Pasi Matilainen [Mon, 14 Nov 2011 14:39:25 +0000 (15:39 +0100)]
Fix QDockWidget titlebar button positioning on Mac OS X

Move the QDockWidget close and float buttons from the right end of the
dock widget title bar to the left end to avoid Mac App Store rejection.

Task-number: QTBUG-19493

Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
(cherry picked from commit 3b2bd144b7873daf2e7119248dbac7c0f0253993)
Change-Id: I3b2bd144b7873daf2e7119248dbac7c0f0253993

12 years agoFixed memory leak in Windows Vista style widgets
Tero Ahola [Mon, 14 Nov 2011 14:27:01 +0000 (15:27 +0100)]
Fixed memory leak in Windows Vista style widgets

The animations are now deleted in destruction of the Vista style.
With the previous implementation the animations were not deleted for
instance if you move mouse cursor off from a widget with hover
animation (like QPushButton).

Task-number: QTBUG-21532

Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
(cherry picked from commit 261bbb12003dab0e45b5814f85dd74aa64bcfb79)
Change-Id: I261bbb12003dab0e45b5814f85dd74aa64bcfb79

12 years agoProvide defaultFont with fontconfig db
Jiang Jiang [Fri, 11 Nov 2011 16:25:30 +0000 (17:25 +0100)]
Provide defaultFont with fontconfig db

So that it won't just return "Helvetica" that may not exist in
target system. Providing it seems to fix QTBUG-21833 as well,
thus we can remove the QEXPECT_FAIL statement in qlistview test.
'_' appears to reach the minimum right bearing in some fonts.

Task-number: QTBUG-21833
Change-Id: I2340af6ee736083ec4f6575e469840ebec4e545e
Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
12 years agoHide QVariant helper classes in a namespace.
Jędrzej Nowacki [Tue, 15 Nov 2011 12:49:52 +0000 (13:49 +0100)]
Hide QVariant helper classes in a namespace.

Moving these classes to an unnamed namespace reduced chances of
a name conflict and size of executable. GCC 4.6 in release mode produces
a 5kB smaller binary.

Change-Id: Ie1819a88180f9db1cd32cc59ea6fe268ecbd5813
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoEnsure that QOpenGLMultiGroupSharedResources are cleaned up
Kent Hansen [Tue, 15 Nov 2011 15:39:16 +0000 (16:39 +0100)]
Ensure that QOpenGLMultiGroupSharedResources are cleaned up

When a GL context group is destroyed, all multi-group shared
resources associated with the group should be cleaned up.
Otherwise we could get a double deletion in the resource's
destructor, because it still retained a pointer to the
deleted group.

The missing cleanup resulted in a crash when the global
static qt_gl_functions_resource was destroyed, first seen
in the tst_examples autotest in qtdeclarative. It possibly
didn't manifest before because it's event loop-dependent
(the contexts are deleted via deleteLater()).

Change-Id: I6b1e0bfdfbbb2bff8e795f545e680fcdfa094768
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
12 years agoMake V8 build on Windows again
Kent Hansen [Tue, 15 Nov 2011 11:22:15 +0000 (12:22 +0100)]
Make V8 build on Windows again

Forgot to add a Windows-specific source file to the project
when the new V8 version was imported.

Change-Id: Id20dcba132bf2609338845e8a769fcc8c1cbc562
Reviewed-by: Aaron Kennedy <aaron.kennedy@nokia.com>
12 years agoAdd the ability to do unsafe SSL renegotiation as a fallback.
Richard Moore [Mon, 14 Nov 2011 21:56:40 +0000 (21:56 +0000)]
Add the ability to do unsafe SSL renegotiation as a fallback.

This commit adds the ability to perform legacy SSL renegotiation as
a fallback via QSsl::SslOptions. This is something that used to work,
but has been disabled by default in newer versions of openssl. The
need for this has been reported by users (eg. in QTBUG-14983).

Change-Id: I5b80f3ffd07e0c5faddc469f6a8f857bac5740f7
Reviewed-by: Corentin Chary <corentin.chary@gmail.com>
Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
12 years agomoc: Remove code that generate QMetaObject.
Olivier Goffart [Tue, 15 Nov 2011 09:33:32 +0000 (10:33 +0100)]
moc: Remove code that generate QMetaObject.

This code is totally outdated, and has never been used in Qt4 AFAIK

Change-Id: I775fe87532807e77fc94fe661e4b659c11bfd8be
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
12 years agomoc: fix Q_INVOKABLE returning references
Olivier Goffart [Tue, 15 Nov 2011 09:14:23 +0000 (10:14 +0100)]
moc: fix Q_INVOKABLE returning references

The moc generated code would not compile otherwise

Keep Moc::parseFunction and Moc::parseMaybeFunction in sync
(the first is used for signals and slots, and the second for normal
 functions such as Q_INVOKABLE)
Last patch that introduced function pointer updated parseFunction
but not parseMaybeFunction

When a slot return a reference, moc generate code that make the
MetaObject system think it is a void, so qt_metacall and invokeMethod
do not mess with the return value.
But when we want to take the function signature, in the IndexOfMethod
call, we need to have the exact return type.

Change-Id: I4661218d7ce367ad3934e73929e7d04f0a6dbc09
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
12 years agoAdd valgrind suppression files.
Morten Sorvig [Wed, 19 Oct 2011 13:06:45 +0000 (15:06 +0200)]
Add valgrind suppression files.

Change-Id: I35626479267de49924038a0aa93103a14f05702a
Reviewed-by: hjk <qthjk@ovi.com>
12 years agoAlways use the hex format for certificate serial numbers.
Richard Moore [Thu, 10 Nov 2011 22:37:16 +0000 (22:37 +0000)]
Always use the hex format for certificate serial numbers.

In Qt 4.x the serial number is reported by a mixture of the hex value
and the number, The hex is what is used by other tools, and we should do
the same.

Change-Id: Ia0361d43fb5b920d053c95e932e0c8a012436e5e
Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
12 years agoQEventDispatcherQPA: processEvents should only be called once
Olivier Goffart [Mon, 14 Nov 2011 21:35:05 +0000 (22:35 +0100)]
QEventDispatcherQPA: processEvents should only be called once

This caused a "deadlock" in tst_qobject::moveToThread

The problem was that QEventLoop::quit was called from the first
prcessed event in that loop, put calling process event a second time
deadlock because there is no more event to process

(In practice, some event can come from the window manager or the
inputs, but they may as well not come)

Change-Id: Ia469110eb9c9de57669e80cf19e933f410e469a4
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
12 years agoAllow to create a custom event dispatcher for specific QThreads.
Sven Anderson [Thu, 8 Sep 2011 15:40:55 +0000 (17:40 +0200)]
Allow to create a custom event dispatcher for specific QThreads.

QAbstractEventDispatcher() does no longer install itself into the current
thread.  Instead the new methods QThread::setEventDispatcher() and
QCoreApplication::setEventDispatcher() allow to install a custom event
dispatcher into any QThread as long as there is no default event dispatcher
created yet.  That is, before the thread has been started with
QThread::start() or, in case of the main thread, before QCoreApplication has
been instantiated.

Change-Id: I7367e13d8d8aebed5a5651260bb69b8818eb1b90
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
12 years agoRemove obsolete QSKIP parameter.
Jason McDonald [Wed, 9 Nov 2011 00:31:43 +0000 (10:31 +1000)]
Remove obsolete QSKIP parameter.

Change-Id: I269337d802ec6b383a496fe8dc62a6b11e4d61c5
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>