summaryrefslogtreecommitdiffstats
path: root/src/plugins
Commit message (Collapse)AuthorAgeFilesLines
* QTouchEvent: add uniqueId and rotation; TUIO: support fiducial tokensShawn Rutledge2016-04-074-30/+382
| | | | | | | | | | | | | | | | | | | | | TUIO supports tracking tagged physical objects on touchscreens by various means (QR codes, RFIDs etc.) It can detect both position and rotation. Likewise, it may be possible for some touchscreens or drivers to detect orientation of the fingers. So, just as QTabletEvent has rotation, each touchpoint needs to include the rotation value. When using tokens, each object has a permanent unique ID, whereas QTouchEvent::TouchPoint::id() is a transient ID which usually auto- increments each time a finger is pressed to the device. So we need to make that available too, to identify each token. Different platforms may use different kinds of IDs (int, UUID, QR code etc.); however for TUIO 1.x, the unique IDs are just 32-bit integers. QPointerUniqueId is added, storing only a qint64 for now (like QTabletEvent::uniqueId()) but able to be expanded as necessary later on. Task-number: QTBUG-51844 Change-Id: I04182042f47fa2954728079139a4664a31184b54 Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
* Always compile sql drivers as pluginsLars Knoll2016-04-0737-36/+15641
| | | | | | | | | | | | Compiling the drivers into Qt Sql does not make a lot of sense anymore, as we handle plugins well enough in the build system these days. [ChangeLog][Build system] SQL drivers are now always compiled as plugins. Change-Id: I364b82a480849399d1fafe4b20e9f08922569260 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> Reviewed-by: Mark Brand <mabrand@mabrand.nl>
* Always build JPEG and GIF support as pluginsLars Knoll2016-04-078-16/+2570
| | | | | | | | | | | | | | | | | Our handling of plugins when Qt is build statically is nowadays good enough, so we don't need to build the JPEG and GIF support directly into Qt for static builds. Let's simply always build them as plugins. Also simplify the logic in configure, and get rid of the no-gif, no-jpeg and no-png config variables. [ChangelLog][Build system] JPEG and GIF image support is now always built as a plugin. Removed -imageformat-[jpeg|gif] arguments to configure. Change-Id: Ic01559ff406c966807b3be8761252e8802adcdf7 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
* Direct2D QPA: Fix build.Friedemann Kleint2016-04-062-2/+2
| | | | | | | | Directly link against DwmApi and fix breakage introduced by refactoring QRegion. Change-Id: I45cd696de630aebb5347130560ab69530eefbcdb Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
* Merge remote-tracking branch 'origin/5.7' into devLiang Qi2016-04-0590-758/+1972
|\ | | | | | | | | | | | | | | | | Conflicts: examples/corelib/ipc/ipc.pro src/plugins/platforms/xcb/qxcbbackingstore.cpp tests/auto/corelib/tools/qcommandlineparser/tst_qcommandlineparser.cpp Change-Id: Ia006e10ff1732fe78f90138c41f05b59b49486cf
| * Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-04-048-7/+41
| |\ | | | | | | | | | Change-Id: I35ca979395620e104e50b06366d0869433a4ffc2
| | * eglfs QPA: Hide the cursor when QT_QPA_EGLFS_HIDECURSOR is setAndy Shaw2016-04-011-0/+6
| | | | | | | | | | | | | | | Change-Id: Ib5491c26db2a29e8905573198741df75d8511ace Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
| | * Windows QPA: Scale the cursor rectangle of the input method.Friedemann Kleint2016-03-312-6/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | Fixes the position of the input method window when High DPI scaling is active. Task-number: QTBUG-51923 Change-Id: I35ee4bcf320f8c2b7d5cc7fb8484348b18e1d833 Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
| | * QFontEngine: Add handle() functionGabriel de Dietrich2016-03-294-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Both QFont::handle() and QFont::freetypeFace() used to be available in Qt 4 but were removed in Qt 5. There's currently no API to get access to the native font handle, which the font engine holds in a way or another. Similar to the way it was in Qt 4, the actual handle type depends on the font engine currently in use. The types map as follows: Font Engine Native Handle ------------------------------------ DirectWrite IDWriteFontFace * Freetype FT_Face Mac CTFontRef Win HFONT All other font engines return a null handle. Change-Id: I3bea8259ac1378fd24079723aa6603bf9e74834c Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
| | * wince: Disable Native Filedialogs for WEC2013Andreas Holzammer2016-03-291-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | Qt crashes when opening a native file dialog. Disable this feature to fix this issue. Change-Id: I1ee17d858238c2531964a63ddbe3e11c5a85483c Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
| | * Windows QPA: Fix regular expression to match CLSIDs in file dialog.Friedemann Kleint2016-03-241-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Match correct number of digits and entire string, amending change 4347e811611ab15e544765a3a34761d2f5c68cb3. Task-number: QTBUG-33962 Task-number: QTBUG-51373 Change-Id: I56de00bd5ffb3a3a700efbb20970154faf86f923 Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
| * | QXcbBackingStore: Fix scrolling when backed with native X PixmapLouai Al-Khanji2016-03-301-32/+62
| | | | | | | | | | | | | | | | | | Change-Id: I7c6618783996c814dc6873b950e2c35e95680f11 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com> Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
| * | Cocoa integration - hitTest for Qt::WindowTransparentForInputTimur Pocheptsov2016-03-301-0/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In case Qt::WindowTransparentForInput is set on a window, we usually call [super someRelatedMethod] on a corresponding QNSView, for example, [super mouseDown:theEvent]. Unfortunately, Cocoa will continue to report the subsequent mouse dragging events to the first view where mouse down occurred, despite of us passing mouse down to the next reponder. Dragging events we'll also 'propagate' by calling super's method, but it's not working properly, since the current view below probably did not have that first mouse down event thus it does not have m_buttons set correctly. And even worse with the closing mouseUp event. So, let's use -hitTest: returning nil on such a 'transparent' view so that it's ignored by mouse events. Task-number: QTBUG-40583 Change-Id: I5e0fef3e246a29332df758a692300d478b862069 Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
| * | Remove the traces of the discontinued android-no-sdk platformEirik Aavitsland2016-03-305-11/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | Cleaning out the workarounds for the discontinued "Embedded Android" platform of Boot2Qt. Change-Id: I0ff9d770e82a43457fb7e5da0428f4597ead4038 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
| * | Unify license header usage.Jani Heikkinen2016-03-2957-673/+844
| | | | | | | | | | | | | | | | | | | | | | | | | | | Update files using old header.LGPL3 to header.LGPL Update files using old FDL template to use new one Update files using old BSD template to use new one Change-Id: I36a78272516f9953d02956522f285b40adfc8915 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
| * | Merge remote-tracking branch 'origin/5.6' into 5.7Simon Hausmann2016-03-243-7/+22
| |\| | | | | | | | | | Change-Id: I13c7ea6a74eb98606cf45702ae068101943bec6a
| | * minimal QPA plugin: Use fontconfig DB if availableGabriel de Dietrich2016-03-233-7/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | This makes minimal a bit more useful for apps needing to access QFonts from non-UI environments. Change-Id: Idc5ca13f0c385ab9b4258e11fea7ec886515eea4 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com> Reviewed-by: Louai Al-Khanji <louai.al-khanji@theqtcompany.com>
| * | Merge remote-tracking branch 'origin/5.6' into 5.7Simon Hausmann2016-03-236-22/+43
| |\| | | | | | | | | | Change-Id: I9a10e1f3c9506ec8554d8f59b6300825ac730939
| | * QCocoaMenus: Use mix-in pattern to implement menu hierarchyGabriel de Dietrich2016-03-225-18/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | To solve menu item roles from their text, we need to find its depth in the menubar hierarchy. Unfortunately, there's no trivial way to access that hierarchy from the QPA side, so we need to come with an ad-hoc solution. Previously, we were using a dynamic proprety to keep track of the 'parent' object. However, as the life span of the different objects has changed since 09acf326dbc6b7b67f21a36, we need a way to keep track of the parent's existence. This is what we do in this patch by having both QCocoaMenu and QCocoaMenuItem also inherit QCocoaMenuObject. This class' sole role is to store the menu hierarchy's parent object and wrap it in a QPointer. Change-Id: Ia18d95171af76d26f6325eef04c77b40d99c4285 Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com> Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com> Reviewed-by: Timur Pocheptsov <timur.pocheptsov@theqtcompany.com>
| | * Android: Fix inputItemRectangle when using EnableHighDpiScalingBogDan Vatra2016-03-211-4/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When EnableHighDpiScaling is enabled, qGuiApp->inputMethod()- >inputItemRectangle() returns the position divided by pixel density, therefore all the controls positions must by multiplied by pixel density to translate them into screen coordinates. Task-number: QTBUG-52001 Change-Id: Iea92a912cfbab03a9497fc8cddc24bebd0db2192 Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
| * | Mir: Call QPlatformIntegration::destroyScreen() as recommended.Christian Strømme2016-03-222-7/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The QPA plugin was deleting the screen object manually, which is not needed or the recommended approach. The screen(s) are already maintained by QGuiApplication and destroying the screen object(s) should be done by calling QPlatformIntegration::destroyScreen(). This change removes the need to keep a reference to the screen(s) in the mir platform integration class, and removes the warning printed on exit. Change-Id: I61f37c25ebabf3e96e4cea458c4af454d025926a Reviewed-by: Paul Olav Tvete <paul.tvete@theqtcompany.com>
| * | Add INTEGRITY Framebuffer-based plugin as a platform plugin.Rolland Dudemaine2016-03-2210-0/+928
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The plugin builds as a static plugin. It is based on the Linuxfb plugin. It uses the INTEGRITY FB API for framebuffer for display, and HID API for input (mouse, keyboard, touch). Because this is the only supported plugin and requires to be included as a static plugin, automatically add the platform to any application through qmake.conf. Change-Id: Ic228afb59cb39dd02c2d538de46caf6e6ea7d153 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com> Reviewed-by: Andy Nichols <andy.nichols@theqtcompany.com>
* | | Windows QPA: Increase API level to 0x600 (Windows Vista).Friedemann Kleint2016-04-018-199/+62
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Directly link against dwmapi which should be present on Windows Vista and remove duplicated header constants. - Remove struct QWindowsShell32DL since all required functions are present on Windows Vista. - Remove functions that are no longer needed from QWindowsUser32DLL with exception of the clipboard functions which are not present in the MinGW stub libraries until v5. Task-number: QTBUG-51673 Change-Id: Ia4a8a3f1db0f0d02322317d547e61ae39f9008b5 Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
* | | Android: Support PasswordMaskDelayKai Uwe Broulik2016-04-012-0/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It is only set if the "Show passwords" option in Android's security settings is enabled, the value is not updated at runtime as this option isn't likely to be changed frequently, if at all. The value of 1.5s is hardcoded in Android's PasswordTransformationMethod. [ChangeLog][Android] Show password while typing is now supported Task-number: QTBUG-48948 Change-Id: I9209b68c8684b825be196e8d0afd37cb0e0d141d Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com> Reviewed-by: Jason Erb
* | | Use quotes instead of angle brackets for local includes in cocoa plugin.Jake Petroules2016-04-012-5/+5
| | | | | | | | | | | | | | | | | | | | | This fixes an inconsistency with all other files in platform plugins. Change-Id: If790f51e250c1e3b2e4525efbc18c59be9c5568b Reviewed-by: Timur Pocheptsov <timur.pocheptsov@theqtcompany.com>
* | | QtNetwork: Remove Windows CE.Friedemann Kleint2016-03-293-42/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | Remove #ifdef sections for Q_OS_WINCE and wince .pro file clauses in library, examples and tests. Task-number: QTBUG-51673 Change-Id: I3706336395620522ceda414d7437295d9ec64f16 Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
* | | Windows QPA: Remove Windows CE.Friedemann Kleint2016-03-2935-1553/+85
| | | | | | | | | | | | | | | | | | Task-number: QTBUG-51673 Change-Id: I5b58a7d1651fce7f868a4d3fdd8fa46f35e67695 Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
* | | Merge remote-tracking branch 'origin/5.7' into devLiang Qi2016-03-22145-1599/+1426
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: configure mkspecs/common/wince/qplatformdefs.h src/plugins/platforms/directfb/qdirectfbbackingstore.cpp src/plugins/platforms/xcb/qxcbbackingstore.cpp Change-Id: Ied4d31264a9afca9514b51a7eb1494c28712793c
| * | Cocoa: Forward masked out mouse events.Morten Johan Sørvig2016-03-212-4/+29
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Forward mouse events hitting the a masked out window area to the next responder by calling the superclass event handler. Implement "inverse mouse grabbing": Qt will not take dragged and up events if the mouseDown was in a masked out area. Change-Id: Ie86281245513cad515b77a468ac63f31ae41bfe0 Task-number: QTBUG-41839 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@theqtcompany.com>
| * | Cocoa: Forward rejected key events.Morten Johan Sørvig2016-03-212-6/+47
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Forward rejected key events to the next responder by checking the return value from QWindowSystemInterface and calling the superclass event handler. This is useful when Qt is running as a plugin in a host application; the host can now react to key events even if Qt has focus. Qt will often not accept keyUp events, even if the corresponding keyDown was accepted, for example in the case of text controls. We don't want to forward 'bare' keyUps, so keep track of which keyDowns have been seen. Change-Id: I976448a5d305a657a0e91aeb271b158f8b598286 Task-number: QTBUG-45768 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@theqtcompany.com>
| * | Cocoa: Unify mouse handling logicMorten Johan Sørvig2016-03-212-66/+106
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Reduce the code duplication for the various button type handlers. Fan in: (example) rightMouseDown handleMouseDownEvent handleMouseEvent The primary mouseDown function is still separate with some duplicated logic. Remove the "invalid button tracking" warning. qWarnings are for application developers in case of improper use of API etc, not internal Qt errors. Change-Id: Idb1a311e37446399668c2a207831fccc84716ca1 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@theqtcompany.com>
| * | Cocoa: Move window logging to qt.qpa.cocoa.windowMorten Johan Sørvig2016-03-216-34/+48
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Remove QT_COCOCA_ENABLE_WINDOW_DEBUG. Replace/Add logging for window state changes and drawing. The window identifier is now the QWindow (not the platform window) everywhere since this object provides more debug output. Change-Id: I4ae56626015241279ab1b44d2b81c9d462b532a0 Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
| * | Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-03-2116-137/+204
| |\| | | | | | | | | | | | | | | | | | | | | | | | | Conflicts: src/widgets/styles/qgtkstyle_p.cpp tests/auto/corelib/io/qtextstream/test/test.pro tests/auto/corelib/plugin/plugin.pro Change-Id: I512bc1b36acf3933ed2b96c00f476ee3819c1f4b
| | * xcb: Merge _NET_WM_STATE hints instead of overwritingDavid Rosca2016-03-181-8/+24
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This makes possible to set custom _NET_WM_STATE hints before showing the window. Change-Id: I86ad3863f7a8b3bb610a31b9af4b02c9d38eb111 Task-number: QTBUG-26978 Reviewed-by: Ilya Kotov Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com> Reviewed-by: Uli Schlachter <psychon@znc.in>
| | * Merge remote-tracking branch 'origin/5.6.0' into 5.6Frederik Gladhorn2016-03-172-5/+5
| | |\ | | | | | | | | | | | | Change-Id: Iac8ff05cd76cbacf859138a73e8e2ed0a979c75a
| | * | QCocoaMenu: Decouple NSMenuItem from NSMenuGabriel de Dietrich2016-03-166-121/+111
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | While Cocoa requires an NSMenu to be coupled to an NSMenuItem (just as Qt requires a QMenu to be coupled to a QAction), making that a hard coupling comes with some limitations. This is because Cocoa won't allow the NSMenu object to be simultaneously coupled to more than one NSMenuItem and, similarly, an NSMenuItem can only be added to a single parent NSMenu. Therefore, it becomes difficult to share one QMenu between two different QMenuBars in different windows, or to use a QMenu as context menu while being accessible from the menu bar. Previous solutions to circumvent those limitations were less than ideal (see 119882714f87ffeb6945fdb2d02997ae125ff50c for the QMenuBar shared QMenu issue). Other workarounds that relied on that hard coupling, like 996054f5e65bc676aaea0743c2eacec51918e4aa, also added gratuitous complexity. In this patch, we break that hard NSMenuItem-NSMenu coupling, and we replace it with a temporary, looser coupling. As a consequence, * QCocoaMenu only contains and manages a NSMenu instance, removing the previously used NSMenuItem. It gets a temporarily attached NSMenuItem instead. * QCocoaMenuItem gains a safe pointer to its QCocoaMenu property removing the necessity containingMenuItem() in QCocoaMenu. * QCocoaMenuBar manages its own NSMenuItems. With this setup, we bind the NSMenu to its parent NSMenuItem at the last moment. In QCocoaMenuBar, when we call updateMenuBarImmediately(). In QCocoaMenu, we use the delegate's -[QCocoaMenuDelegate menu: updateItem:atIndex:shouldCancel:] method which is called when Cocoa is about to display the NSMenu. Note: There's still one use case we don't support, which is sharing a toplevel QMenuBar menu. This is because Cocoa's menu bar requires each of its menu items to have a submenu assigned, and therefore we can't rely on that last moment assignment. Task-number: QTBUG-34160 Task-number: QTBUG-31342 Task-number: QTBUG-41587 Change-Id: I92bdb444c680789c78e43fe0b585dc6661770281 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@theqtcompany.com>
| | * | winrt: enable cross-platform high DPI scalingJochen Seemann2016-03-162-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | Task-number: QTBUG-46615 Change-Id: I7f75bc7da35b9330753130338a06feb49533061c Reviewed-by: Andrew Knight <andrew.knight@intopalo.com> Reviewed-by: Maurice Kalinowski <maurice.kalinowski@theqtcompany.com>
| | * | xcb: Initialize all xcb_client_message_event_t members before useShawn Rutledge2016-03-154-1/+13
| | | | | | | | | | | | | | | | | | | | Change-Id: I01e4b69b138fd19fc7e67751d93adebc1326b2f9 Reviewed-by: Orgad Shaneh <orgads@gmail.com>
| | * | Compile with -no-openglMorten Johan Sørvig2016-03-151-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QCocoaBackingstore::toImage() can only be Q_DECL_OVERRIDE if QPlatformBackingStore::toImage() is present, which it isn’t for NO_OPENGL builds. Change-Id: Ib116f40fd26defb29a8d520d3e3fb104d8da8d57 Task-number: QTBUG-51694 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@theqtcompany.com>
| | * | Cocoa: Fix crash on screen disconnect.Morten Johan Sørvig2016-03-151-3/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Maintain virtual siblings list on screen deletion. QCocoaIntegration::updateScreens() has a loop which will delete all non-current QScreen objects using QPlatformIntegration::destroyScreen(). destroyScreen() vill eventually call QWindowPrivate:: setTopLevelScreen() which accesses the virtual siblings list for the deleted screen. This can cause a stale pointer access if the virtual screen list is not up to date, especially when disconnecting two screens at the same time. Change-Id: Ia6b9d01edf8e5eea25b64604a2b3b28b173125f7 Task-number: QTBUG-48275 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@theqtcompany.com> Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
| | * | Cocoa: Improve native view lifetime accuracy.Morten Johan Sørvig2016-03-111-1/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Ideally all native NSWindows and NSViews owned by QCocoaWindow should be deallocated during the QCocoaWindow destructor. In reality this does not always happen since Cocoa is free to hold references to the views after Qt releases its reference. We can help Cocoa clean up: - Clear the first responder for the NSWindow under the ~QCocoaWndow() autoreleasepool. - Use an autoreleasepool to clean up temp objects from [NSWindow orderFront:] immediately. Together this makes the QNSView lifetime be contained by the QCocoaWindow lifetime, at least for simple QWindow usage. It also fixes the observed memory leak reported in QTBUG-51766 Change-Id: Idd224f54ebd6f61f274461a204ff30c666b22768 Task-number: QTBUG-51766 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@theqtcompany.com>
| | * | winrt: Fix painting glitches when orientation changesMaurice Kalinowski2016-03-111-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In addition to handling the pure rotation enforce a size change as well. This way content is redrawn for the correct orientation. It was done for Windows Phone 8.1 already, we only need to extent this to Windows 10. Task-number: QTBUG-50336 Change-Id: I6b3b964f44b631757ea856331c50f53c39ed9ec3 Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
| | * | winrt: add logging to QWinRTScreenMaurice Kalinowski2016-03-111-1/+21
| | | | | | | | | | | | | | | | | | | | | | | | Task-number: QTBUG-38114 Change-Id: Id653487a03ca2920c46cf16e45f28677a69fa570 Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
| | * | Ported Qt 4 fix when getting an invalid native key on WindowsSamuel Gaist2016-03-101-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | Task-number: QTBUG-36061 Change-Id: Ibde65735d861af4e1ef768e9e4314d30fed534a1 Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
| * | | QWheelEvent: Make NoScrollPhase publicGabriel de Dietrich2016-03-211-2/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This reverts d5fde514106f5479f9c929c8a165aced4a1b2c84 and makes that enum value the default for QWheelEvent::phase() with non phase-aware mice. [ChangeLog][QtGui] QWheelEvent::phase() returns NoScrollPhase with non phase-aware mice. This is most mice and input devices except, for now, Apple's trackpads and Magic Mouse. Change-Id: I929fb39889cf116e89dcd134c1b1ec6587b8f05e Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
| * | | iOS: Use composeAndFlush() to flush all backing store updatesTor Arne Vestbø2016-03-181-5/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QPlatformBackingStore::composeAndFlush() handles an empty texture list just fine, and results in the same blitting of the backing store image as we're doing today using the OpenGL paint engine, except the compose and flush code path is a lot more optimized. Among other things it clears the render buffer as the first step (as recommended by Apple on iOS), doesn't re-create the backing store texture each pass just because the image has changed, and respects the flushed region for both the texture upload (using glTexSubImage2D) and when blitting the texture. The result is a 10x increase in frames per second when blitting full screen updates. Change-Id: I163fab473751f8201758a5684b18d80bb90d42fb Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
| * | | Merge "Merge remote-tracking branch 'origin/5.6' into 5.7" into refs/staging/5.7Liang Qi2016-03-1367-339/+316
| |\ \ \
| | * | | Merge remote-tracking branch 'origin/5.6' into 5.7Liang Qi2016-03-1167-339/+316
| | |\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change partially reverts 1bfc7f68 about QT_HAS_BUILTIN define and undef in src/corelib/tools/qsimd_p.h. This change is also squashed with "Fall back to c++11 standard compiler flag for host builds" which is done by Peter Seiderer. Conflicts: mkspecs/features/default_post.prf src/3rdparty/sqlite/0001-Fixing-the-SQLite3-build-for-WEC2013-again.patch src/3rdparty/sqlite/sqlite3.c src/corelib/tools/qsimd_p.h src/gui/kernel/qevent.cpp src/gui/kernel/qwindowsysteminterface.cpp src/gui/kernel/qwindowsysteminterface_p.h src/plugins/bearer/blackberry/blackberry.pro src/plugins/platforms/cocoa/qcocoasystemsettings.mm src/plugins/platformthemes/gtk2/gtk2.pro src/plugins/styles/bb10style/bb10style.pro src/sql/drivers/sqlite2/qsql_sqlite2.cpp tools/configure/configureapp.cpp Task-number: QTBUG-51644 Done-with: Peter Seiderer <ps.report@gmx.net> Change-Id: I6100d6ace31b2e8d41a95f0b5d5ebf8f1fd88b44
| | | * | xcb: mark mouse events from tablet devices as synthesizedShawn Rutledge2016-03-094-22/+32
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Task-number: QTBUG-51617 Change-Id: Ic1d258c56165947ff821b1bf4d044bcf29b41a3b Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
| | | * | Clean up WINVER, _WIN32_WINNT macros for MinGW.Friedemann Kleint2016-03-072-14/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Define WINVER, _WIN32_WINNT as 0x501 (Windows XP) in qt_windows.h. Remove definitions of the same/lower versions and unneeded definitions in other places. Remove definition for Borland compiler. Task-number: QTBUG-51673 Change-Id: I2a344a7f7cf78b2afbf45dcdf8bf2a19b93f0a07 Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>