Commit Graph

30518 Commits

Author SHA1 Message Date
Oswald Buddenhagen
fe2f8146d4 prune vestiges of DEPLOYMENT_PLUGIN
the code was broken since 5.0, as it still hardcoded the version number
4 for the plugin basenames.
wince is not supported any more, so there is no point in trying to
restore the code to function.

at a later point, we'll make QTPLUGIN universal enough to cover both
static and dynamic deployment.

Change-Id: I0911ce4aff7a799dd471d6218e046f13dca6d49e
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
2016-12-23 13:25:41 +00:00
Alexander Volkov
49f1b667fa platform plugins: Remove unused former overriders
They were implied to override QPlatformIntegrationPlugin::keys()
but it was removed before releasing Qt 5.0.

Change-Id: Ia1f1ad27b7511b1141887f5dcde0dadeb2e5cabf
Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
2016-12-22 23:02:45 +00:00
Alexander Volkov
fb7bfbf18d examples: Use QOverload to select overloaded signals and slots
We can use QOverload since Qt 5.7 (it depends on Q_COMPILER_VARIADIC_TEMPLATES
which is required since Qt 5.7).
Use it in the examples to show the best practice.
qOverload currently can't be used because it requires c++14.

Change-Id: I94a3c0db9d551fe169fa3d19c07ec0b329d5946c
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2016-12-22 14:54:55 +00:00
Oswald Buddenhagen
63e7ff97e9 configure: properly serialize machine tuple detection
detecting the machine tuple must happen before committing qdevice.pri.

Change-Id: Ic37eda42fff805d6e1edb5dd92898abd59d6bdc9
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
2016-12-22 11:48:13 +00:00
Oswald Buddenhagen
4cbec6b730 configure: reload spec after configuring paths
this fixes the x-build for raspberry pi, as that spec refers to the
sysroot.

the path setup doesn't require the device options to be in effect yet,
so it was sufficient to move the existing spec reload to a later point
in time.

Change-Id: Idc521aa13ff441931e954c7c9004472cf7061ee1
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
2016-12-22 11:48:09 +00:00
Oswald Buddenhagen
a71b53d600 fix sysrootification of install paths
initially, the idea was that QLibraryInfo would receive a
pre-sysrootified ExtPrefix from the builtin qt.conf. matching this
against the sysroot would then tell us whether to sysrootify the Prefix
from a "regular" qt.conf as well.
however, this would have lead to some major ugliness and inconsistency
between the code paths, so i changed my mind.
unfortunately, i failed to adjust the remaining code, leading to
169a40d51 entirely breaking sysrootification ...

the proper (and nicely consistent) solution is to introduce a
SysrootifyPrefix key to qt.conf. this is user-accessible as well, so as
a bonus it is now possible to adjust the setting at qmake installation
time. incidentally, this omission was the last thing that prevented
using the same qmake host build for any imaginable configuration of the
same qt version ... i think.

Change-Id: Ic0eebf21f93651f6374628c0ad8b206d696a4a7e
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
2016-12-22 11:48:05 +00:00
Allan Sandfeld Jensen
674430cea0 Silence maybe_uninitialized warning with gcc -Og
GCC produces false positives for maybe_uninitialized when compiling with
-Og in these three places. Simply initialize the variables to silence
it. This should be entirely cost-free for normal compilation.

Change-Id: Iab778a6ba25993f78f190e928c1fcc2dbd8b2fcd
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2016-12-21 22:08:01 +00:00
Joerg Bornemann
88a02c4d63 Remove ToolsVersion from generated VS projects for VS >= 2013
Before VS 2013 ToolsVersion contained a .NET version
number (e.g. "4.0"). Since VS 2013 ToolsVersion is the same as the
Visual Studio version number (e.g. "12.0"), which is also the default.

We always wrote "4.0" (except in one special case which used
"14.0"). This doesn't bother Visual Studio itself, but other tools
like PVS-Studio.

Remove the ToolsVersion attribute from generated VS projects for VS
2013 and newer.

Task-number: QTBUG-57694
Change-Id: I7a3bc4534c492e9540f6b968bee8a969980df63f
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
2016-12-21 16:35:49 +00:00
Joerg Bornemann
5fc2337d74 Fix unnecessary regeneration of mocables in VS projects
Change dcd2f829 introduced fake files with the extension .cbt for custom
build tools that generate code from C++ source inputs. The moc_predefs.h
header file falls into this category, because it is generated from
dummy.cpp.

