summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* qdoc: Highlight selected section / entry in the documentationTopi Reinio2014-09-053-36/+86
| | | | | | | | | | | | | | | | This commit adds id tags with the anchor reference as the value to html entities for documentation section titles and function signatures, properties etc. for both C++ and QML documentation pages. Together with new CSS rules, we can dynamically highlight the title that the user clicked on. This helps to locate the item of interest on a crowded page or when the page cannot be scrolled down enough to place the selected item on top. Change-Id: I7d1db2ed4e12779e1a9e571996ee65c3befa4e7a Reviewed-by: Martin Smith <martin.smith@digia.com> Reviewed-by: Venugopal Shivashankar <venugopal.shivashankar@digia.com>
* Avoid deadlock when suspending devicePaul Olav Tvete2014-09-051-2/+8
| | | | | | | | | | | | | Don't wait for the GUI thread when it's already waiting for us. An application that uses the virtual keyboard may get an inputmethod query just when it is being suspended. If the GUI thread is already blocking on a semaphore at that point, waiting for the android thread, we really do not want to wait for the GUI thread... Task-number: QTBUG-40955 Change-Id: Iea2cf0dd058a41a897d596c4bcf16f0508adb20b Reviewed-by: Christian Stromme <christian.stromme@digia.com>
* Android: don't recreate surface on shutdownPaul Olav Tvete2014-09-052-0/+5
| | | | | | | | | When we suspend the app, we destroy the surface to save resources. We don't want to create it again just as we are shutting down. Task-number: QTBUG-41072 Change-Id: I7a616249bee869b92716d0911201a80d73c2f8da Reviewed-by: Christian Stromme <christian.stromme@digia.com>
* GraphicsView: Fix resolvePalette() for QGraphicsItem's childrenMaks Naumov2014-09-053-3/+20
| | | | | | | Use a proper function for that. Change-Id: I166ce44b8987d522cb01bae57009b2b862851b92 Reviewed-by: Andreas Aardal Hanssen <andreas@hanssen.name>
* ssl: make peerVerifyError test agnostic of error orderJeremy Lainé2014-09-051-2/+15
| | | | | | | | | | | | Currently the peerVerifyError test for QSslSocket makes an assumption about the order in which SSL errors are emitted by peerVerifyError. This assumption does not necessarily hold for non-OpenSSL backends. This change fixes this assumption, and also checks that HostNameMismatch was found both in the errors emitted by peerVerifyError and by sslErrors. Change-Id: I856d1ea43b36332db0f178d35fc14a4bb18ad673 Reviewed-by: Richard J. Moore <rich@kde.org>
* ssl: enable non-OpenSSL backends to compile QSslSocket testsJeremy Lainé2014-09-051-0/+8
| | | | | | | | Some of the QSslSocket tests use OpenSSL-specific symbols. This change fixes this issue. Change-Id: Ib67efa42a15facaf0ad34fc0466341a37d945d1e Reviewed-by: Andrew Knight <andrew.knight@digia.com>
* Windows styles: Scale hardcoded-values according to DPI.Friedemann Kleint2014-09-056-72/+85
| | | | | | | | | Factor out functions to return the fixed values and scale those. Task-number: QTBUG-38993 Task-number: QTBUG-38858 Change-Id: I59c70a206eae76bf08bc2aeb5cda5a740cd3d6dc Reviewed-by: Alessandro Portale <alessandro.portale@digia.com>
* Windows styles: Add device pixel scaling for system metrics.Friedemann Kleint2014-09-055-297/+291
| | | | | | | | | | | | Metrics obtained from the system must be scaled down when device pixel ration scaling is in effect. Factor out functions to return the device pixel values which might still be used for drawing. Task-number: QTBUG-38993 Task-number: QTBUG-38858 Change-Id: I6b90629e4979436bbb46f8c1fa1ee2253ada7ece Reviewed-by: Alessandro Portale <alessandro.portale@digia.com>
* windows: Enable ANGLE D3D11 renderer by defaultAndrew Knight2014-09-053-14/+6
| | | | | | | | | | | | | | | | | | | | | | | Also, remove the -angle-d3d11 configure option, as it no longer is necessary to select the renderer at build time. The D3D11 renderer is the default renderer in upstream ANGLE, and has been shown to be a more reliable solution for developers running over remote desktop and inside virtual machines. It also provides more features to the OpenGL ES implementation. This configuration switch does not disable the D3D9 render; if the GPU does not support D3D11, D3D9 is used instead. [ChangeLog][QtGui][Windows] The ANGLE D3D11 renderer was enabled by default. Systems which cannot use the new renderer will automatically fall back to the D3D9 renderer at runtime. Task-number: QTBUG-41031 Change-Id: If894309c07d9309c236b63c36f37679f74375133 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com> Reviewed-by: Tim Jenssen <tim.jenssen@digia.com>
* Doc: QRect::isEmpty's documentation didn't match the code.David Faure2014-09-051-1/+1
| | | | | | | | | The code says bool QRect::isValid() const { return x1 <= x2 && y1 <= y2; } so the documentation should say <= as well, rather than <. Change-Id: If52005879d2a758b5d1d64b552e6cd96341fae76 Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* QCommonStyle: replace a QPolygon with a QPoint[] (IV)Marc Mutz2014-09-041-10/+22
| | | | | | | | | | | | | | | No need to allocate dynamic memory for a fixed-size point array when QPainter has a (QPoint*,int) overload. This one is a bit more complicated, as the QPolygon was returned from a helper function, so I wrapped the array in a minimal std::array-like StaticPolygonF. Together, these four QPolygon -> QPoint[] changes result in ca. 4.5K text size reduction for libQtWidgets. Change-Id: I082f199d5edb7a7782173fe3748220f373edac8a Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
* QCommonStyle: replace a QPolygon with a QPoint[] (III)Marc Mutz2014-09-041-20/+23
| | | | | | | | No need to allocate dynamic memory for a fixed-size point array when QPainter has a (QPoint*,int) overload. Change-Id: Ie1eecd376a52b73572998ba253a032deaa0daaf9 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* QCommonStyle: replace a QPolygon with a QPoint[] (II)Marc Mutz2014-09-041-6/+7
| | | | | | | | No need to allocate dynamic memory for a fixed-size point array when QPainter has a (QPoint*,int) overload. Change-Id: Ifdf8224ddffe06ef7848562023e372e2c32b9ad6 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* QCommonStyle: replace a QPolygon with a QPoint[] (I)Marc Mutz2014-09-041-10/+12
| | | | | | | | No need to allocate dynamic memory for a fixed-size point array when QPainter has a (QPoint*,int) overload. Change-Id: I50c69103bba47e9f6de4f5616e8f40fee522ddc2 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Fix endianness part of QSysInfo::buildAbi() stringAlex Trotsenko2014-09-042-3/+16
| | | | | | | | | | | Both Q_LITTLE_ENDIAN and Q_BIG_ENDIAN macros are always defined on all architectures. So, byte order detection results in "little_endian" value for big endian systems. Test the system endianness in a right way, according to Q_BYTE_ORDER macro documentation. Change-Id: I5523f90567e78d679a3ff2902a8f5377ed39ceb1 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* iOS: Update QIOSScreen::nativeOrientation() for iOS8Tor Arne Vestbø2014-09-041-2/+9
| | | | | | | | For iOS8 and up [UIScreen bounds] changes based on the interface orientation, so we need to use [UIScreen nativeBounds] instead. Change-Id: I3fc12cfa417df26ca94c803e970bc2dc18a94378 Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
* Add KMS hooks for EGLFS pluginLouai Al-Khanji2014-09-042-0/+427
| | | | | Change-Id: Ic703334e52726cdd815cccf152d9d01aa63c803c Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* ANGLE: Fix compilation with MinGW + D3D11Andrew Knight2014-09-048-6/+227
| | | | | | | | Provide workarounds for things GCC doesn't like, and define a number of macros not found in the MinGW headers. Change-Id: I254c208209c0071fae5efb6727f2b3cfd5542da6 Reviewed-by: Kai Koehne <kai.koehne@digia.com>
* Improve accelerator stripping in accessible widgetsFrederik Gladhorn2014-09-043-7/+14
| | | | | | | | | | | When we strip the & we should also report the hotkey. In addition only strip labels when they are buddys and try not to remove ampersands from all kinds of random text. This fixes https://bugs.kde.org/show_bug.cgi?id=338282 Change-Id: I401281cd9ff43b23a3923ad9909ca9c469b59506 Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
* Accessibility: Improve line boundary helper functionsFrederik Gladhorn2014-09-045-56/+357
| | | | | | | | | These functions are supposed to make it easy for third parties (and QLineEdit) to implement the textAt/Before/AfterOffset functions. Before the functions were ignoring newlines completely and thus only somewhat useful. Change-Id: I7136b9502a7fa6f8ad9ad7236761a34c1a7fd4da Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
* hellowindow: Set all the state for each frameLaszlo Agocs2014-09-041-12/+15
| | | | | | | | | | | Trying to be smart and minimizing the amount of GL calls per frame to provide a good example was a mistake (in a way): There are components, like the eglfs mouse cursor, that change the context state. To make sure the example work in these cases, set the state upon each frame. Change-Id: Ief1fd7bbb0fb1955a64dac97a071b7a3d9d506d4 Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
* Respect android:windowSoftInputMode in manifest.Samuel Nevala2014-09-041-3/+13
| | | | | | | | | | | Read and store softInputMode set at AndroidManifest.xml on QtActivityDelegate. When showSoftwareKeyboard is requested setSoftInputMode for main window if softInputMode is not defined fall back to old behavior. Change-Id: I71cb27d4bdb4ae4e3c2a0706560173703a2f5a50 Task-number: QTBUG-34401 Reviewed-by: BogDan Vatra <bogdan@kde.org> Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
* QMdiSubWindow: Keep event filter on system menu over its lifetime.Friedemann Kleint2014-09-041-2/+1
| | | | | | | | | | | QMdiSubWindow::eventFilter() is supposed to close the sub window on a double click on the menu icon. However, it did not receive the double click event since it removed itself when the menu was hidden, which happened before the double click was delivered. Task-number: QTBUG-25179 Change-Id: I5e7fb02dda26ceab12e8b7554fc604066a0a3136 Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* windows: Fix dynamic opengl buildLaszlo Agocs2014-09-032-6/+6
| | | | | | | Cannot call WGL or EGL functions directly anymore. Change-Id: I0d5c6217679d87a2092c945a9b841dfd7b6c299a Reviewed-by: Andrew Knight <andrew.knight@digia.com>
* Enable QT_ANGLE_PLATFORM selection in dynamic buildsLaszlo Agocs2014-09-031-1/+1
| | | | | Change-Id: I8ebe62ec1e024e8a0a0f9e8aeac6fb81b1095e72 Reviewed-by: Andrew Knight <andrew.knight@digia.com>
* direct2d: Work around ClearType rendering bug in translucent modeAndrew Knight2014-09-037-15/+36
| | | | | | | | | | | | This switches the font rendering to use gray scale antialiasing when in translucent rendering mode. It does so by adding a flags argument to the paint engine, allowing for future expansion in communicating render hints from the device to the engine. Task-number: QTBUG-41002 Change-Id: I0265154716a12060e851b603a109e9c693f5e843 Reviewed-by: Louai Al-Khanji <louai.al-khanji@digia.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* ssl: add support for ASN.1 boolean valuesJeremy Lainé2014-09-033-0/+95
| | | | | | | | | This adds support for reading and writing ASN.1 boolean values. It also adds an operator to test two ASN.1 elements for equality. Change-Id: I4a22cbf9808533d593fc59d27b63caaf650b1f57 Reviewed-by: Richard J. Moore <rich@kde.org>
* DirectFB: Add QT_DIRECTFB_BLITTER_DEBUGPAINT environment variableAndy Nichols2014-09-032-7/+67
| | | | | | | | | | This environment variable will paint an overlay on each paint command that is using the accelerated blitter path for DirectFB. This is useful when you want to assure that you are taking advantage of the DirectFB blitter. Change-Id: I6e374754825794daf9c1bf40bee2b963e752a8e9 Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* Speed up the removal of items from a QGraphicsSceneDimitar Asenov2014-09-031-3/+22
| | | | | | | | | | | | | | | | | | | | | | | When using a linear index, all items in a scene are stored in a QList. While adding new items is a constant operation, removal requires a traversal through the entire list. This is especially problematic when the scene contains millions of items and many of them are removed, which requires a linear search for each item, resulting in a very slow operation. Moreover, this behavior is actually inconsistent with the current documentation which states for the linear index: "Adding, moving and removing items, however, is done in constant time." With this change, the list is sorted once an item needs to be removed. The item to be removed is then found using binary search. To reduce the overhead of sorting the list is not sorted from scratch. First the newly inserted items are sorted and then the two parts of the list are merged. [ChangeLog][QtWidgets][QGraphicsScene] Speed up the removal of items when using the linear index. Change-Id: I28708622605d7fb0fac656df1f9b2f2fa3136759 Reviewed-by: Andreas Aardal Hanssen <andreas@hanssen.name>
* eglfs: Fix regression in config selectionLaszlo Agocs2014-09-031-5/+4
| | | | | | | | | | During the introduction of context adoption support the config choosing got broken for context creation, at least for hooks that return a customized format in surfaceFormatFor(). The returned format is the one that needs to be passed to chooseConfig(), not the original. Change-Id: Iae203cbbf7b39c462386611dd3744f048116df13 Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
* Revert "Speed up the removal of items from a QGraphicsScene"Dimitar Asenov2014-09-032-39/+7
| | | | | | | | | | | | | | | | | | This reverts commit bf2ec0183cb62034f2a4e700b7ab741371fcb106. That patch changed the way the linear index works in QGraphicsScene in order to speed up item removal. That patch occasionally rebuilt the index by recursively exploring all items in the scene, starting with the top level. Further testing revealved that in some circumstances, rebuilding the index in this way can be slow, thereby significantly slowing down the index compared to the unpatched version. The original patch only exists in the qt 5.4 branch and has not been released. Change-Id: I081dbcdcc86196ef382466c3e800a33eab9a5b79 Reviewed-by: Andreas Aardal Hanssen <andreas@hanssen.name>
* ssl: check critical certificate extensionsJeremy Lainé2014-09-031-0/+47
| | | | | | | | This adds a test for a QSslCertificate containing extensions which are marked as critical. Change-Id: I314e1f5c9943bcad5d43129a97f9f834882dc6fb Reviewed-by: Richard J. Moore <rich@kde.org>
* Android: Avoid deadlocks on suspendPaul Olav Tvete2014-09-032-9/+14
| | | | | | | | | | | | Get rid of the rendezvous at shutdown: the android thread does not need to wait for the GUI thread. Since the GUI thread frequently does blocking calls to the android thread, this fixes several known and potential deadlocks. Task-number: QTBUG-41072 Change-Id: Ia6fa8da026b1727e7352b22f4df4d72b63b8c847 Reviewed-by: BogDan Vatra <bogdan@kde.org> Reviewed-by: Christian Stromme <christian.stromme@digia.com>
* ssl: tighten QSslCertificateExtension testsJeremy Lainé2014-09-031-0/+13
| | | | | | | | | This tightens tests performed on a certificate's extensions by checking isCritical() and isSupported() for all extensions. It also explicitly checks the keys when value() returns a QVariantMap. Change-Id: If51c55be25bbcd09cc3a6712ddfea2bf9a01360f Reviewed-by: Richard J. Moore <rich@kde.org>
* Change a qFatal to a qWarningLars Knoll2014-09-031-1/+2
| | | | | | | | | | | There are valid uses cases how to use Qt without installing any fonts (e.g. by using an application font), so let's make the warning non fatal. Task-number: QTBUG-29192 Change-Id: I5684331b687bef4b8a54be1f68303c80aa8d4372 Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com> Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
* Widgets: remove pointless assignmentsMaks Naumov2014-09-033-8/+4
| | | | | | | | | Assignment of a value was two times successively for same variable while the variable itself is not used between these assignments. Change-Id: I3c457e3af0505d32a64f6c8576b458cd15a951e5 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* Use QPlatformTheme::SystemIconFallbackThemeName in static QString ↵Albert Astals Cid2014-09-031-1/+1
| | | | | | | | | fallbackTheme() Instead of QPlatformTheme::SystemIconThemeName Change-Id: Id318944730cd1b8014380a972eb28fd8aab1f382 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* QSwipeGestureRecognizer: Use qAbs() to check distances.Friedemann Kleint2014-09-031-1/+1
| | | | | | Task-number: QTBUG-15768 Change-Id: Idc6c6687430365a015fb2c15f4e4dcae6a687f9f Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* Make QElapsedTimer default to invalid (and now non-POD).Robin Burchell2014-09-034-10/+24
| | | | | | | | | | | The practical uses of a POD QElapsedTimer are not really that clear, and the number of misuses of this API are quite high. Default the state to invalid to prevent against mistakes. [ChangeLog][QtCore][QElapsedTimer] Is no longer a POD. Change-Id: I267292acf2bfca7404e3e449dd04410441d7ce26 Reviewed-by: Lars Knoll <lars.knoll@digia.com>
* WinRT: Fixed initialization of udp socketOliver Wolff2014-09-031-1/+1
| | | | | | | udpSocket() can only be called after the socket descriptor is set. Change-Id: If651ff58507cd66c98de4b699a80149913d9ffcf Reviewed-by: Andrew Knight <andrew.knight@digia.com>
* Doc: Do not include the external sites by defaultTopi Reinio2014-09-032-2/+3
| | | | | | | | | | | | | | | Move the line that adds the external page definions into its own separate include file. This prevents the files from being included in every Qt documentation module by default, needlessly duplicating the information. Currently only the QtDoc module (and modules that depend on QtDoc) need it. Task-number: QTBUG-41003 Change-Id: Ie2ddd3a645ea731787daacfffb3068cb36c79c9a Reviewed-by: Martin Smith <martin.smith@digia.com> Reviewed-by: Venugopal Shivashankar <venugopal.shivashankar@digia.com>
* WinRT: Fixed construction of QNativeSocketEngine without parentOliver Wolff2014-09-031-4/+3
| | | | | Change-Id: If55a8049224a7dceca33a3cf3089d541a3a97b8e Reviewed-by: Andrew Knight <andrew.knight@digia.com>
* ssl: common key parser support for encrypted keysJeremy Lainé2014-09-028-24/+367
| | | | | | | | | | | | | | This adds the infrastructure for reading and writing encrypted private keys when using non-OpenSSL backends. Each platform must provide its cryptographic encrypt / decrypt functions. As WinRT already uses the common parser, this commit includes an implementation for that platform. Done-with: Andrew Knight <andrew.knight@digia.com> Task-number: QTBUG-40688 Change-Id: I0d153425ce63601ff03b784a111e13962061025f Reviewed-by: Richard J. Moore <rich@kde.org>
* Fix drawing of QLineEdit's actions when Qt::AA_UseHighDpiPixmaps is set.Friedemann Kleint2014-09-021-1/+1
| | | | | | | Task-number: QTBUG-40525 Change-Id: Iff3c1e16d9c44e1d36b8f83ca96b48bff05ab1f0 Reviewed-by: Marc Mutz <marc.mutz@kdab.com> Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
* Android: Guard against invalid surfaceIDPaul Olav Tvete2014-09-022-1/+10
| | | | | | | | | | | | | | | | Do not try to resize or destroy invalid surfaces. This caused update problems with all GL apps after suspend, since we would forget the dummy view that we always keep around so we get proper transitions on shutdown. Also make sure that we don't mess this up even if we try to destroy a non-existing surface. This would have fixed the bug by itself, but then we would still be stuck with the annoying warning message. Task-number: QTBUG-41093 Change-Id: I83299e93eb9ac5357b98ca47014789b56c91b35a Reviewed-by: Christian Stromme <christian.stromme@digia.com>
* windows: Allow selection of ANGLE's rendererAndrew Knight2014-09-022-1/+31
| | | | | | | | | | | | The default behavior of ANGLE is to use D3D11 before falling back to D3D9. This change improves flexibility the platform plugin to explicitly create a D3D11, D3D9, or D3D11 software (WARP) context by setting the QT_ANGLE_PLATFORM to "d3d11", "d3d9", or "warp", respectively. Task-number: QTBUG-41031 Change-Id: Ie1d399c1cb0e360e5b3a6d9f2a4b28745d86cc71 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
* Remove vestiges of d3dcompiler_qtAndrew Knight2014-09-022-4/+0
| | | | | Change-Id: I2a233cb0bfec27a7535a31818568955f8bf85c15 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* QImage: add a qMove()Marc Mutz2014-09-022-2/+2
| | | | | | | | | | | | | | | | | | | | | | | The color table is passed by value (good for C++11), so when the argument is assigned to the member variable, that's a good spot for a move assignment. However, the argument is also declared const. The standard says that top-level const is ignored, but some compilers (I know about SunCC) think differently, so we cannot remove it. Instead, we do a const_cast. It is well-defined: Even though apparently the argument was declared as const, the standard says the const is not there, and no sane compiler would put the argument copy into read-only memory. Add a reminder to remove the top-level const from the signature come Qt 6. Change-Id: Iac18846ba669de0a30da620685ad1438c267e193 Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* QOpenGL2GradientCache::getBuffer: calculate hash value outside critical sectionMarc Mutz2014-09-021-1/+1
| | | | | | | | | | | | The code doesn't touch any member variables, so it doesn't need mutex protection. Reducing the time spent under the mutex allows a higher speedup (Amdahl's Law), so do it. Also made the mutex locker const to indicate it is never unlock()ed again. Change-Id: Ic50b827c0e34d39cbddc7ec83675b568a9c33f6d Reviewed-by: Allan Sandfeld Jensen <allan.jensen@digia.com>
* Fix bash syntax error in configureAdam Strzelecki2014-09-021-1/+1
| | | | | | | Fixes missing space before `]` in test condition introduced in 8d5772533887266d. Change-Id: I741c291677f32056a0a0bec12cb4d9fd293a2021 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>