summaryrefslogtreecommitdiffstats
path: root/src
Commit message (Collapse)AuthorAgeFilesLines
...
* | | macOS: Rename QCocoaGLContext::setActiveWindow to setDrawableTor Arne Vestbø2018-09-062-12/+16
| | | | | | | | | | | | | | | Change-Id: I0be5125b434418c005f45f05c54b22f0418b46e4 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* | | QHeaderView: honor qss padding attributeChristian Ehrlicher2018-09-061-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QStyleSheetStyle did not check if a border (which includes the padding) is given and therefore the padding attribute given by css was ignored. Only when another attribute was additionally set, the padding was used. Task-number: QTBUG-59501 Change-Id: If3e691a23266ef6d0fb942a43053b29d65e40047 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* | | QHeaderView: remove dead codeChristian Ehrlicher2018-09-061-7/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | The special handling when a font for a headerview is set became useless after a4e6117c53c3984585b3bbb74c00d6d863c98fcd since it is now included in branch four lines above. Change-Id: I73bec48913ebca5f278128a124b58d1b6172e334 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | | QHeaderView: Take padding/margin into account when eliding textChristian Ehrlicher2018-09-061-2/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When QHeaderView has an elide mode set, the available width passed to QFontMetrics::elidedText() was not adjusted when padding or margin was set. This lead to a too long text displayed in the header. Now QStyle::subElementRect(SE_HeaderLabel) is used to get the correct rect. Task-number: QTBUG-23203 Change-Id: I12fc646092470272bb91b3ffb7c7a51e239c7a35 Reviewed-by: David Faure <david.faure@kdab.com>
* | | uic: Fix pixmap functions for QIconFriedemann Kleint2018-09-062-2/+57
| | | | | | | | | | | | | | | | | | Task-number: QTBUG-8563 Change-Id: I69b16ac2327fee6dd6f26845bdda60ad4dde56fa Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
* | | Fix QSIM::itemData returning role 255Luca Beldi2018-09-061-4/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Before this fix, QStandardItemModel::itemData returns a map containing role 255 which is used internally to store the flags. This role is an undocumented implementation detail so it should not be returned to the user. [ChangeLog][QtGui][QStandardItemModel] itemData does not return role 255 Change-Id: Ibead3cba84cfe92b3c664bc8ce87508cbcbdc9bd Reviewed-by: David Faure <david.faure@kdab.com>
* | | ASAN: Disable SSE4.1 code in qstricmp because of heap-buffer-overflowErik Verbruggen2018-09-051-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Although it is safe to slightly overread a string (provided it doesn't cross page boundaries), ASAN is extremely picky about this kind of behavior. So, do not run with this vectorized code when ASAN is enabled. Task-number: QTBUG-70269 Change-Id: I2b59b524d608afec8985227285feab55158d7247 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | | QWindowsStyle: respect rectangle when drawing PE_IndicatorViewItemCheckRolf Eike Beer2018-09-031-6/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is a follow-up on commit 6553921dd537e416da2f4d1441ab6d63059cda60, which fixed the drawing of the surrounding rectangle when used in item views. This one now fixes the drawing of the check mark itself, for both item views and standalone items. Change-Id: I14f359e9d2ef33652cc68494b7d114e61110e5e0 Reviewed-by: Andre de la Rocha <andre.rocha@qt.io> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | | Doc: Explicitly state that QSqlTableModel only handles EditRoleAndy Shaw2018-09-031-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | Fixes: 5.12.0 Task-number: QTBUG-70234 Change-Id: I65c6aa60048182c5408dca2aa20098af363b10ec Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de> Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
* | | QSFPM: cleanup QRegularExpression includesSamuel Gaist2018-09-032-2/+6
| | | | | | | | | | | | | | | | | | | | | | | | Add feature guard around the include in the header and remove the one from the implementation file. Change-Id: I8dc133cce786ead6059cc66b40a0ffb6c420096f Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
* | | QStringList: add contains(QStringView) overloadAlbert Astals Cid2018-09-032-2/+24
| | | | | | | | | | | | | | | Change-Id: I953e4ef3167011d0348ea482890e29478bd6f761 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | | Add QString::compare(QStringView, CaseSensitivity)Albert Astals Cid2018-09-032-1/+21
| | | | | | | | | | | | | | | | | | | | | | | | There was a QStringView::compare(QString, CaseSensitivity) but it's good that the symmetric also exists Change-Id: Ic789f11d41eb8cfa393cb51c19bd1f89bb87d912 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | | Remove some misplaced sizeof() scalings on array sizes for new[]Edward Welbourne2018-09-031-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Noticed during review of clang-tidy warnings. I have searched the source tree (using grep) and only this one file contains examples of this mistake. Change-Id: I3bbcec736e5a184db7251962fd3671a21ab5d238 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* | | Rename QTimer::connectTo() to QTimer::callOnTimeout()Sergio Martins2018-09-032-9/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some people suggested the later, so let's have a second look at it before it's too late. Although I was in favor of the former I'm now having second thoughts. connectTo() is meant to only be used in classes which have a clear dominant signal, but there are rare classes that have two (example: QAbstractButton::toggled, QAbstractButton::clicked). QAbstractButton::connectTo() would be ambiguous if we ever wanted to add these shorthand connects to QtWidgets Change-Id: I198ad3326d31dcf89b9c47a299124572ee7b11b3 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Lars Knoll <lars.knoll@qt.io>
* | | Fix reading 16bpc grayscale PNGsAllan Sandfeld Jensen2018-09-031-17/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | They were incorrectly attempted to be read as Indexed8, instead use the RGBA64 formats to read them with full accuracy. Task-number: QTBUG-45858 Change-Id: I14fc3cb0d59fa2fc0e68fd870f3b32352c34161f Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
* | | Android: Fix crashBogDan Vatra2018-09-031-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | Android doesn't like nor use RTLD_NODELETE Tasnk-number: QTBUG-64654 Change-Id: I2d884bbf22a681cca592942eba84ba97327ba974 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
* | | Bump copyright year of code generated by dbus toolsAlex Blasche2018-09-032-2/+2
| | | | | | | | | | | | | | | | | | Change-Id: Ic5e2ecf672ea86e8ef70a9fa73c0535262d2e928 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
* | | Windows code: Fix to prefer ranged-for, as clang-tidy advisesFriedemann Kleint2018-09-025-21/+14
| | | | | | | | | | | | | | | | | | | | | Change-Id: Id9bb21855ae832cdbbc456326226ec72b634672e Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Luca Beldi <v.ronin@yahoo.it> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | | Make flatpak portal support to be used also by Snap applicationsJan Grulich2018-09-0212-148/+150
| | | | | | | | | | | | | | | | | | | | | | | | | | | Snap now uses xdg-desktop-portal for portal support. Add check for apps running in Snap and make them use portals by default. We also should be using different name for the platform theme used by sandboxed apps. Change-Id: Ibaa35b7549b3d94775d7edb937f729a300d071b6 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | | Windows code: Fix clang-tidy warnings about else after jumpsFriedemann Kleint2018-09-0212-142/+139
| | | | | | | | | | | | | | | | | | | | | | | | | | | Replace by switch() where appropriate, remove else and unindent code or simplify the return value. Change-Id: Ie988b9068a9579ae5a899b3765e43aad480b564e Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | | qelapsedtimer_win.cpp: Fix clang-tidy warning about else after returnFriedemann Kleint2018-09-021-3/+2
| | | | | | | | | | | | | | | | | | | | | | | | Remove else in nelper nanosecondsToTicks() Change-Id: I6c5291deaeb6651f702a9c118cabcb5a7edd179e Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | | Windows code: Fix clang-tidy warnings about (private) class definitionsFriedemann Kleint2018-09-0212-59/+72
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add override, disable copies where appropriate and use = default for trivial functions. Change-Id: Ia5bc7419b1aa053c5503ea7dfaf11cb6dfafd2e2 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | | Windows: Check Pointer messages in MessageDebugEntryAndre de la Rocha2018-09-011-2/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Some Pointer Input messages are defined only for Windows 10 and new versions of the Windows SDK and could break compilation with older SDKs. Currently, they are not used anywhere outside of the MessageDebugEntry debug function. Checking if they are defined before using. Change-Id: I5fc7bb8e52ab8aca66bb21084289ab8938938063 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io> Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* | | Plugins: Save some architectural requirement flagsThiago Macieira2018-09-014-22/+40
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ...not just the debug flag. The information is saved outside of the CBOR map for two reasons: 1) removing the hack that depended on how QCborStreamWriter and TinyCBOR internally work, allowing for the extra parameter to be written directly. We wouldn't be able to use that hack anyway and would have needed a further, uglier hack to encode a byte whose value we don't know. 2) outside the map, this information can be parsed more quickly and then we can discard any plugins we shouldn't actually load. Since we're doing this for a flag, I decided to move the Qt version there too for reason #2. Change-Id: I61ecce6b1324410bbab4fffd153d4e5fc696d19e Reviewed-by: Lars Knoll <lars.knoll@qt.io> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
* | | Plugins: store the metadata in CBOR instead of binary JSONThiago Macieira2018-09-019-79/+390
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In preparation for Qt 6 deprecating the binary JSON format. Also reduces the size of the metadata a little: for the xcb platform plugin, it went down from 264 bytes to 138; for the jpeg image plugin, it went from 320 to 135. I've had to change the signature so older versions of Qt won't try to parse the CBOR data as Binary JSON. Unfortunately, before QJsonDocument could get a chance to reject it, qJsonFromRawLibraryMetaData() needed to allocate memory and that causes crashes with Qt < 5.11.2. Change-Id: Ieb48f7c0dd0e4e0fb35efffd153bee34e16ce347 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | | Update TinyCBORThiago Macieira2018-09-012-59/+69
| | | | | | | | | | | | | | | | | | | | | | | | Updated to https://github.com/thiagomacieira/tinycbor commit 1286d99bdc664de6acf7c5274702325f5a095a0f Change-Id: I0d3cc366baaa49f3ad28fffd15428e886333bb38 Reviewed-by: Kai Koehne <kai.koehne@qt.io>
* | | Windows QPA: Stop synthesizing mouse events from tablet/touchAndre de la Rocha2018-09-013-27/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | These fake mouse events should be synthesized by QtGui, not the QPA plugin, when the tablet/touch events are not handled by the application and the Qt::AA_SynthesizeMouseForUnhandledTouchEvents or Qt::AA_SynthesizeMouseForUnhandledTabletEvents flags are set. Task-number: QTBUG-47007 Task-number: QTBUG-60437 Change-Id: I4d6d5e6667d245c45a4eb4f3a94db05cf9772f52 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io> Reviewed-by: Romain Pokrzywka <romain.pokrzywka@gmail.com> Reviewed-by: Jan Arve Sæther <jan-arve.saether@qt.io> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | | wasm: disable RasterGlSurfaceLorn Potter2018-08-311-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QOpenGlWidget and QuickQidget do not work at this time anyway. This also causes gl to be initialized for widget apps, so disabling this will optimize widget apps. We could use Qt::AA_ForceRasterWidgets as well. Task-number: QTBUG-67797 Change-Id: I8f86a9f72e6f3d437a818b4fbe3d6f3658e17d04 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* | | macOS: Remove support for QSurfaceFormat::StereoBuffersTor Arne Vestbø2018-08-311-5/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The NSOpenGLPFAStereo attribute was deprecated in macOS 10.12, without any replacement, and adding the attribute to the pixel format results in context creation failure, so we're assuming the feature is no longer supported an disable it wholesale on macOS. Change-Id: I27d9f300fdaff9abe90781e3160b97f8b66121ad Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
* | | macOS: Update all deprecated enums to their 10.12+ equivalentsTor Arne Vestbø2018-08-3114-135/+133
| | | | | | | | | | | | | | | Change-Id: I3034258da95c9c70eb6758db92967f438617f6e9 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* | | Remove codepaths and checks for unsupported Apple platformsTor Arne Vestbø2018-08-3112-219/+104
| | | | | | | | | | | | | | | | | | | | | We no longer support macOS 10.11, iOS/tvOS 10, or watchOS 3. Change-Id: Ide03d8fac06185ef4162ba75ee54a0adf6916905 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* | | WebAssembly for QtBaseMorten Johan Sørvig2018-08-3066-20/+5803
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is the squashed diff from wip/webassembly to dev. Done-with: Peng Wu <peng.wu@intopalo.com> Done-with: Sami Enne <sami.enne@intopalo.com> Done-with: Morten Johan Sørvig <morten.sorvig@qt.io> Started-by: Andrew Knight <andrew.knight@intopalo.com> Change-Id: I6562433c0a38d6ec49ab675e0f104f2665f3392d Reviewed-by: Lorn Potter <lorn.potter@gmail.com> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
* | | Silence warning in gcc 4.9 for AndroidEskil Abrahamsen Blomfeldt2018-08-301-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | When building with warnings are errors for Android with gcc 4.9, it wrongfully fails on use of uninitialized variable. Change-Id: I39c5e8413c30567fba60cbba6a8b26d537c5836e Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
* | | Windows code: Fix clang-tidy warnings about C-style castsFriedemann Kleint2018-08-3023-103/+126
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Replace by reinterpret_cast or const_cast, respectively. Use auto when initializing a variable to fix Clang warnings about repeating the type name, do minor tidying along the way, and a few conversions of 0 or NULL to nullptr. Change-Id: Ieb271a87ddcf064f536e1ff05d23b1e688b1b56a Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | | Update QMetaObjectBuilder::MetaObjectFlag enumBogDan Vatra2018-08-302-3/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | Synced QMetaObjectBuilder::MetaObjectFlag with the MetaObjectFlags enum from qmetaobject_p.h. Also added a few comments for Qt 6. Change-Id: Ieccd5cf8d512a6bf7256b2f4db88d45662774536 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
* | | Allow registering constructor for a set of dynamic typesBogDan Vatra2018-08-303-70/+166
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This feature is needed to register complex types (e.g. Q_GADGETS) at runtime, using a single constructor method and added type parameter. Without having the type id available to the Constructor it is impossible to specialize behavior, thus requiring separate constructors for each type. Generating these separate constructors at compile time is easy, but not at runtime. [ChangeLog][QMetaType] QMetaType can now register constructor for a set of dynamic types. Change-Id: I6071271d0e157864594dd07b4bc3a0abbeb15a44 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | | Windows QPA: Fix duplicate Pointer Touch events and missing TouchCancelRomain Pokrzywka2018-08-304-1/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | translateTouchEvent needs to filter events based on the message type passed in msg, as Windows sends more than just down/up/update events, it also sends enter/leave for each touch and occasionally a few more. One of them is WM_POINTERCAPTURECHANGED which indicates a general loss of touch input, which needs to be translated to a touch cancel event. Ignore WM_POINTERENTER/WM_POINTERLEAVE events as they result in sending duplicate Qt::TouchPointPressed/Qt::TouchPointReleased events otherwise. Also avoid sending duplicate events for each additional touchpoint: Windows already bundles all available touchpoints for a touch event when calling GetPointerFrameTouchInfo, so we get all points at once, but we'll still receive other events for each additional touchpoint, resulting in reading the same bundled data again for each one and sending duplicate events to QWindowSystemInterface. Use SkipPointerFrameMessages() to avoid receiving the additional events for the frame we just processed. Finally, add raw event logging when the platform verbose level is >1. Change-Id: I55d840285f642a00f6ffcda4a3efd7ae3985310b Reviewed-by: Andre de la Rocha <andre.rocha@qt.io>
* | | QWidget: fix setTabOrder for compound widgetsChristian Ehrlicher2018-08-301-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When adjusting the tab order for compound widgets, it can happen that the order is already correct. The check for this case forgot one case which lead to a garbled focus chain. Task-number: QTBUG-68393 Task-number: QTBUG-69619 Task-number: QTBUG-10907 Change-Id: Ic3242746bdcf3a4db6ea8daa1498381500ca116d Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* | | QSS/QTabBar: properly handle QTabBar::scrollerChristian Ehrlicher2018-08-301-3/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | PM_TabBarScrollButtonWidth used the size of the ::scroller subcontrol without considering that there are two QToolButtons and therefore returned the wrong size for a single QToolButton. QStyleSheetStyle::subElementRect() had no handling for SE_TabBarScrollLeft/RightButton and therefore the values for the scroller toolbuttons set via the stylesheet were never used. Fix it by dividing the scroller width by two and add the code path to handle SE_TabBarScrollLeft/RightButton in QStyleSheetStyle::subElementRect Task-number: QTBUG-69653 Change-Id: I1adfe6333f3183bba621bbbb4d10969920c6cd46 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* | | Fix out of buffer access in qt_qimageScaleRgba64_up_xyAllan Sandfeld Jensen2018-08-291-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | Avoid reading a pixel outside the image even if we multiply the result by 0. This mirrors a similar old fix in the the 32bit scaling path. Change-Id: I7860bc808dc46dbc94918672e99c81b56d4a1d27 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | | QSqlQuery: Specify documentation of named placeholdersChristian Ehrlicher2018-08-281-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Named placeholders can only contain characters in the range of [a-zA-Z0-9_] but this was not documented anywhere. Task-number: QTBUG-69775 Change-Id: I5c4eff7674b1fc04cef60e7d7f44cd87414ffbe9 Reviewed-by: Paul Wicking <paul.wicking@qt.io> Reviewed-by: Andy Shaw <andy.shaw@qt.io>
* | | Handle device pixel ratio in QHeaderView::setupSectionIndicatorChristian Ehrlicher2018-08-281-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | The device pixel ratio was not applied to the section indicator pixmap which made it look blurry on HighDPI screens. Task-number: QTBUG-70084 Change-Id: I8b07b2ffc51781c2d2d89484b8618173f0692fe4 Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
* | | Initialize the QSqlQuery to be invalid when creating a sql modelAndy Shaw2018-08-282-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When QSqlQueryModel or QSqlTableModel is created it will create a QSqlQuery which defaults to using the default QSqlDatabase connection. If this connection belongs to another thread then it will throw a warning as this is not safe to use. Since the QSqlQuery is always recreated when a query is set, the instance which is a member of the class can effectively be invalid until a new one is set. Task-number: QTBUG-69213 Change-Id: I68a5dd59fe62788f531d59a0680da11b118ee383 Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de> Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
* | | Remove dead code in QWin32PrintEngineFriedemann Kleint2018-08-281-28/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The functions checks for _glyphs.isEmpty() and returns in that case, so, there is no point in having another code branch for _glyphs.size() == 0 below. Unindent branch for _glyphs.size() > 0 and brush it up a bit to silence clang-tidy (warnings about using isEmpty(), nullptr). Change-Id: I78e86583bb30c7bea1357e7a45f61b07d5a4d139 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
* | | Windows Font databases: Rename struct FontNames to QFontNamesFriedemann Kleint2018-08-283-12/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | Prefix by Q to unclutter the namespace in static builds. Amends 9204b8c31ea1b5f0c05870c5b5d74c33b1a4f622 Task-number: QTBUG-53458 Change-Id: I1448cd944b6a3262b9cfa9f5c3fbab17c1c5c71c Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
* | | Windows QPA: Improve Pointer Pen events translationRomain Pokrzywka2018-08-273-7/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Compute QPointF hi-res screen coordinates based on the HIMETRIC values contained in the native message. This gives the same high-precision screen coordinates as what the old WinTab handler supported. Add the possibility to not synthesize mouse events if the platform plugin option DontPassOsMouseEventsSynthesizedFromTouch is set, just like we do for finger touches. This makes it possible to have clean Pen events without mouse duplicates for an application that handles both input types in parallel. Add raw event logging when the platform verbose level is >1. Change-Id: Ibf68b6275400388a76f8d5c573eed8f4b9bf4e9d Reviewed-by: Andre de la Rocha <andre.rocha@qt.io> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | | JSON: Add qHash functions for JSON and CBOR typesUlf Hermann2018-08-2713-0/+111
| | | | | | | | | | | | | | | | | | | | | This way we can easily use them as keys in QHash and QSet. Change-Id: Ie744c3b5ad1176ba2ab035c7e650af483757a0c9 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | | Tracepoints: fix ETW generator for pointersAlessandro Ambrosano2018-08-251-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | Fixes compilation failure on Windows, due to TraceLoggingValue not correctly casting pointer arguments to a known type. Change-Id: I6027debe4ea3440588dd8677209d6d47048b6b0f Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
* | | Weak-import global objects used for logging on Apple platformsTor Arne Vestbø2018-08-252-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Otherwise the dynamic loader will complain about missing symbols when the binary is run on platforms below our supported deployment target: dyld: Symbol not found: __os_activity_current Referenced from: QtCore.framework/Versions/5/QtCore (which was built for Mac OS X 10.12) Expected in: /usr/lib/libSystem.B.dylib in /Users/torarne/build/qt/5.12/qtbase/lib/QtCore.framework/Versions/5/QtCore Trace/BPT trap: 5 We want this to trigger our own logic in qt_apple_check_os_version(), where we tell the user in more friendly terms what's going on. An alternative to the targeted weak imports would be do import the whole library as weak, using -weak-lSystem.B. This doesn't seem to cause any performance issues at startup, but since we only need the two global symbols we stick to the more targeted solution just to be on the safe side. Change-Id: I87c1f185f6dcf9df26c700d31bb5071ddf7685be Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* | | Improve detection and handling of unsupported Apple platformsTor Arne Vestbø2018-08-253-12/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The application name wasn't always printed, so we try try a few more possibilities before falling back to the process name. We also run the check as early as possible, instead of relying on a QCoreApplication. We do not have to provide a dialog to the user, as macOS will do this for us if the application is launched from Finder. Change-Id: Ifbec86946d60294806364e08964852fd4b74ff56 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io> Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>