Commit Graph

28631 Commits

Author SHA1 Message Date
Lars Knoll
fa23682630 Clean up some unused variables in the qmake.conf files
Change-Id: I04cdcc514b851ad529ad62883fda850159447505
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2016-06-23 19:43:04 +00:00
Milla Pohjanheimo
b24396b925 Remove blacklisting of tst_QDBusConnection::pendingCallWhenDisconnected
Since f8b5142e30 is in, we can remove
the blacklisting of the test.

Task-number: QTBUG-53786
Change-Id: I2eaa2ec1f1f2e14f73f2f4b6f5732a3b51061075
Reviewed-by: Tony Sarajärvi <tony.sarajarvi@qt.io>
2016-06-23 07:43:52 +00:00
Jake Petroules
0c43ef5023 Update for the newest Darwin-family operating systems.
This also corrects for some code that was not included in the forward
merge from 5.6 (ea438b2508) due to code
restructuring.

Change-Id: I90a20fbcb60cfd6deb1cca3716a62754af27901f
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2016-06-23 02:37:12 +00:00
Liang Qi
f4f7ae013d Fix inconsistency between the #if guards in SSL PSK code - Part 2
The declaration and definition of the forwarding functions for PSK
differed which leads to link errors with some versions of openssl.

Change-Id: Ic62d87dbd33a77f3c114f0a597a6c0858b22174a
Reviewed-by: Richard J. Moore <rich@kde.org>
Reviewed-by: André Klitzing <aklitzing@gmail.com>
2016-06-22 20:32:31 +00:00
Thiago Macieira
bff15c547e QDateTime: introduce {to,from,set,current}SecsSinceEpoch
These new functions use a 64-bit integer in the API, instead of the
broken 32-bit unsigned integer that the previous xxxTime_t functions
used. That was a design flaw when the API was introduced back in Qt 4.2,
so I'm deprecating the API and slating it for removal in 6.0.

The changes to qfilesystemmetadata_p.h and quuid.cpp are necessary to
build the bootstrap library. The rest of the adaptation to the new API
will come in the next commit.

[ChangeLog][QtCore][QDateTime] Introduced toSecsSinceEpoch,
fromSecsSinceEpoch and setSecsSinceEpoch functions, which use 64-bit
integers to represent the number of seconds.

[ChangeLog][QtCore][QDateTime] The toTime_t, fromTime_t and setTime_t
functions are deprecated and will be removed in Qt 6.0. For new code,
use the equivalent functions with "SecsSinceEpoch" in the name, or the
equivalent ones with millisecond accurancy that have existed since
Qt 4.7.

Change-Id: Ib57b52598e2f452985e9fffd145a355d0e7ff48d
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2016-06-22 18:34:27 +00:00
Lars Knoll
90eee08b3e Let qmake do most of the work of configuring Qt
Command line arguments, configure tests and features are now
defined in a json file and a configure.pri containing some
custom functions.

qmake uses the json file to determine command line arguments,
tests and features to be executed at configuration time.

A new qt_configure.prf contains all the infrastructure to parse
the command line, run the configure tests, determine the set of
available features and create a report about it.

Change-Id: If30ac089dd3e9f8c67ebd642bde10cfa960893bb
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2016-06-22 14:19:35 +00:00
André Klitzing
71224ccc86 Bump \since 5.7 to 5.8 for QNetworkDatagram
Change-Id: I8dc4a5b7f78d25220d1c473098d5a49e2c3401d8
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2016-06-22 06:41:42 +00:00
Liang Qi
b3100fbadd Merge "Merge remote-tracking branch 'origin/5.7' into dev" into refs/staging/dev 2016-06-21 14:07:10 +00:00
Liang Qi
ea438b2508 Merge remote-tracking branch 'origin/5.7' into dev
Conflicts:
	src/corelib/global/qglobal.cpp
	src/corelib/global/qsysinfo.h
	src/corelib/kernel/qcoreapplication_win.cpp
	src/gui/text/qdistancefield.cpp
	src/gui/text/qdistancefield_p.h
	src/plugins/platforms/windows/qwindowsglcontext.cpp
	src/plugins/platforms/windows/qwindowsglcontext.h

Change-Id: Ib3500acc2b28553bde06758cd9a2e19eb7fe2978
2016-06-21 08:39:41 +02:00
Timur Pocheptsov
62b11af31e OpenSSL symbols - resolve ALPN-related functions
DEFINEFUNC macro is not enough, RESOLVEFUNC also required.

