Commit Graph

6493 Commits

Author SHA1 Message Date
Stephen Kelly
61c433785e Move the CMake unit tests to auto/
This will allow the CI system to run the tests. The tests are only
run if cmake is found.

Change-Id: Ie73a56114c151871160bafcbf0b90b2d54620855
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
Reviewed-by: Sergio Ahumada <sergio.ahumada@nokia.com>
2012-04-23 17:03:56 +02:00
Stephen Kelly
f88212c22f Don't tell CMake we're making debug libraries if we're not.
The config option debug_and_release is set on Windows and on
mac (unless xcode is used independently of whether Qt is configured
with -release or not.)

We need to check CONFIG(release,debug|release) to see if
-release was set.

Change-Id: Ibf952958874f6b102981526b3397e848c207a3f2
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2012-04-23 17:03:43 +02:00
Olivier Goffart
ecba58500e Fix compilation of QDesktopServices without deprecated
Change-Id: I9e225d32b3f7db403cf3eea6a277580b4b7410a7
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-04-23 15:39:24 +02:00
Olivier Goffart
55d1f56c28 Fix warning in qobject.cpp
Variable only used in debug mode

Change-Id: I6601ca68c427b909680423ae81802f1ed5cd178a
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
2012-04-23 15:38:09 +02:00
Miikka Heikkinen
e95d94cbbd Windows: Fix QRawFont loading from data.
The implementation for loading QRawFont from data was missing from
Windows QPA plugin.
For freetype font database, just called the parent QBasicFontDatabse
implementation.
For native font database, ported the implementation from Qt 4.8
qrawfont_win.cpp.

Task-number: QTBUG-24197
Change-Id: Ia784d4cbc4f37c925aa49e53d04faf06a7169a73
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
2012-04-23 15:37:23 +02:00
Jason McDonald
d7a102ac65 Start running some disabled tests again on Mac OS.
These tests were disabled when trying to get CI working on Mac OS
because they asserted or crashed.  Now that CI is working well on Mac
OS, start running these tests again, initially as insignificant tests.
CI results will then be used to determine whether the tests can be made
significant.

Change-Id: Ife411e6b8c84ade45c865ef35f3ae0071d6f8d2b
Reviewed-by: Sergio Ahumada <sergio.ahumada@nokia.com>
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2012-04-23 09:46:22 +02:00
Casper van Donderen
3a78aabf3f QDoc: Support -indexdir on CLI and depends in qdocconf.
You can now specify a list of modules in the "depends" qdocconf
variable. This stringlist is then used by the -indexdir option to
specify in which directory to search for [depends entry]/[depends entry].index

Change-Id: Icab6dd0133e180ac04365da9605743def6fb754d
Reviewed-by: Martin Smith <martin.smith@nokia.com>
2012-04-23 09:45:24 +02:00
Casper van Donderen
8d9cb38a66 Doc: Fix most QDoc errors in QtXml.
Changes:
- XML processing document moved from Qt XML Patterns.
- Moves documentation from /doc/src to /src/xml/doc
- Add new qdocconf file.

Change-Id: I4bc2104714a28905304997e5ff252e662ddf0bee
Reviewed-by: Jerome Pasion <jerome.pasion@nokia.com>
2012-04-23 09:45:24 +02:00
Jonathan Liu
6289636365 Fix unmatched double quote character
Change-Id: I25fb7dac38db2800ce974d40ec275d510f6d47f4
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-04-23 09:45:24 +02:00
Jason McDonald
ed9b52ecfb Re-enable QGraphicsView test on Windows, Mac and Ubuntu 11.10.
On Windows, the test had a stable failure and an XPASS related to an
already closed bug report.  On Mac, the test had one stable failure, on
the same statement that had the XPASS on Windows.  On Ubuntu, the test
has been passing consistently.

Mark the stable failures with QEXPECT_FAIL, remove the QEXPECT_FAIL that
causes the XPASS, and remove the insignificant_test markers to re-enable
the test.

