Commit Graph

37930 Commits

Author SHA1 Message Date
Thiago Macieira
e7998dc187 QCborStreamReader: make sure setDevice() clears the last error
The unit tests weren't running into this problem because the every
setDevice() was preceded by the object being initialized with the exact
same data, so there was never a previous error state. I've only changed
a couple of tests, left the other setDevice() unchanged so we test both
behaviors.

Fixes: QTBUG-71426
Change-Id: I1bd327aeaf73421a8ec5fffd1561a590e3933376
Reviewed-by: Nils Jeisecke <nils.jeisecke@saltation.com>
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2018-11-08 15:19:45 +00:00
Thiago Macieira
c0b1230108 Add qHash(QCborTag) and qHash(QCborSimpleType)
Needed in qHash(QCborValue).

Change-Id: If7e743cf8476463880ccfffd155eeca91369b356
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2018-11-08 15:19:43 +00:00
Thiago Macieira
75e8f6f41e QResource: catch signed integer overflow (just in case)
Change-Id: I343f2beed55440a7ac0bfffd156321748e4d6048
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2018-11-08 15:19:19 +00:00
Kari Oikarinen
b971310e2d QObject: Check for declarative signals in isSignalConnected
Amends a952fd7d5b.

The mentioned commit started to skip QObjectPrivate::isSignalConnected() call if
the connectionLists are dirty, which lead to tst_qqmllanguage::receivers() test
inside qtdeclarative breaking.

Declarative signals were not checked if that function was not called. It
previously also wasn't called for signals higher than 64. Fix that by checking
for declarative signals after the connectionLists search is unsuccessful.

Fixes: QTBUG-71550
Change-Id: Ifcb5fdd0dc9a6b14b9f448a016fd09356a55b985
Reviewed-by: Liang Qi <liang.qi@qt.io>
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2018-11-08 15:15:59 +00:00
Oswald Buddenhagen
bdebc90c28 Bump version
Change-Id: I02c0289a7c8a5becde63875fa684075a2a3a4eba
2018-11-08 11:26:39 +01:00
Andre de la Rocha
35069301f0 Windows QPA: Fix incorrect button state reporting for touchpad
The current state of (emulated) mouse buttons was being incorrectly
reported for touchpad events under some conditions. In the handling
of pointer messages, GetAsyncKeyState() was being used to retrieve the
mouse button state. However, it does not seem to work always with all
touchpads. Furthermore, its use is not necessary, since the button
state information comes as a set of flags with the pointer message
itself. This change makes the handler use these flags instead.

Fixes: QTBUG-71470
Change-Id: Ie2e35bd80778ef74db672604a0f2af659785efbf
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
2018-11-08 04:09:15 +00:00
Gatis Paeglis
2569ac2857 xcb: fix regression with open/close hand cursors
On Linux the correspondence between cursor functions and names
of cursors has never been standardized. Projects have either
assembled their own cursor function-to-name lookup table or
borrowed the table from other projects. The origins of our table
is described in QTBUG-71423.

On Ubuntu the default theme is called Adwaita. Before
bd72950fbe, we would not find a
cursor for 'openhand' and would fall-back to QXcbCursor::
createNonStandardCursor(). Which was sub-optimal, because the
cursors created by the fall-back path don't look like the
themed ones. But the situation was worse after bd72950fb (hence
the regression) - the 'openhand' fall-back name 'fleur' is a
symbolic link to 'grabbing', so we would get into a situation
where Qt::OpenHandCursor displays the same as Qt::ClosedHandCursor.

This patch adds a correct fall-back name for 'openhand' on Adwaita,
which is 'grab'. 'grab' actually is a symbolic link to 'hand1', but
'hand1' with other theams is a pointing hand cursor, that is why we
use the symbolic link's name in this case.

The lookup table still appears to be incomplete when comparing e.g
with KWin. Eventually we need to revise the table and put in a common
place so it can be shared between X11 and Wayland, but is out-of-scope
for this patch (see QTBUG-71423).

Fixes: QTBUG-71296
Task-number: QTBUG-71423
Change-Id: I247ed4b346c2cd3fe1c7fd0440d3763e0033346b
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
2018-11-07 18:51:00 +00:00
Alexander Akulich
7b9de1d4da QSocks5SocketEngine: Remove too optimistic check for UDP proxy setup
The engine used to send a UDP datagram to the local address to check
the proxy setup, but the check fails in case of the proxy hosted in
WAN and the local address hidden behind a NAT. In other words the
check fails because a public proxy hosted somewhere in internet has
no access to local addresses such as 192.168.1.2.

