Commit Graph

34971 Commits

Author SHA1 Message Date
Anton Kudryavtsev
79d3351855 QMenuBar: Add overloads of addAction() using Qt 5 signals and slots
[ChangeLog][QtWidgets][QMenuBar] Add overloads of addAction() using Qt 5 signals and slots

Change-Id: Ief21974213b80111f0ca87df490eb72dd6b9c9b9
Reviewed-by: Martin Smith <martin.smith@qt.io>
2018-01-06 18:48:54 +00:00
Robert Szefner
f99d2b21b8 QPSQL: Add support for forward-only queries
With this change, it is possible to significantly reduce memory
consumption of applications that fetch large result sets from databases.
The implementation is based on the new functionality called "single-row
mode" that was introduced in PostgreSQL version 9.2:

https://www.postgresql.org/docs/9.2/static/libpq-async.html

It also uses asynchronous commands PQsendQuery(), PQgetResult():

https://www.postgresql.org/docs/9.2/static/libpq-single-row-mode.html

[ChangeLog][QtSql][QPSQL] Added support for forward-only queries (requires
libpq version 9.2 or later)

[Important Behavior Changes] The QPSQL driver now supports forward-only
queries. To use this feature, you must build QPSQL plugin with PostreSQL
client library version 9.2 or later. See the Qt SQL documentation for
more information about QPSQL limitations of forward-only queries
(sql-driver.html).

[Important Behavior Changes] If you build the QPSQL plugin with PostgreSQL
version 9.2 or later, then you must distribute your application with
libpq version 9.2 or later. Otherwise, the QPSQL plugin will fail to load.

Task-number: QTBUG-63714
Change-Id: I15db8c8fd664f2a1f719329f5d113511fa69010c
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2018-01-06 08:24:32 +00:00
Christian Ehrlicher
b739b3a040 QSqlRecord: (re)speedup indexOf(const QString& name)
While adding the possibility to access values for QSqlRecord with
decorated field names (table.field), some string-allocations were added
which created a remarkable slowdown. Replace the QString allocations
with QStringRef avoids those allocations and restores the speed for
normal operations (apart from on QString::indexOf() call and some
integer comparisons)

Task-number: QTBUG-65226
Change-Id: I9e458523891421abce9e4a7ed931fec000dcbe76
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
2018-01-06 05:17:28 +00:00
Christian Ehrlicher
3ed91da499 QStyledItemDelegate: adjust editor geometry also in LTR-mode
The editor geometry was adjusted to a proper size in RTL-mode, but not
in LTR-mode. To fix this inconsistency, the geometry is now also
adjusted in LTR-mode to make sure the editor has enough space for the
min/max values for the given datatype.

Task-number: QTBUG-37433
Change-Id: Iff41e854f2fa2104ab5c589d24780facc3ed5815
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2018-01-06 05:17:13 +00:00
Christian Ehrlicher
20604ea554 QHeaderView: respect min/maximumSectionSize property
QHeaderView::resizeSection() did not check if the given section size is
inside the min/max property bounds.
Also on calling setMin/MaximumSectionSize() the current section sizes
were not checked if they are inside the new given bounds.
This is a small behavior change when a user is setting the section size
via resizeSection() without respecting the min/maxSectionSizes.

Task-number: QTBUG-64173
Change-Id: Ia9c9eebf058d60c776ab5f8f8336642013ec553f
Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com>
2018-01-06 05:17:00 +00:00
Martin Smith
1c0ac8c4b8 doc: Correct remaining qdoc warnings in qdeadlinetimer.cpp
clang required adding template clauses to \fn commands and in one
instance, removing a formal parameter name from a \fn command. An
instance of Q_QDOC was changed to Q_CLANG_QDOC in the include file.

Change-Id: Ic7dab56705043d2db8578dfc002d2f41b927f756
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
2018-01-06 00:26:31 +00:00
Martin Smith
dd3f7c5f2b doc: Correct remaining qdoc warnings in qchar.h and qchar.cpp
Several enum values had to be given \value statements, and a
member function only visible for Windows had to become visible
to clang-qdoc.