Task-number: QTBUG-24296
Change-Id: I05dd16b39296919268fee216332929df591f2b66
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2012-04-23 09:45:24 +02:00
Kalle Viironen
83c637aa94 Fix bug in qsslsocket peek()
Calling peek() for qsslsocket caused socket data to be copied into
qiodevices buffer and therefore make it unaccessible in qsslsocket.

Cherry picked form 4.8-branch & modified to Qt5 API changes
(int -> qintptr)
Original commits:
commit 621f18955082fc73471e75d1f8c35c2dcd4befeb
Author: Shane Kearns <ext-shane.2.kearns@nokia.com>
commit 68b1d5c17aa38d5921bdade2b0e0cb67c6c90513
Author: Kalle Viironen <kalle.viironen@digia.com>

Task-number: QTBUG-18498
Change-Id: I6be4b19baec2f3197537f5e7b61432040ec84ad2
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-04-23 09:45:24 +02:00
Jason McDonald
d5f157c165 Fix XPASS in QGraphicsWidget test on Ubuntu 11.10.
This test was marked insignficiant on Ubuntu 11.10, but the only failure
was an XPASS.  Make the test significant again, and only include the
QEXPECT_FAIL for CI platforms where the test is known to fail, i.e.
Windows and Ubuntu 10.04.

Task-number: QTBUG-20778
Change-Id: I24af3dab45118758382ba03c8c7a310f16301f8c
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2012-04-23 09:45:24 +02:00
Jason McDonald
9c21557dd6 Remove insignification from QGraphicsProxyWidget test on Windows.
This test has three stable failures on Windows.  Mark those failures
with QEXPECT_FAIL and re-enable the test.

Task-number: QTBUG-24294
Change-Id: I9eee2701a228912c3a91fa730e712661fb93add6
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2012-04-23 09:45:24 +02:00
Jason McDonald
7ace6169fb Remove insignification from QCompleter autotest.
Until March 15, 2012, this test failed consistently on Mac and passed
on other platforms. Since then, the test has passed consistently on all
platforms.

Change-Id: Ie773643a1c9dc0ab3596786badbc3c3afd4824d6
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2012-04-23 09:45:24 +02:00
Stephen Kelly
47617f68cb Make the QNX QPA plugin work with non blackberry.
Change-Id: Id85d18d9f21711e8d53e8e4bfdf39d10e135f593
Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
Reviewed-by: Kevin Krammer <kevin.krammer@kdab.com>
Reviewed-by: Andreas Holzammer <andreas.holzammer@kdab.com>
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
2012-04-23 07:30:02 +02:00
Kevin Krammer
5c2e560fe9 Send Expose event when top level window becomes visible
Change-Id: I0b45c27fa03bbe073c88ce8d01d9fb283f4051c1
Reviewed-by: Nicolas Arnaud-Cormos <nicolas@kdab.com>
Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
2012-04-23 07:30:02 +02:00
Girish Ramakrishnan
8fb7efeb2f QTextLayout::d is private
Compile fix for tst_qtextscriptengine.cpp test on the mac.

Change-Id: I912a339c6c659dc8958cc5997a331e3c18c9cb06
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2012-04-23 07:30:02 +02:00
Rohan McGovern
8dea797015 Removed invalid C-style license header from .pro file
/* C-style comments */ cannot be parsed by qmake.

Additionally, Qt Project legal has agreed that .pro files do not need to
be covered by license headers.

Change-Id: Ie4d75ee09c2fc85a2f954ec4a931b36ea9d51d93
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
Reviewed-by: Toby Tomkins <toby.tomkins@nokia.com>
2012-04-23 04:28:54 +02:00
Michael Brasser
b332a6c1e4 Don't assume QAbstractDeclarativeData::objectNameChanged is available.
Preparation for removal from declarative now that a proper NOTIFY
signal exists.

