summaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
* Doc: corrected qdoc list syntaxNico Vertriest2017-01-091-0/+2
| | | | | | | qundostack.cpp: Command '\li' outside of '\list' and '\table' Change-Id: Ic162e246c754e125f6ae82a2a66312e925b231c2 Reviewed-by: Martin Smith <martin.smith@qt.io>
* Doc: corrected qdoc syntax parameter descriptionNico Vertriest2017-01-091-1/+1
| | | | | | | qxcbwindowfunctions.qdoc: 109: warning - Unknown command '\role' [Maybe you meant '\row'?] Change-Id: I1f6f8e449921bd415432ebd06e6169b3d8757e22 Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
* Doc: removed reference to non-existing snippetNico Vertriest2017-01-091-3/+1
| | | | | | | | Command \snippet (//! [3])' failed at end of file ../widgets/widgets/charactermap/mainwindow.cpp Change-Id: Ib095053bd4ff3901d7a9cd91aae3d83ec5f60807 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Clarify StripTrailingSlash behaviorKavindra Palaraja2017-01-081-1/+1
| | | | | | | | | StripTrailingSlash removes trailing slashes from the path, but not the entire URL. Task-number: QTBUG-47607 Change-Id: Id62b971e563e290b7ca000576bcc328616a3f1a2 Reviewed-by: David Faure <david.faure@kdab.com>
* QStylesheetStyle: don't lose precision when drawing a progress barMarc Mutz2017-01-071-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | When qreal is float, it cannot represent all values an int can take, so we may lose precision in the expression qreal(a) / b as opposed to the double result double(a) / b For lack of trying, I do not know of a value where this would change the resulting 'fillWidth' value, but better be safe than sorry, and use double instead of qreal arithmetic. Also, when calculating fillRatio, we were converting values back and forth between qreal and double. Using double everywhere avoids that. Found while reviewing integer arithmetic in QProgressBar as part of the fix for QTBUG-57857. Change-Id: I054cb11d35e3ecf5bf79b5c8ee39029bd23bcf49 Reviewed-by: David Faure <david.faure@kdab.com>
* QFusionStyle: don't lose precision when drawing a progress barMarc Mutz2017-01-071-6/+8
| | | | | | | | | | | | | | | | | | | | | When qreal is float, it cannot represent all values an int can take, so we may lose precision in the expression qreal(value) - minimum as opposed to the exact result qint64(value) - minimum' For lack of trying, I do not know of a value where this would change the resulting 'progressBarWidth' value, but better be safe than sorry, and use the 64-bit integer expression instead of floating-point. Found while reviewing integer arithmetic in QProgressBar as part of the fix for QTBUG-57857. Change-Id: I0240c143bb75af6986910489b34042ce9b3a8caa Reviewed-by: David Faure <david.faure@kdab.com>
* Remove strange, incoherent sentences in QColor docsKavindra Palaraja2017-01-071-6/+2
| | | | | | | | | | There were some strange sentences that did not add to the documentation of HSL vs. HSV. Task-number: QTBUG-52483 Change-Id: I5f2b8c3bd420fe9cabc74a94af4b78945723b6cf Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
* QPixmapStyle: do not assume minimum == 0 when painting progress barsMarc Mutz2017-01-071-4/+7
| | | | | | | | | | | | | | | | The arithmetic used to calculate the size of the progress bar fill in QPixmapStyle assumed minimum == 0, but that does not necessarily hold, since the minimum value is user-defined. So, fix the arithmetic to take the minimum into account, taking care, as done elsewhere, to avoid signed integer and qreal=float overflows, by using qint64 and double, respectively. [ChangeLog][QtWidgets][QPixmapStyle] Now handles progress bars with minimum != 0 correctly. Change-Id: I738ded56e8234716c36a5e9fde15bae691c43a35 Reviewed-by: David Faure <david.faure@kdab.com>
* QProgressBar: don't lose precision in text()Marc Mutz2017-01-071-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | When qreal is float, it cannot represent all values an int can take, so we may lose precision in the expression qreal(d->value) - d->minimum as opposed to the exact result qint64(d->value) - d->minimum' For lack of trying, I do not know of a value where this would change the resulting 'progress' value, but better be safe than sorry, and use the 64-bit integer expression instead. Found while reviewing integer arithmetic in QProgressBar as part of the fix for QTBUG-57857. While touching the line, make the (intended) double → int truncation explicit, by using a static_cast. Change-Id: I03dbfce24c709310c3bbad9487a2bf0d1d78137a Reviewed-by: David Faure <david.faure@kdab.com>
* QProgressBar: remove unneeded ctor-style no-op castMarc Mutz2017-01-071-1/+1
| | | | | | | | | | The expression '100' already has type int, so the cast is not necessary, and confusing. Remove it. Change-Id: Id63f56645b1b13532f73e481547c2a606dfc9c9a Reviewed-by: David Faure <david.faure@kdab.com>
* revert to building qmake with qconfig.cppOswald Buddenhagen2017-01-062-85/+16
| | | | | | | | | | | | | | | | | | | | turns out that just appending builtin-qt.conf isn't a good idea: executable-editing tools (objcopy, prelink, etc.) will happily drop the "attachment". a safe method would be adding a proper section to the executable, but there doesn't appear to be an objcopy equivalent in msvc, and using entirely different methods of embedding the file with different toolchains seems like a rather bad idea. so instead go back to the old method of building qmake with a generated qconfig.cpp. of course, as said file is now created by qmake itself, we have to compile qlibraryinfo.cpp a second time, and link a second qmake executable. Task-number: QTBUG-57803 Change-Id: I9e232693550aa870cec154e49cc06add13017cc2 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Add a feature for Qt XmlUlf Hermann2017-01-061-2/+1
| | | | | | | | ... so that we can turn it off if we don't want to build it. Change-Id: Ia330dfa1477bcd2dc8e24eb55400e100fca156b5 Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
* Add a feature for Qt TestlibUlf Hermann2017-01-061-1/+2
| | | | | | | | ... so that we can turn it off if we don't want to build it. Change-Id: Ib27386da4754d843d4e4cbb05f9542852efefb88 Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
* Add a feature for Qt SqlUlf Hermann2017-01-061-2/+6
| | | | | | | | This way we can disable it by passing -no-feature-sql to configure. Change-Id: Ia47d72101de0788478997fa1854cedcd1742f6fd Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
* Add a feature for Qt NetworkUlf Hermann2017-01-061-2/+6
| | | | | | | | | | This way you can disable support for QtNetwork by specifying -no-feature-network on the configure line. Change-Id: I46217ccc525a9e2c85394ed4eb6db0e2b60b6d86 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
* QAndroidStyle: fix UB (signed integer overflow) in ↵Marc Mutz2017-01-061-5/+4
| | | | | | | | | | | | | | | AndroidProgressBarControl::drawControl() The expression 'maximum - minimum' has undefined behavior when 'qint64(maximum) - minimum > INT_MAX'. Use 64-bit arithmetic instead. Also fix calculation of the progress when minimum != 0. Rename QStyleOptionProgressBar* variable to avoid line wraps. Change-Id: I1d48a7930e7f6d69798c2e878bb0045d55c2f057 Reviewed-by: David Faure <david.faure@kdab.com>
* Fix UB (signed integer overflows) in QProgressBarMarc Mutz2017-01-061-6/+8
| | | | | | | | | | | | The expression 'minimum - 1' invokes UB when 'minimum == INT_MIN'. Likewise, the expression 'maximum - minimum' invokes UB when 'qint64(maximum) - minimum > INT_MAX'. Fix by restructuring the code or else by using 64-bit arithmetic. Change-Id: I352eafa72f28ae907f41c8f88abcf0a81705c718 Task-number: QTBUG-57857 Reviewed-by: David Faure <david.faure@kdab.com>
* Fix deleting of QOpenGLVersionFunctionsBackendDavid Faure2017-01-061-6/+12
| | | | | | | | | | Since the destructor is not virtual we need to cast to the proper class when deleting otherwise the wrong destructor is called and the object memory is not entirely freed. Change-Id: Ie4e0e91bfa6e802c7d72fd1f137f5c7f3f31c8a0 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* Accessibility macOS: check for valid interfacesFrederik Gladhorn2017-01-051-5/+5
| | | | | | | | There are a few places that did not check if the returned interface is valid. Task-number: QTBUG-52536 Change-Id: I56ca0952fec0b44dfd4b3991aa94554e9c829642 Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
* Accessibility macOS: fix parentElementFrederik Gladhorn2017-01-051-10/+10
| | | | | | | | | | | | | | Try to return the immediate parent first, nothing else makes sense. The original code relied on the window pointer usually being nullptr, which is not reliable. Make sure to check the validity of the handle returned, since it's possible to have the platform window being nullptr. It's not quite clear to me how to end up with a null window though. Task-number: QTBUG-52304 Change-Id: Id3e70cdab980fb0a86cebbb7c10d824d8a7dd80b Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io>
* QOCIDriver: Ensure the where clause is correctly setupAndy Shaw2017-01-051-3/+3
| | | | | | | | | | | | | | Commit 88e043a8 introduced two bugs: 1. When constructing the WHERE clause, the closing ' around the owner name was dropped. 2. When constructing QLatin1Strings for comparison with system owners, a size of -1 was passed, with the comment "force strlen call". But, unlike QString, QLatin1String does not invoke strlen(), but stores the negative length unchanged, making the comparisons always fail. Change-Id: Ie2835b76877c31ee32c900f67eb0853df7110dbb Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* Win: Account for windows which are WindowTransparentForInputAndy Shaw2017-01-052-18/+14
| | | | | | Task-number: QTBUG-57864 Change-Id: I8793aaa3719fbcf97f95ae462135cbf6b5823097 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Fix compilation without sharedmemoryUlf Hermann2017-01-052-2/+4
| | | | | | | | | | | We have to enable qt_safe_ftok with either sharedmemory or systemsemaphore. In order to make the resulting QT_CONFIG work with the bootstrap library we switch the features off for bootstrapping. Some tests and examples have to be excluded when sharedmemory is not available. Change-Id: I3fc3926d160202b378be2293fba40201a4bf50c5 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Make filesystemmodel feature depend on itemmodelUlf Hermann2017-01-041-0/+1
| | | | | | | | QFileSystemModel inherits from QAbstractItemModel, so it has to be disabled if the latter is not available. Change-Id: Ifc56f7e311d84bd15e8b4ed95d67bf9ad9aba888 Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* Remove pointless QT_NO_THREAD ifdefs from qpropertyanimation.cppUlf Hermann2017-01-041-2/+0
| | | | | Change-Id: I7b7e80abbddf4d43c6135775136d993196d708b3 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Avoid zero-as-nullpointer warnings in QThreadUlf Hermann2017-01-041-2/+2
| | | | | | Change-Id: I3fd557a54d63c2dcabe58fab65326538896d02a2 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* Doc: add note about unsupported platforms for QProcessAleksey Lysenko2017-01-041-0/+3
| | | | | | | Task-number: QTBUG-57840 Change-Id: I46a26a9c4c6ad0aa6994945091a2904c3b51080f Reviewed-by: Martin Smith <martin.smith@qt.io> Reviewed-by: Jake Petroules <jake.petroules@qt.io>
* Avoid compile warnings in qabstractanimation.cppUlf Hermann2017-01-031-0/+2
| | | | | | Change-Id: I57f90fc335b50231fb2093f096ad38168d476145 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* Fix broken link in documentationFrederik Schwarzer2017-01-031-1/+1
| | | | | | | Task-number: QTBUG-57530 Change-Id: Iecb1a26f6b8a7e8a506d768668cde1c277d15dde Reviewed-by: Topi Reiniö <topi.reinio@qt.io> Reviewed-by: Martin Smith <martin.smith@qt.io>
* QDateTime::fromString(): improve performance by 33%David Faure2017-01-031-5/+15
| | | | | | | | | | | | | | | | getMaximum() and getMinimum(), called during parsing, create new QDateTime instances, which on Linux end up calling mktime(). Making these static (for the common case of LocalTime spec) improves performance dramatically, when parsing several date/times. tests/benchmarks/corelib/tools/qdatetime/ (after fixing it to actually parse a valid date/time) says: RESULT : tst_QDateTime::fromString(): - 36,742,060 instruction reads per iteration (total: 36,742,060, iterations: 1) + 24,230,060 instruction reads per iteration (total: 24,230,060, iterations: 1) Change-Id: I0c3931285475bf19a5be8cba1486ed07cbf5e134 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Partially revert "Windows: stop using _beginthreadex on regular builds"Thiago Macieira2017-01-031-0/+35
| | | | | | | | | | | | | | | | | This pertially reverts commit 3ec57107cedb154f256e3ad001ea5475cc64fa94 and brings back the hack to prevent the DLL from being unloaded. It should have been enough, but we've got reports that it's still causing trouble. Since it causes not much harm to keep the DLL loaded (worst case scenario is that QtDBus and QtCore remain loaded after a plugin gets unloaded), we'll keep it. Note: Microsoft is aware that their way of killing threads on process exit is a flaw. See https://blogs.msdn.microsoft.com/oldnewthing/20070502-00/?p=27023/ Task-number: QTBUG-53031 Change-Id: I2962773739e34633b033fffd1493dce695b008c0 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Maurice Kalinowski <maurice.kalinowski@qt.io>
* configure: make library sources fail more verboselyOswald Buddenhagen2016-12-302-0/+3
| | | | | | | | log a message in all unsuccessful exit paths. Task-number: QTBUG-57217 Change-Id: I8b0f2685d327da583c3e42c8149327e05b2a66cc Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* QHeaderView: fix restoreState() on a model with more columnsDavid Faure2016-12-291-0/+14
| | | | | | | | | | | | | When saving state for a 3-columns headerview and then restoring that state onto a 5-column headerview, the headerview shouldn't suddenly think it has 3 columns. Rather than making restoreState() fail, we adjust for the additional columns, so that we can still apply the customizations from the user to all other columns (hiding, moving, etc.). Change-Id: I3f220aa322ea8b629d2fe345f8cde13e0ea615d6 Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com>
* xcb: Ignore XI2 LMB mouse events from touch screensAlexander Volkov2016-12-284-14/+21
| | | | | | | | | | | | | | | | | | | | 157ee01a8d0be9a4dbac03883c9eaf3609fc1172 was trying to minimize some side effects of the bug in the evdev driver (https://bugs.freedesktop.org/show_bug.cgi?id=98188) by not changing mouse button state on motion. Unfortunately it resurrected bugs that were fixed by 76de1ac0a4cd384f608a14b5d77a8cf3ef1ec868. Filter out mouse events from touch screens instead. This change reverts 157ee01a8d0be9a4dbac03883c9eaf3609fc1172. Task-number: QTBUG-32609 Task-number: QTBUG-35065 Task-number: QTBUG-43776 Task-number: QTBUG-44166 Task-number: QTBUG-44231 Task-number: QTBUG-56156 Change-Id: Ie17710d94beabeb08681d669a9d8309be9b44e73 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
* Doc: add a quick note about unfixed Windows encoding bugThiago Macieira2016-12-281-0/+3
| | | | | | Task-number: QTBUG-49640 Change-Id: Icb0289e3118a41dd9438fffd1492925b03de62d6 Reviewed-by: David Faure <david.faure@kdab.com>
* Link QVariant class documentation to the Creating Custom Qt Types articleKavindra Palaraja2016-12-281-1/+1
| | | | | | | | The article does answer the questions asked in the bug. Task-number: QTBUG-56629 Change-Id: Ib8bac0acf45bc10598fc47feb6dd73005b5ad040 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Removed random notes in the documentation that should not be thereKavindra Palaraja2016-12-281-2/+0
| | | | | | | | Two sentences that read like author notes likely added by accident. Task-number: QTBUG-56630 Change-Id: I7a0b114e128f95e54e9e8f26b43493f67747d650 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* windows: use lowercase #includeAndrew Knight2016-12-281-1/+1
| | | | | | | | | MinGW's headers are lowercase, and MSVC is generally run on a case- insensitive file system. Including in the lowercase is the more compatible option. Change-Id: I288cecb77ddd8029bb3925e613a830dd9ce96a6c Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Fix warning from MinGW/GCC 6.2Andrew Knight2016-12-281-2/+1
| | | | | | | | | | | | src/widgets/styles/qwindowsvistastyle.cpp: In member function 'virtual QSize QWindowsVistaStyle::sizeFromContents(QStyle::ContentsType, const QStyleOption*, const QSize&, const QWidget*) const': src/widgets/styles/qwindowsvistastyle.cpp:1872:9: error: this 'if' clause does not guard... [-Werror=misleading-indentation] if (!sz.isEmpty()) ^~ src/widgets/styles/qwindowsvistastyle.cpp:1874:13: note: ...this statement, but the latter is misleadingly indented as if it is guarded by the 'if' return sz; Change-Id: Ifd3faef8c93f12d5fadaf4edf875fbe0fc6fb785 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* Fix typo in documentationAndré Klitzing2016-12-271-1/+1
| | | | | Change-Id: I86584392f2646e87f26bf6de725802e5c6a6c6e0 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QMimeDatabase: fix handling of conflicting globsDavid Faure2016-12-276-51/+55
| | | | | | | | | | | | | | | | | | | This code always intended to follow the recommended checking order from the spec, which says "if multiple globs match, use file contents". But if the globs had different weights, it would discard globs with lower weights, and then wrongly conclude, if there is only one glob left, that there was no ambiguity. The correct way is rather: remember that multiple globs matched, do determination from contents, and if that didn't work, *then* use (one of) the highest-weight glob(s). This fixes PGP-encrypted *.asc files being detected as text/plain rather than application/pgp-encrypted. (https://bugs.kde.org/show_bug.cgi?id=346754) Change-Id: I734459daf9f502baa95ebb89432819964e0ce304 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QMimeMagicRule: endianness fixesDavid Faure2016-12-271-2/+12
| | | | | | | | | | | | | | | | | * apply endianness to the mask as well * do not apply endianness to "host" entries, they were wrongly behaving exactly like "big endian" entries. The issue with the mask was detected by the audio/aac magic <match type="big16" value="0xFFF0" mask="0xFFF6" offset="0"/> which failed to identify the test file ct_faac-adts.aac since it was applying the mask 0xFFF6 instead of 0xF6FF (on a little-endian machine). Not yet detected by tst_qmimedatabase which is based on shared-mime-info 1.0, will be covered by the upgrade to 1.8 in dev. Change-Id: I4fb7af2d367099817e712b14f2a031066d0ac432 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QMimeMagicRule: fix off by one in the number of bytes checkedDavid Faure2016-12-271-1/+1
| | | | | | | | | | | | | | | | | | | | | Since the loop says p <= e, no +1 should be added to e. Testcase: The magic for application/x-gameboy-rom says <match type="byte" value="0x0" mask="0x80" offset="323"/> and this code was checking both byte 323 and byte 324, finding a match at pos 324, returning application/x-gameboy-rom erroneously. Given the magic for application/x-gameboy-color-rom: <match type="byte" value="0x80" mask="0x80" offset="323"/> the expected result for game-boy-color-test.gbc is application/x-gameboy-color-rom Not yet detected by tst_qmimedatabase which is based on shared-mime-info 1.0, will be covered by the upgrade to 1.8. Change-Id: I2396cb1ccfb26db5a24d5551fef493cc0b98a247 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Optimize QtActivity's onCreate a little bitKonstantin Ritt2016-12-251-1/+3
| | | | | Change-Id: Iabb0f561d99f363dfe1dc206b3ad3e8f1a1d04c0 Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* ... and so configureapp.exe disappearethOswald Buddenhagen2016-12-231-5/+2
| | | | | Change-Id: I3fd9f2b0d4cf05a625484fce21532da8563cd62c Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* platform plugins: Remove unused former overridersAlexander Volkov2016-12-223-14/+0
| | | | | | | | They were implied to override QPlatformIntegrationPlugin::keys() but it was removed before releasing Qt 5.0. Change-Id: Ia1f1ad27b7511b1141887f5dcde0dadeb2e5cabf Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
* fix sysrootification of install pathsOswald Buddenhagen2016-12-222-16/+15
| | | | | | | | | | | | | | | | | | | | | initially, the idea was that QLibraryInfo would receive a pre-sysrootified ExtPrefix from the builtin qt.conf. matching this against the sysroot would then tell us whether to sysrootify the Prefix from a "regular" qt.conf as well. however, this would have lead to some major ugliness and inconsistency between the code paths, so i changed my mind. unfortunately, i failed to adjust the remaining code, leading to 169a40d51 entirely breaking sysrootification ... the proper (and nicely consistent) solution is to introduce a SysrootifyPrefix key to qt.conf. this is user-accessible as well, so as a bonus it is now possible to adjust the setting at qmake installation time. incidentally, this omission was the last thing that prevented using the same qmake host build for any imaginable configuration of the same qt version ... i think. Change-Id: Ic0eebf21f93651f6374628c0ad8b206d696a4a7e Reviewed-by: Andy Nichols <andy.nichols@qt.io>
* Silence maybe_uninitialized warning with gcc -OgAllan Sandfeld Jensen2016-12-213-4/+4
| | | | | | | | | | GCC produces false positives for maybe_uninitialized when compiling with -Og in these three places. Simply initialize the variables to silence it. This should be entirely cost-free for normal compilation. Change-Id: Iab778a6ba25993f78f190e928c1fcc2dbd8b2fcd Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* macOS: Take DPR into account when creating CGContexts for a QPixmapTor Arne Vestbø2016-12-211-0/+2
| | | | | | | | | Missing logic when refactoring image manipulation methods into QtGui in c52bb030907. Task-number: QTBUG-57723 Change-Id: I7b55d4451d35faf5fd794daa0b80acbd712f30cd Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
* QLockFile: make sure we encode the hostname as UTF-8 in the lock fileDavid Faure2016-12-211-11/+2
| | | | | | | | | | | | | | | | | | | | We chose to use UTF-8 as it allows us to ensure there's no mistaking the hostname in case the locale is changed, if the host name contains characters outside of US-ASCII. But this didn't work because the code that wrote the hostname always used the local 8-bit codec instead of UTF-8. On Unix, we used the result of gethostname(3) directly, which is supposedly on the locale codec. This commit doesn't fix Windows, which requires _wgetenv, the plan being to encapsulate that with a qEnvironmentVariable() method. [ChangeLog][QtCore][QLockFile] Fixed a bug that caused QLockFile not to recognize a stale lock file if the machine's hostname contained non-US- ASCII characters, on Unix. A Windows fix is still pending. Task-number: QTBUG-49640 Change-Id: Ib9d045544ff370ec901626658a84ec4e6575fe21 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>