Remove the check to fix the issue; we still have other means to
detect network errors.

Change-Id: Ib6df263c87ebd7d6e88a0b5e024e78a559995234
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
2018-11-07 18:38:23 +00:00
Andy Shaw
38b87cc4bb Doc: Clarify what samples() returns if not explicitly set
Change-Id: Icf4478121a9d67356eb976039c666d6945a2099c
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
2018-11-07 16:48:13 +00:00
Sergio Martins
9933511838 Fix typo in define. s/GL_FRAMEBUFFER_SRB/GL_FRAMEBUFFER_SRGB
Found with clazy

Change-Id: Ied84c0fa95a7ae7b7791e167695acfc7877f7e25
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
2018-11-07 14:40:03 +00:00
Richard Moe Gustavsen
a545b85bdd QWidgetWindow: check if receiver is deleted after event delivery
When a popup is active, we set the receiver of mouse events to
be the active popup widget. But when we send a mouse event to
the popup, the receiver might start a new QEventLoop (e.g by
executing a new dialog). And in the meantime, the popup will
be destroyed. This will cause a crash in the line after the
event delivery (where we sat "qt_last_mouse_receiver = receiver"),
since at that point, "receiver" would be a dangling pointer.

This patch will use a QPointer instead of a raw pointer to
store "receiver", to ensure that it's set to null for
such cases.

Fixes: QTBUG-71062
Change-Id: Ie017cfa97370513ecfdd62c056fcb0e6c991f9f6
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
2018-11-07 13:22:21 +00:00
Liang Qi
825f988156 Modernize the "textcodec" feature
Also clean up QTextCodec usage in qmake build and some includes
of qtextcodec.h.

Change-Id: I0475b82690024054add4e85a8724c8ea3adcf62a
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
2018-11-07 13:19:54 +00:00
Allan Sandfeld Jensen
cfbb0d2b40 Avoid crashing with opaque opacity effect
Fixes the crash, but doesn't fix the underlying bug.

Task-number: QTBUG-60231
Change-Id: I5db9b151089b5c0e21e21443c77c725804d3059c
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
2018-11-07 12:26:09 +00:00
Allan Sandfeld Jensen
6d255b467b Fix composition example during OpenGL resizes
Previous images were sometimes not cleared correctly.

Change-Id: I62949b756bf797aa79c5160774f2f258e5c353dd
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
2018-11-07 12:26:03 +00:00
Timur Pocheptsov
d786c55b9e Make tst_qsslsocket::protocolServerSide() less flaky
By accident, when we erroneously tried testing TlsV1_3 on macOS with
SecureTransport (which does not support TLS 1.3) we hit this quite
subtle problem: it can happen that a server-side socket is never
created but a client (after TCP connection was established) fails
in TLS initialization and ... stops the loop preventing
SslServer::incomingConnection() from creating its socket. Then we
dereference nullptr.

Task-number: QTBUG-71638
Change-Id: I8dc5a4c53022a25aafe2c80a6931087517a48441
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2018-11-07 12:25:12 +00:00
Oswald Buddenhagen
1dd6433b19 qmake: fix .prl file generation for bundles
amends 2b27646146a.

Fixes: QTBUG-70444
Change-Id: I8bd310f5624ea0ac9260c7d9ea0d29b0c9caa077
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2018-11-07 10:32:52 +00:00
Janne Koskinen
efc7e02911 INTEGRITY: Fix missing uint/int 128 support for 64-bit ARM
Add 64bit specializations for mul_overflow.

Change-Id: I8bba69233dd71b94346983a100cf4d69bfc686f7
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2018-11-07 10:32:44 +00:00
Timur Pocheptsov
b3ae87fe76 Add missing protocol enumerators, report TLS 1.3 if negotiated
1. Remove the conditional inclusion of DTLS versions, they made difficult
and unnecessary ugly adding new protocols (something like TlsV1_2OrLater + 4).

2. OpenSSL 1.1.1 first introduced TLS 1.3 support. OpenSSL 1.1 back-end is
compatible with OpenSSL 1.1.1, but would fail to extract/report protocol
versions and set versions like 'TLS 1.3 only' or 'TLS 1.3 or better' on a
new context.  Given 1.1.1 is deployed/adapted fast by different distros,
and 5.12 is LTS, we fix this issue by introducing QSsl::Tls1_3 and
QSsl::Tls1_3OrLater.