Change-Id: If0acb73b73d17c49dc8de211d95ecd1e8e80ff1b
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
2012-04-23 01:22:29 +02:00
Thiago Macieira
5f22899a17 Use org.example instead of com.trolltech for the D-Bus examples
We could use org.qtproject, but since this is an example anyway, and
since example.org and example.com are reserved to IANA by RFC 2606
anyway, let's use that.

Task-number: QTBUG-23274
Change-Id: Icdb1ac0390f88b72fa21b02ab362f1a98f26266c
Reviewed-by: Lorn Potter <lorn.potter@nokia.com>
2012-04-22 21:32:33 +02:00
Thiago Macieira
c4a457f8e4 Replace com.trolltech with org.qtproject in D-Bus's performance tests
I had missed these, apparently.

Task-number: QTBUG-23274
Change-Id: I6455dc34b18ec9cefccfe527b3fd3ad34fb61aa3
Reviewed-by: Lorn Potter <lorn.potter@nokia.com>
2012-04-22 21:32:24 +02:00
Olivier Goffart
910b446fb2 Examples: Don't use deprecated methods
Change-Id: Ib6e795f6b5bb6a3ac19882a5fb224460ef1fc8ad
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
2012-04-21 17:29:40 +02:00
Thiago Macieira
fcec903da7 Ensure that qXXXdetection.h can be included directly
Those files might have dependency on one another, on qconfig.h and on
early qglobal.h definitions, so ensure that the only correct include
order is that of qglobal.h.

Change-Id: I89098bacaf16353ee8b51604ee885508dc8e201a
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2012-04-21 11:19:39 +02:00
Thiago Macieira
f4227a7b86 Make the fallback Q_ASSUME and Q_UNREACHABLE be qt_noop
That way, we can properly add ; after them, and I can use Q_ASSUME in
Q_ASSERT's else condition.

Change-Id: Iad35819fbb06714116b7dd0f952e1c2c89044c72
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2012-04-21 05:09:24 +02:00
Thiago Macieira
4d55ba046c Move Q_DECL_{IMPORT,EXPORT,HIDDEN} to qcompilerdetection.h
Mindful of QT_VISIBILITY_AVAILABLE and Q_OS_WIN for GCC: when GCC is
used on Windows (i.e., MinGW or potentially Cygwin), use the declspec
variant so we produce proper DLL imports and exports.

When used on other platforms, rely on configure adding
QT_VISIBILITY_AVAILABLE to qconfig.h, which confirms that the
-fvisibility argument is available. That flag has been available since
GCC 4.0 on ELF targets, but it could be missing on some other targets.

Change-Id: I3dbc0043c1eaee0c469c5b1dc8bf05842fe9cd47
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2012-04-21 05:09:20 +02:00
Thiago Macieira
32758d917e Move some compiler macro definitions into the compiler sections
Makes for a couple of cleaner definitions of fallbacks.

Change-Id: I9b1a6f77bab986514e1862ae1f431ea37b89c1b5
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2012-04-21 05:09:18 +02:00
Thiago Macieira
308ffceea5 Move the compiler-related macros to qcompilerdetection.h
This cleans up qglobal.h a little further and organises things a bit
more.

Change-Id: Ic025e720941cdf59b8a1a0baf515b29f25eba0f1
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2012-04-21 05:09:14 +02:00
Jan-Arve Saether
45991b0f31 Compile on Windows.
The previous code was trying to sum one pointer with one string
literal...
Using QVarLengthArray should also potentially speed things up a bit,
since it will avoid a malloc if className is small enough (less
than 15 bytes).

Change-Id: I41218babb3030e7e6f9c31fc77e4af1c209ae0a5
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
2012-04-21 05:09:12 +02:00
Stephen Kelly
40fe0721d6 Fix typo in backwards compatibility code.
The patch just submitted to Qt4 is not affected by this.

