Commit Graph

3293 Commits

Author SHA1 Message Date
Morten Johan Sorvig
77fb1c71bf Accessibility: Add Text::DebugDescription
Useful for debugging QML accessibility.

Change-Id: I814c64bcc4c6b534666adca5865b1588e4d13f44
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com>
2011-12-07 11:15:28 +01:00
Lars Knoll
33fe499d47 Remove the hacks for having QxmlStream in core and xml
QXmlStream was moved from QtXml to QtCore for Qt 4.4.
Remove all the hacks that we added to support that move
in a binary compatible way.

Change-Id: Iea348e980b8efce322d5a7510e5b3ab5c3a108ce
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2011-12-07 09:33:47 +01:00
Kent Hansen
7d05425e02 fixqt4headers: Support renaming from QtDeclarative to QtQuick
QtDeclarative was recently split into two modules, with the
QtQuick(2)-specific API moved to QtQuick. While strictly speaking
the old API wasn't "Qt 4", it's more convenient to modify this
script than to create a separate one.

For example, "QtDeclarative/qquickitem.h" will now be changed to
"QtQuick/qquickitem.h".

Change-Id: I50b32d60cfd21e3c49ee4222fbd6116f80eac25b
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2011-12-07 09:33:47 +01:00
Jason McDonald
b989444f35 Use QTRY_VERIFY to test asynchronous behaviour.
QTRY_VERIFY waits for a condition to become true while regularly
processing events.  There is no need for a custom solution to this
problem.

Change-Id: Ia65c90cbdb165b543f5c78f9bac3cfadd77dfb3f
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2011-12-07 07:53:30 +01:00
Jason McDonald
7fcc55034c Use QTRY_VERIFY to test asynchronous behaviour.
QTRY_VERIFY waits for a condition to become true while regularly
processing events.  There is no need for a custom solution to this
problem.

Change-Id: Ia23e2fb61cdc5c3a3a8a729cd4356ba930fe7cb7
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2011-12-07 07:53:26 +01:00
Stephen Kelly
dc8fa99b2b Use VERBATIM where needed in macros.
Forward port of fix for http://cmake.org/Bug/view.php?id=12554

Test fails before and passes after.

Change-Id: I7a3ab2369cb3095c63f9e2a3e604088ebdcc2465
Reviewed-by: Clinton Stimpson <clinton@elemtech.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
2011-12-07 03:17:25 +01:00
Casper van Donderen
58617fe77e Move snippets from qtdoc.
These snippets are used on the module pages in qtbase.

Change-Id: I755897176275288521cd557fd82b0687181b302b
Reviewed-by: Jerome Pasion <jerome.pasion@nokia.com>
2011-12-06 22:29:01 +01:00
Holger Hans Peter Freyther
f091eccf91 directfbegl: Add unimplemented QDirectFbWindow::eglSurface, build fix
QDirectFbScreen needs to have the full QDirectFbCursor definition, include
the header file directly instead of a forward declaration.

Impelement QDirectFbWindowEGL::eglSurface to return the EGLSurface of the
underlying DirectFBWindow.

Change-Id: Ib6765331ffea6e0b5f10f738d9e05320b7f8155f
Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
2011-12-06 20:14:10 +01:00
Samuel Rødal
e68642fe10 Added multi-screen support to hellowindow example.
Change-Id: I025de342952bffeffa0705eb4cfcf869f32241cc
Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
2011-12-06 20:14:10 +01:00
Stephen Kelly
e838cf644f Test that options to macros work.
Change-Id: Id2f57cc2f64ae25f5f84d1206035b7a2c309d1c7
Reviewed-by: Clinton Stimpson <clinton@elemtech.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
2011-12-06 20:14:10 +01:00
Bradley T. Hughes
b6e9ff22a3 Fix tst_QSharedPointer invalidConstructs:forward-declaration failure
When using clang, the forward-declaration test fails to link, unlike
with other compilers. The standard says that deleting a forward-declared
pointer is undefined behavior, so the link failure is a valid result of
trying to do so.

