Commit Graph

13998 Commits

Author SHA1 Message Date
Friedemann Kleint
cb7dd74bb5 QWidget: Set screen on top-level windows only.
Change-Id: Iea7fbe253ff3144d9988fd14790296e211075d3b
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
2014-07-08 12:05:49 +02:00
Konstantin Ritt
e26660c004 Don't assert when HB-old is unable to deal with surrogates
Since we have no interest in fixing HB-old to properly support surrogates,
here is a simple workaround for the case when surrogate parts gets
treated like two separate glyphs in log_clusters but a single character.
And since it's a known issue that HB-old doesn't really support surrogates,
it's better to draw some garbage/boxes rather than to assert, IMO.

Task-number: QTBUG-39875
Change-Id: I95ff43e821ae989d7a6f792f71f157dcea92dd16
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
2014-07-08 09:40:24 +02:00
Konstantin Ritt
0412ad3513 Decrease code duplication by reusing QTextEngine::findItem()
Use the findItem()'s optimized binary search impl instead of a generic one.
Also drop the "already shaped item" case since setBoundary() is only
called from itemize(), where the items are not shaped yet.

Change-Id: Ifbecdc41b2e3cb7791a7896fbb0cbea439ca0706
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
2014-07-08 08:58:34 +02:00
Eskil Abrahamsen Blomfeldt
b56a42be14 REG: Fix nbsp in QTextLayout
At some point since Qt 4.8, the nbsp character has acquired
the whitespace attribute, causing it to be treated exactly
like an ordinary space. To account for this, we add an extra
check in the layout code to avoid breaking on non-breaking
spaces even if they have the whiteSpace flag set.

This is a temporary fix for the regression. The line breaking
algorithm needs to be refactored and support Unicode tr14
properly, which it currently doesn't.

[ChangeLog][Text] Fixed lines breaking on non-breaking spaces.

Task-number: QTBUG-39832
Change-Id: Ibd7e1a11ce4b82c611ecda1542c8638a67bf3cae
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
2014-07-08 08:35:02 +02:00
Eskil Abrahamsen Blomfeldt
1c08a41cb9 Support getting test data from qrc
If none of the other locations work, we can fall back to bundling
the test data in qrc to make it possible to include test data on
platforms that do not have any good way of deploying files to the
traditional file system, like Android.

Change-Id: I7779ce6be2380d551697cecfb9f76652d1fd0a38
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
2014-07-08 08:34:30 +02:00
Eskil Abrahamsen Blomfeldt
ac2b15bdd0 Android: [REG] Fix QScreen::physicalSize()
The physical size should be set based on the screen size, not
the available geometry. This used to work in Qt 5.3.0 because
the screenSize and size of the available geometry was identical
on startup, but in Qt 5.3.1 the available geometry is 0x0 until
there the metrics are actually available to avoid flickering on
startup, so this caused a regression.

[ChangeLog][Android] Fixed regression where QScreen::physicalSize()
would return 0x0.

Change-Id: I6c2ee11205427a88764e129b05ece6d3fbbf4c99
Task-number: QTBUG-39978
Reviewed-by: Christian Stromme <christian.stromme@digia.com>
Reviewed-by: BogDan Vatra <bogdan@kde.org>
2014-07-08 08:32:32 +02:00
Friedemann Kleint
cdbd3c412c Use QDropEvent::acceptProposedAction() in drop handlers of QAbstractItemView.
Fix updating of the drop cursor when the user presses/releases the
shift key while dragging.

Task-number: QTBUG-39822
Change-Id: I1d9d3a80d349f7e405db24f8f7dc372428c34f52
Reviewed-by: David Faure <david.faure@kdab.com>
2014-07-08 04:32:47 +02:00
Thiago Macieira
d812682aa4 Rename QSysInfo::cpuArchitecture and fullCpuArchitecture
To buildCpuArchitecture and buildAbi, respectively.

Change-Id: If84852eb4ef48a6e1fb4351f7a1a4434b4dc3f72
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
2014-07-07 23:49:30 +02:00
İsmail Dönmez
9569836668 Document QApplication::cursorFlashTime() can return -1
On Windows QApplication::cursorFlashTime() can return -1 if keyboard
blinking is disabled. Add documentation for that case.

Change-Id: I1e5d683573e55b045e2d9bd9804daf4be579fd02
Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
2014-07-07 19:31:24 +02:00
Niels Weber
81bd9633cc Fix for code snippet in commandlineparser documentation
One line in the code snippet wasn't translated whlie the others were.

Change-Id: Ie77a317833f800087b485609cd001dd26060a40f
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@digia.com>
2014-07-07 13:58:24 +02:00
Friedemann Kleint
3f60bd305a Add convenience function for checking screen changes to QPlatformWindow.
Add function returning the screen for a new geometry for geometry
change events. This ensures that the checking is done in platform
screen coordinates (which might differ from QScreen coordinates
due to high-DPI changes) and also that no screen changes are
emitted for child windows.

Change-Id: I406750f59f006f834c386d09c0c85a804014924a
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
2014-07-07 13:08:46 +02:00
Andras Becsi
16baadab11 Add support for querying "glxconfig" from native interface
This makes it possible to retrieve the GLXFBConfig used by Qt to
create the GLXContext. QtWebEngine on desktop needs this so that
Chromium can use the same config as Qt to eliminate BadMatch errors.

Change-Id: If18c0937b5af3e457ddbfda035e5d652230211c6
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
2014-07-07 16:18:24 +02:00
Jocelyn Turcotte
56ce6ba979 Expose internally QAuthenticator::setRealm
This allows QtWebEngine to use the class API on top of the
Chromium network stack.

