summaryrefslogtreecommitdiffstats
path: root/src/widgets/styles/qmacstyle_mac.mm
Commit message (Collapse)AuthorAgeFilesLines
* QMacStyle: Use NSRect instead of CGRect in drawNSViewInRect()v5.4.0-beta1Gabriel de Dietrich2014-10-131-3/+3
| | | | | | Change-Id: I90fd62dea377dfa9569d1730a67136c7a5dc6f82 Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com> Reviewed-by: Andy Shaw <andy.shaw@digia.com>
* Merge remote-tracking branch 'origin/5.3' into 5.4Oswald Buddenhagen2014-10-061-50/+103
|\ | | | | | | Change-Id: I132bb6cce68e9f8413200f7ee75586bd1cada38c
| * QMacStyle: Fix QToolButton appearance on YosemiteTimur Pocheptsov2014-10-021-1/+20
| | | | | | | | | | | | | | | | | | On Yosemite checkable toolbuttons look differently when highlighted - this modification tries to imitate such look without pixmaps we used on OS X >= 10.5 && < 10.10. Change-Id: I0fcdff42a67fa6d5188c9dc64401f0f27ae60b5d Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
| * QMacStyle: Generalize Cocoa control renderingGabriel de Dietrich2014-09-291-49/+83
| | | | | | | | | | | | | | | | | | | | | | | | So far, we were restricted by the values of ThemeButtonKind, which consist mostly of buttons. We want to generalize to other kind of controls when the time arrives. Already, QPushButton with pull- down menu is not possible to get from that enum, while its easy to get from NSPopupButton. Task-number: QTBUG-40833 Change-Id: I244c42c42ab595f4790050eb15ade70443e155b2 Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
* | Merge remote-tracking branch 'origin/5.3' into 5.4Gabriel de Dietrich2014-09-291-21/+65
|\| | | | | | | | | | | | | | | Conflicts: src/network/socket/qnativesocketengine_unix.cpp src/widgets/kernel/qwidget_qpa.cpp Change-Id: I6f1aa320d5ca66cd92d601a95885aeaab0abb191
| * QMacStyle: Improvements to some buttons on YosemiteGabriel de Dietrich2014-09-241-17/+61
| | | | | | | | | | | | | | | | | | | | | | Radio button, checkbox and non-editable combobox, in normal, small and mini sizes, and only in the inactive state. This commit amends 982b9b7ec2441103b100. Task-number: QTBUG-40833 Change-Id: If3f2bb215e9b8966cbf15f08fa252feb92483c7b Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
| * Fix compilation on OS X with macx-clang-32Andy Shaw2014-09-231-4/+4
| | | | | | | | | | | | Task-number: QTBUG-27335 Change-Id: I1703aee2d90e02b1a6ed386715bebddf6dedb9f5 Reviewed-by: Jake Petroules <jake.petroules@petroules.com>
* | Merge remote-tracking branch 'origin/5.3' into 5.4Frederik Gladhorn2014-09-231-62/+286
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The isAlwaysAskOption was removed in 38621713150b663355ebeb799a5a50d8e39a3c38 so manually removed code in src/plugins/bearer/connman/qconnmanengine.cpp Conflicts: src/corelib/global/qglobal.h src/corelib/tools/qcollator_macx.cpp src/corelib/tools/qstring.cpp src/gui/kernel/qwindow.cpp src/gui/kernel/qwindow_p.h src/gui/text/qtextengine.cpp src/platformsupport/fontdatabases/fontconfig/qfontenginemultifontconfig_p.h src/plugins/platforms/android/qandroidinputcontext.cpp src/plugins/platforms/xcb/qglxintegration.cpp src/plugins/platforms/xcb/qglxintegration.h src/plugins/platforms/xcb/qxcbconnection_xi2.cpp src/testlib/qtestcase.cpp src/testlib/qtestlog.cpp src/widgets/dialogs/qfiledialog.cpp src/widgets/kernel/qwindowcontainer.cpp tests/auto/corelib/tools/qcollator/tst_qcollator.cpp tests/auto/gui/text/qtextscriptengine/tst_qtextscriptengine.cpp tests/auto/widgets/kernel/qwidget_window/tst_qwidget_window.cpp tests/auto/widgets/widgets/qlineedit/tst_qlineedit.cpp Change-Id: Ic5d4187f682257a17509f6cd28d2836c6cfe2fc8
| * QMacStyle: Use NSView rendering for some inactive widgets on 10.10Gabriel de Dietrich2014-09-111-3/+122
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Right now, we use them for inactive non-editable combo box, check box, and radio button only on Yosemite. We keep as much as possible the previous behavior on older versions. In addition, we add a way for QQuickStyleItem to specify the window the item is on. This is currently without effect, since we don't seem to take the inactive window state into account. Task-number: QTBUG-40833 Change-Id: I2fb2a99e6adf1972f881195b79b07ce85a960273 Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
| * QMacStyle: Fix inactive combo box appearance in 10.10Gabriel de Dietrich2014-09-011-2/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | As usual, HITheme is not helping, and renders inactive controls as disabled. Also, given the design changes in Yosemite, we can't just desaturate the active pixmap and render it. In this case, we render the inactive control and enhance it, making very close to the expected result. The pixel-exact version would be to render a plain push button, and then add the combo box arrows. However, these arrows would need to be created (and updated) since there seems to be no more API to render them. Task-number: QTBUG-40833 Change-Id: If1bc366c0bc83123972fabebbc8beeb9f071e7a1 Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
| * QMacStyle: Fix push buttons focus ring on YosemiteGabriel de Dietrich2014-08-271-9/+49
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | HITheme renders the focus ring in a way that diminishes contrast on the focused button edges. The same issue seems to affect combo boxes, check boxes, and radio buttons. We refactor the code that was used to draw CE_FocusFrame into qt_drawFocusRingOnPath(). We use it to render our own path for the push button contour. This should also allow us to implement the focus ring animation in the future. As a side note, notice how the square button part (kThemeBevelButton) is a complete joke. Not only we impose the wrong button kind and let HITheme do what it can with it, but we also prevent ourselves from using it by never adding padding for the focus ring. Hopefully, we can fix this whole button sizing and padding mess in 5.5 or 6.0, whatever breaks less apps around. Task-number: QTBUG-40833 Change-Id: Ib9e7829d99b38dc926c55b31c3d6d5d32b691867 Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
| * QMacStyle: Fix QTabBar appearance on YosemiteGabriel de Dietrich2014-08-261-10/+19
| | | | | | | | | | | | | | | | | | | | | | The selected tab text color should be white except when the window is not active. Also, no text shadow should be rendered in any case. Finally, there's no need to move the tab shape up anymore. Task-number: QTBUG-40833 Change-Id: Ibb35f0bb7a12fb005202fd8c082eb9bb19645b2b Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
| * QMacStyle: Fix default button look on YosemiteGabriel de Dietrich2014-08-261-40/+71
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The default button has different text color on OS X 10.10, and doesn't pulsate anymore. We first make sure we don't start any animation for default buttons. Then, we set the right text color in the attached palette, which implies making a copy of the style option object. This increases the size of this patch but keeps things sane. (It's also more concise than the QGtkStyle approach that consists on duplicating QCommonstyle's code for rendering CE_PushButtonLabel). Task-number: QTBUG-40833 Change-Id: Ifac118bb607eec17400c6ae42342a223a40843b4 Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
* | Allow overriding standardIcon() in a proxy styleAlexander Volkov2014-09-161-3/+3
| | | | | | | | | | | | | | [ChangeLog][QtWidgets][Styles] Allow overriding standardIcon() in a proxy style Change-Id: I3c7983a7e51a8b220a0ca8ead2b4d7b87a77d71b Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* | OS X: Remove mnemonics in parenthesesTakumi Asaki2014-08-081-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | In some language, mnemonics put after label text within parentheses. e.g. "&Open" is translated to "開く(&O)" in Japanese. OS X doesn't use mnemonics and '&' in label text is removed. Mnemonics in parentheses (and spaces before them) also should be removed. Change-Id: I88c0a1f60af7e148b3cf24a4e215ce807d62bce3 Reviewed-by: Tasuku Suzuki <stasuku@gmail.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
* | Merge remote-tracking branch 'origin/5.3' into devFrederik Gladhorn2014-07-031-6/+16
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/gui/accessible/qaccessiblecache_mac.mm src/gui/accessible/qaccessiblecache_p.h src/plugins/platforms/cocoa/qcocoaaccessibilityelement.h src/plugins/platforms/cocoa/qcocoawindow.h src/plugins/platforms/cocoa/qcocoawindow.mm src/widgets/kernel/qwidget_qpa.cpp Manually moved change in qwidget_qpa.cpp to qwidget.cpp (cd07830e3b27da7e96a0a83f91ba08c168b45e62) Change-Id: Ia51f471f9b53de2f3b07d77ea89db9303ac8961d
| * Cocoa: Fix Qt-in-namespace build.Tim Blechmann2014-07-021-1/+2
| | | | | | | | | | | | | | | | Wrap cocoa classes in namespace macros. Task-number: QTBUG-39382 Change-Id: Id840e666105afca21760fcb529b5765e0a534120 Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
| * QMacStyle: Fix focus frame rendering in YosemiteGabriel de Dietrich2014-07-021-5/+14
| | | | | | | | | | | | | | | | | | | | | | | | Using the HITheme API would result in the frame's right edge to be missing. Instead, we use the recommended technique to draw the focus ring around a custom NSCell. (See https://developer.apple.com/library/mac/documentation/Cocoa/Conceptual/ControlCell/Articles/ManipulateCellControl.html) Change-Id: I12d4834d353b5cbd5893bf070b14ad0d8bb75634 Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
* | Merge remote-tracking branch 'origin/5.3' into devFrederik Gladhorn2014-07-011-12/+10
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: mkspecs/qnx-x86-qcc/qplatformdefs.h src/corelib/global/qglobal.h src/network/socket/qnativesocketengine_winrt.cpp src/plugins/platforms/android/androidjniaccessibility.cpp src/plugins/platforms/windows/qwindowswindow.cpp Manually adjusted: mkspecs/qnx-armle-v7-qcc/qplatformdefs.h to include 9ce697f2d54be6d94381c72af28dda79cbc027d4 Thanks goes to Sergio for the qnx mkspecs adjustments. Change-Id: I53b1fd6bc5bc884e5ee2c2b84975f58171a1cb8e
| * Mac Style: Fix QLineEdit frame in 10.10Gabriel de Dietrich2014-06-301-11/+9
| | | | | | | | | | | | | | | | Also removes some dead code. Change-Id: Id590bd56641918a163f8bad251e3e0e750adfc6f Reviewed-by: Jake Petroules <jake.petroules@petroules.com> Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
| * QMac/FusionStyle: fix the background color for transient scrollbarsJ-P Nurmi2014-06-301-1/+1
| | | | | | | | | | | | Task-number: QTBUG-39922 Change-Id: I4b313296ae845bc9e116494aa66c577b432b4a67 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* | Mac Style: Don't crash when rendering PE_IndicatorBranch without widgetGabriel de Dietrich2014-06-051-1/+2
| | | | | | | | | | Change-Id: I45784af3738807ab6753b67a5b103a65d4e28084 Reviewed-by: Jake Petroules <jake.petroules@petroules.com>
* | Use accurate title/status bar gradient colors on OS X.Jake Petroules2014-05-261-11/+31
| | | | | | | | | | | | | | QMacStyle now uses proper system colors when drawing status bars. Change-Id: I618e485a2a68a484f7c8cb5635cd2bf529126c02 Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
* | Merge remote-tracking branch 'origin/stable' into devSimon Hausmann2014-05-221-2/+2
|\| | | | | | | Change-Id: Ia36e93771066d8abcf8123dbe2362c5c9d9260fc
| * QMacStyle: Always draw status bar in active state if the window is main.Jake Petroules2014-05-171-2/+2
| | | | | | | | | | | | | | | | On OS X, most controls are drawn active or inactive based on their window's main state, NOT its key ("active" in Qt) state. Change-Id: If447d0a537bc594978f7202e7888ceacb54ec8fa Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
* | Removed unused variable macItemVMargin in qmacstyle_mac.mm.Ivan Komissarov2014-05-131-1/+0
| | | | | | | | | | Change-Id: Ib888781238f6cc9407732431219e570299a47198 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* | Merge remote-tracking branch 'origin/stable' into devFrederik Gladhorn2014-05-131-2/+2
|\| | | | | | | | | | | | | Manually changed enum to LibGL in src/plugins/platforms/xcb/qglxintegration.cpp Change-Id: If34ee6cce3d1d51fb4bb1fdfa59c30389ea0d207
| * Remove trailing whitespace.Jake Petroules2014-05-081-1/+1
| | | | | | | | | | Change-Id: Id487c8951d7f258c57fa71fd35a60ddb8c5a3fb2 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| * Fixed wrong condition in QMacStyle.Ivan Komissarov2014-05-031-1/+1
| | | | | | | | | | | | Change-Id: I003e59bd50754dbbda23de5c55096ca2d25b7a7a Reviewed-by: Jake Petroules <jake.petroules@petroules.com> Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* | Merge remote-tracking branch 'origin/stable' into devFrederik Gladhorn2014-05-061-6/+24
|\| | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: mkspecs/qnx-x86-qcc/qplatformdefs.h src/corelib/global/qglobal.h src/opengl/gl2paintengineex/qpaintengineex_opengl2.cpp src/opengl/qgl.cpp src/opengl/qglpixelbuffer.cpp src/opengl/qglshaderprogram.cpp tests/auto/opengl/qglthreads/tst_qglthreads.cpp Change-Id: Iaba137884d3526a139000ca26fee02bb27b5cdb5
| * Mac style: Get proper ThemeButtonKind for QDateTimeEditGabriel de Dietrich2014-05-021-6/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When it gets 'calendarPopup' set, that is. The reason lies, indirectly, in the extra margins we add to QComboBoxes and other QPushButtons in the Mac style. However, these extra margins do not apply to spinboxes, which is what QDateTimeEdit is. In particular, this causes Designer to show QDateTimeEdit at the wrong size when it's not in a layout. Task-number: QTBUG-38615 Change-Id: I3dd52e10db8c8970a6dc40b39fbe29dd86167daa Reviewed-by: Jake Petroules <jake.petroules@petroules.com> Reviewed-by: J-P Nurmi <jpnurmi@digia.com> Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
* | Removed unused function qcolorFromCGColor() in qmacstyle_mac.mm.Ivan Komissarov2014-04-281-19/+0
|/ | | | | | Change-Id: Id001ff3087e7317bbcd66cd22a91a4a67942567f Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* Mac: Implement unified toolbar look for QTabBarMorten Johan Sørvig2014-04-091-13/+44
| | | | | | | | | | | | | | | | | | | | | | | | | Extend the unified title and toolbar gradient to tabs in document mode that are adjacent unified tool bars. Change the updateMacBorderMetrics() function to register the tab bar geometry and visibility status with the Cocoa platform plugin. The Cocoa platform plugin will then merge this area with other registered areas if possible. Add QCocoaNativeInterface::testContentBorderPosition(). This function tests whether the given point is within the unified title and toolbar area. Use testContentBorderPosition() in QMacStyle to enable code paths that skips drawing the QToolBar bottom separator line and paints the active tab background with transparent pixels to make the background gradient visible. Change-Id: I2b70f9bb0c2c59af053a691a7df538f958783dab Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* Mac style: Fix one-pixel offset for combo boxes in small sizeGabriel de Dietrich2014-04-081-1/+1
| | | | | Change-Id: I744c102bd086742b1052ed547e50037dddff4654 Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
* OS X: Fix QRubberBand drawing on retina displaysMorten Johan Sørvig2014-04-031-1/+3
| | | | | | | | | | | Extend the existing rect adjustment to cover the upper/left edges as well. Check for a valid rect before drawing. Task-number: QTBUG-34534 Change-Id: I156abf4fb52924c350ec24fb44eadca86b2d5339 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com> Reviewed-by: Steve Mokris <smokris@softpixel.com>
* Mac theming: Remove obsolete private color conversion functionsGabriel de Dietrich2014-03-211-12/+0
| | | | | Change-Id: I165eea19c8e50f981a9fa48c14f0d63c40951747 Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
* Mac theming: Set background brush for menu paletteGabriel de Dietrich2014-03-211-5/+0
| | | | | | | | We also remove overriding the background when polishing the palette in QMacStyle. This is a leftover from pre-10.5 styling. Change-Id: Icaa6d9c864ab01783d83cc02192981136c417d24 Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
* Respect scrollbar position setting on MacJens Bache-Wiig2014-03-201-4/+4
| | | | | | | | | | | This was a regression from Qt 4.7. [ChangeLog][Widgets][QScrollArea] Respect scrollbar setting for click-position on Mac. Task-number: QTBUG-36314 Change-Id: I8bdb1aec9b308b0907f5db29d3519998bc843c18 Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
* QMenu: Enable sloppy submenu mouse navigationGabriel de Dietrich2014-03-191-3/+0
| | | | | | | | | | | | | Since we're in the 21st century, we set QCommonStyle to return true to the SH_Menu_SloppySubMenus style hint. This unlocks all the logic already available in QMenu. Task-number: QTBUG-20094 [ChangeLog][QtWidgets][QMenu] Enable sloppy submenu mouse navigation Change-Id: I134c87e348d98d1f46055e0bfef2b4a4a3d2993a Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com> Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com> Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* Fix QDateEdit popup appearance on macJens Bache-Wiig2014-03-041-6/+0
| | | | | | | | | | | | The WS/OS was obviously incorrect and the hack seems not to be needed any more. [ChangeLog][QtWidgets][Mac] Fixed incorrect appearance of QDateEdit with calendarPopup enabled. Task-number: QTBUG-36692 Change-Id: Ic62c9993dc13e783c00fcb56f75d92967eb5074d Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* Fix some typosSergio Ahumada2014-03-031-1/+1
| | | | | | Change-Id: I7dbe938bff5ac3ab50a0197f94bdb2f6c22fbd16 Reviewed-by: Kevin Krammer <kevin.krammer@kdab.com> Reviewed-by: Mitch Curtis <mitch.curtis@digia.com>
* Merge remote-tracking branch 'origin/stable' into devFrederik Gladhorn2014-02-171-3/+8
|\ | | | | | | | | | | | | Conflicts: src/corelib/global/qglobal.h Change-Id: I03d8b6e07135056baaa1d97c3c63fbe8b25583d9
| * Draw more inactive style elements in retina res.Morten Johan Sørvig2014-02-141-3/+8
| | | | | | | | | | | | | | | | | | | | | | | | Update drawColorLessButton() and qt_mac_cg_context() to handle paint devices with a devicePixelRatio greater than one. Task-number: QTBUG-36792 Change-Id: I9d642846b299fc7048bb8e08765b9e1d7ee631fc Reviewed-by: Denis Dzyubenko <denis@ddenis.info> Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* | Promote the scrollbar style animation to qstyleanimation_p.hJ-P Nurmi2014-02-111-12/+8
|/ | | | | | | Makes it possible for QFusionStyle to utilize the same animation. Change-Id: Ifac9eaa3138cf1068439d5b0271a2acce54a3c16 Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
* Mac Style: Fix non-native menubar item spacingGabriel de Dietrich2014-01-221-0/+8
| | | | | | | | | | | Unfortunate consequence from inheriting from Common style instead of Windows style. Also, a font entry missing in QCocoaTheme. Task-number: QTBUG-36224 Change-Id: I560494b1727734671478f70ee1ba800d21c916ca Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
* Mac: remove unified toolbar workarounds.Morten Johan Sørvig2014-01-121-25/+2
| | | | | | | | | | | QMainWindow::unifiedTitleAndToolBarOnMac() will again return true, but the new implementation is much more similar to the cross platform one so these workarounds are not needed. Task-number: QTBUG-34411 Change-Id: Ic95f491af94354776385dc984f1a00c64429a3f0 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* Mac: Update unified toolbar drawing code.Morten Johan Sørvig2014-01-121-3/+37
| | | | | | | | | | Fill the toolbar background with transparent pixels to allow the view background to shine through. Draw a separator line using HITheme. Task-number: QTBUG-34411 Change-Id: I57732564a67a5a9d1eb7fd9038382b2b65be50a4 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* Mac: Update PE_IndicatorToolBarHandle drawing.Morten Johan Sørvig2014-01-111-8/+4
| | | | | | | | | Smaller, rounder, darker toolbar handles. Works especially well in unified toolbar mode. Task-number: QTBUG-34411 Change-Id: I41eafdf0bb1dbbb4ed96d7bd799eb6f53bccbf7d Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* Mac style: Fix pressed tab appearanceGabriel de Dietrich2013-11-251-1/+1
| | | | | Change-Id: Ib2bfc5afcb4d1a9fa20f5b1ec90c4c239a97954e Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
* Mac style: Fix selected tab text color on 10.6Gabriel de Dietrich2013-11-251-3/+4
| | | | | | | | This is a regression introduced by 65b39b3cdcdfe175d80ccf9428168ed51be77fd8. Task-number: QTBUG-34540 Change-Id: I1f78337b13c806f6b6794b769cfe99206445ce7a Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>