Change-Id: I527b91c15b7d51d9522d95af0630e7dacd26bb30
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2011-12-06 18:37:54 +01:00
Rohan McGovern
841f445c7f syncqt: fixed QT_MODULE_BASE when build path != install path
QT_MODULE_BASE is exclusively used to refer to the top-level source
directory of a module.  However, in non-developer-build mode (used
only when the build path is not equal to the install path), syncqt
would incorrectly set the value of QT_MODULE_BASE to the build
directory.  This caused all $$QT.<module>.sources variables to point
to the wrong place.

Make it always point to the source directory.

Change-Id: I401cf000f9e3a4ab97d68db40330bb98aec25a9a
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2011-12-06 18:37:54 +01:00
Jyri Tahtela
2711230757 Executing 'make install' did not build mkv8snapshot
During shadow-building it was noticed that executing make install
did not actually build mkv8snapshot and therefore caused an error.

Change-Id: I126cdbaffb85170e25412b93bc99af79ac6f4642
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
2011-12-06 18:37:54 +01:00
Bradley T. Hughes
6b889f89dc Remove the QT_THREAD_SUPPORT defines
These are no longer used. Qt 3.x used them to enable thread support
(which was optional at the time), but starting with 4.0, thread support
is always enabled, and these defines were removed from the code.

Change-Id: I4d1c75171c263383fc055d2a7fe52ca0501acd7a
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2011-12-06 18:37:54 +01:00
Stephen Kelly
e8f27a71bb Port to CMakeParseArguments from a custom rolled macro.
Change-Id: Ia7bf5046420ee8f2d690d098937a212eb75b07ce
Reviewed-by: Clinton Stimpson <clinton@elemtech.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
2011-12-06 16:57:16 +01:00
Stephen Kelly
db5b3afa01 Test the qt5_add_resource macro.
Change-Id: I94e4c9e525016405abba90bbdbe58e7786ce5bc4
Reviewed-by: Clinton Stimpson <clinton@elemtech.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
2011-12-06 16:56:54 +01:00
Stephen Kelly
38ca60985e Now that qt5_automoc doesn't exist, this macro is not needed.
Change-Id: I4746ed5ba41fba801599f443d1214e1744807e20
Reviewed-by: David Faure <faure@kde.org>
Reviewed-by: Clinton Stimpson <clinton@elemtech.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
2011-12-06 16:56:18 +01:00
Morten Johan Sørvig
4c330460b4 Revert "Add valgrind suppression files."
This reverts commit f73e42369a5b4ba43cb8dc8cbcc6232e4375306c

This is a work in progress and is not useful yet. Cocoa/Objective C generates a lot of errors which is making creating a suppression file harder than I initially anticipated.

Change-Id: I045ba1eb9ae627a063a09422f6b5c2bfe6a225ac
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
Reviewed-by: hjk <qthjk@ovi.com>
2011-12-06 13:32:55 +01:00
Shane Kearns
7abd5d950d Skip untestable interfaces in QTcpSocket::bind autotest
bind() test failed if there is an autoconfigured IPv4 address.
e.g. bluetooth adaptor that is not attached to a network.
Or WLAN adaptor in peer-peer mode.
- solved by skipping the autoconfigured IPv4 addresses in the same way
  as IPv6 addresses are already skipped

bind() test fails for proxy
- skipped, QTBUG-22964 created

