summaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* Reapply 0d9208cecbbd9ed08e4ffb6540729668e3bd7754 on 5.11v5.11.0-alpha1Liang Qi2018-02-142-7165/+3
| | | | | | | | | | | | This change amends 305dd1b61f657474d751cc3b24f58249ec21b61b, which lost 0d9208ce and brought src/plugins/styles/mac/qmacstyle_mac.mm back. In 4f3249f32dbe5c20aabbfd9b4f9c558aaf449e48, it was moved to src/plugins/styles/mac in 5.10. Task-number: QTBUG-65773 Change-Id: I721268caf12067ed798f5846234cd2fdf3e493dc Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io> Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* QStyleHelper: Remove unused function setWidgetSizePolicy()Gabriel de Dietrich2018-02-142-9/+0
| | | | | | | | This used to be public back when QMacStyle had public API. Long replaced by the WA_Mac*Size attributes. Change-Id: Ifd948e648ec90ff29b6b3652bc9d5cb1dc9c6a09 Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Fix compiling qfloat16_f16c.c with C89 compilerAllan Sandfeld Jensen2018-02-141-2/+4
| | | | | | | Needed by gcc 4.8 Change-Id: I2daa5728761599255cf3912d37e7b9dd60ccb60c Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
* Merge "Merge remote-tracking branch 'origin/5.9' into 5.11" into ↵Liang Qi2018-02-1493-978/+11054
|\ | | | | | | refs/staging/5.11
| * Merge remote-tracking branch 'origin/5.9' into 5.11Liang Qi2018-02-1493-978/+11054
| |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: .qmake.conf src/corelib/animation/qvariantanimation.cpp src/corelib/global/qglobal.cpp src/corelib/global/qlogging.cpp src/corelib/io/qprocess_win.cpp src/corelib/json/qjsonarray.cpp src/corelib/tools/qsimd_p.h src/corelib/tools/qtimezoneprivate_p.h src/corelib/xml/qxmlstream_p.h src/gui/kernel/qsimpledrag.cpp src/gui/kernel/qsimpledrag_p.h src/plugins/generic/generic.pro src/plugins/platforms/cocoa/qcocoamenu.mm src/widgets/styles/qmacstyle_mac.mm tests/auto/concurrent/qtconcurrentmap/BLACKLIST tests/auto/corelib/io/qfileinfo/tst_qfileinfo.cpp tests/auto/corelib/tools/qdatetime/tst_qdatetime.cpp tests/auto/gui/kernel/qwindow/BLACKLIST tests/auto/widgets/dialogs/qmessagebox/BLACKLIST Change-Id: I508d686cf20f7f8cc6a7119b9bc7c3bbb505c58e
| | * Fix GCC 8 warning in qvariantanimationVille Voutilainen2018-02-141-1/+1
| | | | | | | | | | | | | | | | | | | | | qtbase/src/corelib/animation/qvariantanimation.cpp:451:13: error: cast between incompatible function types from ‘QVariant (*)(const QRectF&, const QRectF&, qreal)’ {aka ‘QVariant (*)(const QRectF&, const QRectF&, double)’} to ‘QVariantAnimation::Interpolator’ {aka ‘QVariant (*)(const void*, const void*, double)’} [-Werror=cast-function-type] Change-Id: I5398316adaa0f12fbbdfdb200fd796de284821ef Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| | * Fix GCC 8 warning in qurlrecodeVille Voutilainen2018-02-141-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | qtbase/src/corelib/io/qurlrecode.cpp:514:86: error: ‘void* memcpy(void*, const void*, size_t)’ copying an object of non-trivial type ‘class QChar’ from an array of ‘const ushort’ {aka ‘const short unsigned int’} [-Werror=class-memaccess] memcpy(appendTo.begin() + origSize, begin, (end - begin) * sizeof(ushort)); Change-Id: Ide78a4144d6bc63342c3c4334cc97fe73c5167bd Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| | * Silence GCC 8 warnings in QStringVille Voutilainen2018-02-141-4/+4
| | | | | | | | | | | | | | | | | | | | | | | | qtbase/src/corelib/tools/qstring.cpp:3539:67: error: ‘void* memcpy(void*, const void*, size_t)’ copying an object of non-trivial type ‘class QChar’ from an array of ‘short unsigned int’ [-Werror=class-memaccess] memcpy(uc, d->data() + copystart, size * sizeof(QChar)); Change-Id: Ic601bed1a1f9e1b6f0ac1f9e58f1dcadb50ad724 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| | * Silence a GCC 8 warning in QIODeviceVille Voutilainen2018-02-141-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | qtbase/src/corelib/io/qiodevice.cpp:688:60: required from here ../../../include/QtCore/../../../../qtbase/src/corelib/tools/qvector.h:727:20: error: ‘void* memmove(void*, const void*, size_t)’ writing to an object of type ‘class QRingBuffer’ with no trivial copy-assignment; use copy-assignment or copy-initialization instead [-Werror=class-memaccess] memmove(i, b, (d->size - offset) * sizeof(T)); ~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ Change-Id: I9dc9a17c281b71bf2eb3e89116600ec3ba345d74 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
| | * Fix build failure when QtNetwork module is not buildPasi Petäjäjärvi2018-02-132-2/+2
| | | | | | | | | | | | | | | | | | | | | Affected plugins: tuiotouch, vnc Change-Id: Iabf72e3da0a25de0de2a861c69a29b3887ca81c3 Reviewed-by: Jesus Fernandez <Jesus.Fernandez@qt.io>
| | * Remove QLibrary code path specific to HP-UX on PA-RISCKonstantin Tokarev2018-02-121-33/+2
| | | | | | | | | | | | | | | | | | | | | | | | The only mkspecs that enabled QT_HPUX_LD were removed in ab44ac021de. Change-Id: I9f27f0b487b69c11d19ba76801e3926b7894e6e7 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
| | * Android: Don't rely on QDir::homePath() to get the application directoryChristian Strømme2018-02-121-2/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If the QLoggingRegistry gets called as part of the static initialization phase, it would call into Android's QStandarPaths implementation, which assumed that the HOME env. variable was already set. Since the variable isn't set before main is called, QDir::homePath() returns the root path, which would be cached and always returned. With this fix we now call Android's getFilesDir() directly, which will always return the right path. Since the font locations are also relying on an environment variable being set, we no longer cache that either. Task-number: QTBUG-65820 Change-Id: If45f3d5f0e87b808a62118ae95c31b492885646a Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io> (cherry picked from commit eadf9e542fcc42597bfe02df065fc4cefa94cd56)
| | * Make use of our egl convenience code for QNX QPAAdam Treat2018-02-089-295/+159
| | | | | | | | | | | | | | | | | | | | | | | | | | | This fixes various problems that occur because the current egl context assumes OpenGL ES 2.0 and does not support newer versions of ES. Task-number: QTBUG-64306 Change-Id: I81466ba5cf028b47ca5a2ebcdc702167aff655a2 Reviewed-by: James McDonnell <jmcdonnell@blackberry.com>
| | * Android: Defer initialization of logging rules until qApp constructionTor Arne Vestbø2018-02-072-0/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On Android, we load the application library, and its dependencies (Qt), on Android's main thread (thread 0), and then spin up a secondary thread (thread 1), that we call main() on. If any QObject is constructed during loading of the application library or any of Qt's libraries, via static initializers or constructor functions, we will set QCoreApplicationPrivate::theMainThread to thread 0, which will confuse Qt later on when it's being run on thread 1, and will result in a warning during QCoreApplication construction: QApplication was not created in the main() thread This situation can easily lead to a crash as well. Unfortunately logging via qDebug/qCDebug and friends will trigger this too, as they internally use QObject. Fixing the root cause of this is under investigation, but for now we will partially revert fa2a653b3b934783 for Android. The effect is that any qCDebug with a "qt.*" category before qApp construction will turn into a no-op, like it was before fa2a653b3b934783. This patch does not cover the case of a regular qDebug, or a qCDebug with a non-Qt category. Those will still produce the same symptom, as before fa2a653b3b934783. Task-number: QTBUG-65863 Change-Id: I95675731d233244530d0a2a1c82a9578d5599775 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io> Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> (cherry picked from commit 538b1b50764fb3a1898d425a7155319afbcf3b25)
| | * CoreText: Make sure to keep reference to data when cloning raw font engineTor Arne Vestbø2018-02-072-1/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QFontEngine::cloneWithSize() is used by QRawFont internally when switching a raw-font from one size to another using setPixelSize. For CoreText, we use a subclass of QCoreTextFontEngine to keep track of the QByteArray data of a raw-font, but failed to overload cloneWithSize, so we would lose the data whenever setPixelSize was called, resulting in missing text rendering in QtWebKit. We now retain the data as we should. Task-number: QTBUG-65923 Change-Id: I7d4186a3c32a61d48d1e9388e43f2792e8e46081 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
| | * GTK: fix menu positioning on high-DPIJ-P Nurmi2018-02-071-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The target position is passed in physical native pixels, so call QPlatformWindow::mapToGlobal() instead of QWindow::mapToGlobal(). The latter operates on logical pixels. Task-number: QTBUG-55251 Change-Id: I789128a0a345d4113fced82ed1b215fe14044634 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
| | * ANGLE: Remove workaround for files having the same name (Debug.h/.cpp)Oliver Wolff2018-02-063-432/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With object_parallel_to_source the workaround of making copies of the files and using these is no longer needed. Debug2.h and .cpp were added to the repository by mistake and should not have been there in the first place. Task-number: QTBUG-66059 Change-Id: Ib9dbd15be1dee1cb5190762fe06bad56dd40dd47 Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
| | * QComboBoxPrivate::showNativePopup(): Scale target rectangleJ-P Nurmi2018-02-051-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | The QPlatform* classes operate in native pixels. Task-number: QTBUG-55251 Change-Id: I80490fa802fbc77a1e02c176528cc047630f9a7d Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
| | * macOS: fix menu positioning on high-DPIJ-P Nurmi2018-02-051-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The target position is passed in physical native pixels, so call QPlatformScreen::availableGeometry() and QPlatformWindow::mapToGlobal() instead of QScreen::availableSize() and QWindow::mapToGlobal(). The latter two operate on logical pixels. Task-number: QTBUG-55251 Change-Id: I281f47baee727bc0f4738fd6d6cdf12c9f462b0f Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
| | * Fix QXcbWindow::mapFrom/ToGlobal()J-P Nurmi2018-02-051-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Call the base class implementations to avoid returning an unmapped values for non-embedded windows. Task-number: QTBUG-55251 Change-Id: Ib05fd530498dd4d72d3d4ef37caf4e2f0ebcd2e4 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
| | * QGtk3Menu::showPopup(): fix off by one error in the y-coordinateJ-P Nurmi2018-02-051-1/+2
| | | | | | | | | | | | | | | | | | | | | QRect::bottom() != QRect::y() + QRect::height() Change-Id: I83ae19ab588fb9651354999679f5d3c9e294a97e Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
| | * Suppress GCC 8 warning about realloc() non-trivially-copyable typesThiago Macieira2018-02-041-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | But they are movable. qxmlstream_p.h:654:32: error: ‘void* realloc(void*, size_t)’ moving an object of non-trivially copyable type ‘struct QXmlStreamPrivateTagStack::Tag’; use ‘new’ and ‘delete’ instead [-Werror=class-memaccess] Change-Id: I41d006aac5bc48529845fffd150e8115eb852034 Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| | * Silence GCC 8 warning on memcpy of movable typesThiago Macieira2018-02-042-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is similar to commit 342bb5b03a76d1428fafb8e1532d66e172bd1c0b. From GCC 8: qarraydataops.h:84:17: error: ‘void* memcpy(void*, const void*, size_t)’ writing to an object of type ‘class QStringRef’ with no trivial copy-assignment; use copy-assignment or copy-initialization instead [-Werror=class-memaccess] [etc.] Change-Id: I41d006aac5bc48529845fffd150e817e64973bec Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| | * Silence GCC 8 warning on memcpy of class Value to to class offsetThiago Macieira2018-02-041-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | From GCC 8: error: ‘void* memcpy(void*, const void*, size_t)’ copying an object of type ‘QJsonPrivate::offset’ {aka ‘class QSpecialInteger<QLittleEndianStorageType<unsigned int> >’} with ‘private’ member ‘QSpecialInteger<QLittleEndianStorageType<unsigned int> >::val’ from an array of ‘const value_type’ {aka ‘const class QJsonPrivate::Value’}; use assignment or copy-initialization instead [-Werror=class-memaccess] Both types are standard layout and have the same initial sequence (one uint member), so this is a valid copy. The only difference between the two is that QSpecialInteger has a private member, whereas in the bitfield it's public. Change-Id: I41d006aac5bc48529845fffd150e80585fd24db7 Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| | * Fix some cases of scaled text disappearing with freetypeJoni Poikelin2018-02-022-4/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Commit a56ee60791538e5442b3d97b75270b25dc4986db changed type of advance to short, restoring this fixes at least some cases where glyphs were disappearing. Task-number: QTBUG-65838 Change-Id: I33b252d91fb7541eaea3275b1950a048941869a6 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
| | * Fix window activation in QWindowsWindow::setCustomMargins()Dominik Haumann2018-02-021-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, code paths that call QWindowsWindow:setCustomMargins() automatically also activate the window (=give the window focus). The reason for this is the call of SetWindowPos (Windows API) without the flag SWP_NOACTIVATE. From the Windows API documentation about SetWindowPos() about the flag SWP_NOACTIVATE: Does not activate the window. If this flag is not set, the window is activated and moved to the top of either the topmost or non-topmost group (depending on the setting of the hWndInsertAfter parameter). It seems the flag SWP_NOACTIVATE is accidentally missing in the call of SetWindowPos() in setCustomMargins(), especially since the flag is present in pretty much all other calls of SetWindowPos(). The obvious fix is to add the flag SWP_NOACTIVATE to the call of SetWindowPos() in setCustomMargins(). So far, this issue exists for a long time, an was possibly introduced with commit f5fd5346038, where setCustomMargins() was initially added. Change-Id: Id3f058f8762df17eb3f033ab0b3e1791283937fc Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
| | * Clean-up in QDateTime's parsing of ISODate{,WithMs}Edward Welbourne2018-02-011-7/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Actually check that there's a T where ISO 8601 wants it (instead of just skipping over whatever's there), with something after it; move some declarations later; add some comments; and use the QStringRef API more cleanly (so that it's easier to see what's going on). Simplify a loop condition to avoid the need for a post-loop fix-up. This incidentally prevents an assertion failure (which brought the mess to my attention) parsing a short string as an ISO date-time; if there's a T with nothing after it, we won't try to read at index -1 in the following text. (The actual fail seen had a Z where the T should have been, with nothing after it.) Add tests for invalid ISOdate cases that triggered the assertion. Task-number: QTBUG-66076 Change-Id: Ided9adf62a56d98f144bdf91b40f918e22bd82cd Reviewed-by: Israel Lins Albuquerque <israelins85@yahoo.com.br> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> (cherry picked from commit a9c111ed8c30a5a8fec3f02244f0d5a4bd08e931)
| | * Fix QFileDialog::defaultSuffix on macOSNathan Collins2018-02-011-4/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Don't prepend the default suffix to the NSSavePanel allowedFileTypes. "If no extension is given by the user, the first item in the allowedFileTypes array will be used as the extension for the save panel." The user expects to get the suffix displayed to them in the drop down filter, not the default suffix set by the developer. Apply the default suffix if neither the user or the NSSavePanel provide a suffix. Task-number: QTBUG-66066 Change-Id: I64093b9f3178bd2377a7b65d6f23aed6214a4119 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
| | * Fix native QFileDialog initial selection for remote URLsAlex Richardson2018-02-011-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When using QFileDialog::getOpenFileUrl() with dir set to e.g. "sftp://foo/bar.cpp" we call q->selectDirectoryUrl("sftp://foo") followed by q->selectFile("bar.cpp"). Inside QFileDialog::selectFile() we unconditionally convert "bar.cpp" to an absolute URL and then call d->selectFile_sys("$CWD/bar.cpp") This then calls platform integration that detects that an absolute URL is being passed to selectFile() and therefore overrides the initial directory. Initially reported as https://bugs.kde.org/show_bug.cgi?id=374913 This is a regression that appeared some time between Qt 5.7.0 and 5.7.1. I have not had time to bisect this but the only commit that may have change behavior in that time range appears to be 007f92c6eef6191c48da0c44916591d48813ae62. Change-Id: I6968abe9ed5c5b9de067c453a7e9d2c5cdb3a190 Reviewed-by: Christoph Resch Reviewed-by: David Faure <david.faure@kdab.com>
| | * QSimpleDrag: Fix mouse release coords for delayed event transmissionEike Hein2018-02-012-8/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On platforms such as XCB, the drag cursor pixmap is shown via a window (a QShapedPixmapWindow) under the cursor. The mouse button release event at the end of the drag is received in this QXcbWindow, but intercepted by an event filter that QSimpleDrag installs on the QApplication. It then resends it unmodified(!) after the drag has ended and the drag pixmap window destroyed, causing it to be delivered to the new top-level window. The local coordinates in the unmodified QMouseEvent are local to the drag pixmap window and don't match the window it is delayed-transmitted to. This ends up having fatal, user-visible effects particularly in Qt Quick: QQuickWindow synthesizes a hover event once per frame using the last received mouse coordinates, here: the release posted by QSimpleDrag. This is done to update the hover event state for items under the cursor when the mouse hasn't moved (e.g. QQuickMouseArea:: containsMouse). The bogus event coordinates in the release event then usually end up causing an item near the top-left of the QQuickWindow to assume it is hovered (because drag pixmap windows tend to be small), even when the mouse cursor is actually far away from it at the end of the drag. This shows up e.g. in the Plasma 5 desktop, where dragging an icon on the desktop will cause the icon at the top-left of the screen (if any) to switch to hovered state, as the release coordinates on the drag pixmap window (showing a dragged icon) fall into the geometry of the top-left icon. QSimpleDrag contains a topLevelAt() function to find the top-level window under the global cursor coordinates that is not the drag pixmap window. This is used by the drop event delivery code. This patch uses this function to find the relevant top-level window, then asks it to map the global cusor coordinates to its local coordinate system, then synthesizes a new QMouseEvent with local coordinates computed in this fashion. As a result the window now gets a release event with coordinates that make sense and are correct. Task-number: QTBUG-66103 Change-Id: I04ebe6ccd4a991fdd4b540ff0227973ea8896a9d Reviewed-by: Eike Hein <hein@kde.org> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| | * QHeaderView: properly restore section data after layoutChanged()Christian Ehrlicher2018-01-292-26/+73
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QHeaderView is doing a complete rebuild of the sections when the layout changed because everything could have happened. But since layoutChanged is also called during e.g. sorting, the old data must be restored when possible. Task-number: QTBUG-65478 Change-Id: I088d4d843cad362b97df6dc5e0dcb9819b13547f Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
| | * Don't update the position if the handle was not first pressedBogDan Vatra2018-01-271-0/+5
| | | | | | | | | | | | | | | Change-Id: If09a2ca954a3bfca00b5a0839fea2899e7576c1d Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
| | * Check selection handles positionBogDan Vatra2018-01-271-6/+42
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch fixes the strange behavior when selecting text. This patch (on a Left To Right text) makes sure that: - the left handle will select text only on the left & above of the right handle - the right handle will select text only on the right & below of the left handle For RTL is way more complicated: - the left handle is acuatually the right handle but on the left side and it acts as a right handle - the right handle is acuatually the left handle but on the right side and it acts as a left handle Change-Id: Ifca591398103199d5aef479f0a080161c9f44c0e Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
| | * Move selection handles 1mm downBogDan Vatra2018-01-271-10/+12
| | | | | | | | | | | | | | | | | | | | | | | | This way the user will not cover with his finger the text with the cursor/selection. Set the tolerance to 0.5mm which is less then the width of the thinnest letters (e.g. i, I, l) Change-Id: Ia5d50bd3f4fe79c89d01b3d7f5e5c22e94e8158b Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
| | * Do not allow empty selectionsBogDan Vatra2018-01-271-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | Allowing empty selections leads to strange behavior, it switches from selection handles to cursor handle. Change-Id: Ida69346e2a47b13c92cfd68a555d6b94422bb580 Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
| | * Android: Hide handler(s) if the cursor is not visible anymoreBogDan Vatra2018-01-271-0/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On Android if the edit control is bigger than the remaining screen we resize it, this caused the handler(s) to remain outside the control. A better fix will be to ensure that the cursor/selection remains visible when the control is resized but I don't know if this is the desired behavior on all platforms. Task-number: QTBUG-62994 Task-number: QTBUG-58700 Change-Id: If43eb7bc1ecde426697694a8f26118e95fccb80c Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
| | * Fix missing update of QTreeView on setTreePosition()Igor Mironchik2018-01-271-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There was missing update in setTreePosition() or better to say update was but in not that part of QTreeView that needed. Now QTreeView correctly updates and paints tree decoration in a new place on changing tree position. [ChangeLog][QtWidgets][QTreeView] Fixed missing update of QTreeView on changing tree position. Task-number: QTBUG-65980 Change-Id: Id79ab8fcb39d511245a551068640684dd2a10cb9 Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com>
| | * Remove traces of Growl in QSystemTrayIcon code and documentationKonstantin Tokarev2018-01-262-8/+1
| | | | | | | | | | | | | | | | | | | | | Growl support was removed in Qt 5.8. Change-Id: I00a36cd955194ca8ceee52841a89ca579da01284 Reviewed-by: Jake Petroules <jake.petroules@qt.io>
| | * Android: Fix compilation with warnings-are-errorsEskil Abrahamsen Blomfeldt2018-01-261-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | Variable was added in e2e874415e1f1c6a96915d9dc85dd31c61f73e24 but is not used anywhere. Change-Id: Iff1e7c20317bb489978eb77d24b8da12493d7e45 Reviewed-by: BogDan Vatra <bogdan@kdab.com>
| | * Do a static_cast in bit-blasts that are UBVille Voutilainen2018-01-254-11/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Without this, building Qt and Qt applications fails with GCC 8. The errors look like this: writing to an object of type ‘class QPointer<QQuickPointerHandler>’ with no trivial copy-assignment; use copy-assignment or copy-initialization instead [-Werror=class-memaccess] Task-number: QTBUG-65691 Change-Id: Ie5a30814125deca7a160b9a61f5aa3f944ee1ac9 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| | * Fix compilation with -no-feature-regularexpressionJoni Poikelin2018-01-251-4/+23
| | | | | | | | | | | | | | | Change-Id: I4d213a266034d388af723337deeeb4cdd1f5cbdb Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
| | * Cocoa: Explicitly hide popup windows when the application is hiddenAndy Shaw2018-01-251-0/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When the application is hidden then Qt will hide the popup windows associated with it when it has lost the activation for the application. However, when it gets to this point it believes the popup windows to be hidden already due to the fact that the application itself is hidden. As a result, when the application is restored it causes a problem with the still visible popup window as it is taking the input events without responding to them. Therefore we need to explicitly hide the windows right before the application is hidden to ensure that they are actually hidden correctly. Task-number: QTBUG-58727 Change-Id: I4be1e1c0b1388d0c9ec872e7732185670998b7af Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
| | * CoreText: Add Apple Symbols as a fallback to cover some symbolsAndy Shaw2018-01-241-18/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Since braille characters are not included in Apple Unicode MS, we extend the fallback to include Apple Symbols to cover those too. Task-number: QTBUG-63510 Change-Id: I3977f1f9b7370a9fe9cfde643c86518e006c050a Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
| | * Document licenses for all Qt modulesKai Koehne2018-01-246-9/+67
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Follow the example of the other modules and explicitly mention the valid licenses on each module landing page, optionally combining it with trademark information. Change-Id: I9f1fea0f002e0ab607da89a0cbfe7c53060582d7 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io> Reviewed-by: Topi Reiniö <topi.reinio@qt.io>
| | * Don't indefinitely wait for data if it was able to read some dataAndy Shaw2018-01-241-12/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Passing -1 to waitForReadyRead() may cause it to wait for some time but the data retrieved may be enough for processing. So if 0 is passed from read, indicating that there is potentially more to come, then it will do a waitForReadyRead() then for more data to come. Change-Id: I75f270d1f124ecc12b18512cc20fb11f7a88f02e Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| | * glx: Avoid losing the stereo flag in QSurfaceFormatLaszlo Agocs2018-01-231-0/+4
| | | | | | | | | | | | | | | | | | Task-number: QTBUG-59636 Change-Id: I38394009993e92ab9db853a1450687fc48e471f5 Reviewed-by: Andy Nichols <andy.nichols@qt.io>
| | * QStyleSheetsStyle: Avoid possible division by zeroGabriel de Dietrich2018-01-221-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I5a7588c07106227e2a8b5e1f180230ef5b0342d1 Task-number: QTBUG-65228 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
| | * QFusionStyle: Set alpha on color before creating penGabriel de Dietrich2018-01-221-5/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This affected PE_IndicatorCheckBox in some cases. Change-Id: I6f10dabd2ca4093f4c1bdaa2bd0ebf73c02e8d12 Task-number: QTBUG-65737 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Yulong Bai <yulong.bai@qt.io> Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
| | * Doc: make a note about use of QStringLiteral with non-ASCII charsThiago Macieira2018-01-221-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Both ICC and MSVC have bugs concatenating strings and that's despite the standard giving an example ([lex.string] table 9) that says that u"a" "b" is the same as u"ab" We can't change to preprocessor concatenation (u ## STR) because that fails when QStringLiteral is used with a macro instead of an actual string literal. Task-number: QTBUG-65479 Change-Id: I39332e0a867442d58082fffd1504a0a868c291ef Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| | * Support for Q_OS_ANDROID_EMBEDDED and android-embedded build flagsOtto Ryynänen2018-01-2020-39/+43
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The Embedded Android build (Boot to Qt Android injection) is defined by having both Q_OS_ANDROID and Q_OS_ANDROID_EMBEDDED flags defined, as well as having Qt config android-embedded. This commit enables the possibility to build embedded Android builds. (i.e. Qt build for Android baselayer only, without JNI) Change-Id: I8406e959fdf1c8d9efebbbe53f1a391fa25f336a Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io> Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>