Commit Graph

25226 Commits

Author SHA1 Message Date
Thiago Macieira
1a6ac83193 Ensure there's no sign-extension here.
Both e_shentsize and e_shtrndx are ELF half-words, which means C
integers of rank less than int (they're quint16). That means this
multiplcation was done actually as int, due to integer promotion from
unsigned short. So preempt the integer promotion and force them to full-
word integers (unsigned int).

While the bit-pattern result of the multiplication is the same, the
addition with e_shoff (a qelfoff_t = quintptr) wouldn't: the promotion
from 32-bit int to 64-bit would first execute a sign-extension.

Now, this shouldn't happen on regular ELF files, but it cause QLibrary
to crash if a specially-crafted (or simply corrupt) plugin is found.

Found by Coverity, CID 22642

Change-Id: I42e7ef1a481840699a8dffff1407e9f1282eeecf
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2015-09-28 06:39:05 +00:00
Tor Arne Vestbø
126c2cb8fb Clean up cancel operation handling on OS X
The logic for handling cancel operations was spread out through
the code base and sometimes hard-coded to only include the Escape
key shortcut, missing the Command+. shortcut.

We now intercept both attempts at cancel operations from the system
through cancelOperation, which we forward as normal key events.

A new QKeySequence::StandardKey has been added for the Cancel sequence,
which maps to Escape on all platforms, and Command+. in addition for
OS X. The hard-coded logic in QWidget and subclasses for dealing
with closing the dialogs has been replaced with this key sequence,
which allows clients to override the behavior. Note that the widget
code is not wrapped in checks for QT_NO_SHORTCUT, as we don't care
about keeping widgets building and working under that define.

The logic in QCocoaWindow to bypass windowShouldClose when delivering
IM events has been removed as we now handle that specific case by
also forwarding Escape as a cancel operation.

Task-number: QTBUG-47557
Task-number: QTBUG-45771
Task-number: QTBUG-44076
Change-Id: Ibe0b3a4819f8659d246a2142dd7d9cd3a826ef78
Reviewed-by: Tim Blechmann <tim@klingt.org>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
2015-09-27 20:44:17 +00:00
Dāvis Mosāns
e18554d4f7 Network: Use QFile::encodeName for POSIX paths instead of toLatin1
POSIX API doesn't really have defined encoding and kernel works with
null-terminated byte strings (char *) without any knowledge about
encodings.

But usually applications use LANG (and LC_*) as encoding making it
possible to use any encoding user wishes, including full Unicode
support when UTF-8 is used.

This allows to create and listen to sockets with paths containing
non-latin characters.
eg. listen(QString("/run/υποδοχή"));

Change-Id: I022ac6a8a4575103125c48768a66bef88a232a2a
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Dāvis Mosāns <davispuh@gmail.com>
2015-09-27 19:38:29 +00:00
Lorn Potter
bb281eea17 Make sure networkAccessibilityChanged is emitted
Task-number: QTBUG-46323
Change-Id: I8297072b62763136f457ca6ae15282d1c22244f4
Reviewed-by: Timo Jyrinki <timo.jyrinki@canonical.com>
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
2015-09-26 19:14:03 +00:00
Sebastian Lösch
f98c2ef27a Abort underlying socket when aborting QNetworkReply
If we abort a connection in QNetworkReply::encrypted the underlying
socket gets flushed. This patch fixes that no data will be transmitted
after someone called abort().

Change-Id: I59306e69cb9f2e1421b324e11947375130e52135
Task-number: QTBUG-47471
Reviewed-by: Markus Goetz (Woboq GmbH) <markus@woboq.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2015-09-26 19:13:23 +00:00
Frederik Gladhorn
b2e664df61 Enable tst_qaccessibilitylinux
This test caused problems because it relies on the at-spi services to
run. In addition it could trigger orca (screen reader) to be launched
as a side-effect of the dbus call to the screen-reader-enabled setting.
Instead just export QT_LINUX_ACCESSIBILITY_ALWAYS_ON to make sure that
accessibility will work. This means we won't test the dbus startup any
more, but the test will be reliable.
There is still a dbus call to org.a11y.Bus to launch the service in case
it's not running yet.

Task-number: QTBUG-27732
Task-number: QTBUG-44434
Change-Id: Idb86ed98ca4b47cb209027c8b41529e7e5285197
Reviewed-by: Caroline Chao <caroline.chao@theqtcompany.com>
2015-09-26 00:50:44 +00:00
Thiago Macieira
393c8d0b74 Fix ICC warning about use of "defined" in a macro
qhash.cpp(89): warning #3199: "defined" is always false in a macro expansion in Microsoft mode

Change-Id: I7de033f80b0e4431b7f1ffff13fc960bcbb17352
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2015-09-25 20:24:33 +00:00
Thiago Macieira
d90536787b Work around GCC thinking that a variable could be clobbered by longjmp
It can't be. The block in which the variable "s" exists makes no call
to any function that takes the setjmp buffer. This is not a false
positive warning: it's an incorrect warning.

qjpeghandler.cpp:878:6: error: variable ‘s’ might be clobbered by ‘longjmp’ or ‘vfork’ [-Werror=clobbered]

Change-Id: I42e7ef1a481840699a8dffff140681a3d7e34493
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
2015-09-25 20:24:31 +00:00
Thiago Macieira
ddee17e770 Remove QT_WARNING_DISABLE_GCC for Clang
There's QT_WARNING_DISABLE_CLANG for when a warning applies to a Clang
build.

Change-Id: I42e7ef1a481840699a8dffff1406ac36b6a6eac3
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com>
2015-09-25 20:24:20 +00:00
Friedemann Kleint
3cbb89fa5a tst_qprocess: Instantiate QProcess objects on the stack.
Instantiate the QProcess object on the stack to ensure resource
cleanup and remove the QProcess * member variable.
Use qobject_cast<QProcess *>(QObject::sender()) instead
of the member variable in the helpers slots to ensure that signals
from a leaked QProcess do not interfere with other tests.

Task-number: QTBUG-47370
Change-Id: Ifc0dccb7e4b18069d236df53bccdcb6a47df6346
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-09-25 20:22:17 +00:00
Friedemann Kleint
f322e2aa08 tst_qprocess: Port to Qt 5 connection syntax.
Task-number: QTBUG-47370
Change-Id: I09489a6fb4598238fa5e0120bf751fe5af6f31af
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-09-25 20:22:00 +00:00
Takao Fujiwara
4954ad6dbc Qt IBus plugin connects to IBus Bus again if ibus-daemon does not run
Qt5 applications do not enable IBus when the applications are saved in
the session and launched automatically in the next login.
This patch checks the IBus socket path and connect to the bus when
it's available.

Task-number QTBUG-47657

Change-Id: I0883eaa2438fd27455da93f78f392ea3c1abe6b8
Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
2015-09-25 16:40:22 +00:00
Olivier Goffart
0f2da655ac Remove wrong forward declaration
It confuses auto complete

Change-Id: Ida86f6c8dcca351339d2b41ad40cf5701f5bb2c4
Reviewed-by: Richard J. Moore <rich@kde.org>
2015-09-25 11:26:11 +00:00
Nico Vertriest
58664dbeb3 Doc: fixed links to qmake documentation
Task-number: QTBUG-43810
Change-Id: I56676d6f6f95ed79bd1719404b4e48c26490eea6
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
Reviewed-by: Martin Smith <martin.smith@digia.com>
2015-09-25 10:57:51 +00:00
Alexander Volkov
98c10a02c5 xcb: Show buttons on the title bar for QWindow
QWindow by default doesn't have the window flags to display
buttons on the title bar and it's up to the window manager
whether they will be shown. For example, fluxbox doesn't show
the maximize button.

The cocoa plugin and the windows plugin adjust the window
flags in this special case of QWindow to show some buttons,
so do the same in the xcb plugin.

Change-Id: Idc2575cfeaced524dd67eb5ba99126663626e2b0
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
2015-09-25 10:44:12 +00:00
Daniel Nyström
58bed4cda9 eglfs: Support for alternative Mali driver packages
In addition to the proprietary Mali Linux driver bundle from ARM, there
are a couple of semi open source alternative bundles out in the wild,
which are mostly derivatives from the sunxi-mali bundle.

The non-ARM bundles lacks the proprietary header file fbdev_window.h
which defines the fbdev_window struct. Instead, it has an equivalent
mali_native_window struct in the EGL/eglplatform.h (which in turn is
included by EGL/egl.h).

This change adds an alternative configure test which detects the non-ARM
bundles are used. It also removes the dependency on fbdev_window.h by
defining the structure ourselves, which actually makes the plugin
potentially compilable with *any* EGL SDK.

Change-Id: I78ab4b618e8e9c774c889fe9896105cf2cf4228e
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
2015-09-25 10:15:04 +00:00
Erik Verbruggen
5445eb3541 QStateMachine: make enterStates/exitStates virtual.
This allows handling of state specific code when entering/exiting
states during a micro-step.

Change-Id: If2fa8dde9a1e209345950a93dee59414063d863e
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
2015-09-25 09:47:25 +00:00
Wolfgang Bremer
462f355e4f xcb: fix touchscreen input with certain capabilities only
Touch screens without the "Abs MT Position X" but "Abs X" capability
weren't detected correctly so far. This patch fixes the detection and
enables these tochscreens.

Change-Id: I32fdb4d56c106717c90904a6632c2838bd55a255
Task-number: QTBUG-48279
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
2015-09-25 08:06:33 +00:00
Morten Johan Sørvig
2d6f9b6148 Cocoa: Don't send duplicate close events.
Use the presence of a platform window to detect
if the QWindow has already been closed.

Change-Id: Ieedf231cc5b805ed6383e55a82ca137087805a4f
Task-number: QTBUG-43344
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
2015-09-25 07:56:31 +00:00
Topi Reinio
20918435b6 qdoc: Fix write to invalid memory
Before deleting the children of an Aggregate, we must clear its
internal collections first. This prevents removeChild() (called
from ~Node) from accessing already deleted siblings.

Change-Id: Ic657b1d57fe4c766daa2bd4b791c3840099de709
Task-number: QTBUG-47751
Reviewed-by: Martin Smith <martin.smith@digia.com>
2015-09-25 07:52:53 +00:00
Tim Blechmann
f7338d86af tools: StringBuilder - silence clang warning
warning: implicit conversion loses integer precision: 'long' to 'int' [-Wshorten-64-to-32]
    a.resize(it - a.constData());
    ~        ~~~^~~~~~~~~~~~~~~

Change-Id: I8c199d69f2e0d41d1c288d452b9d621b201fa98e
Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com>
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2015-09-25 07:48:27 +00:00
Thiago Macieira
58d9b42c03 Fix deadlock on disconnectNotify() called from ~QObject
Normally, disconnectNotify() is called at the end of QObject::disconnect
and all the locks have been dropped. That is not the case for the
QObject destructor, so we need to deal with the fact that it there may
be some locks held.

I didn't catch this issue during testing because it depends on the
pointer addresses of the object being destroyed and that of the
QDBusAbstractInterface sender object, as we use one global, non-
recursive mutex pool. For the same reason, this patch is not testable.

The fix is simple: we don't need to remove the relay rules immediately.
It's ok for them to happen later, since the worst case scenario is that
we'll receive a few more signals than we have objects to deliver them
to. If that happens, we'll do a little more work than we have to. But in
the normal case, the amount of work is the same and we get the benefit
of returning more quickly from the destructor. What's more, if the
QDBusAbstractInterface object also gets destroyed, the events are
deleted and QDBusConnectionPrivate will clean everything up.

Task-number: QTBUG-48410
Change-Id: I42e7ef1a481840699a8dffff1406b789ba5217b3
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2015-09-25 07:45:06 +00:00
Allan Sandfeld Jensen
c9697677f4 Use a power of two division factor
Using a power of 2 instead of power of 10 means the result of the
division can be accurately represented as a floating point instead of
being an approximation that could lead to rounding errors.

Change-Id: I8910c06113ec6b69c60ff95d59894bfb56133186
Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
2015-09-24 23:35:11 +00:00
Shawn Rutledge
d72da0b4b2 xcb: fix yet another crash when screens are disconnected
Can't assume that m_screens is not an empty list.

Task-number: QTBUG-42985
Change-Id: I6f9422638c219123dc898813910d03c7afbd1450
Reviewed-by: Uli Schlachter <psychon@znc.in>
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
2015-09-24 20:16:08 +00:00
Shawn Rutledge
61b608dfb5 QScreen manual test: don't crash when a QScreen is null
Need to survive having screens detached/reattached on X11.

Task-number: QTBUG-42985
Change-Id: I81cf9721f0cb61a29180c60d44d588063266e651
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
2015-09-24 20:15:35 +00:00
Shawn Rutledge
d0ca16eae1 xcb: get Genius/Waltop tablets working again
It was working at some point, but not in 5.5.0.

Task-number: QTBUG-48370
Change-Id: I8a0e09d4dfa9ace3d69c10c5f88129958d226a9a
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
2015-09-24 20:15:18 +00:00
Thiago Macieira
d427417c74 Print one warning for the new high DPI variables, not four
For people with non-empty QT_MESSAGE_PATTERNS, the multiple lines would
be unreadable.

This is what it showed for me when starting Qt Creator:

[1442136.587] qtcreator(82762 82762)(?libQt5Gui.so.5?|QGuiApplicationPrivate::createPlatformIntegration|QGuiApplicationPrivate::createEventDispatcher|QCoreApplication::init|QCoreApplication::QCoreApplication|QGuiApplication::QGuiApplication|QApplication::QApplication|?qtcreator?|?qtcreator?|__libc_start_main):
        Warning: QT_DEVICE_PIXEL_RATIO is deprecated. Instead use:
[1442136.592] qtcreator(82762 82762)(?libQt5Gui.so.5?|QGuiApplicationPrivate::createPlatformIntegration|QGuiApplicationPrivate::createEventDispatcher|QCoreApplication::init|QCoreApplication::QCoreApplication|QGuiApplication::QGuiApplication|QApplication::QApplication|?qtcreator?|?qtcreator?|__libc_start_main):
            QT_AUTO_SCREEN_SCALE_FACTOR to enable platform plugin controlled per-screen factors.
[1442136.592] qtcreator(82762 82762)(?libQt5Gui.so.5?|QGuiApplicationPrivate::createPlatformIntegration|QGuiApplicationPrivate::createEventDispatcher|QCoreApplication::init|QCoreApplication::QCoreApplication|QGuiApplication::QGuiApplication|QApplication::QApplication|?qtcreator?|?qtcreator?|__libc_start_main):
            QT_SCREEN_SCALE_FACTORS to set per-screen factors.
[1442136.593] qtcreator(82762 82762)(?libQt5Gui.so.5?|QGuiApplicationPrivate::createPlatformIntegration|QGuiApplicationPrivate::createEventDispatcher|QCoreApplication::init|QCoreApplication::QCoreApplication|QGuiApplication::QGuiApplication|QApplication::QApplication|?qtcreator?|?qtcreator?|__libc_start_main):
            QT_SCALE_FACTOR to set the application global scale factor.

(and imagine it line-broken in a terminal 140 columns wide)

Change-Id: I42e7ef1a481840699a8dffff1406f73dc4d44a41
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
2015-09-24 19:46:32 +00:00
Thiago Macieira
c61aaa28df QtDBus: update debugging info (QDBUS_DEBUG=1)
Change-Id: I9a75ad8521ae4e5cbbe5ffff13d1a740643ec22e
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
2015-09-24 16:55:14 +00:00
Thiago Macieira
3bcb3c64e2 Use QTypeInfo<T>::isRelocatable in QVariant
Change-Id: Ib306f8f647014b399b87ffff13f1f01c40dc3ef7
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2015-09-24 16:55:10 +00:00
Andrew Knight
90ef875785 Use QMAKE_MOD_LEX/QMAKE_MOD_YACC in lex/yacc features
These variables were defined but never used in the respective qmake
features. Utilizing them allows more control over the output file name.

Change-Id: I5ba96c5cd330b18dc060f563186992fe3bd27b49
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2015-09-24 13:49:29 +00:00
Andrew Knight
231199798a Build ANGLE dynamically under static builds which have dynamic GL enabled
Task-number: QTBUG-46814
Change-Id: I8108bcd6f8badbb135f593dcf280470e03b11bff
Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com>
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
2015-09-24 12:53:52 +00:00
Laszlo Agocs
b46ffbca0c Fix up QOpenGLWidget transparency support
The glColorMask call was troublesome. In addition, the Qt::WA_TranslucentBackground
was misinterpreted and recommended misleadingly in the documentation. The hellogl2
example's --transparent argument was disfunctional in practice.

Replace glColorMask with glBlendFuncSeparate. The hellogl2 example and the docs are
now corrected wrt enabling semi-transparency in a QOpenGLWidget that is not a top-level
(which is the most common case).

Task-number: QTBUG-47276
Change-Id: I6f40e732d455f5efcf158649ac9a52ff9f240e85
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@theqtcompany.com>
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
2015-09-24 12:51:37 +00:00
Friedemann Kleint
bf2c9fd2fd Guard against empty keys in QPlatformInputContextFactory::create().
The code relied on QStringList::split() returning a list
consisting of one empty string when passing an enpty string.
Add a check to prevent the plugin loader from trying to load
in this case.

Change-Id: Iadb418d32fdea1d472d6c00726ad039b4afbf409
Reviewed-by: Andy Shaw <andy.shaw@theqtcompany.com>
Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
2015-09-24 12:35:01 +00:00
Topi Reinio
e87df57abf qdoc: Document macro parameters
QDoc has the ability to accept parameters for macros but it was
never documented.

Change-Id: Iaf9a629c906fbe1552717c7444a0fd52b5655a3f
Reviewed-by: Martin Smith <martin.smith@digia.com>
2015-09-24 12:21:35 +00:00
Ulf Hermann
1765046730 Deliver mouse press and release events on X11 also when dragging
We generally assume that for every mouse press we also get a mouse
release eventually. The event filter installed by QBasicDrag broke this
assumption as it didn't take care of filtering mouse press and mouse
release events symmetrically. We cannot immediately pass on the release
event as that would mean a release event is generated from a press
event (via the blocking drag call), which breaks assumptions in other
places.

Change-Id: If7e48c7dc0ef5265bed4f9a9366a7606ec875d93
Task-number: QTBUG-46361
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Gatis Paeglis <gatis.paeglis@digia.com>
2015-09-24 12:16:50 +00:00
Christian Kandeler
73b8cd879c QSettings: Special-case serialization of QDateTime.
QDateTime values with a UTC offset are not correctly serialized with
QDataStream::Qt_4_0. So use a newer QDataStream format for this type and
mark it with "@DateTime" instead of "@Variant".

Task-number: QTBUG-46551
Change-Id: I211c89e8cd0211c949ec993e6ffd5192d0eebbb3
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
2015-09-24 11:25:36 +00:00
Joni Poikelin
9f779088f4 Change indicator arrow direction in Fusion style
[ChangeLog][Important Behavior Changes] Arrow indicator now
consistent with platform styles

Task-number: QTBUG-34611
Change-Id: If55e00a37a22288b2179e03fba299aeebad0ebcf
Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
2015-09-24 08:13:13 +00:00
Joni Poikelin
61f2e9a9a7 Fix QItemSelectionModel deselection range
Left and right were swapped which caused invalid selection ranges to be
emitted through selectionChanged.

Task-number: QTBUG-48402
Change-Id: I18692c2b50c49ab39065f9b360b37b7615227ee9
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>
2015-09-24 08:13:07 +00:00
Friedemann Kleint
7183d08095 Tests: Harmonize code checking on platform name.
Use case insensitive comparison and static invocation
of QGuiApplication::platformName().

Change-Id: I8c197c7b4f0669f71c019fbcee09a0f03dfab399
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@theqtcompany.com>
2015-09-24 07:49:30 +00:00
Morten Johan Sørvig
f0f9f309e0 Support non-latin1 platform plugin paths
Replace two instances of QLatin1String() conversion
with QString::fromLocal8Bit()

Change-Id: I04336c47b0c030c69e38db9aa4dcd208d7200b63
Task-number: QTBUG-48399
Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2015-09-24 07:43:19 +00:00
Christian Kandeler
7a8da57a63 Be more forgiving about arguments to QString::arg(double).
The arguments for the width and precision parameters, that is. There's
no reason to crash if a user sets e.g. a precision of -2.

Task-number: QTBUG-46838
Change-Id: I4afc004a1b8aa1306fd996360b16117b2b643640
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2015-09-24 07:40:39 +00:00
Topi Reinio
1ddd33ae66 Doc: Fix QDoc warnings for QTextStream
qtextstream.cpp:2825: warning: Can't link to 'left()'
qtextstream.cpp:2825: warning: Can't link to 'right()'
qtextstream.cpp:2797: warning: Can't link to 'right()'
qtextstream.cpp:2797: warning: Can't link to 'center()'
qtextstream.cpp:2811: warning: Can't link to 'left()'
qtextstream.cpp:2811: warning: Can't link to 'center()'

Change-Id: I613354ca8137030c9f121cb976fe3bc35e1a415b
Reviewed-by: Venugopal Shivashankar <venugopal.shivashankar@digia.com>
2015-09-24 07:38:00 +00:00
Thiago Macieira
0d75f8e95a tst_QDBusAbstractInterface: fix racy test failing every so often
The explanation is in the code comment. Ever since QDBusConnections
began being processed in a separate thread, we were relying on the fact
that the main thread didn't begin processing its event queue until the
second event got posted (the event loop only exits after it has finished
processing all pending events). We had a race between the main thread
starting its processing, at which point it decides which is the last
event it will process, and the QDBusConnectionManager thread posting the
second event.

This is very fragile code, since it depends on the behavior of
QDBusConnectionPrivate (how it stores the signal relays in a hash) and
that of QHash with duplicate keys. This only works because the hash
key between the two connections is the same (it's only dependent on the
method name and interface name). If we ever begin using something that
isn't the same between "control" and "p", then with QHash's randomness,
we'll be racy again.

Change-Id: I42e7ef1a481840699a8dffff1406c3a4674ec3a6
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
2015-09-24 07:37:05 +00:00
Jędrzej Nowacki
a153bb232c Stabilize qguieventloop test.
The test assumed that an event loop can be tested for emptiness
multiple times, which is wrong because an event can be delivered any
time.

Change-Id: Ic44245321eeed2091b640ada2c83d205b83a1cc2
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
2015-09-24 07:36:25 +00:00
Frederik Gladhorn
493d08aeea Fix tst_qthreadstorage
This test when running on Windows has a race condition since in qthread_win.cpp the
finished signal is emitted before everything is cleaned up.

Change-Id: I3c03d9a245e297e8f79b2be2c34398bf7bac9bae
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@theqtcompany.com>
2015-09-24 07:34:06 +00:00
Oliver Wolff
d53695501a winphone: Obtain QLocale::uiLanguages properly
The methods are supported on Windows Phone since 8.1 so that the
simplified Windows Phone code isn't needed any more.

Task-number: QTBUG-48140
Change-Id: I21c488fe1a1322e85bbe088fb47e81893fd12d40
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@theqtcompany.com>
Reviewed-by: Andrew Knight <andrew.knight@intopalo.com>
2015-09-24 07:34:03 +00:00
Louai Al-Khanji
c0c49b8df7 Allow vertical resizing of wizard pages with water mark
The current behavior has been observed to irritate a lot of users, for
instance in the Qt online installer and the Boot2Qt flashing wizard.

Change-Id: Icd7b819a0cbc9fd04b86b4777c5b9e829045d6df
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
2015-09-24 07:32:11 +00:00
Morten Johan Sørvig
3ea04c7d38 Cocoa: Support Qt::WindowTransparentForInput
Map this to ignoresMouseEvents on NSWindow.

Task-number: QTBUG-45498
Change-Id: I86e518bbf805647d9f12b1af1747355ef55cc167
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@theqtcompany.com>
2015-09-24 07:11:47 +00:00
Serge Lysenko
c6c930415b Fix maximum size of .ico files in ICOReader::write()
According to MSDN, a maximum icon size is 256 pixels.

http://blogs.msdn.com/b/oldnewthing/archive/2010/10/18/10077133.aspx

Change-Id: Id87c89a20c9cba6ef041b49f93f84c5e9c3eb79f
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: aavit <eirik.aavitsland@theqtcompany.com>
2015-09-24 04:38:35 +00:00
Jan Arve Saether
d797a04adc Speed up printing when drawing opaque primitives.
We only need to merge the rectangles into a region if we are painting
a non-opaque a primitive with alpha.

Performance measurements QT_print_speed_bug.zip:
Excluding patch: 244686 ms
Including patch:   5070 ms

This is an improvement of 48x (for debug build)

Task-number: QTBUG-48334
Change-Id: I03684c6e7d8a5fb039ea6477ed1a860f09e1b08c
Reviewed-by: Andy Shaw <andy.shaw@theqtcompany.com>
2015-09-23 16:38:07 +00:00