Change-Id: I47fbbcf9c5e4333abd13a041ce8fee2c13f9541d
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
2018-01-06 00:26:15 +00:00
Jake Petroules
1c8224511d qmake: set COPY_PHASE_STRIP to NO in Xcode generator
Since Xcode 6.3, this must be set to NO because stripping on copy is no
longer fully supported due to the potential of input binaries being code
signed. In this case Xcode will simply ignore the strip step and issue
a warning since stripping would invalidate the code signature. This
change silences that annoying warning for release builds. Also, the
setting assignment is moved from being hardcoded in the generator, to
a QMAKE_MAC_XCODE_SETTINGS value.

Change-Id: If25511edddc12b7b0407e2992d80884b7d6437dc
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
2018-01-05 23:26:50 +00:00
Jake Petroules
fe72571da8 qmake: replace invalid characters in generated bundle identifiers
This problem does not affect the Xcode generator.

Task-number: QTBUG-65477
Change-Id: I6194edc5b679edad9ae1a25e35b71e5df9bd4c95
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
2018-01-05 21:19:21 +00:00
Martin Smith
66a0fecfae doc: Correct remaining qdoc warnings in QStringView
Added missing template clause to \fn commands required by clang-qdoc.
Changed a few Q_QDOC macros to Q_CLANG_QDOC.

Change-Id: I20e6855b13df6384b471fc2bb5de27b0e3b44d1b
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
2018-01-05 20:22:13 +00:00
Martin Smith
81e4d039a9 doc: Correct remaining qdoc warnings in qstring.cpp
Added missing template clause to \fn commands required by clang-qdoc.
Removed several obsolete \sa targets. Added a few missing return types
to \fn commands.

Also changed a } to ] in a \fn command in qrandom.cpp.

Change-Id: I0f004a1e57507ff5fb035e822ca8b1baa7faad9b
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
2018-01-05 20:22:01 +00:00
Martin Smith
4d3c55aa31 doc: Correct remaining qdoc warnings in qstack.cpp
Added missing template clause to \fn commands required by clang-qdoc.

Change-Id: Id2cb480a0780025276639c38f595cb21264bd8cb
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
2018-01-05 20:21:49 +00:00
Martin Smith
d72705c96d doc: Correct remaining qdoc warnings in a few files
Added missing template clause to \fn commands required by clang-qdoc
in qsharedpointer.cpp, qscopedpointer.cpp, and qstringbuilder.cpp.

Change-Id: Ifca5b81db96e678a53e40080d351c69f14db604a
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
2018-01-05 20:21:37 +00:00
Gabriel de Dietrich
1e75dcf251 QStyleHelper: Use palette cache key in pixmap key
This reverts commit d7bcdc3a44.

Now that QPalette::setBrush() is a bit smarter (see
c564779c07), we can be
confident the palette's cache key won't change so often.
Therefore, we can use it again as part of every pixmap's
cache key.

Change-Id: I5cab2296a937f9149c7745291e0442eea24f4e9d
Task-number: QTBUG-65475
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2018-01-05 17:43:50 +00:00
Martin Smith
698fa094b3 doc: Correct remaining qdoc warnings in qscopedvaluerollback.cpp
Added missing template clause to \fn commands required by clang-qdoc.

Change-Id: Ia7bc899153cccedc28e5083d658f427d322acab7
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
2018-01-05 16:03:47 +00:00
Friedemann Kleint
53fae41e42 QWindowsXPStyle: Remove unused code
Fixes a deprecation warning about QDesktopWidget::screenGeometry().

Change-Id: Ib56b2d3f62ddca60d84b4f626571b5e444304804
Reviewed-by: Andre de la Rocha <andre.rocha@qt.io>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
2018-01-05 15:46:32 +00:00
Albert Astals Cid
5e2f583a67 CUPS: Fix conflict handling
The previous code assumed that ppdMarkOption returning non zero (i.e. it has conflicts)
also meant that the option wasn't applied at the ppd level, but it actually is.

What we need to do is after calling ppdMarkOption parse the tree again looking
to see if any option is conflicting and mark it as such in the UI.