Change-Id: I9a799ae8db421783f474e97cf876d6e265516397
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
2011-12-06 11:57:11 +01:00
Stephen Kelly
4d98b83c17 Use plural form for CMake variables.
Change-Id: Idc0cd360e09046a5746c9f7366c7fd4b982058fe
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2011-12-06 11:57:11 +01:00
Stephen Kelly
3b3531285d Remove CMake variables which are not needed in Config files.
Change-Id: I8f6795f1d40983af0478270f33ab1c06abe67133
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
2011-12-06 11:57:11 +01:00
Gunnar Sletta
6ddcdee120 Ask for a context that is likely to be supported.
Most embedded GL chips support 24-bit depth with packed
8 bit stencil, but more rarely 32-bit. Asking for 32
bit means we often fail on other properties to, such as
multisampling.

Change-Id: Ib913d94af0635b09913ff15cff54cc694ba293fc
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-12-06 08:40:25 +01:00
Jason McDonald
7ac3d7c5c1 Remove obsolete autotest parameters.
Previously, autotests silently ignored the -graphicssystem and -qws
parameters so that test-runners did not need to include logic to decide
whether to pass those parameters depending on whether a particular test
was a GUI test or a non-GUI test.

In Qt 5, both of those parameters have been removed from QApplication,
so tests don't need to ignore them anymore as they should no longer be
supplied to any test.

Change-Id: Ic59e38ddfa3303e760645ed1782a211340ce70f2
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2011-12-06 05:04:25 +01:00
Jason McDonald
e3640d1bdd Remove TESTED_CLASS/TESTED_FILES comments from tests.
These comments were mostly empty or inaccurate.  Appropriate naming of
tests and appropriate placement of tests within the directory tree
provide more reliable indicators of what is being tested.

Change-Id: Ib6bf373d9e79917e4ab1417ee5c1264a2c2d7027
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2011-12-06 02:19:25 +01:00
Jason McDonald
5d74683b7a Don't mark selftest subtests as testcases.
The subtests are intended to be executed by tst_selftests and therefore
don't need to have "CONFIG += testcase", which causes 'make check" to
treat them as stand-alone tests.

Change-Id: I1b47e0186be99c591bb1e03bbec6386518f8a449
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2011-12-06 02:19:25 +01:00
Jyri Tahtela
05044cd982 Add new mkspec for cross-compiling Qt5 for ARM
This mkspec provides default compiler settings for cross-compiling
Qt5 for ARM.