Change-Id: Ia73c3fa62b594765a74d2ecabb8e109b62ea6027
Reviewed-by: Richard J. Moore <rich@kde.org>
2016-06-20 19:38:18 +00:00
Thiago Macieira
145136ab4b configure.exe: Remove old code that supported MSVC < 2013
Change-Id: Ib57b52598e2f452985e9fffd14587ce6af57d200
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2016-06-20 16:13:06 +00:00
Thiago Macieira
4da2dda2aa Long live QNetworkDatagram!
This commit adds a new class called QNetworkDatagram that encapsulates
the IP packet header and UDP/IP stack metadata along with the actual
payload data. It can be used for both receiving as well as sending data.

It's called QNetworkDatagram so it can be used by QSctpSocket too, when
that lands.

[ChangeLog][QtNetwork] Added QNetworkDatagram class, along with new
function receiveDatagram in QUdpSocket that returns it and an overload
to writeDatagram that can accept it.

Change-Id: Iee8cbc07c4434ce9b560ffff13ca467f425ddc3d
Reviewed-by: Alex Trotsenko <alex1973tr@gmail.com>
Reviewed-by: Richard J. Moore <rich@kde.org>
2016-06-20 16:11:35 +00:00
J-P Nurmi
3aaa5d6b32 Improve QGtk3FontDialogHelper::onAccepted()
Call currentFont() only once. It does a conversion from a Pango font
description string to a Qt font, so not entirely trivial operation.

Change-Id: Ic67b7c5b0874621c51a5cce4766acd4243d3dfde
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
2016-06-20 13:57:36 +00:00
J-P Nurmi
cf53aa21bf QGtk3ColorDialogHelper: ensure currentColorChanged() gets emitted
GTK does not emit the "color-activated" signal as expected, so make
sure currentColorChanged() gets emitted the same way it's done for
QGtk3FontDialogHelper. This ensures that QML bindings get re-evaluated
as appropriate.

Change-Id: Id00f144e8b9a08afee57ef6a6033972cdc4307b0
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
2016-06-20 13:57:31 +00:00
Mike Krus
d23c2e005f Restore use of ifdef for TVOS
UIScreen.applicationFrame is not defined at all on tvOS.
Was broken by 88ebee5cd7

Change-Id: I692f464d538561961b40a6fbdcab51a3320e5779
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
2016-06-20 13:50:21 +00:00
Joerg Bornemann
f4159d0495 Remove Windows CE vestige
Change-Id: I07bd55c55f8b69dd7c58da8876ca985debf235dc
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2016-06-20 12:51:43 +00:00
Liang Qi
5f0ec7305e Merge "Merge remote-tracking branch 'origin/5.6' into 5.7" into refs/staging/5.7 2016-06-20 07:54:09 +00:00
Thiago Macieira
a2f319e9fb Fix MSVC warning about casting to pointer of different size
qdatetime.cpp(2834): warning C4312: 'reinterpret_cast': conversion from 'int' to 'QDateTimePrivate *' of greater size

Change-Id: Ib57b52598e2f452985e9fffd1458fe3ba3fcfb48
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2016-06-20 06:53:10 +00:00
Liang Qi
e32f1a4d61 Merge remote-tracking branch 'origin/5.6' into 5.7
And blacklisted a few tests in tst_QUdpSocket.

Conflicts:
	src/android/jar/src/org/qtproject/qt5/android/QtNative.java
	src/corelib/global/qglobal.cpp
	src/corelib/global/qsystemdetection.h
	src/corelib/io/qfileselector.cpp
	src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_egldevice/qeglfskmsegldeviceintegration.cpp
	tests/auto/network/socket/qudpsocket/BLACKLIST