Change-Id: If595e30cfa6ecdc62cba8453d8f57ddccc1793d9
Reviewed-by: Peter Hartmann <phartmann@blackberry.com>
2014-07-07 15:04:45 +02:00
Frederik Gladhorn
3b28d3d1c0 Make QAccessibleEditableTextInterface docs public
Task-number: QTBUG-40103
Change-Id: I22c678e38e395fa50fc26b456e9fcc2adcae14e6
Reviewed-by: Caroline Chao <caroline.chao@digia.com>
2014-07-07 13:48:37 +02:00
Frederik Gladhorn
4f9427977c Accessibility: Improve handling current value
Value interfaces on OS X and iOS can be strings, so can the value
property of MSAA. Before we'd always only send doubles, instead
change it to use strings as well.

Change-Id: I1b4410c68238ba7a69a5507d87c251f2ac61c568
Reviewed-by: Caroline Chao <caroline.chao@digia.com>
2014-07-07 12:55:58 +02:00
Laszlo Agocs
3e91d06a39 Fix corruption with QQuickWidget and QOpenGLWidget on ANGLE
This only ocurred in -opengl dynamic builds on Windows, when using
ANGLE. The !QT_OPENGL_ES_2 code path did not correctly check for ES.

We also need to avoid using REPEAT, just to be safe on ES2 implementations
(embedded devices typically) that will not do repeat on non-power-of-two textures.

Task-number: QTBUG-39638
Change-Id: I2eeab6627c17255373193c0a0fec8923f711e28c
Reviewed-by: Andrew Knight <andrew.knight@digia.com>
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
2014-07-07 12:55:25 +02:00
Laszlo Agocs
e7056a8969 Add context adoption support for WGL
This is trickier than the GLX and EGL implementations due to the
way pixel formats, windows and contexts work. Apart from some
restrictions, it should be fully functional nonetheless.

Add also some proper documentation.

Change-Id: Ia6e3eb1ab2701e439b8621b9092c2b0934ff2151
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
2014-07-07 12:55:16 +02:00
Nico Vertriest
637ac8a81e Doc: removed trolltech.com from namespace in manual qdocconf file
Task-number: QTBUG-23270
Change-Id: Id65ded1adbbb4f15ef5634f9a984c6cfad5c18d5
Reviewed-by: Martin Smith <martin.smith@digia.com>
2014-07-07 12:38:27 +02:00
Christian Strømme
f17494e9b8 Android: Refactor exception checking in qjni.
In places where we call java/jni functions that can throw exceptions,
we check and clear the exception, if necessary. This change moves
the "checking" code into a single (private) function.

Change-Id: Ic3de2be51305972b096e1ed0a477e341eb5d9404
Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
2014-07-07 12:00:57 +02:00
Mitch Curtis
a2948e1387 Fix typo in QGraphicsView documentation.
Change-Id: Ib750a78e86b8af87d091705a1107ca1eccf32389
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2014-07-07 11:44:16 +02:00
Bernd Weimer
d8103d0e62 QNX: Override QPlatformScreen::grabWindow
The grabWindow API basically should return a screenshot at the window
location. On QNX only the SCREEN_DISPLAY_MANAGER_CONTEXT can read from
the screen which will require root privileges.
At least this will fix some QWidget auto tests that rely on this API.

Change-Id: I350233173d3aecd376f48af9f650606a5cce6205
Reviewed-by: Fabian Bumberger <fbumberger@rim.com>
2014-07-07 09:36:12 +02:00
Olivier Goffart
d49f7168ab QObject: don't hold mutex when copying arguments in a QueuedConnection
QMetaType::create can call user code and we should not keep mutex held as
this may cause dead lock.

Make sure the tst_qobjectrace actually emit some signal so the test check
there is no race if the receiver object is destroyed while
the mutex is unlocked.

Task-number: QTBUG-39990
Change-Id: I56ca1ae7a11cd7b33c1a68727370972862e11c2f
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2014-07-07 08:45:56 +02:00
Thiago Macieira
7e488626ab Don't look up a QChar's digit value more than necessary
It isn't a particularly complex operation, but why waste CPU cycles?

This is the kind of function that should be declared pure/const.