It turns out that these fake files have to exist. Otherwise the
custom build step is executed on every build. That means re-moccing all
mocables on every build.

Fix this by actually creating the fake .cbt files with some
explanatory comment in them.

Task-number: QTBUG-57695
Change-Id: I251294334425d9914677787d8ba6da1169b4cca5
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
2016-12-21 16:35:22 +00:00
Lisandro Damián Nicanor Pérez Meyer
31f0728ac9 Mark QPA symbols as private
QPA headers are shipped as private symbols, so they should be marked as such.
This helps distros to check which applications/libraries need recompiling
on each Qt patch update.

Task-number: QTBUG-57060
Change-Id: Ie09d4d10e1edb5127d45a05a3dfa3f4c9dd012f2
Reviewed-by: Dmitry Shachnev <mitya57@gmail.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
2016-12-21 16:21:13 +00:00
Tor Arne Vestbø
8533c94a24 macOS: Take DPR into account when creating CGContexts for a QPixmap
Missing logic when refactoring image manipulation methods into QtGui
in c52bb03090.

Task-number: QTBUG-57723
Change-Id: I7b55d4451d35faf5fd794daa0b80acbd712f30cd
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
2016-12-21 16:18:13 +00:00
David Faure
b9edbb5d54 QLockFile: make sure we encode the hostname as UTF-8 in the lock file
We chose to use UTF-8 as it allows us to ensure there's no mistaking the
hostname in case the locale is changed, if the host name contains
characters outside of US-ASCII.

But this didn't work because the code that wrote the hostname always
used the local 8-bit codec instead of UTF-8. On Unix, we used the
result of gethostname(3) directly, which is supposedly on the locale codec.
This commit doesn't fix Windows, which requires _wgetenv, the plan being
to encapsulate that with a qEnvironmentVariable() method.

[ChangeLog][QtCore][QLockFile] Fixed a bug that caused QLockFile not to
recognize a stale lock file if the machine's hostname contained non-US-
ASCII characters, on Unix. A Windows fix is still pending.

Task-number: QTBUG-49640
Change-Id: Ib9d045544ff370ec901626658a84ec4e6575fe21
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2016-12-21 15:57:40 +00:00
Stephen Kelly
baad82d242 QIPM: Persist model indexes after emitting layoutChange, not before
Callers can persist a QModelIndex which was not persisted before in a
slot connected to the signal, and such a persisted index must be updated
in the course of the layoutChange.

Store the indexes to persist after emitting the signal.

Task-number: QTBUG-32981
Change-Id: Ibee4c0d84817d72603a03fe5b22fdeefeac0695e
Reviewed-by: David Faure <david.faure@kdab.com>
2016-12-21 01:37:50 +00:00
Stephen Kelly
0874861bcc QSFPM: Remove data manipulation from move handlers
Similar to the fix in the parent commit, incorrect updating of the
internal data structures during layout changes can lead to dangling
pointers being dereferenced later.  Moves are treated as layoutChanges
by this proxy by forwarding to the appropriate method.  However, data is
incorrectly cleared prior to that forwarding.  Remove that, and let the
layoutChange handling take appropriate action.

Change-Id: Iee951e37152328a4e6a5fb8e5385c32a2fe4c0bd
Reviewed-by: David Faure <david.faure@kdab.com>
2016-12-21 01:37:40 +00:00
Stephen Kelly
3bd0fd8f97 QSFPM: Fix handling of source model layout change
In sourceLayoutAboutToBeChanged the source model update is ignored if
the affected parents are filtered out anyway.  The same logic is
attempted in the sourceLayoutChanged slot, but there the early-return
logic is applied too late - the mapping is cleared before performing the
early-return.  Because pointers into the mapping are used in the
internalPointer of QModelIndexes in this class, persistent indexes used
later will segfault when attempting to dereference it.

Additionally, if a parent becomes invalid as a result of the
layoutChange, it would be filtered out by the condition in the loop,
resulting in a different result in the comparison of emptiness of the
parents container.

Fix that by persisting the parent's container, and performing the test
for early-return before clearing the mapping.

