summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms/windows
Commit message (Collapse)AuthorAgeFilesLines
* Merge remote-tracking branch 'origin/5.13' into devLiang Qi2019-05-157-97/+253
|\ | | | | | | | | | | | | | | | | Conflicts: src/corelib/global/qfloat16.cpp src/corelib/global/qfloat16.h src/plugins/platforms/windows/qwindowswindow.cpp Change-Id: I0938aaa6a9771f55e48c95ed29f6f5291431b947
| * Merge remote-tracking branch 'origin/5.12' into 5.13Friedemann Kleint2019-05-147-82/+189
| |\ | | | | | | | | | Change-Id: Id3d16035c9692af42e9c1bf512218f3c836ae2eb
| | * Windows QPA: Fix resize loops when moving fixed size windows between screensFriedemann Kleint2019-05-133-23/+44
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Postpone the screen change until the DPI changed event in case a move between screens with different DPI is detected. Task-number: QTBUG-65580 Change-Id: I356f144b243d7d1ce7feabf0434c3f534b903965 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io> Reviewed-by: Andre de la Rocha <andre.rocha@qt.io>
| | * Windows QPA: Fix window frame calculation in multi-monitor setupsFriedemann Kleint2019-05-137-60/+146
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When introducing EnableNonClientDpiScaling() for QTBUG-53255, the window frame calculation was not adapted. That is, window frames were calculated from the style for the primary screen only, causing - minimum size constraints not being calculated correctly for applications on secondary screens when populating the MINMAXINFO structure. - warnings about not being able to apply a geometry when moving fixed size windows across screens. The calculation of the frames for propagating size hints is also no longer required after 3035400f36731c400adb9204b94e9afe346a71b7, which retrieves them from the WM_NCCALCSIZE message; QWindowsWindow::fullFrameMargins() can be used instead. For newly created windows, use the newly added AdjustWindowRectExForDpi() function to calculate the initial frame size. Change QWindowsGeometryHint from a class to a collection of static functions and add overloads to calculate the frame. In checkForScreenChanged(), update the margins until WM_NCCALCSIZE is received. Task-number: QTBUG-67777 Task-number: QTBUG-65580 Task-number: QTBUG-53255 Change-Id: Iff2d382b2b316adec6c1a0622ae8015dba6de371 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io> Reviewed-by: Andre de la Rocha <andre.rocha@qt.io>
| * | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-05-123-17/+66
| |\| | | | | | | | | | Change-Id: I0c00ffe0eabebc919f22d6faa4bf958b288e8fd9
| | * Windows QPA: Improve debug messagesFriedemann Kleint2019-05-093-17/+66
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Include screen and MINMAXINFO values in the message about not being able to set the geometry. Suppress output of some window finding functions unless verbose. Change-Id: Iaaae59ecb302438b3444735067d018c77d2af162 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* | | Merge remote-tracking branch 'origin/5.13' into devLiang Qi2019-05-134-1/+79
|\| | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/tools/qstring.cpp Change-Id: I81dbf90fc936c9bf08197baefa071117bddb1c63
| * | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-05-092-0/+6
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/tools/qlocale_data_p.h (Regenerated by running the scripts in util/local_database/) src/gui/opengl/qopengltextureuploader.cpp Done-With: Edward Welbourne <edward.welbourne@qt.io> Done-With: Allan Sandfeld Jensen <allan.jensen@qt.io> Change-Id: I12df7f066ed0a25eb109f61c4b8d8dea63b683e2
| | * Windows QPA: Fix over-large transparent tooltipsFriedemann Kleint2019-05-071-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Setting transparency (WS_EX_LAYERED) causes a WM_PAINT to be sent to the invisible windows, which causes a resize to the default size (640x480) to be sent from QGuiApplicationPrivate::processExposeEvent(). Suppress these messages. Fixes: QTBUG-75455 Change-Id: Idc540aa7f9bf0047e78ec7c27db260940483f7c4 Reviewed-by: Andre de la Rocha <andre.rocha@qt.io>
| | * Fix generation of Leave events when using tablet devicesDmitry Kazakov2019-05-071-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When both mouse and tablet events are handled by QWindowsPointerHandler, m_currentWindow variable is shared among the two event streams, therefore each stream should ensure it does equivalent operations, when changing it. Here we should subscribe to the Leave events, when we emit Enter event from the inside of the tablet events flow. Without whis subscription, the cursor may stuck in "resize" state when crossing the window's frame multiple times. Change-Id: I88df4a42ae86243e10ecd4a4cedf87639c96d169 Reviewed-by: Andre de la Rocha <andre.rocha@qt.io>
| * | Fetch stylus button remapping from WinTab driverDmitry Kazakov2019-05-082-1/+73
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The user can remap the stylus buttons using tablet driver settings. This information is available to the application via CSR_SYSBTNMAP WinTab feature. We should fetch this information every time the stylus gets into proximity, because the user can change these settings on the fly. Change-Id: Idc839905c3485179d782814f78fa862fd4a99127 Reviewed-by: Andre de la Rocha <andre.rocha@qt.io> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | | Migrate Windows system libs to external dependenciesJoerg Bornemann2019-05-083-8/+14
| | | | | | | | | | | | | | | | | | Started-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io> Change-Id: I211ce3252b836894aeeac1c85eb316d9596bca57 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* | | Return QScreen's HMONITOR handle via QPlatformNativeInterfaceDmitry Kazakov2019-05-074-0/+24
| | | | | | | | | | | | | | | | | | | | | | | | It is needed to be able to fetch extra information about the display via DXGI interface. Change-Id: Id83982eb07ade157719e430d0abcc2613409a343 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | | Prefix textstream operators with Qt::Lars Knoll2019-05-0214-52/+52
| | | | | | | | | | | | | | | | | | | | | As the non prefixed variants are deprecated Change-Id: I2ba09d71b9cea5203b54297a3f2332e6d44fedcf Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
* | | Merge remote-tracking branch 'origin/5.13' into devQt Forward Merge Bot2019-04-291-10/+12
|\| | | | | | | | | | | Change-Id: Ic712e8a84b01b212bb1121d7a2c9b85e0d2da9da
| * | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-04-281-10/+12
| |\| | | | | | | | | | Change-Id: Ibce9bfef928ce39070183c488ce86ae32e5ea705
| | * Windows QPA: Fix blank Cursor on secondary displaySimeon Kuran2019-04-271-10/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | CreateCursor only works with standard sizes (32, ...) depending on the display hardware. No longer apply the scale factor for the blank cursor, because it might lead to unsupported cursor sizes resulting in random pixels. Change-Id: I48d84bd913d2dd8f62129126c9a41e58ee2cbcae Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | | Merge remote-tracking branch 'origin/5.13' into devLiang Qi2019-04-247-29/+94
|\| | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/gui/util/qshaderformat.cpp src/gui/util/qshaderformat_p.h src/widgets/graphicsview/qgraphicsitem_p.h Change-Id: Idafd88eb9a0a15b4af29f6143d009c1ec8ceecca
| * | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-04-243-26/+51
| |\| | | | | | | | | | Change-Id: I26da00aa71b0f0b91c9bfb4a9e8550345ee62875
| | * Windows QPA: fix media keys losing autorepeat/keycode informationAndre de la Rocha2019-04-181-12/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | For WM_APPCOMMAND messages that also trigger WM_KEYDOWN/WM_KEYUP, let the latter messages be handled, instead of stripping them and synthesizing a press/release from the command code, in order to get the correct scan codes and autorepeat info. Fixes: QTBUG-73879 Change-Id: I936cd76be87a76dc6b6223eeb246e4e7aee3a4ac Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
| | * Merge remote-tracking branch 'origin/5.12.3' into 5.12Qt Forward Merge Bot2019-04-171-8/+27
| | |\ | | | | | | | | | | | | Change-Id: I2816cb8a3cbc4a2cf5ca5f333a1fddc245b3c06a
| | | * Fix QTabletEvent::uniqueId() when Qt uses WinInkv5.12.3Dmitry Kazakov2019-04-091-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A new 'pointerId' is assigned to the stylus every time it enters tablet's proximity. But applications expect this ID be constant, at least during one application run. Therefore, it needs to use 'sourceDevice' instead. Basically, WinInk doesn't have an ability to distinguich two different styluses connected to the same tablet. We cannot do anything about it, it is supported only in WinTab. Task-number: QTBUG-74700 Change-Id: I8328f1e5102b037b370082e69e965ab68b487882 Reviewed-by: Andre de la Rocha <andre.rocha@qt.io>
| | | * Windows QPA: Fix mouse button reported in non-client eventsAndre de la Rocha2019-04-081-2/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The current mouse buttons state was being retrieved from WPARAM for all mouse messages. However, for non-client messages this parameter contains unrelated information, which resulted in non-client events reporting incorrect button state. Changing it to retrieve state using GetAsyncKeyState() for non-client messages, like in the legacy mouse handler implementation. Fixes: QTBUG-74649 Change-Id: Ia246164208707072e584dd521697e9d31d3e65ad Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
| | * | Windows QPA: Fix custom drop formats being ignoredAndre de la Rocha2019-04-161-6/+16
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changes QWindowsDropDataObject to only ignore non-CF_HDROP formats when the drop contains only "text/uri-list" mime data, and the URIs are for local files, to avoid messing with custom formats set by the developer, while still fixing the case reported in QTBUG-62662. Fixes: QTBUG-74232 Change-Id: I946ced222377716876d0aea54b3eb05d40e7fa44 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
| * | | Merge remote-tracking branch 'origin/5.12' into 5.13Liang Qi2019-04-164-3/+43
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/tools/qlocale.qdoc tests/auto/corelib/io/qfileinfo/tst_qfileinfo.cpp Done-with: Edward Welbourne <edward.welbourne@qt.io> Done-with: Volker Hilsheimer <volker.hilsheimer@qt.io> Change-Id: I88e0757b2d020f0a244714c87844631df4b3fd13
| | * | Windows QPA: Fix QComboBox accessibility with screen readersAndre de la Rocha2019-04-123-2/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Screen readers like NVDA and Narrator were not reading the contents of a QComboBox when changing its value using the keyboard, without expanding it, due to missing UI Automation notifications in this case. This change should also help in other cases where updated string values were not notified to screen readers. Fixes: QTBUG-75066 Change-Id: Id7f488380aec5ad27fd11b3cf854d44ab1b28688 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
| | * | Windows QPA: Fix Drag and Drop of images onto MS PowerPointFriedemann Kleint2019-04-091-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Use the PNG format only for transparent images. Fixes: QTBUG-64322 Change-Id: I5e02132ca446876e20fcf46f2ef8daa599e85e71 Reviewed-by: Andre de la Rocha <andre.rocha@qt.io>
* | | | Merge remote-tracking branch 'origin/5.13' into devLiang Qi2019-04-111-12/+27
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/widgets/styles/qstyle_p.h Change-Id: I0e6e856bd6628da1135b3ba674dddffabbeb5c09
| * | | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-04-101-12/+27
| |\| | | | | | | | | | | | | | Change-Id: I44eda44bf424fdcffab048a2534905d6162e5559
| | * | Windows QPA/File dialog: Pass up http[s] URLsFriedemann Kleint2019-04-081-12/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The native Windows allows for typing in http[s] URLs directly (without checking existence). Pass these up. Fixes: QTBUG-71785 Change-Id: I60237bab596ca3f52e6f513f17544ff94e9080da Reviewed-by: Andre de la Rocha <andre.rocha@qt.io> Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
* | | | Merge remote-tracking branch 'origin/5.13' into devLiang Qi2019-04-101-25/+63
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: mkspecs/win32-clang-msvc/qmake.conf src/gui/image/qpnghandler.cpp Change-Id: Ied79d02912ffb3a307a99483df7db08c7f9d0cd8
| * | | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-04-061-25/+63
| |\| | | | | | | | | | | | | | Change-Id: Iec860bb703f983b7438e67c695b9c454e72b3e0f
| | * | Windows QPA/File dialog: Refactor code copying non-file shell itemsFriedemann Kleint2019-04-051-25/+63
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove the canCopy() check which is not required and pass up the error message. Remove special characters and use the base name of the display name which can be an URL. Task-number: QTBUG-71785 Change-Id: I22966cb8d1f5bca0bbca71cf3ebe66e4ede1a747 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io> Reviewed-by: Andre de la Rocha <andre.rocha@qt.io>
* | | | Merge remote-tracking branch 'origin/5.13' into devQt Forward Merge Bot2019-04-061-1/+3
|\| | | | | | | | | | | | | | | Change-Id: Ib7c4fc52915b5e6c72b9aa262fb59f2a041dccd7
| * | | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-04-051-1/+3
| |\| | | | | | | | | | | | | | Change-Id: I010a6322d12e038fdce247a58dfb05e204c2ff3b
| | * | Windows QPA/File dialog: Avoid UI hangs caused by empty resultsFriedemann Kleint2019-04-041-1/+3
| | |/ | | | | | | | | | | | | | | | | | | | | | | | | Typing in invalid URLs results in empty result lists. Emit rejected() in this case. Task-number: QTBUG-71785 Change-Id: Ia257b85a5c4370227f753752f6a473bbb3a054be Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
* | | Windows code: Replace deprecated QVariant APIFriedemann Kleint2019-04-052-2/+2
| | | | | | | | | | | | | | | | | | Task-number: QTBUG-74043 Change-Id: I6f5f47b74830597eec74e2582e24d2d7dd235a80 Reviewed-by: Christian Ehrlicher <ch.ehrlicher@gmx.de>
* | | Merge "Merge remote-tracking branch 'origin/5.13' into dev" into ↵Qt Forward Merge Bot2019-04-043-13/+11
|\ \ \ | | | | | | | | | | | | refs/staging/dev
| * | | Merge remote-tracking branch 'origin/5.13' into devLiang Qi2019-03-311-1/+2
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/configure.json Change-Id: I93ac67f3bf4844bc7c691183e94bceb922b7b919
| | * | Merge remote-tracking branch 'origin/5.12' into 5.13Friedemann Kleint2019-03-261-1/+2
| | |\| | | | | | | | | | | | | Change-Id: I71cc71881fb638e207d83a8733bad8f267701c0f
| | | * Windows: Fix tooltip flicker on GL surfacesFriedemann Kleint2019-03-211-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QPlatformWindow::initialGeometry() would assign a default height to the initial geometry of the QRollEffectClassWindow since it has height of 0. This causes the obtained geometry to not match and subsequently a geometry change being sent synchronously. Introduce a new flag QWindowPrivate::resizeAutomatic similar to the existing QWindowPrivate::positionAutomatic to prevent assigning a default size and pass through the geometry as is where required. Fixes: QTBUG-74176 Change-Id: I70c66490838a2c4dfe200ec86094d28bd984dd03 Reviewed-by: Kati Kankaanpaa <kati.kankaanpaa@qt.io> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@qt.io>
| * | | Merge remote-tracking branch 'origin/5.13' into devFriedemann Kleint2019-03-263-12/+9
| |\| | | | | | | | | | | | | | Change-Id: I38389a69411f4549fed432f1181dbe23398b34a2
| | * | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-03-203-12/+9
| | |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/gui/kernel/qplatformintegration.cpp src/gui/kernel/qplatformintegration.h src/plugins/platforms/wasm/qwasmintegration.cpp src/plugins/platforms/xcb/qxcbconnection_screens.cpp Change-Id: I15063d42e9a1e226d9d2d2d372f75141b84c5c1b
| | | * Move screen maintenance functions from QPlatformIntegration to QWSITor Arne Vestbø2019-03-192-7/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QWindowSystemInterface is the de facto API for any plumbing going from the platform plugin to QtGui. Having the functions as protected members of QPlatformIntegration was idiosyncratic, and resulted in awkward workarounds to be able to call the functions from outside of the QPlatformIntegration subclass. The functions in QPlatformIntegration have been left in, but deprecated so that platform plugins outside of qtbase have a chance to move over to the new QWSI API before they are removed. Change-Id: I327fec460db6b0faaf0ae2a151c20aa30dbe7182 Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
| | | * Windows QPA: Make the expected screen be in sync with the geometry changesAndy Shaw2019-03-191-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When the window moves to a new screen then we should ensure the screen is updated at that point with the new size so it can account for any scaling changes. This reverts f1ec81b543fe1d5090acff298e24faf10a7bac63. Change-Id: I2be3aab677c4677841a07beaaf373f498483b320 Fixes: QTBUG-72504 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
* | | | Remove remaining Q_DECL_NOEXCEPT/Q_DECL_NOTHROW usageAllan Sandfeld Jensen2019-04-041-1/+1
|/ / / | | | | | | | | | | | | Change-Id: I91ac9e714a465cab226b211812aa46e8fe5ff2ab Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* / / Widen out parameter "result" of the native event filters for Qt 6Friedemann Kleint2019-03-221-0/+8
|/ / | | | | | | | | | | | | | | | | LRESULT on Windows 64 is a 64bit type, adapt filter functions of QAbstractNativeEventFilter and QAbstractEventDispatcher accordingly. Fixes: QTBUG-72968 Change-Id: Ie53193e355f0b8e9bd59fa377f43e2b4664a2ded Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-03-156-43/+109
|\| | | | | | | Change-Id: I2bf3b4ceb79364330eae4cbf3cdee9a82d1be46d
| * Windows QPA: only calculate invisible margins when window has a frameChristian Andersen2019-03-142-2/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In commit ec97be5585 an invisible frame calculation was added for Windows 10 that fixes QWidget::move(0,0) for main windows and dialogs. But because e.g. Qt::ToolTip windows do not have a window frame, the invisible margin calculation causes them to pop-up in the wrong position (off by a few pixels). [ChangeLog][Windows] Fixed QToolTip pop-ups and QComboBox animation pop-ups being off by a few pixels on Windows 10. Fixes: QTBUG-74062 Change-Id: I218e8409a250a8b81ecd1d409b597ebd01fb255f Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
| * Windows QPA: Output all adapters in diagnostics used by qtdiagFriedemann Kleint2019-03-144-41/+104
| | | | | | | | | | | | | | | | | | | | | | | | Split up the code detecting the GPUs into small helpers. Add a QDirect3D9Handle class providing Direct3D9 functionality, add GpuDescription::detectAll() and add a QVariantList "gpuList" property to the native interface. Task-number: QTBUG-50371 Task-number: QTBUG-65882 Change-Id: I8673542d327837babc2ad8f507da76e8ff5524ea Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>