summaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* iOS: Account for UITextInteraction when building against 12.x or lowerv5.12.6Andy Shaw2019-11-081-4/+2
| | | | | | | | | | In iOS 13.0 we can handle UITextInteraction as normal, but in lower versions it is not available to utilize at compile time. So we have to check for the other types instead and return if it is not one of those. Change-Id: Icbc5558e677ed40c03f30a174e2d79b87f489f68 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> (cherry picked from commit 3916b8a28bc9c55e10f4de611ed76e17017494aa)
* Ensure that child windows are visible again when showing their parentAndy Shaw2019-10-312-3/+13
| | | | | | | | | | | | | | | When a window is closed, then it will cause the child windows to be closed as well as a result. Therefore in order to ensure that they are shown again as a result, we need to remove the WA_WState_ExplicitShowHide attribute if the widget was not already hidden before. This enables us to test for this attribute when calling showChildren(), so that if the window has a windowHandle then we can make sure that this widget is shown again. Fixes: QTBUG-73021 Change-Id: I1186242b889899dfcd38d782a67567348e2055ee Reviewed-by: Ulf Hermann <ulf.hermann@qt.io> (cherry picked from commit ccd3bf0871b81dfc09bb469b161f32dfb47ee53e)
* Update bundled libjpeg-turbo to version 2.0.3Eirik Aavitsland2019-10-3015-78/+185
| | | | | | | | | | | | [ChangeLog][Third-Party Code] libjpeg-turbo was updated to version 2.0.3 Squashed cherry pick of: e14e8427faae670c662efede723edc2db4c875cb 97e78b0e1f0396cdee0319bafaf8ce1d6eb74f64 f3dbe98dca58731ff98dff3cc9111a8252f8e1e6 Change-Id: I9f9b8b3a913fd5843759c0610f43b22c5bee67dc Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* Only call ShowCaret if Windows 10 1709 or later is usedAndy Shaw2019-10-301-5/+7
| | | | | | | | | | | | | This amends cc873ec23a98ac32d10ac5fa569792fde2f6b2c8 which worked around a problem that was showing up on earlier versions of Windows. This extends the workaround up to Windows 10 1703 as the problem was still occurring up to that version. Fixes: QTBUG-79143 Change-Id: Ib7eace17fb8e3817c556e2bcd462e37834b1cbcf Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: André de la Rocha <andre.rocha@qt.io> (cherry picked from commit be73bdc5d2491d036e5a6334dada453ed808dbc0)
* Fix a -Wclass-memaccess problem in qjsonVille Voutilainen2019-10-281-1/+3
| | | | | | | | | | qtbase/src/corelib/serialization/qjson_p.h:230:38: error: ‘void* memcpy(void*, const void*, size_t)’ copying an object of type ‘QJsonPrivate::qle_ushort’ {aka ‘class QSpecialInteger<QLittleEndianStorageType<short unsigned int> >’} with ‘private’ member ‘QSpecialInteger<QLittleEndianStorageType<short unsigned int> >::val’ from an array of ‘const class QChar’; use assignment or copy-initialization instead [-Werror=class-memaccess] 230 | str.length()*sizeof(ushort)); | ^ Change-Id: Ie58e7fe4bae3003227364012ad56ab23bd560d8c Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> (cherry picked from commit 9367d966e6c10c95b92f2b55e2cead7e85d80cfe)
* Revert "Release left button before showing the popup context menu"Eskil Abrahamsen Blomfeldt2019-10-253-19/+0
| | | | | | | | | | | | | | | | | This partially reverts commit 5e8b16f0e4247cc978b08480450526cfa3b25029. Releasing the mouse button synthetically made it impossible to use tap and hold gestures. When investigating, it seems that other changes have fixed the original issue that 5e8b16f0e4247cc978b08480450526cfa3b25029 was meant to address, so this is no longer needed. [ChangeLog][Android] Fixed regression that made it impossible for an application to use the tap-and-hold gesture. Fixes: QTBUG-72408 Change-Id: I53f687d047a4ad0fdf3c8c96a00ed1b11d09f047 Reviewed-by: BogDan Vatra <bogdan@kdab.com> (cherry picked from commit d3398207d0384e786f466662fa40c6fb86844fb6)
* Windows/MinGW: Fix posted events timer not stoppingFriedemann Kleint2019-10-242-3/+7
| | | | | | | | | | | Specify the type of the enum value SendPostedEventsWindowsTimerId to be UINT_PTR to work with the g++ interpretation of enumeration signedness and use the correct type for the returned timer id. Fixes: QTBUG-78491 Change-Id: I7b3f306d3f60da7a21500ece5243ac90854ccf1a Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> (cherry picked from commit d35de9e1b250ce46739dcb6afb9ae8a0247195c7)
* Remove DirectWrite warning when loading bitmap fontsEskil Abrahamsen Blomfeldt2019-10-211-8/+10
| | | | | | | | | | | | | | | | | | | | | We use DirectWrite to determine whether a font is a color font or not, so all fonts go through DirectWrite initially. However, the load call will fail for bitmap fonts, causing us to output lots of pointless warnings each time such a font was in use. Instead, we only output this warning if we actually plan to load the font through DirectWrite later. If the load fails, we can assume it is not a color font and do not need to output any warning for this. [ChangeLog][Windows][Text] Removed confusing DirectWrite warning when loading bitmap fonts. Task-number: QTBUG-57180 Change-Id: Iaac8117745ef05a1dff23b346dbe0c6dbfb315f7 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> (cherry picked from commit c4a524f3a129ad9ab6d08cd8de2dc917e3d78fc5) Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
* macOS: Optionally flush sub-layers via sub-image copies of the backingstoreTor Arne Vestbø2019-10-181-10/+19
| | | | | | | | | | | | | | | | | When we're flushing the backingstore to sub-views with their own layers we don't want to pay the cost of uploading the whole backingstore to the GPU in the case where we're dealing with a discrete GPU. To work around this we make a copy of the appropriate part of the surfcace. This results in additional copies of the data, and will need further investigation to limit these. Task-number: QTBUG-77447 Change-Id: I318ae80e433dd7b0a55fd5a598b19f114d8bd28e Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io> (cherry picked from commit eaf4911db29a82b3d94826a8ff09afe075a2b636) Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* iOS: Account for when the older SDK is used when buildingAndy Shaw2019-10-182-2/+5
| | | | | | | | | | | Since the pre-built versions of Qt at this point are still built against the iOS 12.x SDKs, then we need to account for this in order to have the workaround implemented in e00d888daefbfbd5f17e0772421773f8e295087b still working when deployed to an iOS 13 based device. Change-Id: I649a453c549ee272de64624d68f9382276fcba64 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> (cherry picked from commit 631efee29371246ba1a1d9d007b23ca08b867191)
* Fix for compilers that don't allow casting nullptr_t to an integerVolker Hilsheimer2019-10-141-1/+2
| | | | | | | | | | Visual Studio 14.0 toolchain at least seems to be broken enough to somehow interpret the cast from nullptr to a quintptr as being ill-formed, inspite of it being valid C++. Change-Id: Ifb29be3af82764cb31fa65409f7e1000ea419498 Fixes: QTBUG-79080 Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
* Include likely-adjusted uiLanguages for the system localeEdward Welbourne2019-10-103-17/+69
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QLocale::uiLanguages() on the system locale uses whatever the system locale's query(QSystemLocale::UILanguages,...) returns. On Android, this is just a list of locales. However, for non-system locales, we also include some results of removing likely sub-tags from the locale name, where equivalent. Thus zh-CN would also get zh and zh-Hans-CN added to it; however, if the system locale is zh-Hans-CN, the shorter forms are omitted. So post-process the system locale list in the same way, albeit tweaked to avoid duplicates and rearranged so that we can insert likely-adjusted entries between what they adjust and what followed it. Added QLocalePrivate::rawName() in the process, since it looks likely to be useful in other contexts (and I needed its value): it just joins such tags as are non-Any. This, however, uses QByteArrayList, so added that (it's small) to the bootstrap library and qmake. This follows up on commit 8796e3016fae1672e727e2fa4e48f671a0c667ba. [ChangeLog][QtCore][QLocale] The system locale's UI languages list now includes, as for that of an ordinary locale, the results of adding likely sub-tags from each locale name, and of removing some, where this doesn't change which locale is specified. This gives searches for translation files a better chance of finding a suitable file. Fixes: QTBUG-75413 Change-Id: Iaafd79aac6a0fdd5f44aed16e445e84a2267c9da Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Paul Wicking <paul.wicking@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> (cherry picked from commit 0118e2e9151ae3e1e1cd72f24e8c129eaa69dc4f)
* Filesystem: avoid crashes on exit in case the locale codec is nullThiago Macieira2019-10-091-1/+3
| | | | | | | | | | | | | | | | | | | | On exit, QLocale::codecForLocale() can return null as the codec may have already been destroyed. In that case, pretend that Latin1 was the locale, so any file name is acceptable. This matches QString: QTextCodec *codec = QTextCodec::codecForLocale(); if (codec) return codec->toUnicode(str, size); #endif // textcodec return fromLatin1(str, size); Note that if we're wrong and the locale was *not* Latin1, files that you had a name to may not be encoded or decoded the same way. Fixes: QTBUG-78446 Change-Id: Iece6e011237e4ab284ecfffd15c54077728a17ca Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> (cherry picked from commit 70e6e9fe590590f602dee230a64870365d9301aa)
* evdevtouch: Report stationary touchpoints that include pressure changesShawn Rutledge2019-10-091-1/+5
| | | | | | | Task-number: QTBUG-77142 Change-Id: I35446092679573df51891302155c896a3bb6fc1c Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io> (cherry picked from commit ee9bc61cd906505271bad887664c15b9397906ab)
* Fix QRandomGenerator initialization on AMD CPUsDmitry Kazakov2019-10-084-46/+88
| | | | | | | | | | | | | | | | Some AMD CPUs (e.g. AMD A4-6250J and AMD Ryzen 3000-series) have a failing random generation instruction, which always returns 0xffffffff, even when generation was "successful". This code checks if hardware random generator generates four consecutive equal numbers. If it does, then we probably have a failing one and should disable it completely. Change-Id: I38c87920ca2e8cce4143afbff5e453ce3845d11a Fixes: QTBUG-69423 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> (cherry picked from commit 5839714d986f28412c9f9ed4801d1bf9378f7b51) Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Ensure all children of a widget get updated when a stylesheet changesAndy Shaw2019-10-081-0/+5
| | | | | | | | | | Before, only the direct children would get an update when the stylesheet changed, any children below that would be unchanged. Fixes: QTBUG-77006 Change-Id: Id668eaae74a8289d78d66644f077e6a3302960cd Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io> (cherry picked from commit 9b6179cf957c32e0c02547d510dfee2088f02340)
* iOS: Prevent UIKit from adding UITextInteraction to our viewTor Arne Vestbø2019-10-071-0/+12
| | | | | | | | | | | | | | | | | | | | It's added automatically when some languages such as Japanese are the active input language/keyboard, which results in UIKit triggering the edit menu for any tap in the UI, regardless of whether it hits the focus object or not. Adopting the protocol is a much larger effort and needs to be coordinated so that we still support text interaction on iOS versions pre 13.0. Even with this patch the UITextSelectionView will still blink its own cursor, which doesn't seem to sync up with the UITextInput protocol's view of where the cursor is. Fixes: QTBUG-78496 Change-Id: I61500ad7ab9c8577f71188c0c99ead39465e3839 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> (cherry picked from commit e00d888daefbfbd5f17e0772421773f8e295087b)
* Fix CVE-2019-16168 in SQLiteAndy Shaw2019-10-072-1/+46
| | | | | | | | | | | | v3.29.0 is the latest and there is no indication as to when the next release is so we will apply this separately for now and it can be reverted once it is in a release that we ship with. This patch is taken from https://www.sqlite.org/src/info/98357d8c1263920b Change-Id: I82d398b093b67842a4369e3220c01e7eea30763a Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> (cherry picked from commit c3faeb852866a2fc8ae9cd6f8cf91947bd42b538)
* sqlite: Update to v3.29.0Andy Shaw2019-10-073-3112/+4062
| | | | | | | | [ChangeLog][QtSQL][sqlite] Updated to v3.29.0 Change-Id: Ibf61c829dcd24dc8cdf00f5b57078255b0ad5ef1 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> (cherry picked from commit f88476569a8608d0f8257fcf3c426cbc68de6d7c)
* Add QQuickMultiPointTouchArea as a friend of QTouchEventShawn Rutledge2019-09-251-0/+1
| | | | | | | | | | | QQuickMultiPointTouchArea needs to understand whether a stationary touchpoint has relevant property changes, to decide whether to emit its updated() signal. Amends 217dd1b3b03cd40b4bb926631464c684f7f84a69 Task-number: QTBUG-77142 Change-Id: I85e031820bef9d687369b7d67a57c67fe2875b4b Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> (cherry picked from commit bc35941dbbf6cbd09805a2217ecb062c565855ad)
* Mark stationary touch points as updated if pressure or velocity changesShawn Rutledge2019-09-253-1/+6
| | | | | | | | | | | | | | This is to inform Qt Quick when a stationary touchpoint is delivered that it is because of a changed property. Qt Quick still needs to avoid delivering item-customized events (with only the touch points that occur inside the item) that contain only stationary touch points without changed properties. To be able to check this private flag, QQuickPointerTouchEvent needs to be a friend. Task-number: QTBUG-77142 Change-Id: I6ee0dffbbeca9e513c77227b757252e2eec6a4ef Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> (cherry picked from commit 217dd1b3b03cd40b4bb926631464c684f7f84a69)
* Move DialogButtonBoxLayout case to be before MouseDoubleClickDistanceAndy Shaw2019-09-241-3/+2
| | | | | | | | | | This amends 9be66cb282dee1ce4380602a2f3caf5abfd144cf so that the DialogButtonBoxLayout case is moved to be before the MouseDoubleClickDistance one in case the fallthrough is triggered. Change-Id: I843dad6b55ccffe6b6c275cd75587f04659e512f Reviewed-by: BogDan Vatra <bogdan@kdab.com> (cherry picked from commit 54d3059ccfe6df0a375d2addac4ad41333122b8d)
* evdevtouch: Add fallback definition of ABS_MT_PRESSURE; fix alignmentShawn Rutledge2019-09-201-2/+5
| | | | | | | Fixes: QTBUG-78298 Change-Id: Ib6acb1fdca551a84aba5dec2f28cf784a212692c Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io> (cherry picked from commit 15e1c159868774b0b3c532a09281d45798b0f5d8)
* widgets: Mark widgets as needing flush during paintingTor Arne Vestbø2019-09-202-12/+4
| | | | | | | | | | | | | | | | | | | Except for the case of syncing in response to an expose event, where the platform asked us to flush a specific region, we should strive to only flush parts that have been repainted. And we should flush those parts to their nearest native child, instead of unconditionally flushing the root/top level widget as well. By allowing drawWidget to schedule the flush we automatically flush the minimal region, to the right widgets. (manually cherry-picked from commit 79bf1b7e348d186934b14c417859a48bf9b3a06c) Task-number: QTBUG-77447 Change-Id: I1a8fa703c0b7172655271e2a8f5eca694cb14129 Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
* macOS dark mode: set the link colorShawn Rutledge2019-09-191-1/+5
| | | | | | | Fixes: QTBUG-71740 Change-Id: I49f49338c7f3a28845de63c2a6bf2dc8495dd108 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> (cherry picked from commit 117175a2f2ecab990f65eefd32b42be22f9aa3ce)
* Doc-fix: correct some misinformation about QDateTime's handling of DSTEdward Welbourne2019-09-191-23/+30
| | | | | | | | | | | | | | | | | Tidy up QDateTime::offsetFromUtc's doc, in the process. We don't take DST into account for dates before the epoch; that should be mentioned when saying we take DST into account. Also, referring to *this as the "current" time begs to be misunderstood. The \class comment also misleadingly claimed that we don't take into account any changes to time-zone before DST; where, in fact, we only ignore DST changes before 1970, not changes to standard offset. (Conflict resolution also pulled in a typo-fix from 5.14.) Change-Id: I090e668edf0338c825f5afcc67f894579a129c46 Reviewed-by: Paul Wicking <paul.wicking@qt.io> (cherry picked from commit c6bde29e143b1fadac97f656ba6c3059135d4a11) Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* MS TZ data: avoid calculating a date in year 0Edward Welbourne2019-09-191-13/+29
| | | | | | | | | | | | | | | | | | | | | | | | | There is no year 0 in the proleptic Gregorian calendar, so QDate() won't be happy if asked for a date in it. Tweak scanning of the data we get from MS-Win so as to avoid a date calculation that could otherwise happen in year 0 when constructing QDateTime(QDate(1, 1, 1), QTime(0, 0, 0), QTimeZone("Australia/Sydney")). Added a test for this case, which Oliver Wolff has kindly verified does reproduce the assertion failure. However, Coin is unable to reproduce, as all its MS builds are configured with -release, so Q_ASSERT() does nothing. (The relevant code then skips over year 0, albeit for the wrong reasons, and gets the right results, albeit inefficiently, leaving no other symptom by which to detect the problem.) Fixes: QTBUG-78051 Change-Id: Ife8a7470e5bd450bc421e89b3f1e1211756fc889 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Oliver Wolff <oliver.wolff@qt.io> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> (cherry picked from commit 8286daba038d3c90d2bc06785ffcf9c0c603cb83) Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* Update hints on how to link to OpenSSLKai Koehne2019-09-193-7/+7
| | | | | | | | | | | | | | | | | | | | The traditional way to fix building against a custom OpenSSL is to set the OPENSSL_LIBS environment variable. Anyhow, since Qt 5.6 there's a more generic way to configure linking against external libraries by configuring the <LIB>_INCDIR, <LIB>_LIBDIR, <LIB>_PREFIX, <LIB>_LIBS, <LIB>_LIBS_DEBUG and <LIB>_LIBS_RELEASE qmake variables at configure time. Using these have following advantages: - Can handle different libs for a -debug-and-release build - Can be used also for other libs than just openssl So let's try to promote this. Also update any examples for OpenSSL 1.1. Change-Id: I24dbccdd87d0fc50bf31c6afe7aa692d4b810fb7 Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>
* macOS: Keep default NSWindow background unless window is framelessTor Arne Vestbø2019-09-161-2/+2
| | | | | | | | | | | | | | | | | | | | | The logic was changed in ee82f8661 to only draw a window background when the window was textured, and otherwise ask for a clear window background. This has an unfortunate side-effect on macOS 10.15 that the window's title bar will be partially transparent and reflect the content under the window, with a blur effect. It also inadvertently broke the use-case of setting the NSWindow background color explicitly. With this patch we're back to the behavior before ee82f8661, and users who still want to have a non-borderless window with a clear background can still do this by setting the background color to the clear color manually. Task-number: QTBUG-77637 Change-Id: I8a11bc46e6393b29a37f002ea123a987048106b9 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io> (cherry picked from commit 4534522ff0f189418d828fd29b9d417b5a1b5d27)
* Handle robustness with OpenGL < 4.0Allan Sandfeld Jensen2019-09-131-1/+23
| | | | | | | | | | We need to have the right idea of robustness, so check for extension. Fixes: QTBUG-78107 Change-Id: I26987269e5c50bee20e2e3cc6d75f91a6c9af25e Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io> (cherry picked from commit bc34784d053ebf9b0d167e9398052fcc80d8af87) Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* QMenu::popup(): don't change the menu's screen if called from exec()Shawn Rutledge2019-09-101-7/+10
| | | | | | | | | | | | | | | | | | | | | | Since b3fc5e1ea3eb4fe838ac716aaca4efaa5de5a814, topData()->initialScreenIndex has always been short-lived: it only remembers the screen in case the widget parent is a QDesktopScreenWidget (gotten from QDesktopWidget::screen()), only until the window is created. Then it is reset. In the case of exec() we need to avoid calling setScreen() twice, because that would set the screen once, then forget which screen it was supposed to be on, then set the screen again when exec() calls popup(). This is achieved by using the stored eventLoop pointer to detect that popup() is being called from exec(), and avoid calling setScreen() a second time in popup(), because exec() already needed to call createWinId() before it created the event loop. Amends 82da8306bc1313b85632eee0faf858239261a092 Task-number: QTBUG-76162 Change-Id: I70da517b9d530630e59d103cb2a1ce11c897b2c8 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Joni Poikelin <joni.poikelin@qt.io> (cherry picked from commit 648dac1ceb40a346adf2081997f5c6166c3ad503)
* Merge remote-tracking branch 'origin/5.12.5' into 5.12Qt Forward Merge Bot2019-09-071-8/+7
|\ | | | | | | Change-Id: I41a252fdbf22551aadb0b1a6e9ecf3f95f99fbd4
| * Fix crash when text contains too many directional charsRainer Keller2019-08-301-8/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In case a text to be layouted contains more than 128 directional characters it causes the application to crash The function initScriptAnalysisAndIsolatePairs() collects information of RTL/LTR chaaracters into vector "isolatePairs". The size of the vector is capped to 128. Later the function generateDirectionalRuns() iterates the text again and tries to access items from the previously capped vector above the upper bound. Task-number: QTBUG-77819 Change-Id: Ibb7bf12c12b1db22f43ff46236518da3fdeed26a Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | A follow-up to a recent fix in QHttpNetworkConnectionChannelTimur Pocheptsov2019-09-063-1/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | While working with HTTP/2, we are not re-sending failed requests. In case we receive a GOAWAY frame, we properly handle it by processing some active streams if possible, and aborting streams that will not proceed further with ContentResendError. But it's possible that some server failed to send us GOAWAY (for example, it died) or closed the connection not finishing the streams that were still active and valid (ID <= value from GOAWAY frame). Now that we will not re-connect, there is no reason to be quiet about us not progressing - emit RemoteHostClosedError on any remaining active stream/request we cannot process further. Fixes: QTBUG-77852 Change-Id: I4cd68a1c8c103b1fbe36c20a1cc406ab2e20dd12 Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io> Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io> (cherry picked from commit 543769666f18f79bd6ebd6119a39834aafc2b0df)
* | QShortcut: call base class implementation in event()Christian Ehrlicher2019-09-051-4/+2
| | | | | | | | | | | | | | | | | | | | | | QShortcut::event() did not call the base class implementation QObject::event() which caused that e.g. QEvent::DeferredDelete was not handled. Fix it by calling QObject::event() when the event was not handled. Fixes: QTBUG-66809 Change-Id: Ideebc980bc658f8f2b9ec4417e738bccda5eeab5 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* | qFatal: make it so you cannot disable the messageThiago Macieira2019-09-041-2/+2
| | | | | | | | | | | | | | | | | | | | Solves a few recursion problems in Qt, since then we won't try to inspect the logging registry while creating the logging registry. Fixes: QTBUG-78007 Change-Id: I44cc9ee732f54d2380bafffd15c0f51c7140682e Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | Deliver stationary touchpoints that have changed pressureShawn Rutledge2019-09-022-4/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | As a rule, we don't deliver touch events containing only stationary touchpoints. To fix QTBUG-52510 we added an exception in 1bd0ab7050304d9e8989cde77e486947c56b9696 : if the velocity changed, deliver it anyway. Now we need to do the same if the pressure changed. Also, on the customer's hardware, pressure is indicated via ABS_MT_PRESSURE. Change-Id: If7f7088df055d686cdd86967b999e38024f8170f Fixes: QTBUG-77142 Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* | Avoid invalid memory access in QIconCacheGtkReader::lookup()Alexander Volkov2019-09-021-1/+1
| | | | | | | | | | | | | | | | | | If name argument is empty, e.g. an icon is created by QIcon::fromTheme(""), then icon_name_hash() will access a byte at index 1, which is outside of the string. Change-Id: I109c476718939d7dd252007ebac48c3dbbeceb72 Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
* | QHttpNetworkConnectionChannel - avoid re-connecting on 'disconnected'Timur Pocheptsov2019-09-021-2/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The _q_error slot has a special case for RemoteHostClosedError, where the current channel's state is 'idle' and no request/reply is in progress. The comment states that: "Not actually an error, it is normal for Keep-Alive connections to close after some time if no request is sent on them. No need to error the other replies below. Just bail out here. The _q_disconnected will handle the possibly pipelined replies." _q_disconnected, indeed, takes care about pipelined replies ... calling 'ensureConnected' even if we have 0 replies in pipeline, which makes zero sense to me and results in QNAM endlessly trying to re-connect to the server. Fixes: QTBUG-77852 Change-Id: I6dcb43b36a6d432bc940246a08f65e1ee903fd24 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io> Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
* | Windows QPA: Update theme fonts when the primary screen changesFriedemann Kleint2019-09-022-1/+8
| | | | | | | | | | | | | | | | | | | | Call into the theme to update the fonts on a change. This at least helps in the case of disabled High DPI scaling. Task-number: QTBUG-77144 Change-Id: I2c8fd85259403eaaeea56cd096f99116fc6bba9a Reviewed-by: André de la Rocha <andre.rocha@qt.io> Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* | Doc: Clarify QJsonDocument::toJson()Joerg Bornemann2019-08-301-1/+1
| | | | | | | | | | | | | | | | Mention that this method returns an indented document. Change-Id: I0cadcc1c894c9a87910cfce389c6a5288238044d Reviewed-by: Christian Kandeler <christian.kandeler@qt.io> Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
* | Remove hardcoded qt_instdate field from binaryFredrik Orderud2019-08-301-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | Move hardcoded date to the only client code in the repo. This field is currently modified by MaintenanceTool and possibly windeployqt, which contributes to breaking the DLL signature on Windows. Removing the field should avoid this problem. Task-number: QTBUG-76985 Change-Id: I01386136ac493ea50c99c05879a3e215f3f6344c Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | Fix invalid end range appended to HTTP requestRainer Keller2019-08-281-1/+2
| | | | | | | | | | | | | | | | | | | | | | When the end range of a byte range in a HTTP request is skipped the download manager adds 0 it its place when resuming that download. When there is no end range given the value is skipped. Task-number: QTBUG-77867 Change-Id: I52358c94cf56c88217fcc91abb102ed393ac7242 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
* | Add Third-Party code in qregion.cpp to qt_attribution.json fileKai Koehne2019-08-283-54/+58
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This makes it visible also in the overview documentation of the module, and can be used to automatically generate attribution documents. The code actually mentions the names and file versions (CVS?) where things got copied from; however, X11 seems to have stopped using CVS a long time ago, and without a server it's hard to determine the exact X11 version that was copied from. It arguably doesn't matter, anyhow, because we won't update the code anymore. Fixes: QTBUG-70556 Change-Id: Ib17117a1a3c4112b81982afbd51273048a43221a Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* | Fix assertion on passing nullptr QLatin1Strings to qt_compare_stringsMarc Mutz2019-08-251-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | qstrnicmp() has an assertion that the lhs string is not nullptr. Fix by moving the length check back to the front, regardless of cs's value. Amends cad7100fda1b27ba56c4d9efc6bceba62859dfbc. Change-Id: I31f808936c8dc6fbb10a70a59923746ef3e675e9 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | Don't defer platform backingstore creation if we already have a platform windowTor Arne Vestbø2019-08-241-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | The creation was made lazy in 18f415e46d592f, for those platforms (macOS) that need a platform window to successfully create a platform backingstore. But we don't need to delay creation if we actually have a platform window at the time of constructing the QBackingStore. Change-Id: I6367736ddca82900dec2751a85a8bc35cc742bb5 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
* | macOS: Choose appropriate NSWindow depth based on surface formatTor Arne Vestbø2019-08-242-15/+31
| | | | | | | | | | | | Change-Id: I67e63412096ca11a8f056f5755525311756906ef Reviewed-by: Andy Nichols <andy.nichols@qt.io> Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
* | Use qsizetype for qt_memfill functionsThiago Macieira2019-08-248-29/+32
| | | | | | | | | | | | | | | | | | Just in case the image is larger than 2 GB (512 megapixels). Change-Id: I343f2beed55440a7ac0bfffd15636cbc68dfa13d Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> (cherry picked from commit 1e2bf51d3e5d891db3c1383e6567d1c77dfc8973) Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | QGuiApplication: drop mutex before emitting fontChanged()Marc Mutz2019-08-231-2/+5
|/ | | | | | | | | | | | | | Emitting a signal executes an unknowable amount of code. We shouldn't hold a mutex while doing so. E.g., if the signal emission causes another call to QGuiApplication::setFont(), the old code would deadlock, since applicationFontMutex is not recursive. Fix by taking a copy of the application font under mutex protection, then dropping the lock for the emission of the signal. Change-Id: Ib2569b3a08af6ef5f38459a19f74cb0db27b7772 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Fix build with -no-feature-printer on macOSAndré Klitzing2019-08-223-17/+24
| | | | | | Fixes: QTBUG-62675 Change-Id: I3bfcd6d78c3124769ff8662941472333c795fdbe Reviewed-by: Jörg Bornemann <joerg.bornemann@qt.io>