Task-number: QTBUG-47711
Task-number: QTBUG-32981
Change-Id: If45e8a1c97d39454160f52041bc9ae7e337dce97
Reviewed-by: David Faure <david.faure@kdab.com>
2016-12-21 01:37:31 +00:00
Samuel Gaist
1274a7e419 Doc: Updated code sample to match documentation of QCompleter
The QCompleter documentation mentions QFileSystemModel while the code
sample still uses QDirModel. This patch fixes this by updating the code
sample.

Change-Id: I99a0d2419efcf781af3e9530508df088d77fbbfa
Reviewed-by: Sze Howe Koh <szehowe.koh@gmail.com>
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
2016-12-20 21:28:37 +00:00
Allan Sandfeld Jensen
bee9a78e13 Avoid using QRgba64 for buffers
Benchmarking showed most time rendering in rgb64 mode was spend on
memsetting the buffers because they were not declared with a primitive
type.

This patch changes the buffers to quint64, but leaves refactoring
function arguments to a later patch in the dev branch.

Change-Id: Iacc81b0d8e9570b1975dffb85c955b0aabb096a7
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
2016-12-20 14:56:16 +00:00
Oswald Buddenhagen
20fd99d863 fix typos in "ras[p]berry pi"
Change-Id: I2d8910df9266d9cbf2426e5f2ba2a88eb2e821ef
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2016-12-20 10:16:44 +00:00
Oswald Buddenhagen
33c33f6475 micro-optimize FOO-=$$BAR for empty FOO
there is no point in iterating BAR if FOO is (or became) empty.

Change-Id: I86c89bf0ad726a5ab7ead990a27ef7cc32caebbf
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2016-12-20 10:16:40 +00:00
Oswald Buddenhagen
d88ff29c57 fix conditionals on the spec after assigning QMAKESPEC
this is of marginal value, as only our own code ever messes with
QMAKESPEC, and we mostly stopped matching on the spec in favor of
compiler and platform flags.

Change-Id: Ibdd9a9c85067623f0f1f064d139d23b4e6b0677d
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2016-12-20 10:16:37 +00:00
Oswald Buddenhagen
f2b31fdb6b make QMAKE_DIR_SEP magic on writing
since ab0cc305, the spec will be replaced by an entirely new one during
configuration, and so needs to update the path separator for
$$shell_{path,quote}(). however, the latter didn't happen, as the spec
reloading doesn't go through the "real" spec loading path.

Change-Id: I45ab3156b8e040f683328ac46e48b09c2eb94ef7
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2016-12-20 10:16:32 +00:00
Joerg Bornemann
29a929668b Fix capitalization of <PlatformToolset>
This tag was never spelled "PlatformToolSet". The correct spelling
is "PlatformToolset" (lower case s). VS itself can load qmake-generated
projects despite this misspelling, but tools like PVS-Studio are
bothered by it.

Task-number: QTBUG-57435
Task-number: QTBUG-57694
Change-Id: Ib70e8561f1827e195194bcf518445b2909a8d8c0
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
2016-12-20 09:36:24 +00:00
Allan Sandfeld Jensen
6614f7754c Silence implicit-fallthough warnings
Fixes Werror build with GCC 7.

Change-Id: Ie0e9fb907af545b6c200558faaaf83b8ec058b7a
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2016-12-19 09:35:57 +00:00
Stephen Kelly
7adfe7494b Update model-view documentation about layoutChanged
This has always been true, but hasn't been documented well enough, so
triagers are giving incorrect information in bug reports (eg QTBUG-47711
and QTBUG-53221). That incorrect information is being treated as truth
by Qt users which take action based on incorrect information. That is a
problem, so try to make the documentation clear.

Change-Id: I4e44a9a0675cdd7d9289ec209ae32d5a92899fc9
Reviewed-by: David Faure <david.faure@kdab.com>
2016-12-18 21:34:36 +00:00
Thiago Macieira
7c402ad3d1 Make the bearer QFactoryLoader a member variable, not a static
Because it was a function-level static, the QFactoryLoader was getting
destroyed out-of-sync with the bearer thread stopping. Under normal
conditions, the thread stopped first (~QApplication / ~QCoreApplication
via qAddPostRoutine), and the static got destroyed when the process
exited. However, if QApplication leaked or if the destruction order is
wonky (as seen in PyQt5), the thread could still be running when the
plugins were already unloaded.