SecureTransport, WinRT and OpenSSL below 1.1.1 will report an error in case
the application requests this protocol (SecureTransport in future will
probably enable TLS 1.3).

Saying all that, TLS 1.3 support is experimental in QSslSocket.

Done-by: Albert Astals Cid <albert.astals.cid@kdab.com>
Done-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Change-Id: I4a97cc789b62763763cf41c44157ef0a9fd6cbec
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2018-11-07 10:32:35 +00:00
Timur Pocheptsov
edacfd2f0b Fix QTableView/Widget on macOS
For this we can use whatever the current NSColor.gridColor contains.
While this is mostly needed by the 'Dark' appearance, it also affects
the 'Light' theme, since the color QCommonStyle returns is different.
Let's use whatever Apple suggests.

Task-number: QTBUG-71048
Change-Id: I084414bad546755e9e67792484fe4601826ed0fa
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2018-11-07 06:54:00 +00:00
Thiago Macieira
b5d249f953 Update the floppy disk icon (save) to be physically correct
[ChangeLog][Documentation] Fixed the icons for the "file save" action
that were inaccurate representations of a 3.5-inch floppy disk (the cut
edge was on the wrong side). Now all floppy representations are
physically accurate.

Change-Id: Ia3b27ae12a1a4fefa3b7fffd155bb86fee5271c3
Fixes: QTBUG-71012
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2018-11-06 20:43:36 +00:00
Allan Sandfeld Jensen
97600d2c28 White-list more recent Mesa version for multi-threading
The issue we had has been fixed for years, but was unfortunately in
libxcb which we can't check at runtime. Instead assume very recent
Mesa drivers works.

Change-Id: I5fdd726b480b77edbedc0f369ae82ab4acbb77c9
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
2018-11-06 19:16:22 +00:00
Edward Welbourne
ac4d954cfb Update DejaVuSans.ttf from upstream
Document the version in the process; and make the wordings of
copyright notices match those in DEJAVU-LICENSE.

Task-number: QTBUG-70008
Change-Id: I1c965e5d7afb18dc4dbdffed908512c5771ab717
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2018-11-06 16:41:18 +00:00
Edward Welbourne
d16babf351 Update sha3's brg_endian.h, document provenance and version
The existing copyright notice gave me a name; github found me a file;
but it doesn't match what we had before.  Made some guesses at which
parts of the change relative to upstream to keep, documented the diff
as a patch and recorded details in qt_attribution.json

Task-number: QTBUG-70008
Change-Id: I423724435eaeeda7237f8b3df8691b436fed8652
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2018-11-06 16:41:08 +00:00
Volker Hilsheimer
3f61873f49 Correctly document value of QThread::currentThreadId on Windows
The implementation calls GetCurrentThreadId, not GetCurrentThread, so
the return value is not the pseudo-handle.

Task-number: QTBUG-67686
Change-Id: Ifde0cf603dcea01bc1c454a8bebe1e5c0f22617f
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2018-11-06 16:41:00 +00:00
Oswald Buddenhagen
e14e8427fa fix configure instructions in libpng and libjpeg attributions
Fixes: QTBUG-71379
Change-Id: Ib1efbe0fc4407ccf6ab814229dc4a08d9d03b6b5
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2018-11-06 16:40:44 +00:00
Liang Qi
1f984dee90 Merge "Merge remote-tracking branch 'origin/5.12.0' into 5.12" into refs/staging/5.12 2018-11-06 13:00:36 +00:00
Andrew Smolko
9f2216667a Fix memory copy in QGIFFormat::disposePrevious()
Fix invalid destination address in memcpy operation when RestoreImage disposal method is used.

Task-number: QTBUG-71599
Change-Id: Ib74a044c0e45250ff708268c463f831ee54933e6
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
2018-11-06 12:54:17 +00:00
Topi Reinio
4615415500 Doc: Tie the QScopeGuard documentation to a class
Previously no documentation was generated for the global qScopeGuard()
function. Create a class documentation page and add the the function
as a related non-member using \relates.

