summaryrefslogtreecommitdiffstats
path: root/src/plugins
Commit message (Collapse)AuthorAgeFilesLines
* Add a platform function to enable setting the touch flags on WindowsAndy Shaw2015-01-054-10/+34
| | | | | | | | | This makes it possible for the flags that RegisterTouchWindow takes to be specified after the window has been created. Task-number: QTBUG-41433 Change-Id: I166143875ef54ab6a249cffb31d017845a694a01 Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
* Merge "Merge remote-tracking branch 'origin/5.4' into dev" into refs/staging/devSimon Hausmann2014-12-306-17/+14
|\
| * Merge remote-tracking branch 'origin/5.4' into devFrederik Gladhorn2014-12-296-17/+14
| |\ | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/tools/qbytearray.cpp src/gui/kernel/qplatformsystemtrayicon.cpp src/gui/kernel/qplatformsystemtrayicon.h src/plugins/platforms/xcb/xcb-plugin.pro Change-Id: I00355d3908b678af8a61c38f9e814a63df808c79
| | * Fix win32-g++ build due to -WerrorSérgio Martins2014-12-261-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | qwindowsprintdevice.cpp:182:85: error: comparison between signed and unsigned integer expressions [-Werror=sign-compare] && DeviceCapabilities((LPWSTR)m_id.utf16(), NULL, DC_PAPERSIZE, NULL, NULL) == paperCount MinGW DeviceCapabilities is returning an int, although microsoft documents it as returning DWORD. Change-Id: I3acd76dde0b8b83f8a785ec84e3413115c847cb2 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| | * Revert "OS X: rename special menu items instead of duplicating"Timur Pocheptsov2014-12-222-14/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts commit 8c538d10da618add00aba1acbc8d8dc2f24445b4. This patch, unfortunately, do not combine well with another problematic code producing, as a result, a serious regression. While the proper/better fix in Cocoa menu not found, I'm reverting this patch. Change-Id: I1ff03dbe12805da447cb3cfe3e2f231528bf1a16 Task-number: QTBUG-43471 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>
| | * Remove direct linkage to dbus and qdbusSimon Hausmann2014-12-181-5/+0
| | | | | | | | | | | | | | | | | | | | | It appears that there is no code in the plugin that actually uses dbus. Change-Id: I654cf0b8f5ecc018f2c6ae8701220f7496915a60 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| | * QNX: Handle the case where screen returns a refresh rate of 0.Roger Maclean2014-12-181-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Screen sometimes returns a refresh rate of 0. This has been observed on VMWare though it is unknown if this is always the case and whether it happens on other platforms as well. Returning a refresh rate of 0 causes animations to fail so we're better off returning a value that might be wrong than returning 0. Change-Id: I4846017bcb0d6bd52faad727df4ef6dac1a6250f Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
| | * xcb: Don't return 0 from QXcbKeyboard::possibleKeysAlexander Volkov2014-12-181-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It's possible to get 0 for baseQtKey in case Caps Lock is used as a layout switcher. So don't include this value in the result. Similar fix was in commit d904533acba1267431ca2c5f0d3e85cc59a20a26. Task-number: QTCREATORBUG-9589 Change-Id: I46fc91f9faf6fd0699f062a72fd2ca3187232f5a Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
* | | Fix crash when running QtWayland compositor on xcb-egl.Erik Larsson2014-12-291-2/+3
|/ / | | | | | | | | | | | | | | | | | | | | When running the compositor on xcb the compositor backend will call nativeResourceForWindow with EglDisplay as resource. When this is done the window->handle() will be null and result in a crash. By returning just the eglDisplay() when the window->handle() is null solves the problem and also makes the compositor work. Change-Id: I72f4341402facc8c44a41151c4f76d6447bd8070 Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
* | Fix potential memory access violation issuesKonstantin Ritt2014-12-244-29/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | LOGFONT docs clearly states `lfFaceName` member is a null-terminated string of length not longer than LF_FACESIZE, including trailing null. This patch covers two cases at once: 1. If family name is longer than LF_FACESIZE - 1, it would be truncated and terminated with null, to prevent memory access beyond the LOGFONT instance. 2. If family name is a fromRawData QString, we don't assume it is null-terminated either and guarantee trailing null ourselves. Change-Id: I8f607efc7d0901537a4179e36cc51df94203f08d Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
* | Fix build when using -egl and -no-xcb-xlibGiulio Camuffo2014-12-233-0/+8
| | | | | | | | | | Change-Id: I533f1d989b5f4b427ce572620e27c3870a64c2ae Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
* | Add a function for QPA plugins to explicitly destroy QScreensGiulio Camuffo2014-12-2313-17/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Previously QPlatformScreen was automatically deleting its QScreen in ~QPlatformScreen(). That means that we cannot use QScreen's methods when the screen is being removed, because doing so would call virtual methods of QPlatformScreen. By that point the QPlatformScreen subclass object does not exist anymore, and we call the default implementation instead of the subclassed one, or get a crash for the pure virtual methods. This happens for example when removing a screen which contains a QWindow with some QML item using QQuickScreenAttached. This patch adds a QPlatformIntegration::destroyScreen() function, which deletes the QScreen and later the QPlatformScreen. ~QPlatformScreen will still delete the QScreen if it was not deleted with destroyScreen(), so code not ported to the new approach will continue to work as before, with only a warning added. Task-number: QTBUG-41141 Change-Id: Ie4a03dee08ceb4c3e94a81875411f6f723273fe1 Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com> Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* | Add some missing nativeResourceForIntegration imlementationsJørgen Lind2014-12-226-1/+61
| | | | | | | | | | | | | | | | The EglDisplay and the Display is normally a PlatformIntegration wide resource Change-Id: Ie5382a2a0b34fbe1c506b5134bf581afbd7f5d99 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
* | Add libinput supportLaszlo Agocs2014-12-205-0/+95
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Supports relative pointer, axis, keyboard and touch events. libinput support is only available in combination with libudev. libxkbcommon is required to perform key mapping. For now the default keymap is used always (selected when building xkbcommon). [ChangeLog][QtGui] Added a plugin to get mouse, keyboard and touch events via libinput. Change-Id: I469d8992c0cd3e79225cefaeb931697baf86a92b Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* | Use Qt 5 signals & slot syntax in the Windows QPA plugin.Friedemann Kleint2014-12-202-14/+14
| | | | | | | | | | Change-Id: Ide8f79e82c9d22e40577e6fb0116ebaa2a6d90d9 Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
* | Merge "Merge remote-tracking branch 'origin/5.4' into dev" into refs/staging/devGiuseppe D'Angelo2014-12-2012-46/+72
|\ \
| * | Merge remote-tracking branch 'origin/5.4' into devSimon Hausmann2014-12-1812-46/+72
| |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/global/qglobal.h src/platformsupport/platformcompositor/qopenglcompositor.cpp src/platformsupport/platformcompositor/qopenglcompositorbackingstore.cpp tests/auto/gui/kernel/qwindow/tst_qwindow.cpp Change-Id: I5422868500be695584a496dbbbc719d146bc572d
| | * Qt should not print warning unless we have an API miss-usage caseAlex Blasche2014-12-181-4/+4
| | | | | | | | | | | | | | | | | | | | | This warning is always printed. Change-Id: I524011f251f7f7e0d76eb94b16e1511e72f26422 Reviewed-by: Lorn Potter <lorn.potter@gmail.com>
| | * Fix PDF when embedding fonts with large internal leadingEskil Abrahamsen Blomfeldt2014-12-181-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Setting lfHeight to a positive value in LOGFONT requests the font with the given cell height, which is em square size + internal leading. When setting this to the em square size, it means we will get glyphs that are actually sized for an em square with sides that are (emSquareSize - internalLeading). For most fonts, this was not noticeable, but for some fonts with large internal leading, the resulting glyphs would be very small. When setting lfHeight to something < 0 instead, we are selecting the font with the given character height instead, which is not including the internal leading. [ChangeLog][PDF] Fix embedding glyphs from fonts with large internal leading. Task-number: QTBUG-43082 Change-Id: Id74cf2279df2062804e9431fe305d803cb0b19d2 Reviewed-by: Lars Knoll <lars.knoll@digia.com> Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
| | * Windows: Return false from event processing of unhandled multimedia keys.Friedemann Kleint2014-12-181-1/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Otherwise, potentially active players no longer receive the keys when a Qt application is running. Task-number: QTBUG-43343 Change-Id: Iefa511a101734690305e3244fafec4a460a9212d Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
| | * Fix crash when Android Style is set more than once.BogDan Vatra2014-12-153-7/+18
| | | | | | | | | | | | | | | | | | | | | | | | Load again JSON document is it was freed. Task-number: QTBUG-43111 Change-Id: I22f1de221371b49fec8b3d66ad5f0bd2af9656fe Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
| | * Fix xcb backend not grabbing the server as defaultJørgen Lind2014-12-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The xcb backend relies on grabbing the x server in a few situations like popuphandling. For Qt 5.4.0 the logic enabling this code path was moved into the plugin. However it defaults to never grabbing the server Change-Id: I82489a0727affbce62587b3d7470085cf716a0cc Task-number: QTBUG-43049 Reviewed-by: Martin Gräßlin <mgraesslin@kde.org> Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
| | * Windows: Do not register windows obtained by QWindow::fromWinId() for touch.Friedemann Kleint2014-12-111-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes a warning: RegisterTouchWindow() failed for window ''. (Access is denied.) Task-number: QTBUG-43252 Change-Id: I92a565f3a5e2e8815eb709b5c6d0ccdba7330e31 Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
| | * Windows: Fix window geometry when using QWindow::fromWinId().Friedemann Kleint2014-12-111-3/+4
| | | | | | | | | | | | | | | | | | | | | | | | Take margins into account. Task-number: QTBUG-43252 Change-Id: I816115d2bbbcee3e8663f42bf07b1a140a049e69 Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
| | * iOS: let keyboard gesture work better with other gesturesRichard Moe Gustavsen2014-12-111-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Let the keyboard gesture work better alongside other gestures by reporting that it should: 1. not prevent other gestures from triggering. This means that even if our gesture triggers (we close the keyboard), gestures attached to sub-views will still continue tracking. 2. not be prevented by other gestures. This means that if a gesture in a sub-view triggeres before our gesture, our gesture will still continue to track. In short it means that regardless of other gestures, we always close the keyboard if our text responder is first responder and the user flicks down. And we do so as "silently" as possible. Change-Id: I22386b5ef5dedbc498a2899929ddd07424e514d8 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
| | * iOS: only clear focus object if it supports IMRichard Moe Gustavsen2014-12-112-4/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We try to keep a on-to-one relationship between UI controls with text input and keyboard visibility. But if the control does not use text input, then there is no reason for us to clear focus when the keyboard hides. In fact, we should avoid doing so, since that will stop e.g buttons from working correctly. The typical flow is: - a touch release targeting a button is sendt to QApplication. - QApplication transfers focus to the button. - qiosinputcontext gets notified, we refuse, and clear focus again. - QApplication enters a propagation loop where it tried to find out the receiver of the event. Since the button is now unfocused, the event will propagate up to a grandparent instead. - the button will as such not trigger. Change-Id: I70baa38299f40defc4a77f62790502e2d6ebbba9 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
| | * iOS: Only scroll to cursor on keyboard hide gesture reset if requestedTor Arne Vestbø2014-12-111-3/+12
| | | | | | | | | | | | | | | | | | Change-Id: I15b313b5f0d57358e405f16e941fc5061028c6a7 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@theqtcompany.com> Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
| | * iOS: Don't scroll screen on changes to input item transformTor Arne Vestbø2014-12-112-20/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We auto-scroll the screen to reveal the cursor whenever the cursor rect changes or other properties of the input methods are updated, but the expected behavior when explicitly moving an item under the keyboard, such as when scrolling a view or moving an item using drag, is to not scroll the screen until typing commences. This matches how eg. Safari or the Notes app handles the same use-case. Change-Id: I6b6932d9bcbdccd8df26db982246c162f1574d86 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@theqtcompany.com> Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
| | * Handle SelectionClientClose in QXcbClipboardMartin Gräßlin2014-12-101-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QXcbClipboard listens for subtype SelectionClientClose of Xfixes SelectionNotify event, but doesn't handle it. When the client holding the clipboard selection closes the Clipboard becomes empty and thus the change should be emitted. This fixes downstream KDE Bug #329174. Change-Id: I19fb8cfd7bd3b249c0bc6ca2a724a9aeeb05ac7e Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com> Reviewed-by: Aleix Pol Gonzalez <aleixpol@kde.org>
* | | Make GLX and EGL dynamic dependencies for xcbJørgen Lind2014-12-2045-600/+2497
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | [ChangeLog][QPA][Xcb] GLX and EGL code paths are now dynamically resolved, making it possible for one build of a plugin to use both code paths. Default is to use the GLX code path if available. This can be overwritten by specifying QT_XCB_GL_INTEGRATION=xcb_egl as an evnironment variable. Enable qt.xcb.glintegration.debug to get debug log output of what integration is used Change-Id: Ia9fa95fcca3d901b91dadb8c98a695fea0ae3b1e Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
* | | Long live the TuioTouch input plugin!Robin Burchell2014-12-1913-0/+1176
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is an import of the tuio2qt plugin (https://github.com/rburchell/tuio2qt), as of sha 9b1f163ac52ea440e83f16b3906f9b55e21b87be henceforth to be developed as a part of Qt itself. This plugin offers touch events via QPA interfaces, using data offered over the TUIO protocol (http://www.tuio.org). It is useful for accepting touch input on devices which otherwise don't have touch input (such as desktops) for the purposes of development, as well as accepting input from some hardware which offers up touch events specifically over the TUIO protocol. Known "shortcomings" at this time, as documented in the README: * Multiple TUIO sources sending data at the same time will conflict. This will not cause problems, strictly speaking, but it will not work well (repeated touchpoint release/press events for the same IDs) * TCP transport is not currently supported. I don't see a need for it at this time, but I have left the capability in terms of port acceptance open for it to be made available. Change-Id: I7178f9db13c635268db8460fbe4d4ea6be654c05 Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* | Xcb: remove compile warningsJørgen Lind2014-12-152-2/+2
| | | | | | | | | | Change-Id: Ieb3ccd18a2bdde9ef7628a031266004cd55480da Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
* | Add QFont::Weight enum valuesPierre Rossi2014-12-124-69/+17
| | | | | | | | | | | | | | | | | | | | And try to make good use of them in order to match the QFont request more closely. Task-number: QTBUG-38482 Change-Id: I768dfa8828e370d77a1c17ecf4796d750b3edd9b Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>
* | Merge remote-tracking branch 'origin/5.4' into devSimon Hausmann2014-12-1016-168/+315
|\| | | | | | | | | | | | | | | Conflicts: doc/global/template/style/online.css mkspecs/android-g++/qmake.conf Change-Id: Ib39ea7bd42f5ae12e82a3bc59a66787a16bdfc61
| * Windows: Limit cursor cache.Friedemann Kleint2014-12-091-1/+14
| | | | | | | | | | | | | | | | | | Prevent the cursor cache from growing indefinitely hitting GDI resource limits if new pixmap cursors are created repetitively by purging out all-noncurrent pixmap cursors. Change-Id: I4a3bbd6235af13e306ca84ac6fea3fcd69d53279 Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
| * Added support for CTRL key modifier to Android builds.Przemysław Czerpak2014-12-081-22/+21
| | | | | | | | | | Change-Id: Ib3eddb33348c54cec6cee62abdf69104059affb0 Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
| * qt_mac_loadMenuNib: Prevent stale NIB files by diffing file sizeTor Arne Vestbø2014-12-051-1/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If we're changing the contents of the nib files in Qt, we need to overwrite the nib files that we write to /tmp, as QFile::copy() does not overwrite files. This also catches the case where the files in /tmp are empty due to a possible broken qrc-run, where re-runs of qrc to fix the resources would still leave the corrupt nib in /tmp, resulting in: -[NSKeyedUnarchiver initForReadingWithData:]: data is empty; did you forget to send -finishEncoding to the NSKeyedArchiver? And as a consequence: qt_mac_loadMenuNib: could not instantiate nib ASSERT: "mainMenu" in file qcocoamenuloader.mm, line 154 Change-Id: I2907a32d1a56c23a27343c81839a06b65a529372 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
| * Merge "Merge remote-tracking branch 'origin/5.4.0' into 5.4" into ↵Simon Hausmann2014-12-052-5/+21
| |\ | | | | | | | | | refs/staging/5.4
| | * Merge remote-tracking branch 'origin/5.4.0' into 5.4Simon Hausmann2014-12-052-5/+21
| | |\ | | | | | | | | | | | | Change-Id: I0cd11cbe95693b78450ea81a0187760f4a6a8b5f
| | | * winrt: Fix window resizev5.4.0Andrew Knight2014-12-051-4/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The fixed-size EGL display must be updated on PC as well as Windows Phone. Task-number: QTBUG-43112 Change-Id: I0ba90370b67e8c065843e5754579e341b647266d Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
| | | * Android: Fix broken system paletteEskil Abrahamsen Blomfeldt2014-12-031-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When we overwrite the default palette, we have to make sure we don't overwrite default values with black for all the colors that are not retrieved from the json file. We would for instance get black as both the base color and text color which would make some components unusable. Change-Id: I1079a70a0ac7eb379ed5e8d92c6b39c2ea77ba49 Task-number: QTBUG-42812 Task-number: QTBUG-42998 Reviewed-by: BogDan Vatra <bogdan@kde.org> Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
| | | * winrt: Fix Windows Store CertificationAndrew Knight2014-12-011-0/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | WinRT requires that IDXGIDevice3::Trim() is called on application suspend in order to pass Store Certification. Task-number: QTBUG-38481 Change-Id: Ia3cb5d3f6a2db8f11e4bfa4fd5c7791e18d6c36d Reviewed-by: Maurice Kalinowski <maurice.kalinowski@theqtcompany.com>
| * | | Fix QOpenGLWidget/QQuickWidget GUI freezePaul Olav Tvete2014-12-051-5/+10
| |/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | A window with a renderToTexture child uses the OpenGL path, but when we open a popup or dialog, that uses the raster compositor, which opens a separate surface. This patch fixes two issues when combining GL rendering with the raster compositor: 1. GL-rendered widgets were counted as part of the raster-rendered region, meaning that we did not punch a hole in the raster surface. 2. We did not destroy the surface when no longer needed. Task-number: QTBUG-41467 Change-Id: I2a2a0e860cce065b330df1c864d51fd02103aa1b Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com> Reviewed-by: BogDan Vatra <bogdan@kde.org> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com> Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
| * | Windows: Skip calculating margins for Qt::FramelessWindowHint.Friedemann Kleint2014-12-051-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Always skip calculating style-dependent margins for windows claimed to be frameless by Qt. This allows users to remove the margins by handling WM_NCCALCSIZE with WS_THICKFRAME set to ensure Areo snap still works. Task-number: QTBUG-40578 Change-Id: Ice7771df8fbf59b370568219d10c12ce04e99628 Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com> Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
| * | Windows: Handle WM_WINDOWPOSCHANGING during window creation.Friedemann Kleint2014-12-043-6/+15
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix warnings: QWindowsContext::windowsProc: No Qt Window found for event 0x46 (WM_WINDOWPOSCHANGING), hwnd=0x0xde0408. occurring when using Active X controls. Factor out message handling to a static function which can be used during window creation when QWindowsWindow does not yet exist. Task-number: QTBUG-36318 Change-Id: I3ce56fd377e3392b0dd22d3d26a7048065380f13 Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
| * | Windows: Bring FreeType rendering up to par with other platformsSérgio Martins2014-12-041-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The text was very washed out, almost white on small font sizes. This ifdef was introduced to cater for GDI differences between Vista and Pre-Vista, it's GDI specific, nothing to do with FreeType. Text now looks good, and md5sum of the rendering is the same as on Linux. Task-number: QTBUG-42564 Change-Id: I2e06b83b80df093331454fe1b780d26462db597d Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
| * | iOS: Guard against UIGestureRecognizer messing with selfTor Arne Vestbø2014-12-021-0/+3
| | | | | | | | | | | | | | | | | | | | | | | | We pass in self to initWithTarget, so we need to be sure that the init doesn't return a new self. Change-Id: I90d0d10d2fd1a5d38ef1ff3f23169dcce00b28e2 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@theqtcompany.com>
| * | iOS: Properly support QInputMethod's visible and animating propertiesTor Arne Vestbø2014-12-022-99/+136
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We now emit and change the 'visible' and 'animating' properties of the QInputMethod according to the documentation, which means the 'visible' property will change immediately when the keyboard is about to become visible, or about to hide, and the 'animating' property will determine if the visibility-change is just starting out, or has ended. The keyboard rect will at all times reflect the currently visible area of the virtual keyboard on screen (in focus-window-coordinates), not future state after the animating completes. Getting the future state is a missing piece of the QInputMethod API, and could be solved in the future by adding arguments to the animatingChanged signal that allow platform plugins to pass on the before- and after states. The logic for determining the keyboard state has been moved into a central function, updateKeyboardState(), which allows us to change and emit property changes atomically. There is still some parts left of the old approach, but these are left in to make further changes to the code easier to diff and understand in isolation. Change-Id: Ica52718eba503165ba101f1f82c4a425e3621002 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@theqtcompany.com>
| * | iOS: Simplify view management in QIOSKeyboardListenerTor Arne Vestbø2014-12-024-31/+48
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We don't need to keep track of the view-controller or add ourselves as a gesture recognizer inside QIOSKeyboardListener. In fact, leaving the call to removeGestureRecognizer in [QIOSKeyboardListener dealloc] will result in QIOSKeyboardListener never being released, as the view that we add the recognizer to will keep a strong reference to the recognizer, so dealloc is never called unless the view is also released, which is unlikely to happen. We now fully control the lifetime of the recognizer. Change-Id: I6755e8cdfcc8f1062314db51aa54a2b7ecd1b967 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@theqtcompany.com>
| * | iOS: Refactor QIOSKeyboardListener implementation and usageTor Arne Vestbø2014-12-022-60/+83
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QIOSKeyboardListener takes care of both maintaining the virtual keyboard state, and acting as a gesture recognizer for the hide keyboard gesture. We make this explicit though a union in QIOSInputContext, so that we can access each 'mode' separately. This improved code readability and allows later refactoring of the state and gesture into separate classes without changing the call sites. Change-Id: Icc60f4a542983cda7ca0fd6622963d32d1e90db9 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@theqtcompany.com>