Change-Id: I13f03ef0f87607f7649c66beeb37614a31ef2a10
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
2014-07-07 07:12:10 +02:00
Thiago Macieira
9eceb21d62 Add missing detection for some 64-bit architectures
Architectures missing were arm64, mips64, power64, s390x and sparcv9
(sparc64, but we're using the name that matches the Q_PROCESSOR_xxx
define, which in turn matches Solaris's psrinfo output).

Change-Id: I50b8152b3c42589b98db157b9efeae2be6a90414
Reviewed-by: Kai Koehne <kai.koehne@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2014-07-07 03:51:54 +02:00
Thiago Macieira
2fe90a61bd Mark all QChar static functions as [[gnu::const]]
The GCC documentation says that a const function is not allowed to read
global memory. This needs to be clarified: it's not allowed to read RW
global memory. It's fine to read read-only memory, as that is equivalent
to just pure code.

The QChar static out-of-line functions only lookup a property of the
given Unicode character and always return the same value.

The only exception is the decomposition() function, which returns a
QString and is therefore not allowed to be marked const.

Change-Id: Id36b2f84a1b8ff9db5acf1d4e59e8b3811068cff
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
2014-07-07 03:51:43 +02:00
Thiago Macieira
11c30f9705 Remove QT_STATIC_CONST
This macro is no longer used. It was introduced probably by mistake,
due to MSVC not following the strict string requirement of the C and
C++ standards by default (you can assign a string literal to a
non-const char*).

Change-Id: I4b221dd435191b0eea689dbed35915cf3206648b
Reviewed-by: Martin Smith <martin.smith@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2014-07-07 03:51:41 +02:00
İsmail Dönmez
a6ec09d7ed Fix QTimer with negative interval in QWidgetLineControl::setCursorBlinkPeriod
When keyboard blink is disabled, msec will be negative (-2 in my case).
In that case if (msec) will evaluate to true and create a QTimer
with a negative interval. Fix is to check for msec > 0.

Change-Id: I5c8d82c3cdaf26a961c986f4164805aacfe3ae37
Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
2014-07-06 20:16:18 +02:00
Thiago Macieira
16dccb24e4 Attempt to work with Visual Studio in -Za (strict ANSI) mode
Visual Studio always treats enum values as signed int, even when the
value doesn't fit in a signed int (like 0x80000000 or larger than 32-
the tags themselves are still signed. That causes ambiguity in creating
a QFlag from an enum value.

Visual C++ defines __STDC__ in C mode, but we have no macro in C++ mode.

Also note that the Windows SDK headers don't compile in -Za mode.

Task-number: QTBUG-39700
Change-Id: Ia943cef37ac1f539bd461c3c18200b0c365c72b3
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2014-07-05 23:03:59 +02:00
Thiago Macieira
1d111091b5 Make QTextStream use group separators in floating-point numbers
Like for integers, this is activated only on QLocales other than C.

[ChangeLog][QtCore][QTextStream] QTextStream now uses group separators
when writing floating-point numbers when the locale is not the C locale.
The old behavior can be restored by setting QLocale::OmitGroupSeparator
on the locale.

Change-Id: Ie451b91017746c3a9b11b6211b2ddd09cd295cd2
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
2014-07-05 19:06:14 +02:00
Allan Sandfeld Jensen
8a031696a1 Make QOpenGLTextureCache::bindTexture upload efficiently
Currently QOpenGLTextureCache::bindTexture always convert any uploaded
image to RGBA8888 before uploading. This is quite inefficient when
OpenGL natively supports uploading formats in the original format.

This patch adds support for uploading a few native QImage formats. This
also get the performance of QOpenGLTextureCache::bindTexture on par with
QGLContext::bindTexture.

The texture brush used by QOpenGLPaintEngine is also converted to QImage,
since bindTexture will convert it to QImage anyway, and going over QPixmap
may cause an unnecessary conversion.

[ChangeLog][QtGui][QOpenGLTextureCache] Support uploading common QImage
formats directly to OpenGL when supported.

Change-Id: I828a763126441a98e4547c32ef52dddf7c129a32
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
2014-07-04 16:09:27 +02:00
Leo Franchi
0eefa785a0 Support transparency in qt5 system tray icons, regardless of tray visual
This ports the Qt4 method of supporting the system tray
window visual that has an alpha channel as well as ones
that do not. We detect whether or not we have a 32-bit
format and either use a Qt::transparent background, or
call xcb_clear_region before painting the icon.

[ChangeLog][Linux/XCB] Fix transparency of tray icons in cases where
there is no alpha channel or system tray visual.

Task-number: QTBUG-35832
Change-Id: I43d500c39846d2916dd39f8c47c8d85e59b49cae
Reviewed-by: Uli Schlachter <psychon@znc.in>
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@digia.com>
2014-07-04 15:32:45 +02:00
Alessandro Portale
6577ac381e Windows: Use native-looking drag cursors
QWindowsDrag::defaultCursor() used xpm-based cursors which are aliased,
dark and not available in different sizes.

This patch uses the new cursors from QWindowsCursor::customCursor for
the drag cursors and gets the ignoreDragCursor from the system. If
fetching the ignoreDragCursor cursor fails, we still fall back to the
ignoreDragCursor.xpm.

The other xpms were moved to QWindowsDrag::defaultCursor() for the WinCE
or non-png case.

Change-Id: If216ffc8c9cc134529b7addd0121857d41805eac
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2014-07-04 15:20:18 +02:00
Frederik Gladhorn
14a80bd4df Merge "Merge remote-tracking branch 'origin/5.3' into dev" into refs/staging/dev 2014-07-04 18:46:06 +02:00
Allan Sandfeld Jensen
3acd4b546d QImage support for RGB30 formats
Adds basic support for 10-bit per color channel formats to QImage
and the XCB plugin. This will make it possible to paint to and from
these formats, but only at 8-bit per color channel accuracy.

This also fixes Qt5 applications on X11 with native 30bit depth.

[ChangeLog][QtGui][QImage] Added support for 10-bit per color channel image formats.

Task-number: QTBUG-25998
Change-Id: I93ccd3c74bfbb0bd94b352476e5fe58a94119e1f
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
2014-07-04 14:03:46 +02:00
Tor Arne Vestbø
715b41ce48 iOS: Fix compilation warning
warning: unused variable 'iface' [-Wunused-variable]

Change-Id: I882b71e5ae4afac1f3eb8b59d378b1a0c6fcade1
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
2014-07-04 12:29:37 +02:00
Jerome Pasion
e4661df947 Doc: Removed "url" variable from qdocconf files.
url is set in qtbase/doc/global which is inherited by the
Qt 5 module qdocconf files.

Change-Id: Ieffa174f598f4a3b8ce8be9bfae7ca9b6981f12b
Reviewed-by: Martin Smith <martin.smith@digia.com>
2014-07-04 12:12:29 +02:00
Niels Weber
9a5b0265d0 Fix compiling with -no-opengl
Task-number: QTBUG-39982
Change-Id: Ib3fc49c89472fbaf77abea0b463e380725440613
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
2014-07-04 11:33:14 +02:00
Allan Sandfeld Jensen
dec5fb4bf9 Improve QOpenGLFramebufferObject::toImage()
This patch makes it possible to use QOpenGLFramebufferObject::toImage()
together with QOpenGLPaintDevice::setPaintFlipped where the FBO is
already mirrored.

The patch also makes checks for proper BGRA support before trying to use
it, and fixes the rare case of OpenGLES on big endian.

[ChangeLog][QtGui][QOpenGLFramebufferObject] Introduce an argument
to QOpenGLFramebufferObject::toImage() to save mirroring the result.

Change-Id: I163d802736b7059411f7dda96a31385d772823cc
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
2014-07-04 11:19:08 +02:00
Kai Koehne
21c8385105 Windows: Fix build with QT_NO_OPENGL
Fixes compiler breakage introduced in 39e0607825.

Change-Id: I39813018915a70b848ca9377089e262952715545
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
2014-07-04 11:02:36 +02:00
Mitch Curtis
76371c4d56 Improve QListWidget documentation.
Mention that removeItemWidget() isn't sufficient to remove a row.
List related functions so that it's easy to see the relation
between them.

Change-Id: Ia1d467390f00976e2276d50df35dd555f7992a9a
Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
2014-07-04 10:59:24 +02:00
Frederik Gladhorn
f01c5cdb8d Update copyright to 2014 for accessibility
Change-Id: I4210456122bf8a6d3730f017f3ce6dd1a1bcb3f5
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2014-07-04 08:59:21 +02:00
Frederik Gladhorn
3066cb37a9 Accessibility Windows: Add shortcuts to name
Under windows it is customary to add the shortcut (e.g. Ctrl+O) to the
accessible name.

Task-number: QTBUG-38915
Change-Id: Ib79f8624346a1d9d08381e815383ddcdda2d0488
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
2014-07-04 08:58:59 +02:00
Frederik Gladhorn
01f1e10695 Accessibility Linux: Implement set focus action
This is used by Orca for geometric navigation (aka flat review) to move
the focus around. It is also generally sensible to be able to
programatically move the focus around. This way of moving the focus
is redundant with the action interface's focus action.

Task-number: QTBUG-40048
Change-Id: I1b61ea843f6bfc3dc00007772e0e5102555ca752
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
2014-07-04 08:58:42 +02:00
Jędrzej Nowacki
9c79f6dfb3 Add initializer list support in QJsonArray
It allows to create a QJsonArray instance in C++ by using
a similar expression to JSON. For example:

QJsonArray a = {1, 2, 4};

[ChangeLog][QtCore][QtJson] QJsonArray now supports
C++11 initializer lists.

Task-number: QTBUG-26606
Change-Id: Icc352e518d9649d24176c89e7113d200d5c50b0d
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2014-07-04 08:24:05 +02:00
Martin Smith
391b2accd8 qdoc: ASSERT failure while writing index file
An attempt was made to write an XML attribute after the
atart tag had been closed. This has been fixed by moving
some code around.

Change-Id: I279d91c345f4217dab8fc47faabe3350258d9ece
Task-number: Qt QTBUG-40039
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
Reviewed-by: Mitch Curtis <mitch.curtis@digia.com>
2014-07-04 07:55:34 +02:00
Friedemann Kleint
d7bb914ac8 Fix debug output of QTouchEvent.
Return dbg.space().

Task-number: QTBUG-29946
Change-Id: Ia79b297ee3801ccba9f7b1c22ac7a8761cbe8b2e
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
2014-07-04 06:29:32 +02:00
Frederik Gladhorn
39a290af6c Merge remote-tracking branch 'origin/5.3' into dev
Conflicts:
	src/gui/accessible/qaccessiblecache_mac.mm
	src/gui/accessible/qaccessiblecache_p.h
	src/plugins/platforms/cocoa/qcocoaaccessibilityelement.h
	src/plugins/platforms/cocoa/qcocoawindow.h
	src/plugins/platforms/cocoa/qcocoawindow.mm
	src/widgets/kernel/qwidget_qpa.cpp

Manually moved change in qwidget_qpa.cpp to qwidget.cpp
    (cd07830e3b)

Change-Id: Ia51f471f9b53de2f3b07d77ea89db9303ac8961d
2014-07-03 23:56:45 +02:00
Friedemann Kleint
9150563940 Windows clipboard: Deny CF_DIB support for images with alpha.
Support CF_DIBV5 for these images so that transparency is preserved.

Task-number: QTBUG-11463
Change-Id: I51881ae8bfbd05b92abd309766f4da9a7ea26c2d
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2014-07-03 22:43:17 +02:00
Liang Qi
88a47439d1 Doc: fix a link in QAbstractOpenGLFunctions documentation
Change-Id: Icc0109de22de756f7e4b3e888b0ee28a9b9c04d5
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
2014-07-03 20:01:26 +02:00
Frederik Gladhorn
5b4c996f36 Accessibility Linux: Fix crashes when accessing invalid functions
There is no way to prevent ATs from calling random functions on DBus.
While these functions shouldn't exist when we don't advertise the
interface, they should just fail gracefully.

Task-number: QTBUG-40044
Change-Id: Ia29b49b16feabc0beb80007456e53497f230c7d4
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
2014-07-03 18:20:04 +02:00
Frederik Gladhorn
71c58f0369 Fix build with -no-accessibility
Change-Id: Ib66d806b978c9e187d614fe1c553db7dc2b4ffaa
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
2014-07-03 15:08:44 +02:00
Martin Pley
1a32cc0ae4 QPdf::addImage(): avoid a QImage detach when it's in an acceptable Format
Don't detach QImage, when it's in Format_Mono or Format_ARG32.
Use QImage::constScanLine() instead of QImage::scanLine().

Change-Id: I30fcafb576aea3189637a40fd75f77c70017ba46
Reviewed-by: John Layt <jlayt@kde.org>
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
2014-07-03 11:15:15 +02:00
David Faure
aabe80ae28 Make QDom/QXmlSimpleReader reentrant.
I moved the evil static bool to QXmlSimpleReaderPrivate, and used
it from QDom, when the reader instance is a QXmlSimpleReader
(if it's not, nothing happens, like before).

Task-number: QTBUG-40015
Change-Id: I54ba89db334d7b086379c4a6840cf0de23f77027
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2014-07-03 10:59:07 +02:00
David Faure
e26fa6d206 Move QXmlReaderPrivate to private header.
First step for making QXmlSimpleReader reentrant.

Task-number: QTBUG-40015
Change-Id: I1666672b1759adb745b86ce58488142f3c66d3f5
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2014-07-03 10:58:56 +02:00
Mitch Curtis
b398515b09 Tidy up and expand QSharedPointer documentation.
Also adds the 5.4.0 changes file.

Change-Id: I10967ca179b91229e7d1ee0fc666bbd8dbe54425
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2014-07-03 10:57:40 +02:00
Erik Verbruggen
3fd2f0b7d8 ARM: do not use the clang integrated assembler in some cases.
The integrated assembler of clang does not understand some/all of the
ARM macro assembler syntax used in pixman-arm-neon-asm.S. By default,
this integrated assembler is used when using the "clang" command as a
driver. This patch turns off the integrated assembler of clang for that
file.

Change-Id: Ic06801266b5a4b097ca835d815bcc5d5fc672946
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2014-07-03 10:10:30 +02:00
Gunnar Sletta
de1d5815c1 Fix typo in 'time' message pattern.
Change-Id: I3f3861a0307aad9d5bb92c0fdeb719950aa370c8
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
2014-07-03 09:34:08 +02:00
Alessandro Portale
7de95ede1b Windows: Add non-standard mouse cursors
Windows does not provide SplitVCursor, SplitHCursor,
OpenHandCursor, ClosedHandCursor, DragCopyCursor,
DragMoveCursor, DragLinkCursor.

This change adds those mouse cursors mimicking the look
of the standard Aero cursors. 32px, 48px and 64px for
each one.

For WinCE or if Qt is configured without png support, the
behavior should not be changed by this patch.

Task-number: QTBUG-38993
Change-Id: Ic0f739d7c5031168b7d105b4d41271a9359d0728
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2014-07-03 09:33:38 +02:00
Morten Johan Sørvig
5f3ec26d90 Add opt-out environment variable for @2x images
There are cases where @2x images are in use but
where you don't want the associated behavior:
- You are implementing an image editor
- You are inheriting a resource set which has @2x
  images, but don't want that behavior with Qt.

Add support for disabling @2x behavior with QT_HIGHDPI_DISABLE_2X_IMAGE_LOADING.

Change-Id: I206e050b6241f8935b4404c7a28b024a9e00d46c
Task-id: QTBUG-38485
Reviewed-by: Jake Petroules <jake.petroules@petroules.com>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
2014-07-03 09:15:42 +02:00
Friedemann Kleint
0831cb26f4 Ensure that QTemporaryFile clears all file mappings.
Factor out code to clear all mappings into
QFSFileEnginePrivate::unmapAll() and call that
from QTemporaryFile.

Task-number: QTBUG-39976
Change-Id: Ic1ceeba0ba4451866f1081fee430e5c458c0819d
Reviewed-by: Jonathan Liu <net147@gmail.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2014-07-03 06:34:51 +02:00
Friedemann Kleint
ba92215432 Add fixme-comment to QWidgetResizeHandler.
Task-number: QTBUG-34352
Change-Id: I2415bdf125f90f5cd4f5af55e7ec6bb8ef48217e
Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
2014-07-03 06:33:39 +02:00
Friedemann Kleint
135e9d5a82 Implement QWidget::grabCursor(const QCursor&).
Implement using QGuiApplication::setOverrideCursor().

Task-number: QTBUG-39311
Change-Id: I83e289bfd5e911c31f08df9a4fc17fb8a0cf27f2
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
2014-07-03 06:32:50 +02:00
Friedemann Kleint
a4c4c12f0a QDockWidget: Delay-create QWidgetResizeHandler.
Task-number: QTBUG-34352
Change-Id: Ia7e5d8038b334686bedeee60c35656f3ab948e4c
Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
2014-07-03 06:31:01 +02:00
Aleix Pol
5f50416620 Make it possible to know when a screen is being removed
So far, we had to listen to the QObject::destroyed signal from the QScreen
class to figure out whether a screen was removed. Often, this is already
too late, given that most of the QWindows have been moved by then and we
don't get to react before the windows are being set to the primary screen.

This patch introduces a new signal that will notify about a screen removal
before the screen is started to be destroyed, so that the application gets
to decide what to do with the screens before Qt decides to move things around.

[ChangeLog][QtGui][QGuiApplication] Added QGuiApplication::screenRemoved
signal to inform that a screen has been removed, before Qt reacts to it.

Change-Id: I99304179f4d345cae581a87baac6cff7b8773dea
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
2014-07-02 23:14:19 +02:00
Laszlo Agocs
0541516907 Use the standard functions in GLES3 builds in VAOs
There is no guarantee that the OES extension is present and the standard
functions are not required to be dynamically resolvable on ES.

By performing the ARB-style lookup for the suffixless function names we
can also support ES3 compatible contexts on desktop GL.

This also fixes the problem of picking up the APPLE extension functions
instead of ARB when both are available. vaoFuncsType was set to ARB correctly
but the helper has to take the preference of ARB into account too.

Task-number: QTBUG-38168
Change-Id: If7402320e8f96891017674f3c43bc57c4b5d29f3
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
2014-07-02 19:53:20 +02:00
Adam Majer
c714695304 Add support for initializer_list construction in QFlags
[ChangeLog][QtCore][QFlags] Added initializer_list constructor

Task-number: QTBUG-39786
Change-Id: I36967c67b489c2a893fb031954f46f5243aba2c4
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2014-07-02 14:49:45 +02:00
Laszlo Agocs
e8bb49e1d4 Report keyboard modifiers in evdevmouse
Mouse and wheel events have no modifiers set. This is not ideal.
Pass at least QGuiApplication::keyboardModifiers() to get the
modifiers from the last key event.

Task-number: QTBUG-39812
Change-Id: Ica0c338c60c3e289dccfafa5aa6d602d4e111ad5
Reviewed-by: Leonard Lee <leonard.lee@digia.com>
Reviewed-by: Will Wagner <willw@carallon.com>
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
2014-07-02 14:40:53 +02:00
Maarten Lankhorst
19d289ab1b Listen to touch events on the master device instead of slave.
Listening to touch events on the master prevents pointer emulation
events from being generated, alleviating the need to grab.

Grabbing on the slave device is buggy, and breaks pointer emulation
on all current servers that support XInput 2.2 due to a bug in the
server, and will also grab unwanted touch events.

For reference, see https://bugs.freedesktop.org/show_bug.cgi?id=78345

Reverts 2c65b78b40.  The idea of
enabling each touchscreen separately was introduced in
4dbf574b7acb7ae8f852219700afa95f8d568f0e; that aspect is also
reverted.

Change-Id: I30d36397aa4ff2fb7a8ad2bbb94c2a13abd472b4
Task-number: QTBUG-38625
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
2014-07-02 13:55:42 +02:00
Morten Johan Sørvig
cd07830e3b Cocoa: Handle Qt::WA_ShowWithoutActivating
Forward the flag to QWindow by setting the _q_showWithoutActivating
property on the window in QWidgetPrivate::create_sys().

Implement by refusing to become the key window
or first responder during QCocoaWindow::setVisible().

Task-number: QTBUG-19194
Change-Id: I8446927ec510d7226a5a7b51b7be49d2f9bfd098
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
2014-07-02 12:56:32 +02:00
Morten Johan Sørvig
3c982a6384 Cocoa: Handle Qt::WindowDoesNotAcceptFocus
Make windows with the Qt::WindowDoesNotAcceptFocus
flag refuse to become the key window.

This is in addition to the existing refusal to become
the first responder in QNSView. Refactor the common
test into a new function:
bool shouldRefuseKeyWindowAndFirstResponder()

Task-number: QTBUG-32385
Change-Id: I31021b5d8895a17c48f94f3691e6590c90b68627
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
2014-07-02 12:56:24 +02:00
Tim Blechmann
4f155b0535 Cocoa: Fix Qt-in-namespace build.
Wrap cocoa classes in namespace macros.

Task-number: QTBUG-39382
Change-Id: Id840e666105afca21760fcb529b5765e0a534120
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
2014-07-02 12:56:06 +02:00
Morten Johan Sørvig
62f1aa7ca7 Cocoa: Separate framestrut and normal button state
Frame strut button state can get out of sync due to
missing calls to handleFrameStrutMouseEvent, typically
when a mouse down is sent but the mouse up isn't.

There is no reason this should interfere with normal
button state: Add m_frameStrutButtons for tracking
the frame strut button state.

Change-Id: Ia21700af94fe000c73088b7657237372f3a04bf8
Task-number: QTBUG-39810
Reviewed-by: Eike Ziller <eike.ziller@digia.com>
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
2014-07-02 12:55:55 +02:00
Gabriel de Dietrich
769af66893 QMacStyle: Fix focus frame rendering in Yosemite
Using the HITheme API would result in the frame's right edge
to be missing.

Instead, we use the recommended technique to draw the focus 
ring around a custom NSCell. (See 
https://developer.apple.com/library/mac/documentation/Cocoa/Conceptual/ControlCell/Articles/ManipulateCellControl.html)

Change-Id: I12d4834d353b5cbd5893bf070b14ad0d8bb75634
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
2014-07-02 12:44:49 +02:00
YAMAMOTO Atsushi
07297c4eaa Doc: Fix qRound64 Example documentation
Change Example code for qRound64.
qRound to qRound64 and int to qint64.

Task-number: QTBUG-39932
Change-Id: I6b423013ed539eaec396c84945e7a885b198aec4
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2014-07-02 11:20:59 +02:00
Shawn Rutledge
90053954b8 OS X: when opening a URL via QFileOpenEvent, pass as QUrl
Opening a file from Finder and opening a URL from the browser are two
different operations, and the URL might not be a local file.

Task-number: QTBUG-39972
Change-Id: I467dfef7efe8eb88c922410db16137e135bc8133
Reviewed-by: Jake Petroules <jake.petroules@petroules.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2014-07-02 10:52:26 +02:00
Bernd Weimer
375b52f20f QNX: Override QPlatformScreen::topLevelAt
Implemented QQnxScreen::topLevelAt method, as base implementation
returned wrong results. This fixes "tst_qwidget widgetAt" for instance.
Removed related method, that is not used at all.

Change-Id: I25c4f474cb0d661e5e5cdcdd0ab13d670fd4dc37
Reviewed-by: Fabian Bumberger <fbumberger@rim.com>
Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
2014-07-02 10:29:33 +02:00
Tasuku Suzuki
5250e4f157 xcb: make sure to update window title when it is changed
Task-number: QTBUG-33775
Change-Id: Ibe346c4304532d031bfa1c9b4d73cd02d1e5a64f
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
2014-07-02 09:50:30 +02:00
Andreas Holzammer
23961aa54c WINCE: Fix grabWindow
BitBlt does not support CAPTUREBLT under
Windows Embedded compact. It was before defined to
the value it would have for a desktop Windows,
but as it looks if the bit gets set for Windows
Embedded Compact he does not do the right thing
anymore. So lets define it to 0 so that we dont
do any harm.

Change-Id: I447ebcd90eb9ae7c64f931aa8859b83794f201a0
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Björn Breitmeyer <bjoern.breitmeyer@kdab.com>
2014-07-02 09:12:12 +02:00
Timur Pocheptsov
1529a3df95 Empty icons and Cocoa menu items.
Clear menu item's image if QImage is empty (isNull).

Task-number: QTBUG-39557
Change-Id: I8145b67342b0361da2bb945070603cc182202b71
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
2014-07-02 09:09:03 +02:00
J-P Nurmi
82d906a20d QGuiApplication::paletteChanged(const QPalette &palette) [signal]
This allows QQuickSystemPalette to listen to palette changes without
installing an expensive event filter on the application object.

Change-Id: I8b693e047d993c444e393d7a714a5709692c3560
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
2014-07-02 00:44:18 +02:00
Giuseppe D'Angelo
9e5765fba0 QOpenGLTexture: fix the feature test for Buffer Textures
1a4ff6f122 modified the features test
by checking extensions as well as the GL version. The problem was that
the GL version was wrong in the first place -- buffer textures are
natively supported since OpenGL 3.0, not 4.3.

4.3 introduced support for buffer texture ranges, i.e.
ARB_texture_buffer_range; however it's pointless to take the highest
requirement, especially considering that so far QOpenGLTexture doesn't
wrap glTexBuffer(Range) in any way. In the future, if QOpenGLTexture
will also wrap glTexBuffer, then we will also be able to introduce
a different feature flag for testing buffer texture ranges.

Change-Id: I6becbd49ac26d44ce01d088cbb7831b5cc127bdb
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
Reviewed-by: Paul Lemire <paul.lemire@kdab.com>
2014-07-01 23:26:37 +02:00
David Faure
9ee27005ee qDebug: fix data race in qt_message_print
The setting of (static) messageHandler to qDefaultMessageHandler if null
was happening in multiple threads simultaneously, so it needs synchronization.

Used an atomic pointer in case qInstallMessageHandler is called from a thread,
but more importantly, initialized the static vars right away.

Improve auto test to ensure that qInstallMessageHandler(0) still sets the
default message handler.

Change-Id: I70335af38c1d28a1cdba1df8a79c6006f227422e
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2014-07-01 20:23:31 +02:00
Jan Arve Saether
b31c9d8c03 Accessibility OS X: Publish synthetic increase and decrease actions
Increase and decrease actions can be generally applied to any value
interface. We therefore make them available regardless of the
existence of any action interface.

Change-Id: If5916c7cfd79812e2139e882a397ac1e040aca78
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
2014-07-01 19:01:36 +02:00
Frederik Gladhorn
e6a94778d0 Merge "Merge remote-tracking branch 'origin/5.3' into dev" into refs/staging/dev 2014-07-01 18:41:14 +02:00
Frederik Gladhorn
0272ce6417 Accessibility Windows: Do not assert on invalid indexInParent
We try to but don't always guarantee a valid hierarchy, having
applications crash because of this is not a good idea.
The assert currently triggers when showing message boxes.
Fix for the message box case is in progress but this may happen in other
situations.

Change-Id: I6f82b23c8abfcb7f91ecde0584f0e01bd8216ca1
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
Reviewed-by: Caroline Chao <caroline.chao@digia.com>
2014-07-01 17:21:20 +02:00
Thiago Macieira
256f810be3 Fix annoying warning from ICC 14 on Windows
It says that defining a macro that does defined() is not portable. The
solution implemented for MSVC 2008 and earlier does work, however, and
is portable to all compilers (the parentheses around the macro are
unnecessary).

Incidentally, this makes d98004cd2f
actually work: Q_CC_MSVC wasn't defined at that point in the file, so
that change had never taken effect.

warning #3199: "defined" is always false in a macro expansion in Microsoft mode

Task-number: QTBUG-39597
Change-Id: Iaa2895e7f63d97c439090043435a2b8d2f185c3a
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
2014-07-01 17:17:27 +02:00
Frederik Gladhorn
a09a8d509a Merge remote-tracking branch 'origin/5.3' into dev
Conflicts:
	mkspecs/qnx-x86-qcc/qplatformdefs.h
	src/corelib/global/qglobal.h
	src/network/socket/qnativesocketengine_winrt.cpp
	src/plugins/platforms/android/androidjniaccessibility.cpp
	src/plugins/platforms/windows/qwindowswindow.cpp

Manually adjusted:
	mkspecs/qnx-armle-v7-qcc/qplatformdefs.h
	to include 9ce697f2d5

Thanks goes to Sergio for the qnx mkspecs adjustments.

Change-Id: I53b1fd6bc5bc884e5ee2c2b84975f58171a1cb8e
2014-07-01 16:25:19 +02:00
Jerome Pasion
bcbf38b701 Doc: Various \note fixes in Qt namespace documentation.
-changed \note and \warning to "Note:" and "Warning:"
-\note and \warning split the table.
-other minor \note changes

Task-number: QTBUG-36972
Change-Id: I88042550cd01101e7225cd3b5f4e0115ea102ea9
Reviewed-by: Liang Qi <liang.qi@digia.com>
Reviewed-by: Martin Smith <martin.smith@digia.com>
2014-07-01 13:01:31 +02:00
Oliver Wolff
2ddc0fcd9b winrt: DNS lookup: don't have duplicate entries
Change-Id: I60ee29bd692f8e385080d4532a0e3230942a2cd3
Reviewed-by: Andrew Knight <andrew.knight@digia.com>
2014-07-01 12:59:06 +02:00
Frederik Gladhorn
605ba2c226 Fix init order of platfromIntegration and forcedWindowIcon
The problem shows when running tst_qguiapplication.cpp and configuring
with -no-widgets

Change-Id: I9f241760953e543d488096c66a3e886a14f6ae50
Reviewed-by: David Faure <david.faure@kdab.com>
2014-07-01 11:56:07 +02:00
Friedemann Kleint
e4becdc3d3 Move deletion of the QDrag object into QDragManager::drag().
The QDrag objects were apparently leaking on all platforms
other than XCB.

Task-number: QTBUG-39651
Change-Id: I09efcd250c1f42eb385e9d5779be7af6b9b59376
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
Reviewed-by: Tim Jenssen <tim.jenssen@digia.com>
2014-07-01 14:08:09 +02:00
Thiago Macieira
7beca6e20f Remove the rcc output file if we failed to write it
This happens if the second pass failed to find the signature data in the
compiled output, which can happen if the compiler is not *actually*
compiling anything (LTO / LTCG mode).

If we left the unmodified file in the output, make would continue
running next time it was invoked, resulting in bad data.

Change-Id: I97f23a89a1ca1f8b8c449b0744de3f0c78daa706
Reviewed-by: hjk <hjk121@nokiamail.com>
2014-07-01 13:31:23 +02:00
Robin Burchell
685655c4a5 qdoc: Add header file debug output to match source file debug output
Change-Id: If8c941be42986704e9ac4da056a6c4b2490e6131
Reviewed-by: Martin Smith <martin.smith@digia.com>
2014-07-01 10:56:02 +02:00
Fabian Bumberger
febded2353 QNetworkReply: Fix finish signal is not emitted
When a QNetworkReply is in WaitingForSession state and is aborted the finished signal
was not emitted.

Task-number: QTBUG-37473
Change-Id: Iccc4dfd8e8e65e9e42625a908432ce9083caa231
Reviewed-by: Peter Hartmann <phartmann@blackberry.com>
2014-07-01 10:54:26 +02:00
Thiago Macieira
7a848d5f13 Save the _MSC_VER variable instead of <unknown version>
That way, for future or old versions, we at least will know which
version it is. For example, for MSVC "14.0" (compiler version 19), it
produces "MSVC _MSC_VER 1900".

Change-Id: I86dcaea8e4b23bd052288cea5663b267da31c890
Reviewed-by: Kai Koehne <kai.koehne@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2014-07-01 09:41:29 +02:00
Frederik Gladhorn
2e038d681c Accessibility: Password QLineEdit should use * as text replacement
Change-Id: Ie07e86f1b6dff3096cab462f918994efa07b2a87
Reviewed-by: Caroline Chao <caroline.chao@digia.com>
2014-07-01 08:27:16 +02:00
Thiago Macieira
4b28152da6 Make QFreeList constexpr
It's still not a literal type because the destructor is not constexpr

Change-Id: If89bdfdd3f0ffe9bdd5a7953e872e520e92cfd66
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2014-06-30 21:33:46 +02:00
Gabriel de Dietrich
83f06da1c6 Mac Style: Fix QLineEdit frame in 10.10
Also removes some dead code.

Change-Id: Id590bd56641918a163f8bad251e3e0e750adfc6f
Reviewed-by: Jake Petroules <jake.petroules@petroules.com>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
2014-06-30 17:02:39 +02:00
Christian Strømme
50cf698b76 Android: Fix hover-event handling.
The accessibility delegate needs to intercept the hover events before
the view gets them, but since the dispatchHoverEvent() method was added
in API level 14 and we build with API level < 14, we can't call the
super class implementation (e.g., when the event isn't handled by
the accessibility delegate). In the previous implementation we where
trying to solve this by using the reflection API, but that does not
provide a solution to call the super class implementation
(Note: It's possible with JDK 7 or newer), so the code would call
itself recursively and we would eventually get a stack overflow
exception.

This change uses the OnHoverListener class to intercept the hover
events, this way we avoid "overriding" the dispatchHoverEvent() method
in QtSurface and therefore avoid the problem it causes.

Task-number: QTBUG-38905
Change-Id: I8b3cbad718d8524042397bb877e39e3005bfb4ce
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>
2014-06-30 16:58:57 +02:00
Christian Strømme
8f96ce3733 Android: Fix namespace usage
This change makes it possible to set a Qt namespace for Android builds.

Change-Id: I79f4ae8200223f36f97e2849aae49e45b8850d23
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
2014-06-30 16:58:43 +02:00