Task-number: QTBUG-71502
Change-Id: Ida5d7044f4de962360dfee9321feb49005d4b299
Reviewed-by: Martin Smith <martin.smith@qt.io>
2018-11-06 12:44:28 +00:00
Topi Reinio
46a595b047 Doc: QCbor classes: Fix \variable commands
\variable must not include the variable type, QDoc will resolve that.
This commit resolves four documentation warnings.

Task-number: QTBUG-71502
Change-Id: I5e88cf66d3c3bb8f18495d5477e1271ac2cd9e74
Reviewed-by: Martin Smith <martin.smith@qt.io>
2018-11-06 12:44:21 +00:00
Topi Reinio
a92735ec00 Doc: Document Qt::ScrollMomentum
And fix a typo in Qt::ScrollEnd.

Task-number: QTBUG-71502
Change-Id: I3efdbd12415814e066edd1b2f102a792812d36d5
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2018-11-06 12:44:14 +00:00
Topi Reinio
411430f420 Re-add missing ANGLE license files
Commit 0a7aebad inadvertently removed two ANGLE-related files for
license information. This caused the licensing documentation to
fail to generate for those components.

Task-number: QTBUG-71502
Change-Id: I33ee673267c43474304d577e78fc1a0c3bd8691f
Reviewed-by: Martin Smith <martin.smith@qt.io>
2018-11-06 12:43:35 +00:00
Topi Reinio
ec1548ae12 Doc: Fix various documentation warnings
These include typos, marking functions as \internal, documenting
trivial things, and fixing the function signatures passed to the
\fn command.

Task-number: QTBUG-71502
Change-Id: I24a9e1f7e1cdb39e5c31b99202bdd593c6b789ff
Reviewed-by: Martin Smith <martin.smith@qt.io>
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2018-11-06 12:43:26 +00:00
Topi Reinio
8828993c44 Doc: Qt GUI: Fix documentation warnings
These are minor typos or documentation warnings that snuck in with
new features.

Task-number: QTBUG-71502
Change-Id: I03669cfecc3c3d80168ff7b1ca8bca7571e06d25
Reviewed-by: Martin Smith <martin.smith@qt.io>
2018-11-06 12:43:17 +00:00
Christian Ehrlicher
1771b8d7c6 QFbCursor: Avoid nullptr access when QT_QPA_FB_HIDECURSOR is 0
When the environment variable QT_QPA_FB_HIDECURSOR is set to 0,
the two class members mCursorImage and mDeviceListener are nullptr
but this was not checked in the functions afterwards.

Task-number: QTBUG-64844
Change-Id: Ic0fd6a09851777643e59bedf2c006a6bb9a36801
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
2018-11-06 12:11:22 +00:00
Samuli Piippo
033cc3403a mkspecs: use cross compile tools with LTCG
AR and NM have different tools when LTCG is used,
override those also when cross compiling.

Fixes: QTBUG-71595
Change-Id: I5347bd1874688dd89395c50ff6dd08fb1c0ebab1
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
2018-11-06 10:51:38 +00:00
Liang Qi
eedb3a06cb Merge remote-tracking branch 'origin/5.12.0' into 5.12
Change-Id: I12f26470e01a8582d0f02f51e20d5b742bd95d6f
2018-11-05 19:06:47 +01:00
Allan Sandfeld Jensen
73e7eb785f Enable swizzling
This part was accidently left disabling after testing the
fallback still worked.

Change-Id: Ic2df939753641a9771e68bc8857c570d356cff44
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
2018-11-05 15:16:24 +00:00
Jani Heikkinen
d24835a60c Merge "Merge remote-tracking branch 'origin/5.11' into 5.12.0" into refs/staging/5.12.0 2018-11-05 12:49:22 +00:00
BogDan Vatra
60197af485 Android: Fix build.gradle
Configuration 'compile' is obsolete and has been replaced with
'implementation' and 'api'.
It will be removed at the end of 2018. For more information
see: http://d.android.com/r/tools/update-dependency-configurations.html

Task-number: QTBUG-71570
Change-Id: I6f498d8cb3ff01ad641aee697496e3dc56059a72
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
2018-11-05 12:49:17 +00:00
Laszlo Agocs
67c66c4ea4 windows: Give up on SwitchableComposition
Opt out of switching between the normal and OpenGL based flush paths.
Once a QOpenGLWidget or QQuickWidget becomes visible in a window, the
window contents will be composed using OpenGL from that point on, even
if said widgets become invisible afterwards. Now that Qt Creator does
not rely on QQuickWidget the issue is less burning anyways.