With the loader a member variable, it gets destroyed when the thread
stops.

Note: in Qt 5.7, QFactoryLoader no longer unloads the plugins (since
commit 494376f980), so this crash cannot
happen in that version.

[ChangeLog][QtNetwork][Bearer management] Fixed a bug that could cause a
crash on application exit, depending on the order of destruction of the
QCoreApplication object and the QtDBus manager thread.

Task-number: QTBUG-56228
Task-number: QTBUG-52988
Change-Id: I33dc971f005a4848bb8ffffd147853376f82de2a
Reviewed-by: Lorn Potter <lorn.potter@gmail.com>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2016-12-17 04:11:13 +00:00
Thiago Macieira
c7b0f56fb1 Fix build on Windows: winsock2.h requires WIN32_LEAN_AND_MEAN
This is required for the next commit.

Change-Id: I73fa1e59a4844c43a109fffd148c8c3e3a100c79
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
2016-12-17 04:11:10 +00:00
Thiago Macieira
7ca66b1e66 Fix race condition in QFactoryLoader: lock the mutex we already have
The process of loading a plugin is examplified by the qLoadPlugin
function (though not all users of QFactoryLoader use this function, they
all do something similar):

    const int index = loader->indexOf(key);
    if (index != -1) {
        QObject *factoryObject = loader->instance(index);
        if (FactoryInterface *factory = qobject_cast<FactoryInterface *>(factoryObject))
            if (PluginInterface *result = factory->create(key, std::forward<Args>(args)...))
                return result;
    }

QFactoryLoader::indexOf already locked the mutex, but not
QFactoryLoader::instance. This commit fixes that.

Note that calling the virtual create() in the plugin's factory is not
protected by the mutex. Each plugin's factory must be thread-safe and
also create an object that works on any thread too. It's also the
responsibility of the caller of qLoadPlugin to ensure that it's called
thread-safely.

Task-number: QTBUG-42855
Change-Id: I63e21df51c7448bc8b5ffffd148ebee33d4c47de
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
2016-12-17 04:11:09 +00:00
Peter Varga
8325808dcf QTestLib: Add timestamp to mouse click events
Timestamp is necessary for testing custom mouse event handlers e.g. what
Qt WebEngine uses for handling triple and quadruple mouse clicks.

Based on commit 181ee8f9ff

Task-number: QTBUG-56223
Change-Id: I2bf840f326255333eec83ca8c42f087cb7deb1fb
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2016-12-16 19:18:07 +00:00
Liang Qi
9bfe3ab71e Merge remote-tracking branch 'origin/5.8.0' into 5.8
Conflicts:
	doc/global/qt-cpp-defines.qdocconf
	src/plugins/platforms/android/qandroidplatformopenglcontext.h
	src/plugins/platforms/android/qandroidplatformtheme.h

Change-Id: I13d51cc66f708138ff4d667ceea7d515992e58a4
2016-12-16 09:45:16 +01:00
Laszlo Agocs
179045f36a Silence platformheaders syncqt warning about qt_egl_p.h
Drop the include for qt_egl_p.h. For Qt itself this should have no effect
since platform plugins including this header include EGL headers on their
own anyway.

Similarly, applications relying on such advanced functionality will likely
include EGL/OpenGL headers on their own - the point is anyhow to interoperate
with native, non-Qt EGL and GL code.

This avoids a lot of hassle since normally no EGL (or other winsys interface
API) bits are exposed in the public Qt APIs, and thus there are no public
headers provided to set up EGL headers in the same way Qt does internally.

Change-Id: Icdbc28811b753799abc06085bc8dff7f09bdbff9
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2016-12-16 04:07:22 +00:00
Oswald Buddenhagen
21f283b0f0 fix directfb build without EGL
Task-number: QTBUG-57176
Change-Id: I174828e0657e244b060df6223650091a06ecd980
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
2016-12-16 04:06:58 +00:00
Gabriel de Dietrich
2a44f81fe7 QCocoMenu: Fix patch b2f78b796b
A null pointer check was accidentally removed while
refactoring the code.

