summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Extend touch events.Laszlo Agocs2011-12-0930-148/+793
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The capability flags indicate which information is valid in the touch points. Previously there was no way to tell if e.g. the value returned by pressure() is actually the value provided by the driver/device or it is just something bogus due to pressure not being supported. The points' flags return information about the individual touch points. One use case is to differentiate between touches made by finger and pen. Velocity, if available, is now also exposed. Each touch point can now contain an additional list of "raw" positions. These points are not reported individually but are taken into account in some way by the underlying device and drivers to generate the final, "accurate" touch point. In case the underlying drivers expose these additional positions, they are made available in the lists returned by the touch points' rawScreenPosition(). The raw positions are only available in screen coordinates to prevent wasting time with mapping from global positions in applications that do not use this data. Instead, apps can query the QWindow to which the touch event was sent via QTouchEvent::window() and can call mapFromGlobal() manually if they need local raw positions. The capability and device type information is now held in a new QTouchDevice class. Each touch event will contain only a pointer to one of the global QTouchDevice instances. On top of type and capability, the new class also contains a name which can be used to differentiate between multiple touch input devices (i.e. to tell from which one a given QTouchEvent originates from). The introduction of QTouchDevice has three implications: The QTouchEvent constructor and QWindowSystemInterface::handleTouchEvent need to be changed (to pass a QTouchDevice pointer instead of merely a device type value), and each platform or generic plug-in is now responsible for registering one or more devices using the new API QWindowSystemInterface::registerTouchDevice. Change-Id: Ic1468d3e43933d8b5691d75aa67c43e1bc7ffe3e Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Remove QtWidgets dependency from QTcpSocket autotestShane Kearns2011-12-093-33/+12
| | | | | | | | | | | | | | QMessageBox was being used to test nested event loops. This has been changed to use QEventLoop directly. Also, there was an unnecessary use of QPushButton to trigger a test case, which has been removed. As a result, 3 test cases can be run on VXWORKS, and one more test case on Windows that were previously skipped. Change-Id: Ic65ed441cd37d242f89df3ef3b8638a1458d9cf3 Reviewed-by: Robin Burchell <robin+qt@viroteck.net> Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
* Fix unstable test caseShane Kearns2011-12-092-2/+1
| | | | | | | | | | | | | tst_QTcpSocket::disconnectWhileLookingUp required the host lookup + connect + disconnect procedure to complete in <50ms, which is not always true. When disconnecting (rather than aborting with close()), wait for the disconnection to complete with a timeout of 5 seconds. Task-number: QTBUG-21043 Change-Id: I3b59abf9a8eb2c6d99416e1a8ec6b528885b656e Reviewed-by: Robin Burchell <robin+qt@viroteck.net> Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
* QProcess-test: Fix executable location on Windows.Friedemann Kleint2011-12-091-7/+0
| | | | | | | | | | The executable needs to be in the test directory as it expects it sub-executables from there. Breakage introduced by 3385fb91e1e55e1bfa1f78dfb8ce2e9f3fdaedef Change-Id: Ic1f3db70851f65e2f12041c3a16cb8f0b7bdf35e Reviewed-by: Sergio Ahumada <sergio.ahumada@nokia.com>
* Do not assert on invalid model index.Frederik Gladhorn2011-12-091-6/+2
| | | | | | | | No need to crash here, just warn. This will happen when asking a table for out of range indexes. Change-Id: Ida83604bd587390a3b54fbed68f98dab8038c757 Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
* Promote openStandardStreams sub-tests to top levelJoão Abecasis2011-12-091-10/+2
| | | | | | | | | | | | Commit a72468e820c2922540737c053eef27d033c2e77b split the test into two functions, but kept them combined in a single slot for QTest to invoke. That being the case, we might as well have them as test functions of their own right. Should work nicer with test failures, skips and such. Change-Id: I62c1fc7777c08b3e87a5903632d73dc1e1d97e1a Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Add support for three new X11 keysAlbert Astals Cid2011-12-094-0/+19
| | | | | | | | | New keys are: XF86XK_TouchpadToggle, XF86XK_TouchpadOn and XF86XK_TouchpadOff Change-Id: I51c0330213def093adf959d4065ee6d7c1f66d76 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Denis Dzyubenko <denis.dzyubenko@nokia.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* QPixmap test: Re-enable tests of Windows bitmap/icon conversion.Friedemann Kleint2011-12-091-40/+48
| | | | | | | | | | - QPixmap::to/fromWinHICON/BITMAP() became free internal functions (see b8d330904b279de57d70caef70ab2d2a6770f0cc) - Improve QImage check function similar to 11732d133b6a1e367b43d6a2853b3e297eafbf9f Change-Id: I80ff066964ce6c339a6b9bfa5a0e10421dca162a Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Tests: Fix the language change test.Friedemann Kleint2011-12-092-15/+21
| | | | | | | | | | | | | | | - Use correct overload for QTranslator::translate() - Fix LTR source text - Use QDir::TempDir correctly (check for slash). - Do not copy executable on Windows (which is locked), use arbitrary data instead. - Use Q_OS_MAC Task-number: QTBUG-21402 Change-Id: I6ba1c7c764d4c847278eaff9a96c8cd312ac204d Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com> Reviewed-by: Sergio Ahumada <sergio.ahumada@nokia.com> Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* QFile-test: Do not fail when run with redirected stdout/stderr.Friedemann Kleint2011-12-091-5/+11
| | | | | | | Check whether stdout/stderr is sequential. Change-Id: Ia6311e265f0da03dce5b05d78a2058e0c2098bbf Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
* QProcess-Test: Improve error handling.Friedemann Kleint2011-12-091-6/+23
| | | | | | | | In case a subprocess fails to start. Change-Id: I1372c07de8f3580a8e7aadd6874da15bf273ac53 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com> Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
* Re-enable 'check' target for tests/auto/gui on Mac OS XBradley T. Hughes2011-12-0910-1/+18
| | | | | | | | | | Failing tests are marked with CONFIG+=insignificant_test. tst_QTextLayout currently asserts, so it has been disabled to prevent destabilization of the CI system. Change-Id: I7bd836ee14085689c8a0f0ce8e3c80d81a55eb94 Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com> Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
* Forward the contents of the parents argument through this proxy.Stephen Kelly2011-12-093-16/+102
| | | | | Change-Id: Ifabc2a7deec8ea045bf9a9f46fb3a97410dd33f2 Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* Notify about moves in the source model more efficiently.Stephen Kelly2011-12-094-21/+256
| | | | | Change-Id: I5ea2a2dddc1b39a3d2b405bda815f42df7c07c75 Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* Remove wacomcfg.h from 3rdpartyJoão Abecasis2011-12-091-138/+0
| | | | | | | | | | | The last reference to this file was removed in commit a2337f79. With the new QPA architecture there is no longer a reason why this should be needed in qtbase. Change-Id: I84765eca066fd6bdd1dabac32e866c58a39fe183 Reviewed-by: Denis Dzyubenko <denis.dzyubenko@nokia.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Fix failing setSocketDescriptor test in QTcpSocketShane Kearns2011-12-091-0/+1
| | | | | | | | | | setSocketDescriptor fails because socket is in the wrong state. This is timing dependent, if qt-test-server is still in the DNS cache then the test failed. - clear the DNS cache to avoid the host lookup state being skipped. Change-Id: If159d514b1aa9b62a4834f6352d5e7b0a00a5724 Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
* testProcessSpacesArgs fixedJoerg Bornemann2011-12-092-2/+2
| | | | | | | Target names with spaces must be quoted. Change-Id: I913ef386353fc75991c8db4e3205ab511fc1f1a9 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Remove the backwards compatibility signal emissions when moving items.Stephen Kelly2011-12-088-22/+52
| | | | | | Change-Id: I29a44835d3397c1dbf37026daf0c5234dae770e0 Reviewed-by: David Faure <faure@kde.org> Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* Improve/cleanup qtemporarydir (and qtemporaryfile) unit testsDavid Faure2011-12-082-75/+33
| | | | | | | To follow the comments in the review by João Abecasis. Change-Id: Ie566705d3b4071b8628d269246aadcde4866f34f Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
* QTemporaryDir/File: cleanups (static internal function, QScopedPointer)David Faure2011-12-083-13/+10
| | | | | Change-Id: I61311d151e2ae94a22df58297bbfb7a636a01c4a Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Merge QColorDialog::getColor() overloads.Robin Burchell2011-12-082-37/+3
| | | | | | | | Symbian-specific code was removed as a side effect of the merge. Change-Id: I01d28b2aa2fef16ce3988382c2b2a0436c46227c Reviewed-by: John Brooks <john.brooks@dereferenced.net> Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com>
* Fix QTemporaryDir unittest on Mac OS XDavid Faure2011-12-081-7/+9
| | | | | | | | | mkdtemp(10*X) replaces all 10 chars on Mac, while on linux it only replaces the last 6. Adjusted the too-strict tests to allow for both possibilities. Change-Id: Ie6d57bd4947254ad7a39e75ac0e8881cebeaa428 Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
* document the -force-asserts switchHarald Fernengel2011-12-081-0/+3
| | | | | Change-Id: I6af833625d94be98ffebbdecff725f4669e7cbc6 Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
* Cocoa: remove autoreleasepool in QCocoaIntegrationMorten Johan Sorvig2011-12-082-4/+0
| | | | | | | | | | | | | This one was far to long lived and would delay releases until application shutdown. We might get more "no autoreleasepool in place" warnings now, these should be fixed by adding local auto release pools. Change-Id: Ia7a46ab05fb1937154997d0c47b8899d2a0cef65 Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com> Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@nokia.com>
* Remove unused QMapData::createData()/node_create() overloads.Robin Burchell2011-12-082-12/+0
| | | | | | | Change-Id: I79010e1ecfdfe579d996db65681ab1559598f3ce Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com> Reviewed-by: João Abecasis <joao.abecasis@nokia.com> Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* QPixmap test: Make lenientCompare() more verbose.Friedemann Kleint2011-12-081-19/+15
| | | | | | | | - Output cause of failure - Streamline code Change-Id: I597e8cf0178c2417ea55c2319398a48d839b4474 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* QTestlib/Selftest: Fix Windows.Friedemann Kleint2011-12-081-2/+20
| | | | | | | | | - Do not run with empty environment. At least PATH is required at least (Qt + MSVC/MinGW runtime) - Account for MSVC's different formatting of double numbers. Change-Id: Ic7b1cf4a16a88c5384347b2651b011ac13c92d70 Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
* Create a class to contain accessibilty enums.Frederik Gladhorn2011-12-0822-417/+428
| | | | | | | | This is needed in order to expose the enums to qml. Do not inherit QAccessible. Change-Id: I220a0ea3add2d790e4fa6e93ce3deda762859e1a Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
* Avoid variable shadowing in qobject_impl.hKent Hansen2011-12-081-1/+1
| | | | | | | | | Some people like to build their Qt-based projects with -Wshadow -Werror, and since qobject_impl.h is included from a public Qt header, their build breaks. Change-Id: I5d8a5ee1937092149a18c0ff66a723f5bfc9ffc3 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Remove unused overload of QTest::qExec.Jason McDonald2011-12-089-140/+4
| | | | | | | | | | | | | The overload of QTest::qExec() that takes a QStringList is not used anywhere in Qt's autotests, despite having been in the qtestlib API since Qt 4.4. This lack of use most likely derives from the fact that none of the QTEST_MAIN macros use the overload, and more than 99% of Qt's tests use those macros to avoid explicitly calling QTest::qExec(). Change-Id: I264b21d7fe1a9f2d565f748cf8bbe32414a73bb0 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Remove ptmalloc from source treeJoão Abecasis2011-12-0819-8496/+1
| | | | | | | | | | | | | | | | | | | This malloc-replacement library is marked experimental and disabled by default. It is also Unix-only. On linux (GNU C library, actually) ptmalloc graduated to become the native allocator, according to its webpage (http://www.malloc.de/en/), making the need to have a copy here significantly lower. Anyway, there is nothing preventing interested parties from adding this library to their own setup and very little value in keeping it around in qtbase. Change-Id: I2b1c798ca38b59bb767b44d6e5190080ec6ecdf4 Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Make reduce-relocations the default if supportedLars Knoll2011-12-071-1/+1
| | | | | | | | | | | reduce-relocations will enable the -bsymbolic-functions linker option when supported by the linker. This reduces the amount of relocations required within a shared library, by binding symbols locally where possible. Change-Id: I00ddc408df79097857d6b36f7fc1b0f510362fcc Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Add "see also" links for QPrinter::{get|set}PageMarginsDavid Faure2011-12-071-0/+4
| | | | | | Change-Id: Ie1ec9cf3740818c71a7afbdec2c99f5fa0e81337 Reviewed-by: Richard J. Moore <rich@kde.org> Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* Port externaltests.cpp to QTemporaryDirDavid Faure2011-12-071-69/+23
| | | | | Change-Id: I6097ea92dd4b300cb562510e0ea27cee3c01b466 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Remove unused includeDavid Faure2011-12-071-1/+0
| | | | | Change-Id: Idec12079fdc7ad29e780b537577050f01d8d076c Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QNetworkAccessManager: check the buffer size before allocateMartin Petersson2011-12-071-5/+9
| | | | | | | | | | The downloadBuffer size should not be larger then the downloadBufferMaximumSize. I also added a try catch for the allocation incase we are low on memory, so that we don't crash. Task-number: QTBUG-23040 Change-Id: Ib9820bc19fc5db994ede20f123f8c167a8d43ff7 Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
* qtbase: Remove QSound.Friedemann Kleint2011-12-0712-846/+2
| | | | | | | | | Which currently causes tests not to compile on Windows due to missing symbols in QtWidgets (QSound::QSound() ,etc). Change-Id: I87f0a403e61c3a67f9a758f114e33db1012e33e8 Reviewed-by: Michael Goddard <michael.goddard@nokia.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Check we're connected before startClientEncryption()Richard Moore2011-12-072-0/+17
| | | | | | | | | The docs say this is required, but we don't check it and instead segfault right now. Change-Id: I825b00a312a481c5383af127333c0c4698188348 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
* qmake: Add object_parallel_to_source config optionTor Arne Vestbø2011-12-071-0/+23
| | | | | | | | | | | | | | | | | | | This solves the problem of two source files in the same project having the same name, which ends up with colliding object files. It also solves issues with moving files around in the source tree when the GNUmake option is used together with gcc_MD_depends, where the dependency file would end up with a dependency to the old source location. We already have object_with_source option, but that does not play nicely with shadow-builds. The new option tries to keep the same hirarcy in the output dir (while still respecting OBJECTS_DIR), as the sources. Any source with a path outside of the root project directory (absolute or relative, ../../foo.cpp), will be put inside the objects directory with the full path appended. Change-Id: I0c96291974f4801f4c55a26485d512b15c144c00 Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
* Set QMAKE_*_VERSION_OVERRIDE for all modules.Rohan McGovern2011-12-072-13/+11
| | | | | | | | | | | | | | | | | | | On Windows, qmake searches for and uses the highest numbered available version of each requested library, or a version with no number if no libraries were found. This meant that qmaking a library's consumer before qmaking the library itself could result in the consumer incorrectly attempting to link against $${LIB}.lib rather than the correct $${LIB}5.lib (for example). QMAKE_$${LIB}_VERSION_OVERRIDE is the way to work around this. Previously, a hardcoded list of libraries had version overrides set up on Windows, but the qmake order issue affects all libraries, not just these. Therefore, handle it for all modules. Change-Id: I83b4646e3819f525193d1fc065b0d0e65b3be99f Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Better handling of GLX / EGL errors.Samuel Rødal2011-12-077-15/+48
| | | | | | | | | | If context creation fails, try again without a shared context. Added QPlatformOpenGLContext::isSharing() and QPlatformOpenGLContext::isValid() to propagate whether the platform context was successfully created with or without sharing. Change-Id: I37080b645f531fd207946441057be6d3f6be3f6e Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
* Accessibility: Add Text::DebugDescriptionMorten Johan Sorvig2011-12-072-1/+2
| | | | | | | | 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>
* Remove the hacks for having QxmlStream in core and xmlLars Knoll2011-12-071-66/+9
| | | | | | | | | | 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>
* fixqt4headers: Support renaming from QtDeclarative to QtQuickKent Hansen2011-12-071-0/+8
| | | | | | | | | | | | | 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>
* Use QTRY_VERIFY to test asynchronous behaviour.Jason McDonald2011-12-071-23/+2
| | | | | | | | | 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>
* Use QTRY_VERIFY to test asynchronous behaviour.Jason McDonald2011-12-071-18/+1
| | | | | | | | | 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>
* Use VERBATIM where needed in macros.Stephen Kelly2011-12-076-3/+175
| | | | | | | | | | 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>
* Move snippets from qtdoc.Casper van Donderen2011-12-064-0/+172
| | | | | | | These snippets are used on the module pages in qtbase. Change-Id: I755897176275288521cd557fd82b0687181b302b Reviewed-by: Jerome Pasion <jerome.pasion@nokia.com>
* directfbegl: Add unimplemented QDirectFbWindow::eglSurface, build fixHolger Hans Peter Freyther2011-12-062-1/+16
| | | | | | | | | | | 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>
* Added multi-screen support to hellowindow example.Samuel Rødal2011-12-063-9/+36
| | | | | Change-Id: I025de342952bffeffa0705eb4cfcf869f32241cc Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>