Change-Id: If58a1833141ab305bd57928796f7444e9b7aa2b3
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2011-12-06 00:35:49 +01:00
Bradley T. Hughes
e2d5c06e1a Fix QT_DEPRECATED_SINCE evaluation
QT_DEPRECATED is defined by default by the logic in qglobal.h, but
QT_DEPRECATED_SINCE is evaluated before that definition, making
QT_DEPRECATED_SINCE evaluate to 0, disabling all deprecated code (even
though it shouldn't be disabled).

Fix this by moving the QT_DEPRECATED_SINCE evaluation to after the
evaluation of QT_NO_DEPRECATED and/or definition of QT_DEPRECATED, to
ensure that QT_DEPRECATED_SINCE works as expected.

Change-Id: I57d9f6a3e1859b0057fd4f37bcf2d2cc3dfba230
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2011-12-05 23:03:16 +01:00
Bradley T. Hughes
2c9d042476 Re-add QInternal::EventNotifyCallback
This is needed by QtScript, so we need to keep it for now.

Change-Id: Iee6bd7daf7e86a09242523f5aca72ede413a6981
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-12-05 23:03:03 +01:00
Jędrzej Nowacki
d242d78339 Make tst_QVariant::canConvertMetaTypeToInt more verbose.
Change-Id: If17cbd1154c4fd3c006648b28e91a009de5b373b
Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
2011-12-05 17:23:00 +01:00
Friedemann Kleint
097a3f4231 qpixmap_win.cpp: Fix typo in format conversion (alpha).
Change-Id: I8abdae5482e94a7f9af494e5d547352431285336
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2011-12-05 15:08:25 +01:00
Holger Hans Peter Freyther
7beed86493 v8: Introduce MIPS code for the QML code
Copy and paste the ARM code into the MIPS dir, there is no lithium
support in MIPS right now.

Change-Id: I21491d36da2a4ac4cb6898c47b0e5bd37a733b41
Reviewed-by: Aaron Kennedy <aaron.kennedy@nokia.com>
2011-12-05 12:29:42 +01:00
Holger Hans Peter Freyther
30a5928e2a v8: Attempt to fix a typo in the commit message
is resolve -> is resolved

Change-Id: I95a6072be63e353bafdafccc404e90d331a01894
Reviewed-by: Aaron Kennedy <aaron.kennedy@nokia.com>
2011-12-05 12:27:58 +01:00
Holger Hans Peter Freyther
ddc580643b mips: Really build the MIPS V8 code
2008d2d40e was not rebased properly and
should have used the V8_TARGET_ARCH to add the MIPS code to the build.

Change-Id: Idf0c183fca63da0fa9f9aa8d091a764b88c888f5
Reviewed-by: Aaron Kennedy <aaron.kennedy@nokia.com>
2011-12-05 12:25:07 +01:00
Stephen Kelly
bae85d2f0e Fix typos in Sqlite docs.
Change-Id: I4a57e9e37831c135b1ad620c8c9586a5eea76220
Reviewed-by: Richard J. Moore <rich@kde.org>
Reviewed-by: Alan Alpert <alan.alpert@nokia.com>
2011-12-05 10:48:37 +01:00
Jason McDonald
260a2e52b2 Fixing naming of selftests.
Make the test object names correspond to the test program names, so that
it is easier to see which test produced each block of test output.

Change-Id: Ib19a955938b549f27cdcaac83bfa9150285b396d
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2011-12-05 09:02:15 +01:00
Jason McDonald
4bca278d63 Don't set graphics system at start of test.
QApplication::setGraphicsSystem() is a no-op, and even if it wasn't it
would be unwise to force a graphics system that isn't guaranteed to be
included in the Qt build, without including any logic to skip the test
if setting the graphics system failed.

Change-Id: Id9a0a87586872088625de7840b5032d0c3cc48a1
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
2011-12-05 07:28:47 +01:00
Rohan McGovern
2d8d258f1d Fixed tst_selftests findtestdata subtest for shadow builds.
This test uses qt.conf to enforce a predictable tests install location.
This was not working in the shadow build case, as qt.conf was only
present in the source tree; embed it as a resource at :/qt/etc/qt.conf
so it works in the shadow build case too.

Change-Id: Iec708d9686c29a1fc5ff0020dc11a93a593d20c5
Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
2011-12-05 06:00:04 +01:00
Jiang Jiang
25be03f046 Remove unused Mac specific font code in widgets
Change-Id: If7a81b8b59aedcc0ba54c735787a220bab9ca535
Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
2011-12-04 23:39:42 +01:00
Jiang Jiang
d05b6b6e95 Remove QCoreTextFontEngineMulti
It's not used anymore since we have switch to HarfBuzz on Mac.

Change-Id: I68252fbe3021f54dacac5a901184c3f3e541a6b7
Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
2011-12-04 23:39:38 +01:00
Jiang Jiang
6887a7e395 Enable subpixel rendering for raster on Mac
Change-Id: I06e6465e03c17776974d361254abf5b750736080
Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
2011-12-04 23:39:34 +01:00
Stephen Kelly
7d2ab7f01d Move the metatype declaration for QGraphicsScene.
From where it is forward declared to where it is fully defined.

Change-Id: Ie2240ffef6d1edbbbd5b193f9528ef94ef412d82
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2011-12-04 20:45:49 +01:00
Frederik Gladhorn
298f8b67ab Remove unused enum values.
These were used for foreground/background color.
Since we have proper functions for these two now,
the hack with invoke_method is no longer needed.

Change-Id: I66eb645124caa838adb1ceb41383a2724a45f553
Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
2011-12-04 17:29:09 +01:00
Stephen Kelly
353c404f04 Quote the path in CMake so that spaces in paths work.
Change-Id: Ie73a4b242ab0bf90e6f292be9a7b7913ae4273a5
Reviewed-by: Clinton Stimpson <clinton@elemtech.com>
Reviewed-by: Richard J. Moore <rich@kde.org>
2011-12-03 23:14:33 +01:00
David Faure
e999c543a0 New class QTemporaryDir.
As discussed on qt5-feedback / development lists.

Change-Id: If1733369d12daa29054776ec2cbd78e63679768e
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2011-12-02 21:04:34 +01:00
Honglei Zhang
4d696d53b0 Fix tst_qsql crashes on Mac OS X
In tst_qsql, there are function calls to  QApplication(argc, 0, false), where
argc is zero. According to the documentation, argc must be greater than
zero and argv must contain at least one valid character string. The
misuse of this API has no problem on any platform other than Mac OS. This
commit has fixed the crash by passing valid dummy parameters.

Task-number: QTBUG-22811
Change-Id: I42b26d66f0becb7a942896e6ddcaea52ff720a48
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
2011-12-02 17:35:11 +01:00
Bradley T. Hughes
ad8edac53c Remove QInternal callbacks and internal functions
After commit 79f675a1e0, the connect and
disconnect callback API effectively becomes useless. Now that these
callbacks cannot/do not, it makes little sense to keep the backdoors
added for Qt Jambi support.

Remove them for now. Should the Qt Jambi team want/need to port to Qt 5,
we can re-add them, possibly designing a better API for doing so as
well.

Change-Id: I6209a1d647d683c979d5294b632b8c12c0f9f91c
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-12-02 15:59:58 +01:00
Kent Hansen
613183ff8c Automatically add QtQuick module if only QtDeclarative is specified
QtQuick and related APIs (QQuickItem, SceneGraph, et al), which
used to live in the QtDeclarative module, have moved to a new
module, QtQuick.

Existing projects that use QtQuick-specific APIs should add "quick"
to their project's QT variable, and update their include statements.

E.g.,

QT += declarative

should be changed to

QT += declarative quick

and

 #include <QtDeclarative/qquickitem.h>

should be changed to

 #include <QtQuick/qquickitem.h>

and similarly for the other QtQuick classes.

In order to give existing projects a chance to migrate smoothly, we
should issue a warning and automatically add the QtQuick module if
only the QtDeclarative module was specified. (If a project doesn't
use any QtQuick APIs, the warning can be ignored -- but there is no
way to disable it.)

This change, along with the compatibility headers in QtDeclarative,
make it possible to build existing projects without any modifications
on the project's side.

This change will be removed at a later time; when that happens,
existing projects that did not port to the QtQuick module will no
longer build.

Change-Id: I56abcadc1e5c74490527fc03646310d801bfc084
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2011-12-02 15:59:58 +01:00
David Faure
1bb51cb8b1 Implement QDir::removeRecursively
Task-number: QTBUG-4592
Change-Id: I363e2c24d1c0ada975b8b927d7c6e776b8aae579
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2011-12-02 15:59:58 +01:00
Honglei Zhang
8c74fe5c7a QSqlRelationalTableModel doesn't follow relations on the first column
QSqlRelationalTableModel doesn't follow relations on the first column
of a table. The DisplayRole and the EditRole for indexes on column 0
are always the same. The bug is found in QSqlRelationalTableModel::data.

Task-number: QTBUG-20038
Change-Id: Ie1e98b5f46ffc171113f2d51b9b19ff5febb1c3c
Reviewed-by: Yunqiao Yin <charles.yin@nokia.com>
2011-12-02 15:59:58 +01:00
Gunnar Sletta
35a9e53dea Added minimal class docs for QWindow to make it visible.
Change-Id: Ibed2279ba5454547fb4060005e805a11221b3732
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2011-12-02 15:59:58 +01:00