Change-Id: I547936671bd134bb7df710a4b123a0d731076bf2
Task-number: QTCREATORBUG-17438
Task-number: QTBUG-57404
Task-number: QTBUG-57657
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2016-12-16 04:06:39 +00:00
Thiago Macieira
9f96e4f431 Work around old Clang bug parsing of NSDMI referring to members
Clang pre-3.4 didn't like this and it's used in Xcode 5.1 (which we need
to support for 5.8).

error: 'this' cannot be implicitly captured in this context
    typename T::const_iterator i = c.begin(), e = c.end();
                                   ^

Task-number: QTBUG-57488
Change-Id: I63e21df51c7448bc8b5ffffd148e688d7c9b89d6
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
2016-12-16 04:05:56 +00:00
Aleksey Lysenko
28dffdecda Delete aborted QDrag
Aborted QDrag object has never been removed, moreover there was no way
to know a previous drag-and-drop operation status

Task-number: QTBUG-53990
Change-Id: I2b6a7aad86d94b9d5083f9799fe54752c251660b
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2016-12-15 19:22:53 +00:00
Sergio Martins
7797c13131 QDockWidgetGroupWindow now honors custom title bar
When you change tab it will loose or gain native window decos
depending on if the current dock widget has them or not.

Change-Id: I1171f43fa5ee897ce7d695fc447255dcb0d1d5a1
Task-Id: QTBUG-56866
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2016-12-15 15:37:00 +00:00
Paul Olav Tvete
f9b1ec2d79 Touch fix for popups blocked by modal dialog
Don't block the event that Qt depends on to close popups.

This is the same fix as 5b65698248,
but for touch this time.

Task-number: QTBUG-57292
Change-Id: I47bc19883c2e2b5dc9615c12dc6c198193c055cf
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
2016-12-15 14:08:27 +00:00
Thiago Macieira
d8b678661b Re-fix build error with ICC 17 on Windows
This is a repeat of ae880beb7d, which had
fixed the problem for ICC 16. That commit was a repeat of
acf80b9a2b, which had fixed it for ICC 15.

As reported in ae880beb7, ICC doesn't like polymorphic exported classes
with inline constructors. That commit added the default constructor, but
we forgot the copy constructor. This constructor should have been
protected, so users are forced to use the virtual clone() function, but
we can't make it so in Qt 5 because MSVC encodes the protection and has
exported the inline function in debug builds.

qsvgiconengine.obj : error LNK2001: unresolved external symbol "const QIconEngine::`vftable'" (??_7QIconEngine@@6)

Change-Id: I427336c52fc342638c74fffd149033b990ea7ade
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2016-12-15 12:52:20 +00:00
BogDan Vatra
104854708c Update Ministro's url
Task-number: QTBUG-57645
Change-Id: I014b1926c9b91e085baa5df563dc4cc06fe0596c
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
2016-12-15 12:52:09 +00:00
Eskil Abrahamsen Blomfeldt
3a9801d568 doc: Specify which characters are replaced by toPlainText()
Some formatting characters are replaced by ASCII in the output
from toPlainText(). Since this is a bit inconsistent, we should
document it.

Task-number: QTBUG-57552
Change-Id: I46033588d37517056a8d4668d1d16d48c72ee1b5
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2016-12-15 08:12:15 +00:00
Oliver Wolff
56a167d30c winrt: Check for removed timers after sending events
After all the check makes sense here. If a timer was removed as a result
of sendEvent and it was not at the end of the list the list is not
shrunk but the timer info's id is just set to INVALID_TIMER_ID.

Additionally the timer's object should be fetched before we unlock the
locker as timerIdToObject is changed in removeTimer and we might access
a nullptr if the timer has been removed.

Reverts c83ba01f7b

Task-number: QTBUG-56756
Change-Id: Ib1a04c02fbfcf4c939b4891d42f954dc9e87149e
(cherry picked from commit 8f2088db17)
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@qt.io>
2016-12-15 05:20:45 +00:00
Topi Reinio
cfbe5df48c qdoc: Define Q_COMPILER_UNICODE_STRINGS
Some public functions in QString and QDebug are declared inside
Q_COMPILER_UNICODE_STRINGS. This commit defines it for QDoc, and
adds documentation for QDebug functions that are now visible to
QDoc.