Change-Id: I3f38f1a56f2a9a2058b2c8ff0a6ee1715be41e85
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-04-21 01:24:05 +02:00
Olivier Goffart
7eebe4e960 Fix compilation with Q_DECL_OVERRIDE
In C++11, the override keyword is placed after the function declaration

Change-Id: I3a079860762f30fa21eb01611c770713f6ba4acb
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-04-20 22:23:23 +02:00
Stephen Kelly
460bf5f051 Build the tests with the build type that the top-level was invoked with.
Change-Id: I87918276987b3a506c2ac8556940fce89a2d20cd
Reviewed-by: Alexander Neundorf <neundorf@kde.org>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
2012-04-20 22:23:23 +02:00
Aurindam Jana
d8a1899682 QDataStream: Update Version info for doc
QDataStream::Qt_5_0 was modified in
aee1f6cc41
but the documentation was not updated.

Change-Id: I520798a7572b0f21cd275290bcd689e1b686d098
Reviewed-by: Kai Koehne <kai.koehne@nokia.com>
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
2012-04-20 22:23:23 +02:00
Thiago Macieira
ad83a7ad6f Silence two warnings in QVariant's unit test.
These warnings are expected and correct, so ignore them.

Change-Id: I43931950e46bd3c931db869902574ee7219efa1d
Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
2012-04-20 22:23:23 +02:00
Thiago Macieira
369863efef Don't push unnecessary data to a data stream for QVariant()
Adjust the test because we don't read past the end anymore.

Task-number: QTBUG-25108
Change-Id: I8243f1d5ae79d1256aab2cb1132598a716a7eeeb
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
2012-04-20 22:23:23 +02:00
Shane Kearns
fffc900f78 Windows - "bypass proxy for local..." also affects IP addresses
If the "bypass proxy for local addresses" option is enabled in
the windows proxy configuration, then do not use the proxy for
any IP address in the subnet of any network interface.

As the systemProxyForQuery api is now offering HTTP proxy tunnels
for TCP sockets, this change avoids local ad-hoc network
connections being routed through the proxy.
In the case where the local address was on a different interface to
the proxy server, it may have been unreachable through the proxy.
For example IP over USB or Bluetooth.

Change-Id: I0842732832a7795112be029d923ed168edc008d6
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-04-20 22:23:23 +02:00
Stephen Kelly
57482b930f Make sure -fPIE is added to the compile flags.
Change-Id: I279881693b6eba15a2e145742b3281c9425e9b2e
Reviewed-by: Alexander Neundorf <neundorf@kde.org>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
2012-04-20 19:59:43 +02:00
Stephen Kelly
2dff7ad9e8 Only run the CMake DBus unit tests on UNIX systems.
Change-Id: I0c5b511229a7ac0c2aa23a9c3d2053077e94936c
Reviewed-by: Alexander Neundorf <neundorf@kde.org>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
2012-04-20 19:59:34 +02:00
Miikka Heikkinen
a941e0c0a6 Windows: Remove fontengine autodetection logic
Always default to native font engine as native fonts now work in
QML applications, too.

Change-Id: Iafa5f6d25a9a3b22f49763f287e4e358216cfc2d
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-04-20 16:21:31 +02:00
Friedemann Kleint
9b7739899e Window geometry manual tests: Add Window state controls.
- Factor out controls from the window flags test, split state
  into Qt::WindowState (QWindow) and Qt::WindowStates(Qt::Widget).
- Add to geometry test.

Change-Id: I25b9a8696bfb7f4faef113ac82559ebb90a140c5
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
2012-04-20 16:21:17 +02:00
Miikka Heikkinen
4c6d12e6d2 Fix missing Windows native fonts in QML applications
Windows native fonts were not getting rendered because the font engine
was cloned incorrectly for QRawFont, resulting in multi-engine instead
of the specific cloned engine.

Task-number: QTBUG-25410
Change-Id: I08f543e541739ac1b51f96f381ae1bb20b59399a
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
2012-04-20 16:21:08 +02:00
Thiago Macieira
e7da3a104c Disable the tst_exceptionsafety_others test completely.
QObject is no longer exception-safe and there's no one working on
improving this, so let's not block innocent commits because of this
failure.