Change-Id: I836f1902d14dc8c176bb06776471cbf4ed11786f
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
2018-01-05 15:38:35 +00:00
Andy Shaw
5e9e4ccdc3 Add an option to scroll the QComboBox on macOS with the mouse wheel
Since there may be some applications that want to make their comboboxes
scrollable or not with the mouse wheel then a style hint is added to
make this toggable. It defaults to true for all platforms except macOS
to keep it in line with existing behavior.

[ChangeLog][QtWidgets][QStyle] Added SH_ComboBox_AllowWheelScrolling as
a style hint to enable/disable the use of the mouse wheel in a QComboBox.
This defaults to true in all styles except the macOS one so there is no
change in existing behavior.

Task-number: QTBUG-53094
Change-Id: I6eb61e1990bfc79e3b3ea82d7b91ee39096fa077
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
Reviewed-by: Andy Nichols <andy.nichols@qt.io>
2018-01-05 15:01:43 +00:00
Oswald Buddenhagen
2226f01d74 qlalr: fix description
amends 710875efde.

Change-Id: Ia5e9dd6f3b080b876e4dc1eb99f2b43d73999c04
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2018-01-05 10:32:20 +00:00
Mårten Nordheim
da81b01df8 Change use of qDebug to qCDebug
Task-number: QTBUG-65532
Change-Id: I8b6b8f04f5f6b63eb3c80f140710c8c05291986a
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
2018-01-05 09:37:57 +00:00
Friedemann Kleint
bef0db36ac QtPrintSupport: Raise minimum supported MSVC version to 2015
Remove code for older versions and streamline #ifdefs.

Task-number: QTBUG-51673
Change-Id: Ib87b2559d0d04fcfa70cabd134ac6936a3c2a261
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
2018-01-05 08:32:21 +00:00
Thorbjørn Lund Martsum
d5a11a0ec2 Revert "QTreeView: Make sure QHeaderView is notified on layoutChanged()"
It caused some sorting issues.
This reverts commit 93dabeba9d.

Change-Id: Ie8c7f2d47885be6626ddb6284474a78dcf09cf33
Task-number: QTBUG-65478
Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com>
Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2018-01-05 08:22:30 +00:00
Allan Sandfeld Jensen
7e9460306b Update qurltlds_p.h
It has been a while and it is supposed to be updated at every release.

[ChangeLog][Third-Party Code] Updated top level domain-list from Mozilla

Change-Id: Ifd3e5fe33166e793908b3ce28d29a507b483dd8a
Reviewed-by: Kai Koehne <kai.koehne@qt.io>
2018-01-05 08:22:23 +00:00
Oliver Wolff
9f2ce7e2f6 winrt: Remove -qdevel and -qdebug from command line parameters
These options are used by winrtrunner/Qt Creator to control logging
and debugging behavior and should not influence applications.
Without this change applications that use
QCommandLineParser::process have to explicitly remove these values
from the arguments list or the application will exit with an
"unknown option" error when run from Qt Creator.

As winrt applications do not natively support command line arguments,
breaking the use case of having these values as valid command line
options is acceptable.

[ChangeLog][qtmain][winrt] -qdevel and -qdebug are removed from the
command line arguments and not passed to the application.

Change-Id: I60e5565148fd3dd0155b946607fdf5042139d2e1
Reviewed-by: David Schulz <david.schulz@qt.io>
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@qt.io>
2018-01-05 07:37:20 +00:00
Martin Storsjö
f663c83f9d harfbuzz: Fix building for win64 with clang
Clang errors out on casting from a pointer to a smaller integer
type.

This is an adapted backport of a newer upstream harfbuzz
commit, 03b7a221f701a9b003890878e730ad175c3fdd86.

Change-Id: I0de62d90008021aed6acf4e946ce1d346f9aac8c
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
2018-01-05 07:34:23 +00:00
Timur Pocheptsov
4a11243d3c tst_QUdpSocket - unblacklist tests on Ubuntu 16.04
We use QSKIP instead for kernel versions [4.6, 4.13).