Change-Id: Ia7f2501c1dc7b8244dcc3ce4adcd2019fdbffcb6
Reviewed-by: Martin Smith <martin.smith@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2016-12-15 05:20:24 +00:00
Topi Reinio
6b79e18f17 qdoc: Ignore macro QT_WARNING_DISABLE_DEPRECATED
This macro, introduced in Qt 5.8, needs to be ignored by QDoc
in order to generate documentation correctly for a number of
deprecated functions.

Change-Id: I50bcd42167e3fafb7dda88484fde86e1aebb5980
Reviewed-by: Martin Smith <martin.smith@qt.io>
2016-12-15 05:20:16 +00:00
James McDonnell
b08bdfb2e4 Fix qtlibpng being built despite system libpng being found
90eee08b made system-png a subset of png, which is strictly speaking a
porting error. However, as this is a good idea as such, fix it by adding
the missing !system-png check.

Change-Id: I1557a2130a22ac668be315dc9aea67845928ff4c
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Reviewed-by: Andrew Knight <andrew.knight@intopalo.com>
2016-12-15 05:19:56 +00:00
Alexander Volkov
39642fcc9e manual tests: Fix build with modularized configure.json
Change-Id: I7979b147cc53d9f5250ba983da1245152dcbb2ec
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
2016-12-14 16:49:34 +00:00
Alexander Volkov
b57e7c0963 doc: Replace Q_DECL_OVERRIDE by override in snippets
And remove redundant virtual.

Change-Id: If0650409b88ad962f6713d082d9095675f4c68e8
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: hjk <hjk@qt.io>
2016-12-14 16:49:23 +00:00
Christian Strømme
87e553b58a Android: Fix the bearer management plugin when running as a service
Since Qt for Android now supports running as a service, we shouldn't
use the activity context unconditionally, but instead query the current
context from QtAndroidPrivate::context().

Change-Id: Ib793ba890fdbfc0cfe7b20115e41ff64cc73477a
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
2016-12-14 15:08:11 +00:00
Ulf Hermann
1f665efa91 Q_CHECK_PTR the result of QDataBuffer's allocations
We might run out of memory or malloc() or realloc() might fail for any
other reason. We want to crash cleanly with a clear message in that
case, rather than returning a null pointer.

Change-Id: If09c1b9e905fc60a5d9d45e598a418df433cf83b
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2016-12-14 14:33:11 +00:00
BogDan Vatra
b8fab7c9f5 Add Q_[ENUM|FLAG]_NS to global qt-cpp-defines doc conf
We need to add Q_[ENUM|FLAG]_NS to global qt-cpp-defines doc conf otherwise
qdoc ignores them and it will not produce any documentation or links to
these enums/flags

Task-number: QTBUG-57616
Change-Id: I744317346feb41db02787677f8698c4de15db226
Reviewed-by: Martin Smith <martin.smith@qt.io>
2016-12-14 14:16:46 +00:00
Thiago Macieira
5556308cbf MySQL: Make sure we clean the libraries from mysql_config
It prints libraries necessary for linking against the MySQL static
library. When linking against dynamic libraries, we end up with too many
parameters. We don't want to explicitly link our plugin to OpenSSL and
this is especially important on macOS since Sierra no longer comes with
OpenSSL development files.

On my Linux:
  -L/usr/lib64 -lmysqlclient -lpthread -lz -lm -lssl -lcrypto -ldl

On my macOS:
  -L/usr/local/Cellar/mysql/5.7.16/lib -lmysqlclient -lssl -lcrypto

Instead, keep only -L options (that haven't been removed by the function
$$filterLibraryPath above) and the actual client library.

Change-Id: I3e3f0326f7234a26acf5fffd148fa985d0fd9c93
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
2016-12-14 13:29:57 +00:00
Friedemann Kleint
1d68e3386d eglfs/deviceintegration: Ensure eglfs_kms_support is added only once
Use qmake operator *= to prevent adding it multiple times resulting
in warnings on Linux/Desktop:

Makefile:114: warning: overriding recipe for target 'sub-eglfs_kms_support-qmake_all'
Makefile:64: warning: ignoring old recipe for target 'sub-eglfs_kms_support-qmake_all'
Makefile:118: warning: overriding recipe for target 'sub-eglfs_kms_support'
...

Change-Id: I18a926c9faeb8f9eafea5223d32c526c06c43724
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
2016-12-14 13:06:41 +00:00