QObjectPrivate's constructor initialises the
QObjectPrivate::threadData member to null, but the destructor
dereferences it unconditionally (the member is initialised in the
QObject constructor). That means QObjectPrivate is not exception-safe
by any definition and, so, anything depending on QObject is not
exception-safe.

Change-Id: If9d5004630b7ce2fb357e328627794caad67564f
Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
2012-04-20 15:48:15 +02:00
Shane Kearns
7742b2c97c Stabilisation of tst_qnetworkreply on windows
Workaround QTBUG-24451 by retrying creation of SocketPair if it fails
(waitForConnected and waitForNewConnection are used in the factory
function).
Skip very unstable test cases due to QTBUG-25386

Change-Id: I32129922329b895eb3719d61719c487a4d52c466
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-04-20 12:46:47 +02:00
Casper van Donderen
ac090486c4 QDoc: Remove the text around previous and next page links.
Previously we printed "[Previous: <link>] and [Next: <link>]. After this
change we only print the <link>, which should include an icon.

Change-Id: I30d0c7d53b70ec2e537774d57a4ac9af01b26b16
Reviewed-by: Martin Smith <martin.smith@nokia.com>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@nokia.com>
2012-04-20 12:46:47 +02:00
Lars Knoll
9ce1acd9e4 Revert "List QtPrintSupport as a dependency of QtPlatformSupport."
This reverts commit 9c7cdce672.

platform support does not and should never depend on widgets
or print support.

Change-Id: I828d1dfc02e7993325cf653ed92100750761eaae
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-04-20 12:46:47 +02:00
Friedemann Kleint
6331894524 Fix MSVC conversion warnings in new bytearray code.
Change-Id: Ifc81564daf3fef0d7f08ae8d250ba41d3b1d5b0f
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-04-20 12:46:47 +02:00
Martin Petersson
a8a5b38b00 QSslSocket: call to ERR_free_strings to free loaded error strings
Since we are calling q_SSL_load_error_strings to load error strings
we should call ERR_free_strings to free the memory again.

Task-number: QTBUG-15732
Change-Id: Ie41291bb0e1434f82025378edfca51930712a8aa
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-04-20 12:46:47 +02:00
Morten Johan Sorvig
fb8cd418fb Fix crash in QCocoaBackingStore.
QWindow->handle() may be null during construction,
and also during calls to resize(). Get and check
the pointer at each call instead of caching it
in the constructor.

Change-Id: Icd950b55e16fdd2077e3b7fe3c3393d8b89b5903
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-04-20 12:46:47 +02:00
Konstantin Ritt
65ae2151c3 mingw: fix a lot of annoying warnings
like "QRect::intersected() redeclared without dllimport attribute
after being referenced with dll linkage" (-fno-keep-inline-dllexport)

Change-Id: Id24e5ee857579ee9f97a60de0ab88ce3db8385cf
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-04-20 10:29:14 +02:00
Morten Johan Sorvig
128b7c56b7 Implement QCocoaWindow::setWindowState.
Add window state change notification logic. Send
and expose event in addition to window state change
on window restore since the QWidget logic expects
this.

Modify QCocoaWindow::setVisible to sync up window
state that may have been set on the hidden window.

Refactor NSWindow event observing to use one observer
function for all notifications.

Add window state testing to tests/manual/windowflags
Add delay after showFullScreen in tst_qstatusbar to
wait for the Lion fullscreen transition.

Change-Id: I57c523cedd0644d4181b40d72046fad4fdb09a9c
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-04-20 10:29:14 +02:00
Morten Johan Sorvig
872f567d53 Set the window title for the QWindow as well.
Change-Id: I2ff20307974c4b6a2a4fb09d09941d0a0dd09d0e
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-04-20 10:29:14 +02:00