Task-number: QTBUG-65440
Change-Id: Ie764b5a4eb8a67dc2a43d4dc67b5d6eb772f6b2a
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Joni Jäntti <joni.jantti@qt.io>
2018-01-05 03:59:13 +00:00
Martin Storsjö
8cef809b16 qmake: Handle QMAKE_LINK_OBJECT_MAX being unset for static libraries
This was missed in 8bebded9.

Task-number: QTBUG-63637
Change-Id: I6be472430a9aa8f533def4fd6c14c8dbfe8b6f70
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
2018-01-04 22:41:53 +00:00
Orgad Shaneh
534ad22b32 configure: Prefer cl.exe over clang-cl.exe
This is a remake of 8e4c8be0b9 that was
undone by mistake in 8f49da6c18.

Change-Id: I9596b860dea90b042baa8b2b95b1e3b050e9b835
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
2018-01-04 21:22:42 +00:00
Friedemann Kleint
874c3e3c05 Direct2D: Replace class Direct2DVersion by QVersionNumber
Change-Id: Iad8c659a301c6d71b26964d84a67a51352712218
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
2018-01-04 20:25:10 +00:00
Friedemann Kleint
3439f523b8 QtDBus: Raise minimum supported MSVC version to 2015
Remove code for older versions and streamline #ifdefs.

Task-number: QTBUG-51673
Change-Id: I0c0ba4e914a1f3b7a324c68c59544a5074f7b075
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2018-01-04 20:24:09 +00:00
Friedemann Kleint
98a3502fa5 QtSql: Raise minimum supported MSVC version to 2015
Remove code for older versions and streamline #ifdefs.

Task-number: QTBUG-51673
Change-Id: I1d0f89784f8fb698828e11ce39086501971f1756
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
2018-01-04 20:23:54 +00:00
Friedemann Kleint
c9539f340e QtWidgets: Raise minimum supported MSVC version to 2015
Remove code for older versions and streamline #ifdefs.

Task-number: QTBUG-51673
Change-Id: I2ba95bde2b8bbcca1833dc14c344b9a14394bc1d
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2018-01-04 20:23:40 +00:00
Friedemann Kleint
5af4cb5a5a Tests: Raise minimum supported MSVC version to 2015
Remove code for older versions and streamline #ifdefs.

Task-number: QTBUG-51673
Change-Id: If456567691538b1a1f452111814c5f9eba401c43
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2018-01-04 20:23:25 +00:00
Frank Richter
3edcd9420e Support legacy X11 keymaps
Not all X server vendors support the XKB protocol. Furthermore,
while X.org seems to use keycodes that match the usual keyboard
scancodes, other vendors may not do so. This means that using an
XKB keymap suitable for an X.org server results in garbled input
with servers for other vendors.
Both of these issues are addressed by using the core keycode
information as a fallback.

[ChangeLog][X11] Fall back to X11 core keycode information
if an XKB keymap could not be determined through the connection.

Task-number: QTBUG-44938
Change-Id: I64568aa31113d5a3fd90f70c63320a497db21477
Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
2018-01-04 19:47:53 +00:00
Gabriel de Dietrich
c564779c07 Make QPalette::setBrush() check before detaching
Setting the same brush on the same group and role should
not detach nor alter the result of QPalette::isCopyOf().

Task-number: QTBUG-56743
Change-Id: Ic2d0dd757d703b01e8c5d835a8c124b3317653f4
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
2018-01-04 18:59:35 +00:00
Liang Qi
79dfc08437 Merge remote-tracking branch 'origin/5.10' into dev
Change-Id: I644cd82b0d952b7d139e0228bf5017f147db77e7
2018-01-04 19:49:26 +01:00
Milla Pohjanheimo
952c4fa251 Add binary compatibility files for QtBase for 5.10
Files to test binary compatibility for 5.10 added. It looks like
tst_bic (that runs the BC tests) is implemented so that it will start
testing new content when e.g in case of 5.10 branching to 5.10.1 has
happened.

Change-Id: Ic97db0339cc2942c088962dda495eb42b96fe153
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2018-01-04 16:26:32 +00:00
Liang Qi
4ef667d200 Merge remote-tracking branch 'origin/5.9' into 5.10
Change-Id: I3fa5c9e216201bdf7da260c395f65d7fb95cba0b
2018-01-04 17:24:18 +01:00
Albert Astals Cid
6efbd4381a CUPS: Fix advanced options cancel of the print properties dialog
When the user changes the advanced settings we call
setProperty PDPK_PpdOption so if the user cancels we
need to set them back to what they were originally

