summaryrefslogtreecommitdiffstats
path: root/src/widgets
Commit message (Collapse)AuthorAgeFilesLines
* Merge remote-tracking branch 'origin/5.14' into 5.15Qt Forward Merge Bot2019-10-182-0/+2
|\ | | | | | | Change-Id: I4fbbf100b673ab100997dbf2f42bf195dc3c050f
| * Set icon on the select-all action in the text edit context menu tooVolker Krause2019-10-172-0/+2
| | | | | | | | | | | | | | | | | | Makes this consistent with the rest of the actions here, and avoids dirty hacks like KIconTheme::assignIconsToContextMenu. Change-Id: I749f4d5f67efdbf595a52185dd507de5f87f6487 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* | Generate metatypes.json for QtCore, QtGui, and QtWidgetsUlf Hermann2019-10-171-0/+2
| | | | | | | | | | | | | | | | These libraries contain types which are exposed to QML from qtdeclarative. Change-Id: Ie0edaef94fcb40074b6f6b2ea1a1c3a77ed3e9a9 Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
* | Merge remote-tracking branch 'origin/5.14' into 5.15Qt Forward Merge Bot2019-10-165-2/+15
|\| | | | | | | Change-Id: Ifd83db69416230175ddc3161f640b612755018fc
| * Prepare for deprecating the QDesktopWidgetSona Kurazyan2019-10-151-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | QDesktopWidget is marked as obsolete in docs, but it is not yet completely deprecated, some of its methods are still in use. Replace uses of the following methods marked as obsolete: - QDesktopWidget::screenNumber(QWidget*) -> QWidget::screen() - QDesktopWidget::screenGeometry(QWidget*) -> QWidget::screen()->geometry() - QDesktopWidget::availableGeometry(QWidget*) -> QWidget::screen()->availableGeometry() Task-number: QTBUG-76491 Change-Id: I2cca30f2b4caa6e6848e8190e09f959d2c272f33 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
| * QtWidgets: Suppress QEvent::WindowActivate when minimizedFriedemann Kleint2019-10-141-0/+2
| | | | | | | | | | | | | | | | | | | | Prevent call to activateWindow() for minimized windows in QWidget::setWindowState() by clearing the flag. Fixes: QTBUG-46763 Change-Id: I40389d0906438ffe251fc79f18a523ecb53edb1b Reviewed-by: Andy Shaw <andy.shaw@qt.io> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
| * Fix the size calculation of QHeaderView when stylesheet is usedSona Kurazyan2019-10-141-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | When calculating the header section size based on its contents when a stylesheet is used, the size hints from the stylesheet are used. In case if the stylesheet specifies only one of the sizes, the other is set to -1. Because of this the actual content size is ignored. The solution is to calculate the size based on the application style, in case if it's not specified in the stylesheet. Fixes: QTBUG-75615 Change-Id: I3453fa623d75b6b32832edf753de6e3e4e7f5a22 Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
| * Remove usages of deprecated APIs of QDesktopWidgetSona Kurazyan2019-10-132-1/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Replaced the usages of the following deprecated APIs: * QDesktopWidget::screenCount() -> QGuiApplication::screens().size() * QDesktopWidget::screenGeometry(int) -> QGuiApplication::screens().at() * QDesktopWidget::screenNumber(QPoint) -> QGuiApplication::screenAt(QPoint) - Added notes for the QWidget *QDesktopWidget::screen(int), which currently has no replacement. - Fixed the tests to build conditionally, only when these APIs are enabled. Task-number: QTBUG-76491 Change-Id: I2fdec96d0a6a4fc782c53549b05a5556412b8305 Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* | Merge remote-tracking branch 'origin/5.14' into 5.15Qt Forward Merge Bot2019-10-137-17/+33
|\| | | | | | | Change-Id: I9953c1ca16862184c2373027e946c482ce8e6f0e
| * QGroupBox: always disable children in a checkable, unchecked groupboxVolker Hilsheimer2019-10-111-2/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The childEvent handler sets the enabled property of children as they are added to the groupbox, but applications might later enable children and check/uncheck the groupbox's checkbox in undefined order. In that case, we would end up with enabled children inside a conceptually disabled groupbox (the groupbox's checkbox represents the logical "disabled" state), which breaks documented QWidget::enabled rules. To make sure that all children are disabled as per the state of the groupbox, we need to run that logic once the UI has been set up, and before it becomes visible. This is what polishing is for, so listen for that event in addition and handle it the same way as adding (which duplicates things, but keeps existing code that might depend on things being updated as they are added working). Adds the case to the existing enabledChildPropagation test case. [ChangeLog][QWidget][QGroupBox] Always disable children of a checkable, unchecked group box before showing. Change-Id: I978bd27b6f1a3f54ec745faeea529a98d0d93619 Fixes: QTBUG-25938 Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| * Fusion Style: Use high-dpi pixmapsMorten Johan Sørvig2019-10-111-5/+11
| | | | | | | | | | | | | | | | | | Pass the QWindow as context to QIcon::pixmap(), which enables it to return high-dpi pixmaps when needed. Fixes: QTBUG-74100 Change-Id: I4556f0a98df8b6ba65376778379a03eb8c470d00 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
| * QAbstractScrollArea: when used as a popup, apply regular popup behaviorVolker Hilsheimer2019-10-101-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | QWidget::mousePressEvent is documented to implement the closing of popups if the widget is a popup. QAbstractScrollArea is one of the QWidget subclasses that might be used as a popup as well, so instead of just ignoring mousePressEvents, pass the event on to the QWidget implementation for regular popup handling. Change-Id: I05f77a334945f3c167f729f30bc022599230379b Fixes: QTBUG-60885 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io> Reviewed-by: Paul Olav Tvete <paul.tvete@qt.io>
| * Make QTextBlockFormat::MarkerType an enum classShawn Rutledge2019-10-102-5/+5
| | | | | | | | | | | | | | This came up during API review. Change-Id: I9198e1eb96db0c21e46a226a032919bb62d3ca66 Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
| * Merge "Merge remote-tracking branch 'origin/5.13' into 5.14"Liang Qi2019-10-102-3/+6
| |\
| | * Merge remote-tracking branch 'origin/5.13' into 5.14Liang Qi2019-10-102-3/+6
| | |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/plugins/platforms/xcb/qxcbscreen.h src/src.pro Change-Id: I4e1981e69a1ddcbe4078ec6ab2a64b0da6a445de
| | | * Fix text not rendering properly after setAlignment callKari Hormi2019-10-081-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Sometimes when setAlignment is called, the text stops rendering correctly at some point. Adding relayoutDocument call to setAlignment fixes the problem. Fixes: QTBUG-78728 Change-Id: Iab1cf161f0c8d700804448733338c813b5bf9762 Reviewed-by: Ville Voutilainen <ville.voutilainen@qt.io>
| | | * Add check for global share context for QOpenGLWidget initializeMichal Klocek2019-10-081-3/+5
| | | | | | | | | | | | | | | | | | | | | | | | Fixes: QTBUG-78863 Change-Id: I678f66a2057fb9c98863e19eb09042306e72f68a Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
| * | | QWidget: Answer question raised in fixme commentFriedemann Kleint2019-10-101-1/+1
| |/ / | | | | | | | | | | | | | | | | | | | | | Add a comment for fixme comment added in f1268d137ea7839b320c84314d0c2265f5a629ba. Change-Id: I08cd104442b13925be2aa5a48e64e391c9903099 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* | | Merge remote-tracking branch 'origin/5.14' into 5.15Qt Forward Merge Bot2019-10-101-3/+5
|\| | | | | | | | | | | Change-Id: Iadeca81f499d6b19e86ceae1edd7960db2575e90
| * | QWidget: document that a widget might only get a mouseDoubleClickEventVolker Hilsheimer2019-10-081-3/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If two widgets are on top of each other, and the top widget disappears in response to a press or release that is followed by a double click, then the widget at the bottom only receives the double click event. This is a sequence of events that the application developer that choses to build such a UI has to take care of. Change-Id: I440efd2cac01631de8995abf9a9fb76815de8f9a Fixes: QTBUG-61173 Reviewed-by: Paul Wicking <paul.wicking@qt.io>
* | | Merge remote-tracking branch 'origin/5.14' into 5.15Qt Forward Merge Bot2019-10-053-6/+10
|\| | | | | | | | | | | Change-Id: I554a2762890391b3b6013c8b82211a8386a4ced8
| * | Merge remote-tracking branch 'origin/5.13' into 5.14Qt Forward Merge Bot2019-10-043-6/+10
| |\| | | | | | | | | | Change-Id: I31c1c469c00016f1bd21ecfab39794df372e56f2
| | * QTreeWidget: Don't assume the selected indexes include the first columnAndy Shaw2019-10-031-5/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If the first column is hidden in a QTreeWidget then when doing a drag then the selected indexes will not include any that have a column of 0. Therefore it has to account for this use std::unique to ensure that there is only one instance of the selected items represented by the selected indexes. Fixes: QTBUG-35511 Change-Id: I39dff596959f30db7378ff946735ee2866778524 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
| | * Remove the unregistered recognizer from the main listAndy Shaw2019-10-031-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This amends 1320b2f64412f0d86bd09c66c22df845e13a94a1 to keep the behavior of removing from the main list but without re-introducing the memory leak. Fixes: QTBUG-77770 Change-Id: I91fa6cb71fab8d60baa35417fdb34322af11dbbb Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
| | * Always update the pressed position when pressing on an itemAndy Shaw2019-10-021-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If there is an item already selected then the pressed position needs to be updated regardless when selecting a new one even if it is not made current as this will be used to determine the drag distance. Otherwise it will start a drag within one pixel of moving due to the fact it is doing it relative to the first item to be pressed rather than the last. Fixes: QTBUG-78797 Change-Id: I853041b278b2e92ccf20660f7ced945fef72527a Reviewed-by: Samuel Gaist <samuel.gaist@idiap.ch> Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
* | | Merge remote-tracking branch 'origin/5.14' into 5.15Qt Forward Merge Bot2019-10-041-0/+6
|\| | | | | | | | | | | Change-Id: I43393cf47675fd6c14972df1221986335c6f493c
| * | Quiet several more warnings about QWheelEvent deprecationsShawn Rutledge2019-10-021-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We want to ensure that the qt4D and qt4O members are still initialized the same way whenever deprecated constructors are used; and we want to be able to verify it using qDebug. So we merely suppress these warnings. Change-Id: Ic2e5f0dd6feeabe81f06f9c31693c550ac0781e3 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | | QTableWidget: Fix -Wdeprecated-copy warningAlbert Astals Cid2019-10-032-5/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In file included from ../../include/QtCore/qlist.h:1, from ../../include/QtCore/../../../qtbase_dev_de_verdad/src/corelib/kernel/qobject.h:49, from ../../include/QtCore/qobject.h:1, from ../../include/QtCore/../../../qtbase_dev_de_verdad/src/corelib/kernel/qcoreapplication.h:46, from ../../include/QtCore/qcoreapplication.h:1, from /src/widgets/kernel/../../gui/kernel/../../corelib/global/qt_pch.h:66, from /src/widgets/kernel/../../gui/kernel/qt_gui_pch.h:48, from /src/widgets/kernel/qt_widgets_pch.h:48: ../../include/QtCore/../../../qtbase_dev_de_verdad/src/corelib/tools/qlist.h: In instantiation of ‘void QList<T>::node_construct(QList<T>::Node*, const T&) [with T = QTableWidgetSelectionRange]’: ../../include/QtCore/../../../qtbase_dev_de_verdad/src/corelib/tools/qlist.h:614:13: required from ‘void QList<T>::append(const T&) [with T = QTableWidgetSelectionRange]’ /src/widgets/itemviews/qtablewidget.cpp:2416:71: required from here ../../include/QtCore/../../../qtbase_dev_de_verdad/src/corelib/tools/qlist.h:471:35: warning: implicitly-declared ‘constexpr QTableWidgetSelectionRange& QTableWidgetSelectionRange::operator=(const QTableWidgetSelectionRange&)’ is deprecated [-Wdeprecated-copy] 471 | else *reinterpret_cast<T*>(n) = t; | ~~~~~~~~~~~~~~~~~~~~~~~~~^~~ In file included from /src/widgets/itemviews/qtablewidget.cpp:40: /src/widgets/itemviews/qtablewidget.h:52:24: note: because ‘QTableWidgetSelectionRange’ has user-provided ‘QTableWidgetSelectionRange::QTableWidgetSelectionRange(const QTableWidgetSelectionRange&)’ 52 | class Q_WIDGETS_EXPORT QTableWidgetSelectionRange | ^~~~~~~~~~~~~~~~~~~~~~~~~~ Change-Id: I72ca2dbf1d46a0f51a6fc7b7df80c79f937657de Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
* | | QItemViews: hide ToolTip/What's this when cell has no data for itChristian Ehrlicher2019-10-031-20/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A QToolTip/QWhatsThis was not hidden when the cursor moved to a cell which does not return valid data for Qt::ToolTip/WhatsThisRole or when the index is not valid. Therefore a wrong information was shown e.g. when the cursor moved from a cell with a tooltip to one without. Fix it by passing an empty string to QToolTip/QWhatsThis::showText(). This syncs the behavior with QGraphicsScene::helpEvent(). Fixes: QTBUG-78722 Change-Id: Ie99fe3b1d35d2f5be41dd65e2fe3173b0cc551b2 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
* | | Merge remote-tracking branch 'origin/5.14' into 5.15Qt Forward Merge Bot2019-10-013-106/+77
|\| | | | | | | | | | | Change-Id: I77ba01f09b3dbcaf13cb265a70d9da661c32a61f
| * | Merge remote-tracking branch 'origin/5.13' into 5.14Liang Qi2019-09-302-106/+76
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/global/qrandom.cpp src/corelib/io/qfileinfo.cpp src/corelib/kernel/qeventdispatcher_win.cpp src/corelib/kernel/qeventdispatcher_win_p.h src/gui/text/qfontdatabase.cpp src/platformsupport/fontdatabases/mac/qcoretextfontdatabase.mm src/plugins/platforms/windows/qwindowsglcontext.cpp src/testlib/qtestcase.cpp Done-With: Tor Arne Vestbø <tor.arne.vestbo@qt.io> Done-With: Edward Welbourne <edward.welbourne@qt.io> Change-Id: I4893212471aa24be804c989a581810e2f714545c
| | * QWidget::setFocusProxy: adjust focus widget properlyDavid Faure2019-09-251-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | My commit 3e7463411e adjusted the focus widget by setting QApplicationPrivate::focus_widget directly, while there is a method for doing this properly, including setFocus_sys() and emitting signals. Fixes: QTBUG-77364 Change-Id: I218acf7a9de39173d282ced46def4f65594f80b4 Reviewed-by: Florian Bruhin <qt-project.org@the-compiler.org> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io> Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
| | * QWizard/Aerostyle: Fix "&Next" shortcutFriedemann Kleint2019-09-251-4/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The fix for QTBUG-35203 set the Alt+Right shortcut on the next button, clobbering the Alt+N shortcut from parsing the text (similar for other languages). Add a separate shortcut for Alt+Right since a button may not have several shortcuts. Amends 6714196f45fbae755b26a4b2406a7bbe066084dc. Fixes: QTBUG-78604 Change-Id: I1367da739c35fbd011d11f850c9bc3915113c644 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
| | * QWizard: Use member initialization in private classesFriedemann Kleint2019-09-241-101/+57
| | | | | | | | | | | | | | | | | | | | | | | | Remove superfluous constructors. Task-number: QTBUG-78604 Change-Id: I8a422cfeaaedf89ce310e06d5db80907cd1102d4 Reviewed-by: Jesus Fernandez <jsfdez@gmail.com>
| * | QCommonStyle: Add SP_DialogNoButton case in standardIconKai Uwe Broulik2019-09-281-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | It is present in standardPixmap but missing from standardIcon resulting in QMessageBox using the fallback PNG provided by Qt for the "No" button. Change-Id: If4f14c7de26eb32277cd19a7be75360dba4f4e29 Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
* | | Merge remote-tracking branch 'origin/5.14' into 5.15Qt Forward Merge Bot2019-09-242-1/+6
|\| | | | | | | | | | | Change-Id: I9ec6345a38ada55219f3cdfb6bd0d6e9169fe880
| * | QAbstractSpinBox css: properly honor spincontrol-disable-on-boundsChristian Ehrlicher2019-09-231-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The css style 'spincontrol-disable-on-bounds' was not properly honored within QAbstractSpinBox::initStyleOption() because the affected widget was not passed to QStyle::styleHint(). Therefore QStyleSheetStyle did not find the correct render rule. Fix it by passing 'this' as third argument to QStyle::styleHint(). Fixes: QTBUG-18008 Change-Id: Iabcebf0b83143f45309b4e7066bccb8d20bd0419 Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
| * | Merge remote-tracking branch 'origin/5.13' into 5.14Liang Qi2019-09-231-0/+5
| |\| | | | | | | | | | | | | | | | | | | Conflicts: src/widgets/styles/qstylesheetstyle.cpp Change-Id: If11da7799075cc2d5768da5603c5fc46773c4eae
| | * Ensure all children of a widget get updated when a stylesheet changesAndy Shaw2019-09-211-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | Before, only the direct children would get an update when the stylesheet changed, any children below that would be unchanged. Fixes: QTBUG-77006 Change-Id: Id668eaae74a8289d78d66644f077e6a3302960cd Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
* | | Merge remote-tracking branch 'origin/5.14' into 5.15Qt Forward Merge Bot2019-09-211-3/+7
|\| | | | | | | | | | | Change-Id: Ib615dbfd783c5a3cf0f130ff82965382ce5cfb5a
| * | Merge remote-tracking branch 'origin/5.13' into 5.14Joerg Bornemann2019-09-201-3/+7
| |\| | | | | | | | | | | | | | | | | | | | | | Conflicts: qmake/generators/makefile.cpp qmake/generators/makefile.h Change-Id: I4c2deac4f6376c85f5e4fe7fb0ccc9ab9a013cd7
| | * QWizard/AeroStyle: Fix condition introduced by previous fixFriedemann Kleint2019-09-191-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Set the variables within the condition introduced by 6c0e1dba403ce65285e089bf281319de36d29235, as otherwise, the code might not be executed. Task-number: QTBUG-78300 Change-Id: Ia83db6fce197ebf16783f3b0c6d6fad7ebd2ba52 Reviewed-by: André de la Rocha <andre.rocha@qt.io> Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
| | * QWizard/AeroStyle: Fix crash when Qt::AA_NativeWindows is setFriedemann Kleint2019-09-181-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | Prevent recursive platform window creation from the events received during window creation (WM_POSCHANGING, etc). Fixes: QTBUG-78300 Change-Id: Ie2bb4308af645c30e556666589e2dd08f14d4035 Reviewed-by: André de la Rocha <andre.rocha@qt.io>
* | | Merge remote-tracking branch 'origin/5.14' into 5.15Qt Forward Merge Bot2019-09-192-9/+13
|\| | | | | | | | | | | Change-Id: I46ec05ade1c84e61f7f45562a218aa9ff55e2975
| * | QStyleSheet: Resolve the rule font before it is usedThorbjørn Lund Martsum2019-09-181-8/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The styleSheet font cannot know about e.g dpi or other settings (e.g from the current screen) so we should resolve font settings from the original font. This patch ensures that the stylesheet font is resolved with a relevant font before it is used. This likely fixes many dual/triple screen issues. [ChangeLog][QtWidgets][QStyle] Style sheets now only use the part of the stylesheet font that it knows about. The remaining will be resolved/inherited from the context. Fixes: QTBUG-77502 Change-Id: I3b1f821e1be9707506a6c1d1e93f76eeac4007e0 Reviewed-by: Morten Kristensen <me@mortens.dev> Reviewed-by: David Faure <david.faure@kdab.com> Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de> Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io> (cherry picked from commit b68ade8282274c2d4ee1e4f861d34ea0655c1eab) Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
| * | QGraphicsScene: register ItemIndexMethod enum for propertyFabian Kosmale2019-09-181-1/+1
| | | | | | | | | | | | | | | | | | Fixes: QTBUG-57903 Change-Id: I2b2725bceb5189dd21102bbacb10e9775740cf5d Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | | Add QScreen::virtualSiblingAt() and use it in QMenubarPrivate::popupActionShawn Rutledge2019-09-191-9/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QGuiApplication::screenAt() is documented "If the point maps to more than one set of virtual siblings, the first match is returned." But in many cases it's possible to start from a known screen and consider only its siblings, as when deciding where to open a QMenu from a QMenuBar: the QMenuBar is already shown on some screen(s), so the QMenu must be shown on a sibling from that set. This function should be useful in other such cases too, hence it might as well be public API. Task-number: QTBUG-76162 Change-Id: I83c74b40eb53f56fb285a6074a3dc2c0ea9c570b Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io> Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
* | | Merge remote-tracking branch 'origin/5.14' into 5.15Qt Forward Merge Bot2019-09-172-19/+15
|\| | | | | | | | | | | Change-Id: I4d7f0e35f4a6ccb6d5494f947fd82fc276feadd3
| * | Windows style: Fix size of controls in multimonitor-setups with scaling disabledFriedemann Kleint2019-09-161-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The function calculating a correction for the size of windows metrics depending on screen would bail out when high DPI scaling was disabled. This is wrong since the correction is also needed in that case, delete the clause. Task-number: QTBUG-64890 Change-Id: Idef22e18fc616a211ccac48400490fc52393a338 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
| * | Brush up the Windows stylesFriedemann Kleint2019-09-162-17/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - use range-based for loops where possible - use nullptr - use member initialization - remove a lot of C-style casts - use override - fix some signedness warnings - add some missing break statements Task-number: QTBUG-76493 Change-Id: Ica6ed65ec29e958406e54d816b8a679ed81bd177 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>