According to the Qt naming policy, methods that return value(s) via
the mutable parameter(s) should have "get" prefix to mention that.
[ChangeLog][QtGui][QQuaternion] Added methods to convert a quaternion
to/from Euler angles and to/from rotation matrix.
Change-Id: I95704e1f4623dc4ca54cd237ea203539fb60d452
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
Otherwise, values that are composed of others are not handled
correctly. For example,
Qt::Dialog|Qt::FramelessWindowHint (Qt::Dialog=0x2|Qt::Window)
is currently output as
"Window|FramelessWindowHint" since
Qt::Window matches first and its bits are removed from the flag value
so that Qt::Dialog in the next iteration no longer matches.
Change-Id: I67db5c977c75f887392aa8f345c5e6e9d82c5c26
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Make styleHints a static member variable of QGuiApplicationPrivate and
fix accessor accordingly. Extend tst_QApplication::settableStyleHints()
to run without QApplication instance as well and add a similar test
to QGuiApplication.
Task-number: QTBUG-44499
Change-Id: I42b92ef38f7dd512d08d70accfa7dd4f09a22f01
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
the existing test is a blackbox test. this one is going to be different.
the first test is a bit trivial ...
Change-Id: Iba1b0b5c32490677551ee92c36f381b884c2765d
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Currently Qt uses the QPlatformIntegration::StyleHint
SynthesizeMouseFromTouchEvents to check whether to synthesize mouse
events from touch events. But not only platform plugins can produce
touch events, they can be created by e.g. QTest::touchEvent() and in
this case we almost definitely need synthesizing regardless of the
platform.
This commit introduces a QTouchDevice::MouseEmulation capability which
replaces use of the QPlatformIntegration::SynthesizeMouseFromTouchEvents.
So it's possible to pass QTouchDevice without this capability to
QTest::touchEvent() and be sure that mouse events will be synthesized.
Notice that touch pads always emulate mouse events.
As a result we can activate some tests which were disabled for specific
platform configurations by commits 6c1670d8c2
and e9760f1559.
Change-Id: Idc82fa4007a095fc1cb5934979361b0023d2b793
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
On platforms which does not have at all sysv support, all
posix ipc tests and compilation failed because sysv
specific header files were included unconditionally.
Change-Id: I5713ace6daeb6e79f8794ce42b2b3dfa1b95ab2d
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
This test accidentally causes the screen reader (in newer Gnome
environments) to be launched. This messes up the CI machines enough that
nothing works afterwards. Disable the whole test until I write the
proper fix. We don't lose anything because it was marked as
insignificant anyway.
Task-number: QTBUG-44434
Change-Id: I410e80580977178ea99a370c6c0909d1fb49a71c
Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
Reviewed-by: Jan Arve Sæther <jan-arve.saether@theqtcompany.com>
Those QTimeZones failed to convert to other timezones because the data()
virtual function was never overridden and reimplemented. That meant all
QUtcTimeZonePrivate objects were *really* UTC, with no offset.
Task-number: QTBUG-44600
Change-Id: Ia0aac2f09e9245339951ffff13c5294bb783c674
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
The c2m() function which converts a const_iterator into an iterator
is a broken concept for an implicitly shared container such as
QVector, because the act of calling begin() as the starting
point already detaches and invalidates the c2m argument.
This could be fixed in c2m, but the bug wasn't even in c2m,
but in removeAll(), which called end() before c2m, so the c2m
argument was already invalidated when entering c2m.
The solution is to store the positions as indices instead of
iterators before calling the first detaching function.
Task-number: QTBUG-44592
Change-Id: I66cf4f1277e71148a4d5b5bbfb6a3369ad02db68
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
As requested in review of 1d2efe1f27.
I didn't add a comma in front of the timeSpec() as the other fields
aren't separated by commas, either.
Change-Id: I54d74b7199ca7e46e28d2ceca22b02205e318c90
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
This slipped in with commit 1d2efe1f27,
but is of course completely bogus (though harmless).
Change-Id: If3875b65af0fa3fe85216391599433158043e361
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Reasons:
- the PlayBook NDK is old and its compiler does not keep up with newest
C++11 improvements inside Qt code.
- the PlayBook NDK diverges considerably from the standard BB10 NDK,
making it non-trivial to keep a common codebase.
- It's a defunct platform.
- Maintenance time is limited.
[ChangeLog][Platform Specific Changes] Removed BlackBerry PlayBook support.
Change-Id: Ia338aff55f4e4b747ebdecb0e1463a369a656c03
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Bernd Weimer <bernd.weimer@pelagicore.com>
Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
To make the test compatible with cross-compilation, we need
to bundle test data in qrc, and then extract files to the file
system during initialization. We did this for Android before,
but the change is required on many platforms and since it will
also work on desktop platforms, we consistently just do it this
way everywhere.
Change-Id: I7f65bd9e1dd6f217e6adffda44a40da7599cfe72
Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
Introduce a template function to determine the special values
via macro and use that for QVariant::Double and QMetaType::Float.
Task-number: QTBUG-44381
Change-Id: I379dd82b22d467b0aebaa42f4f0f5c52472a5c47
Reviewed-by: Andy Shaw <andy.shaw@digia.com>
Use correct path for executable file.
Change-Id: I50283fc43fe6561cb8eb687f739f21a3d5cbadbd
Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
Add one tag class for each of QList's three different memory layouts
to QListData, and inherit QList<T>::MemoryLayout from exactly one of
them.
To simplify overloading, added tag classes that express the negation
of the two extreme poles of memory layout (C-compatible and heap),
too. The "missing" one could be added when needed, too.
Change-Id: I45ea603731499fd3fdfb37d60a0a98fb22ac15ec
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The Movable type, surprisingly, was as large as sizeof(void*), so on
32-bit platforms, we were not testing the QList memory layout where
items are placed directly into the void*-slots, but are too small,
leaving gaps.
Fixed by making sure that Movable is smaller than void* and adding
a variant of Movable, Optimal, that is guaranteed to be the same
size as void*, and replacing the int tests with tests of Optimal.
Had to demote the State variable to uchar, since MSVC will apparently
not make a collection of bit-fields smaller than the largest type used
in any of the consituent bitfields, so State s : 8 wouldn't work.
Change-Id: I4f0e24bd6928f076b4ce60e8d977d5d98a724161
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The /tmp directory doesn't exist on Android, and the test needs
a directory that it can cd into which is one level above root.
So we just use /system which should be available on all devices.
Change-Id: I8e6a15f278429491fd871f87af497e5d7184ddf8
Reviewed-by: BogDan Vatra <bogdan@kde.org>
When the default font has the pixel size set instead of point
size, then pointSize() will return -1 and the output from the
HTML will include the pixel size instead. This happens e.g.
on Android when we extract font information from the system.
Change-Id: I26dc49fff215c9887cf0b78dcfff88df0f74450d
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
Most of the time the widget passed in to finish() will not yet have a
window handle so it would just call close() straight away. This
way it ensures has a window handle.
Task-number: QTBUG-35757
Change-Id: I2e212a2ea496cc4e4bba57a8c2d0d127afc43e48
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com>
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
The problem is that the operator<< was taking a non-const reference to the QDebug
object. This causes a problem as all other operator<< return a temporary.
Since every other roperator<< takes the QDebug by value, we should also take it by value
in this case.
Move the operator<< in qdebug.h because i don't want to #include qdebug.h from qobject.h
And move the qt_QMetaEnum_debugOperator to be in the corresponding .cpp
Task-number: QTBUG-44462
Change-Id: Ia01629224c58930c2997e767efc43de90d6309e2
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
We must do something when requestUpdate() is called on a QWidgetWindow.
The semantics of UpdateRequest for QWindow and QWidget are unfortunately
different: for widgets an UpdateRequest means "sync the backing store".
For QWindow it also involves marking as dirty.
Change-Id: Idf40b3fc0873652dc081edeb12c96b3007a126ef
Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
Instead of constructing a QString that describes the QDateTime
instance, stream the constituents of the string into QDebug
directly, using op<< for Q_ENUM, now that it's available.
Adapt test to new format of enums.
Effects on Linux GCC 4.9 stripped release builds:
text -1068B
data +-0B
relocs +-0
Change-Id: I1a5ce28904edd7d0f6c8d982fd41c52e3536e036
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
[ChangeLog][QtWidgets] Added QPlainTextEdit::createStandardContextMenu(QPoint)
overload that takes the position in document coordinates. This method enables
the actions that are sensitive to the given position eg. where the user clicked.
Change-Id: I47ed7a1afc4fcfb3318c9b7af37867aeb7f2aa35
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Similar to what we've done to QString, only we print each byte that is
not ASCII as \OOO (octal representation).
[ChangeLog][QtTest] QtTest now prints an escaped version of
QByteArrays that failed to compare with QCOMPARE, instead of the hex
dump.
Change-Id: I6a8c43f138c66c998280998a242b43cd579666a0
Reviewed-by: Richard J. Moore <rich@kde.org>
Currently QDBus relies on a key in QMetaClassInfo to understand the DBus interface name.
This patch allows QDBus to also use a specified interface name in the registerObject call
instead of relying on QMetaClassInfo that might not be there (if the QObject was created
in QML or Javascript for example).
Change-Id: Ie02b2c67e7deb07f43e35eb166c11833fcbf38f3
Task-number: QTBUG-44074
Reviewed-by: Kevron Rees <kevron.m.rees@intel.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
- Add support for reading out feature lists from GPU bug lists
in Chromium format (supporting OS + version, exceptions lists,
device ids and vendor ids).
Add a overloads allowing for passing file name,
data or JSON documents.
- Test reading in tst_qopenglconfig
- Prototypically have the Windows plugin read the file
from the environment variable "QT_OPENGL_BUGLIST" and
turn off renderers depending on the standard keyword
"disable_d3d11" and newly introduced keywords
"disable_d3d9", "disable_desktopgl".
- QT_OPENGL_BUGLIST can point to an absolute or relative
path, in which case it is resolved via QLibraryInfo::SettingsPath
and QStandardPaths::ConfigLocation.
[ChangeLog][QtGui][Windows]
Introduce experimental feature allowing the user to specify
a GPU driver buglist with some additional keywords to chooose
the GL renderer backend depending on GPU.
Task-number: QTBUG-43263
Change-Id: I8c20b0e8ee3cf575b91d0672bf405c42d3e9fb64
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
On Haiku the '/' filesystem is a pure namespace to mount
in the actual root partition (/boot), and therefor returns
0 for free/available/total bytes.
Change-Id: I60d4786389e01ee271f6cd1aba6f96b19e6a828f
Reviewed-by: Augustin Cavalier <waddlesplash@gmail.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Ivan Komissarov <ABBAPOH@gmail.com>
Remove the ia32 data since there are no linux x86 machines in
the CI system (which makes the data useless from an automated
testing point of view) and most people use x64 these days anyway.
Change-Id: Ifdf8850767869eb2706e2a9d6396314d1fb25500
Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
This operation is the exact opposite to QQuaternion::fromAxisAndAngle()
(so that it is a way to extract the axis and angle values suitable
to create the same quaternion via QQuaternion::fromAxisAndAngle()).
Change-Id: I41fda58f5fb2b867cccd6b2faf58ab671fa070da
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
We've been setting the -Zm argument since the dawn of times (even before
the first git commit). Anyhow, MSDN from VS2008 onwards indicates
that this is not needed:
"In earlier versions of Visual C++, the compiler used several discrete
heaps, and each had a finite limit. Currently, the compiler dynamically
grows the heaps as necessary up to a total heap size limit, and requires a
fixed-size buffer only to construct precompiled headers. Consequently, the
/Zm compiler option is rarely necessary."
[ChangeLog][Compiler Specific Changes] Visual Studio: -Zm200 (an option to
specify the precompiled header memory allocation limit) is not added anymore
by qmake to the compiler calls. If you encounter an C1076 compiler error you
might need to re-add it in your .pro file.
Change-Id: Ia4bec7eba09d893a7d81886a1814602b9ce7563c
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
QTextFormat::font{Weight,PointSize}() etc. return the font trait explicitly
set on the QTextFormat, while QTextFormat::font() returns font which also
uses the QTextDocument::defaultFont() as a default for any font traits not
explicitly set on the QTextFormat. Accessibility support for text attributes
used the former, which was wrong; this commit fixes it to use the latter.
Also includes tests to verify the fix.
Change-Id: Iab7f2be1b68adaad847d1f29c9e5af2195416035
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
Secure Transport relies on keychains, both client/server are constantly
updating default keychain and as a result tests are failing: when
verification is expected to fail, it succeeds; when the number of certificates
is expected to be 1 - it's 2 (Secure Transport can find certificates in a keychain).
This makes verifyClientCertificate test quite useless at the moment - QSKIP it.
Change-Id: I578398b4912a86dc60f585ac5a1bdd0098914005
Reviewed-by: Richard J. Moore <rich@kde.org>