Change-Id: Idd0cb413fb1e68dd28cf66f7f66f7e0afb38393e
Reviewed-by: Michael Weghorn <m.weghorn@posteo.de>
Reviewed-by: Kevin Ottens <kevin.ottens@kdab.com>
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
2018-01-04 13:01:17 +00:00
Albert Astals Cid
030d815eb8 Refactor QPPDOptionsModel a bit
Make the members private and add getters
Make some other functions also private
Move setCupsOptionsFromItems from QPrintPropertiesDialog to QPPDOptionsModel

Change-Id: Ibb555a6e6be53550f30c159c3ad611d55e2a767a
Reviewed-by: Kevin Ottens <kevin.ottens@kdab.com>
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
2018-01-04 12:54:53 +00:00
Martin Smith
8700c4dba7 doc: Correct remaining qdoc warnings in qfsfileengine.cpp
Removed a dupicate qdoc comment.

Change-Id: I43214c63bda3dd3ff398b173472306955f8a72b7
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
2018-01-04 12:51:51 +00:00
Martin Smith
68c432f90c doc: Correct qdoc warning in QVariantAnimation
Added missing template clause to a template friend function
of class QVariantAnimation.

Change-Id: Ia96dcbb1dad1f6678642564a55991445d0b6ba0e
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
2018-01-04 12:51:36 +00:00
Martin Smith
38cfda3c82 doc: Correct remaining qdoc warnings in qmetaobject.cpp
clang required adding template clauses to a few \fn commands.

Change-Id: I4e875f719ed58901d227fb0e6b80d4551f3b6e89
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
2018-01-04 12:51:23 +00:00
Martin Smith
0a383146c5 doc: Correct remaining qdoc warnings in qvariant.cpp
clang required adding template clauses to several \fn commands.

Change-Id: I1ee9855c626b41e499392c05160df01daa5c0618
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
2018-01-04 12:51:09 +00:00
Martin Smith
c2b4681493 doc: Correct remaining qdoc warnings in qtimer.cpp
clang required adding template clauses to a several \fn commands.
There was also a case where Q_QDOC was changed to Q_CLANG_QDOC
in qtimer.h

Change-Id: I1184e507a3fa719fe5049ade80e5da24f52ac851
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
2018-01-04 12:50:55 +00:00
Martin Smith
58a47ccfe5 doc: Correct remaining qdoc warnings in qmutex.cpp
clang required adding template clauses to a few \fn commands.
|| defined(Q_CLANG_QDOC) was also added in qmutex.h.

Change-Id: I7e61f460a8f8f15032094fb35c02f73721a5eb8a
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
2018-01-04 12:50:42 +00:00
Martin Smith
9e005c9401 doc: Correct remaining qdoc warning in qsignaltransition.cpp
clang required adding template clause to a \fn command.

Change-Id: Ie95a1db90adcc9f6b10a7d2943af574c3b0ce2e2
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
2018-01-04 12:50:29 +00:00
Martin Smith
69ad098d17 doc: Correct remaining qdoc warning in qstate.cpp
clang required adding template clause to a \fn command.

Change-Id: Icbe0557f7fa67ba211df5cfbc68baa6cf737d7b1
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
2018-01-04 12:50:16 +00:00
Martin Smith
5211f785ff doc: Correct remaining qdoc warnings in qbytearraymatcher.cpp
clang required adding template clauses to a few \fn commands.

Change-Id: I5877c7bebd6a8a7b2630addb656d32e6f2043cf1
Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
2018-01-04 12:50:04 +00:00
Allan Sandfeld Jensen
f95fbca5f3 Add AVX2 optimized versions of the most basic RGB64 compositions
Speeds up RGB30 and ARGB32-unpremul painting.

Change-Id: I419afdf5c26ceffc0f7557b8f196035056178c9a
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2018-01-04 12:50:01 +00:00