Task-number: QTBUG-68329
Change-Id: I177e6e6094ee06ea26d8d0343bd3d84aadfa5913
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
2018-11-05 12:33:14 +00:00
Liang Qi
b36c5bdc30 Merge remote-tracking branch 'origin/5.11' into 5.12.0
Conflicts:
	src/plugins/platforms/cocoa/qcocoaglcontext.mm
	src/plugins/platforms/xcb/qxcbscreen.h

Change-Id: If9b4c67288396ff7346088ce591c7a3588b51979
2018-11-05 09:59:59 +01:00
Lars Knoll
98365711a0 Remove unused variable
Change-Id: I241969d10502e944f7a73971771730d43dd2784f
Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
2018-11-02 13:48:57 +00:00
Allan Sandfeld Jensen
dc2aead842 Fix build with -qt-libpng on powerpc
It appears we are missing some setups for SIMD optimization, and already
have a workaround for that for NEON, so do the same for VSX.

Fixes: QTBUG-66388
Change-Id: I1cc1d0fe9c5a9df97acb589d29dec4dceb8fc576
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
2018-11-02 13:48:46 +00:00
Edward Welbourne
ceeecbae51 Update various qt_attribution.json files
Marking various as final because no upstream is known or available.
Listing versions of others, where I was able to discover them.
Updated a stale link (that helpfully redirected).

Task-number: QTBUG-70008
Change-Id: Id00f34827133c560735c68793b4f1353f2b2ca85
Reviewed-by: Tobias Koenig <tobias.koenig@kdab.com>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: Jani Heikkinen <jani.heikkinen@qt.io>
Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
2018-11-02 13:48:35 +00:00
Frederik Gladhorn
daf9ba91ae Stabilize tst_QAccessibilityLinux::testFocus
The tests would rely on the window manager giving it focus a bit too much.

Change-Id: I1b28def2c95a4f0a9665a7cf6e0c14db03df98d5
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
2018-11-02 13:45:49 +00:00
Nico Vertriest
47869340b9 Doc: Solve issue with gridlayout image file
Due to name conflict with file from qtdeclarative

Task-number: QTBUG-65769
Change-Id: I9ebf237701ce76b424f528feacb24e4158f06c0d
Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
2018-11-02 12:41:10 +00:00
Paul Wicking
afba8fcc49 Doc: Add description for mode argument of qmake's $$system()
Fixes: QTBUG-70926
Change-Id: Icfd13352cd64053c11502058188041ad16f6c287
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
2018-11-02 12:40:59 +00:00
Edward Welbourne
3fbf8fbc85 Update to CLDR v34
This only updates data on languages already present in 5.12; once it
has merged up to dev, the scripts need to be run again to pick up a
few more languages and possibly add any more new languages present in
v34.  Change some tests to match changes in en_AU's abbreviated day
and month names.

[ChangeLog][ThirdParty][CLDR] Update locale data to CLDR v34.

Task-number: QTBUG-71144
Change-Id: I68402b5e7e9d3dba669b8ba31b9a8abd86675c6e
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2018-11-02 12:40:46 +00:00
Christian Ehrlicher
2b682972c2 QSqlQuery: add another testcase for bindBool()
tst_QSqlQuery::bindBool() did not check if the bool is correctly bound
as part of the WHERE statement. Add a new test to query for the bool
column and check if there is exactly one row returned.

Fixes: QTBUG-38891
Change-Id: I0bd1ceb1b30e50f67f44f5b06d68683195b78b29
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
2018-11-02 08:27:12 +00:00
Gary Wang
e3c84b6da1 QMimeType: Use default key as fallback for comment() property
When QMimeProvider parses the shared mime database xml files,
it will read the <comment> element for mime comment and treat the
`xml:lang` attribute as locale language string. When no `xml:lang`
attr is provided, QMimeProvider will read the value and treat it as
a en_US locale string as the default key.

When we call QMimeType::comment(), it will try to get the locale
comment string with the default language (QLocale().name()), once
it can't find a matched result, it should return the default key
(which QMimeProvider set it as en_US locale before) as fallback.

Task-number: QTBUG-71314
Change-Id: I444f8159d6f19dfef6338cd79312f608d8f13394
Reviewed-by: David Faure <david.faure@kdab.com>
2018-11-02 08:27:10 +00:00