Task-number: QTBUG-54205
Change-Id: I11dd1c90186eb1b847d45be87a26041f61d89ef6
2016-06-20 08:00:26 +02:00
Thiago Macieira
683c30074e Add "-softfloat" to archdetect.cpp and clarify what to use when
Change-Id: I1cc7601489634e96833cfffd14563e033c85ff6d
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2016-06-19 18:46:36 +00:00
Thiago Macieira
7497cfcfcb PowerPC: Add detection of SPE (found on e500) and VSX
Poky (Yocto's reference distro) has a special build for the e500v2, so
I'm guessing this ABI is somewhat important.

Change-Id: I14839ba5678944c2864bffff14176c4d61b8799f
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2016-06-19 18:46:26 +00:00
Thiago Macieira
ffe8db538f Fix ICC warning about comparing pointers of different types
error #3781: comparing a pointer to void and a pointer to a function is nonstandard

Change-Id: Ib57b52598e2f452985e9fffd1458fd651d3985d2
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2016-06-19 15:51:52 +00:00
Mike Krus
221b123e5d Fix tvOS build
Replace Q_OS_IOS with QT_PLATFORM_UIKIT

Change-Id: I98bbd549a3613fe474202af23ca0acb947601e2b
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
2016-06-17 18:51:00 +00:00
Simon Hausmann
ee2eed350f Remove overload tag from QByteArray QIODevice::readAll()
This does not seem to be a function that is overloaded.

Change-Id: Icf8942dfb1e78a2ddb38cbd1c49657f745a61989
Reviewed-by: Alex Trotsenko <alex1973tr@gmail.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2016-06-17 16:56:55 +00:00
Jake Petroules
2fa4a48ff6 Fix documentation of some QSysInfo functions.
Qt 5.8 no longer supports Windows CE, or versions of Windows where the
marketing version is not an orderable version number.

Change-Id: I8fab7d9b0d466f891e872b6c3fdf9d98ffe6ebc1
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2016-06-17 16:43:04 +00:00
Thiago Macieira
fdb956a3ed Ensure that configure.exe is built in C++11 mode with ICC
I changed qmake with commit f5eeadb9, but that change was apparently
incomplete.

Change-Id: Ib57b52598e2f452985e9fffd1458b02579f33c5d
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2016-06-17 16:28:11 +00:00
Thiago Macieira
6da32c7806 Fix compiler warning about missing return statement in non-void function
Found by ICC 17 Beta on Windows.

This commit also removes the "default" cause from the switch, which will
make compilers let us know if we add another enum but don't handle it in
the switch.

Change-Id: Ib57b52598e2f452985e9fffd1458b5b39b238db7
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
2016-06-17 16:27:26 +00:00
Thiago Macieira
691b867895 Fix warning about non-void function not returning anything
Found by ICC 17 Beta on Windows.

Change-Id: Ib57b52598e2f452985e9fffd1458b6990b70837a
Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
2016-06-17 16:12:52 +00:00
Lars Knoll
34c24ceb1f Improve error reporting when parsing JSON files
At least report the error string and the file offset where
the error happened.

Change-Id: Iaa1733593b8af2a7a52b67c0f495731f045d2c11
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2016-06-17 16:11:11 +00:00
Alexander Volkov
a11ced4981 TuioTouch: Report empty touch areas for tokens
Currently TuioTouch plugin reports touch areas of size 1x1.
It's inconsistent with the platform plugins which report
empty touch areas when their size is unknown.

Change-Id: I253e4f7a95e8fb3ecc76c809a9be2afe3c976bef
Reviewed-by: Ariel Molina R <ariel@edis.mx>
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
2016-06-17 16:03:04 +00:00
Thiago Macieira
3238b43597 Fix build on macOS: Apple changed their minds if null is allowed
qcorewlanengine.mm:88:37: error: null passed to a callee that requires a non-null argument [-Werror,-Wnonnull]
    currentInterface = [CWInterface interfaceWithName:nil];
                                    ^                 ~~~

Change-Id: Ie7d159a97176ca53161423cfcddba547e735d5b3
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2016-06-17 15:51:29 +00:00
Olivier Goffart
f7a0968da4 Forward declarations for platform specific types should also be done with Q_QDOC
The clang based qdoc need to be able to parse properly anything that is
in #ifdef Q_QDOC

The #if for the forward declararion now match the one in which it is used.

Change-Id: Ia6cf84dd07a979b4e7aa8da764d9fb2fce74baa1
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
2016-06-17 14:58:30 +00:00
Liang Qi
2a6961f188 eglfs_kms_egldevice: fix warnings about -Werror=maybe-uninitialized
src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_egldevice/qeglfskmsegldeviceintegration.cpp: In member function ‘bool QEglFSKmsEglDeviceIntegration::setup_kms()’:
src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_egldevice/qeglfskmsegldeviceintegration.cpp:391:28: error: ‘encoder’ may be used uninitialized in this function [-Werror=maybe-uninitialized]
     m_drm_encoder = encoder;
                            ^
src/plugins/platforms/eglfs/deviceintegration/eglfs_kms_egldevice/qeglfskmsegldeviceintegration.cpp:392:29: error: ‘connector’ may be used uninitialized in this function [-Werror=maybe-uninitialized]
     m_drm_mode = connector->modes[0];
                             ^
cc1plus: all warnings being treated as errors

Change-Id: Ic444450d06a6dd8047bd6871febb08a4a3fde6f9
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
2016-06-17 14:39:50 +00:00
Tor Arne Vestbø
d2bffe0fc9 UIKit: Detect swapBuffers on non-exposed windows and skip flush
When using threaded rendering the render-thread might be half-way into
rendering a frame when the application is backgrounded, resulting in
the following swap happening on a non-exposed window. This may result
in the system killing the application, as rendering is not supposed to
happen when an application is backgrounded, so we skip the flush.

Change-Id: I9ab8f2c4617391fd827558af9fb473f1734b3688
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2016-06-17 13:18:33 +00:00
Tor Arne Vestbø
3e4f885f0c UIKit: Ensure that Qt's application state is initialized at startup
Using dispatch_async to deliver the initial application state at startup
was broken, as that would leave the application in the default application
state, inactive, until the next runloop pass. This became a problem when
an application was started backgrounded, eg. in response to location
updates or a Bluetooth accessory waking it up, as it would have a small
window of time at startup where it would think it was able to render
content (since the window was exposed), while in fact the application
was running in the background. iOS will in these situations kill the app
for doing background rendering.

Change-Id: I1ab4a6af08a154d8625c6451b4b5c8f4453e6b43
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2016-06-17 13:18:29 +00:00
Tor Arne Vestbø
655687d84d UIKit: Don't reallocate renderbuffer on QIOSContext::swapBuffers()
During device rotation, the backing CEAGLLayer of our custom UIView is
resized by the system. Normally this is the time where we would then
reconfigure the corresponding renderbuffer that we render to, which
shares memory with the CEAGLLayer, but we chose a lazy approach where
we'd defer the reconfigure until client code actually called makeCurrent.

This caused problems because not only did we implement the lazy reconfig
in makeCurrent, but in every QIOSContext function that operated on the
default FBO, including swapBuffers(). When using threaded rendering,
such as in Qt Quick, the render thread may be half way in rendering a
new frame when the system resizes the CEAGLLayer, and we pick up that
resize on the swapBuffer call and allocate a new renderbuffer, before
flushing the queued up GL commands that were operating on another
renderbuffer of a different size. This resulted in the following crash:

  0 - gpus_ReturnObjectErrorKillClient()
  1 - gpusSubmitDataBuffers()
  2 - glrFlushContextToken()
  3 - flush(__GLIContextRec*)()
  4 - QIOSContext::swapBuffers(QPlatformSurface*)
  ...

We solve this by still being lazy in how we reconfigure, but limit the
reconfigure to makeCurrent(). If the CEAGLLayer is resized in between
two frames, we skip the half-drawn frame. The old frame will then be
scaled to match the new size by the system, but this is preferable to
flushing a new frame that may have been drawn with two conflicting
window geometries.

Task-number: QTBUG-50017
Change-Id: Ie229f26d156dfbfc7ed8d9efd0eb5e992eee73f1
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2016-06-17 13:18:24 +00:00
Tor Arne Vestbø
0b6adbcd23 uikit: Deliver update requests via CADisplayLink callback
Improves performance over the default timer-implementation, and allows
us to control the rate and paused state of the display link.

Change-Id: I05761b6eb48f5e91af35735e2faa477427cd8440
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2016-06-17 13:18:11 +00:00
Anton Kudryavtsev
80a4f8b867 Fix compile QtGui with png support
Add corresponding dependency to QtGui module.

Task-number: QTBUG-53660
Change-Id: I719f0ff3d6a0208ad69139a8f64358536a718eed
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2016-06-17 13:02:21 +00:00
Oswald Buddenhagen
fc1092cfad correctly link xcb-static lib
this apparently makes no difference except for not creating bogus .prl
files - presumably, the correct path is coming from somewhere else
already.

Change-Id: Ia3f3c44e506ba14b533ff097f05acecf1e86cfb3
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
2016-06-17 12:23:33 +00:00
Alexander Volkov
d53d77e66b TuioTouch: Report empty touch areas for the cursor
Currently TuioTouch plugin reports touch areas of size 1x1.
It's inconsistent with the platform plugins which report
empty touch areas when their size is unknown.

Change-Id: Iea8ad38a5712b666126780411380d963877b0229
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Reviewed-by: Ariel Molina R <ariel@edis.mx>
Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
2016-06-17 12:04:37 +00:00
Milla Pohjanheimo
b82707a7b6 Blacklisting tst_QWindow::modalWithChildWindow on Ubuntu 16.04
The test is flaky and we need to blacklist it.

Task-number: QTBUG-54179
Change-Id: I12ff10b2370e4e6cc55782031449d4c15cf468b7
Reviewed-by: Tony Sarajärvi <tony.sarajarvi@qt.io>
2016-06-17 12:00:22 +00:00
Oswald Buddenhagen
4c23b69bf7 fix detection of default incdirs on mac
don't add framework directories (including the respective marker!).
this is consistent with the unix configure code.

Change-Id: I2e187057bc3fe2b35128cd5dc2af57b9f3685d83
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
2016-06-17 09:47:02 +00:00
Oswald Buddenhagen
ccf461acf0 fix logical mismerge from 5.6
iphonesimulator_and_iphoneos was renamed to simulator_and_device in 5.7.

Task-number: QTBUG-54163
Change-Id: If4a76f45450edc0f6e8fb3615355613212314300
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
2016-06-17 09:45:23 +00:00
Liang Qi
3cb56800d5 Merge remote-tracking branch 'origin/5.7' into dev
Conflicts:
	tests/auto/widgets/itemviews/qlistview/tst_qlistview.cpp

Change-Id: If899cda251b4dc8b8a7c6764520e88ab719737cd
2016-06-17 10:53:42 +02:00
Mat Sutcliffe
23bce6b169 qmake: Fix missing newlines in generated vcxproj files
A bug in the Windows C Runtime causes text mode pipes to drop newlines
sometimes. This bug was hidden because of another bug in rcc which
caused newlines to be redundantly duplicated. When the latter bug was
fixed (commit 53d5811b) the former bug was exposed, causing invalid
vcxproj files to be generated. The Windows bug is described here:
https://connect.microsoft.com/VisualStudio/feedback/details/1902345
The workaround is to avoid text mode, and do the conversion of "\r\n"
to "\n" ourselves (which we were already doing anyway).

Change-Id: I792599a4cd7822f109fa921f02207fb1b144b1d1
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2016-06-16 22:46:54 +00:00
Jake Petroules
1e147f446a Add back osx compatibility check in QMAKE_PLATFORM.
If macx is present, osx AND macos should be required.

Change-Id: I5cd9d41270c741dc314720a1119b163dd17fdfd7
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2016-06-16 22:44:15 +00:00
Kaligin Sergey
5d31c9831d QTreeView: fix keyboard navigation when using the right arrow key
The visual column index needs to be replaced by the logical column
index in QModelIndex::sibling() call in QTreeView::moveCursor() method.

[ChangeLog][QtWidgets][QTreeView] Fixed a key navigation bug
when the columns were reordered.

Task-number: QTBUG-52793
Change-Id: I4dc89a2705966a94b20edd7f9a4422f089bb670f
Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com>
2016-06-16 15:19:45 +00:00
Vyacheslav Koscheev
797cd4b7bc Android: Don't send tabletEvent when it's not supported
If QT_NO_TABLETEVENT defined, then there is no sense to create tablet
events.
Its better to create general touch events in this case.

Task-number: QTBUG-53887
Change-Id: I2fabc2241158d54d6c39a2f6071ab874f7debd39
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
2016-06-16 14:08:27 +00:00
Liang Qi
3d8c8daae1 Merge "Merge remote-tracking branch 'origin/5.7.0' into 5.7" into refs/staging/5.7 2016-06-16 12:25:24 +00:00
Timur Pocheptsov
aed7540d45 Cocoa integration - inconsistent window types/styles
NSWindow does not support 'utility window' style, but NSPanel - does.
If we first create a normal widget, then later make it a Qt::Tool,
we still have NSWindow with (now) invalid 'floating panel' window level
(but no 'utility window' style) - it's a window that stays on top even
when we switch to a different application.

Change-Id: I691bc6f681cdf8bc2a9637444da33e7e6200ee2f
Task-number: QTBUG-45938
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
2016-06-16 11:15:24 +00:00