summaryrefslogtreecommitdiffstats
path: root/tests/auto/corelib/kernel
Commit message (Collapse)AuthorAgeFilesLines
* Fix MSVC warnings in tests.Friedemann Kleint2012-04-021-1/+1
| | | | | | | | | - Unused variables - conversion truncations - Overflow in expressions like '-1 + sizeof()' Change-Id: Ibbd18497951e9e7e9dccaf596cb4e864b69ec02c Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
* Make QCoreApplication::applicationName() default to argv[0]David Faure2012-03-281-1/+2
| | | | | | | | | | | | This makes it more useful in all the Qt apps that don't set it, given that it's used internally by QTemporaryFile, QTemporaryDir, QStandardPaths, QDBus, QAccessibleApplication, etc. Qt4 compatibility in the deprecated QDesktopServices is preserved, no fallback there. Change-Id: I584463507cf917a3720793c6bd45d07c60f8356c Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Fixed path in qobject unittestKurt Korbatits2012-03-221-1/+1
| | | | | | | - Fixed path was failing to find sub program. Change-Id: I86f1a6941e244c9bc25ad0441cc7a441607560b7 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Add new test cases to tst_QMetaType.Jędrzej Nowacki2012-03-181-6/+14
| | | | | Change-Id: I405ab5df9d9de3a0a0a71276b172a27ee01392e3 Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* Unify QMetaType::TypeFlags detection.Jędrzej Nowacki2012-03-141-19/+29
| | | | | | | | | Duplicated code was removed. As an side effect: - one runtime flag check was replaced by a compile time check. - is enum flag can be used together with built-in types. Change-Id: I54173e7b07ce7e487d3cc21ba24dcccd28b5d049 Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* Remove outdated assumption from QVariant autotest.Jason McDonald2012-03-121-2/+2
| | | | | | | | The test was assuming that "data()" is a special function in autotests, but that hasn't been the case since early prototypes of testlib. Change-Id: Ic24cf5dc539b55d12eba0a6ab17173e2ed698f21 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Fix compile warnings in QCoreApplication autotest.Jason McDonald2012-03-121-17/+22
| | | | | | | | | - Use const_cast to avoid "deprecated conversion from string constant to 'char*'" warning when building argv arrays from string literals. - Use Q_UNUSED to avoid warnings on unused local variables. Change-Id: Idd2c8279adc102b6ebc6af7486ba26fe9ed4e7c1 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Add Q_IS_ENUM(), and provide as flag in QMetaType::typeFlags()Glenn Watson2012-03-111-0/+34
| | | | | | | | | | | | | | Add Q_IS_ENUM() macro to determine if a given type is an enumeration. Use information from that in QMetaType::registerType() to store whether custom registered metatypes are enums or not. This information can then be accessed by calling QMetaType::typeFlags(int type). This is used by the declarative code to determine whether a custom type in a variant can be safely cast to an integer, which is required to allow passing non-local enums as signal/slot params. Change-Id: I9733837f56af201fa3017b4a22b761437a3c0de4 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Crash fix in QMetaType::typeFlags.Jędrzej Nowacki2012-03-111-0/+6
| | | | | | | The function is public, so it should validate input instead of crashing Change-Id: Id67463b0b61ab74a76c1ede7f052bdbed37822b6 Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* Crash fix in QMetaType::typeName.Jędrzej Nowacki2012-03-081-4/+8
| | | | | | | The function is public, so it should validate input instead of crashing Change-Id: Ifd9f1110f8631f942929d85db6a57eee7afffb6a Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* Fix crash in QVariant::canConvert.Jędrzej Nowacki2012-03-081-0/+6
| | | | | | | | The function was crashing when an unsupported type id was given as an input argument. Change-Id: I2b0e3e6d43f6f248dc71532f8e6485efe68e8120 Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* Automatic metatype registration of two-template-argument types.Stephen Kelly2012-03-021-0/+133
| | | | | | | | | | | This commit is complimentary to the commit which introduced a similar partial specialization for single template argument types: 6b4f8a68c8da1af7c5be7dc6075b688c9d6ca55f If T and U are available as metatypes, then QHash<T, U> is too. Change-Id: I09097b954666418b424c8c23577032beb814343a Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* QPair: specialise QTypeInfo based on the typeinfos of its argumentsMarc Mutz2012-03-011-0/+39
| | | | | | | | | | | | | | Specialise QTypeInfo<QPair<T1,T2>> based on the properties of T1 and T2: - If either T1 or T2 is Q_COMPLEX_TYPE, so is QPair<T1,T2>. - Otherwise, if either T1 or T2 is Q_MOVABLE_TYPE, so is QPair<T1,T2>. - Otherwise, QPair<T1,T2> is Q_PRIMITIVE_TYPE. Change-Id: I8aecbd37e3b7924f77f38967498deabf1a19ca24 Reviewed-by: Olivier Goffart <ogoffart@woboq.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* QEvent (and subclasses): make ctors explicitMarc Mutz2012-03-011-1/+1
| | | | | | | | | | | | | Do this regardless of whether the event subclass is public API or only used in examples. Examples are examples, used by others as templates or even copied verbatim, so they should also follow sound engineering rules. Anyway, there's only one in examples/... Change-Id: I586ff16407a956c9e89288fdd4377eed73f45c0f Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
* moc: Only generate IndexOfMethod for signals.Olivier Goffart2012-02-281-4/+5
| | | | | | | | | | | | | | | | | | | | moc is currently generating code to convert from a pointer to member function of a slot or signal to its index. The idea was that it could be usefull for slots to have the new syntax do the same as the old one (connecting signal index to slot index). But in practice, the new syntax do not use the IndexOfMethod for slots. Also, it does not work for all the slots (no Q_PRIVATE_SLOT, no static slots) So since it is not used, and that it would take room in the binaries to generate all the code to get the index of slots, we remove it. If ever we need it, we can still add it later. Change-Id: Ia417e3e524d7915ca86433ea86c66ac2b299c81a Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
* clean up qmake-generated projectsOswald Buddenhagen2012-02-241-4/+1
| | | | | | | | remove "header" and assignmets which are defaults or bogus, reorder some assignments. Change-Id: I67403872168c890ca3b696753ceb01c605d19be7 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Fixed tst_qobject signalbug silently not compiled in -fast builds.Friedemann Kleint2012-02-232-6/+8
| | | | | | | | | | | | | | | | When configuring with -fast on Windows, a directory which contains two .pro files, one SUBDIRS and one not, will have the SUBDIRS Makefile silently clobbered by the non-SUBDIRS Makefile. In practice, this may cause various subdirectories to be silently excluded from the build. Rearrange .pro files for this test to avoid triggering this bug. See also e9015b3bc8827a8276f58bdd41adcac1bcbf2137. Task-number: QTBUG-21168 Change-Id: I18fac1ac636fdc6b2aaee1b4cdfee9c4bc2a77ff Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Silence warnings/debug output from qobject testsKent Hansen2012-02-201-0/+14
| | | | | | | | | They create noise in the test results. Change-Id: I40e7239ba7cd41bec577fe8220c86476553a6502 Reviewed-by: Olivier Goffart <ogoffart@woboq.com> Reviewed-by: João Abecasis <joao.abecasis@nokia.com> Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
* Add QMetaMethod::isValid() functionKent Hansen2012-02-201-0/+15
| | | | | | | | | | | | This function provides a proper way of determining whether a function returned by QMetaObject::method() is valid. (Checking whether signature() returns a 0 pointer, which e.g. testlib does, is not an ideal API -- especially given that signature() will soon be removed and replaced by a function that returns a QByteArray.) Change-Id: I644f476b09904925f2042945f5d0ad744482b682 Reviewed-by: Olivier Goffart <ogoffart@woboq.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Fixed qobject unittest to work from installation directoryKurt Korbatits2012-02-202-2/+6
| | | | | | | | | | - Made test depend on subprogram to make sure it was there when test ran. - install signalbug subprogram Change-Id: Ie0a19e52d131adcd17c97b263389aecffb81520e Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com> Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
* QMimeData: export URLs as text tooDavid Faure2012-02-171-2/+5
| | | | | | | | | | | | This allows to drop or paste them into lineedits and text widgets (including such widgets in non-Qt applications) Implementation note: this is done on-demand rather than in setUrls so that it's still possible to setText explicitely; the new code is only a fallback for when no text/plain data is available. Change-Id: Ie90c43a30bfa64a6047b627e7351d20bf5ec8e03 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Implement new static less API for QMetaType.Jędrzej Nowacki2012-02-161-23/+133
| | | | | | | | | | | | | | Currently QMetaType API contains almost only static methods. This works nice until someone needs more information or needs to do more operations on a type. In this case every function call has to do type dispatch. This API allows to avoid redundant type dispatching, by caching a type information in a QMetaType instance. It gives significant performance boost especially for custom types (up to 9x). Change-Id: I223d066268402e072e41ca1d0a3e7bc160655d7f Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com> Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
* Add QMetaType::FirstCoreType enum value.Jędrzej Nowacki2012-02-161-1/+2
| | | | | | | We should not assume that the first type id is 0. Change-Id: I17ba6ba57e97ebd495904bfd11235fe458f214e5 Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
* Add autotest for QMetaMethod introspectionKent Hansen2012-02-153-0/+621
| | | | | | | | | | This autotest checks that meta-methods can be properly inspected (signature, return type, parameter types, etc.). Change-Id: I13dc75ec5123280e94ec738dade3f54e427fdbaa Reviewed-by: Olivier Goffart <ogoffart@woboq.com> Reviewed-by: João Abecasis <joao.abecasis@nokia.com> Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
* tst_QVariant passes on Mac OS XBradley T. Hughes2012-02-151-2/+0
| | | | | | | | Do not mark with insignificant_test anymore. Task-number: QTBUG-22747 Change-Id: I4ef6d5d7e1189b03fd1ab812a0839e3709686e1b Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
* Test template-based connect() with qmetaobjectbuilderKent Hansen2012-02-151-9/+17
| | | | | | | | | | | For template-based connect(), the meta-object is resolved at compile-time (the virtual metaObject() function isn't called). But we can make it work by copying the members of the dynamically constructed meta-object to the statically defined one. Change-Id: Ia4d3263a89008e36e187c584db6d25d9042f32b3 Reviewed-by: Olivier Goffart <ogoffart@woboq.com> Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
* qmetaobjectbuilder: Add support for revisioned methods and propertiesKent Hansen2012-02-151-0/+25
| | | | | | | | | moc supports it, so qmetaobjectbuilder should too. Change-Id: I01475794e928b5a1b659f0dab044933948186971 Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com> Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com> Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
* Fix tst_QSocketNotifier on Mac OS XBradley T. Hughes2012-02-132-9/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Socket notifier behavior is very OS-dependent. QtNetwork uses non- immediately (it will return -1 w/ errno=EINPROGRESS). We have to wait with select(2) to indicate that the connection is ready, then call connect(2) again. When this happens, we need another call to select(2) to get notification on the listening socket so that we can call accept(2) to complete the connection. The mixingWithTimers() failure happens due to the test expecting a single processEvents() call to be able to completely connect a TCP socket. But as described above, this may not happen. The test should QTRY_COMPARE() to give the test a chance to let all this happen. The posixSockets() test can fail due to the same connect() behavior. The test already has a comment about the write notifier behavior being very OS dependent. This caused the first enterLoop() to return too early, before the read notifier fired (which is what the test is checking for, that the read notifier fired). Move creation of the write notifier to where we expect it to fire, just before writing to the posix socket. In the same test, the read notifier inside QTcpSocket may not fire after the write notifier on the posix socket. Use the waitForReadyRead() function to give the socket a chance to read the data written to the posix socket. Change-Id: I541e6ee9a39a92ce3acf6b9ffee51079febe43e4 Reviewed-by: Jonas Gastal <jgastal@profusion.mobi> Reviewed-by: Shane Kearns <ext-shane.2.kearns@nokia.com>
* Test posted events in tst_QEventDispatcher with various flagsBradley T. Hughes2012-02-101-1/+13
| | | | | | | | | Add QEventLoop::ProcessEventsFlags test data for tst_QEventDispatcher::sendPostedEvents() to test that posted events are sent when waiting for events and when not waiting. Change-Id: I99f9eb121d0b1ded725e19c5233922fc0a6b81e4 Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
* Run tst_QEventDispatcher with the GUI event dispatchers as wellBradley T. Hughes2012-02-101-1/+16
| | | | | | | | | | | | | Since some GUI event dispatchers are complete reimplementations and do not build on the corelib ones, we want to run the same tests with the other dispatcher. Since this is a GUI test now, we need to make sure to drain system events queued during application startup to make sure we can reliably run the test functions. Change-Id: I4905db70bc8f8584c4ef1f4d767824040281452c Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
* Add tst_QEventDispatcher to tests/auto/corelib/kernelBradley T. Hughes2012-02-103-0/+191
| | | | | | | | | | | | This will test the event dispatcher in corelib for proper timer and posted event handling. The test makes sure all of the necessary virtual functions are implemented and working as expected. This test doesn't test socket notifiers or Win32 event notifiers, as these are already covered in existing tests. Change-Id: I5540ffc4e6d7f97bcd6c3725d7e74c0ab9c97015 Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
* Force -fPIE on ELF if Qt is built with reduced relocationsOlivier Goffart2012-02-101-3/+0
| | | | | | | | | | | | | | | | Put in qconfig.h whether qt is compiled with reduced relocations. When using -Bsymbolic-functions (enabled by default on Qt) but not -fPIE, the comparison of the function pointers fail because the addresses are different in Qt, and in the executable. Hence we now enable -fPIE by default on qmake, and force a compilation error when it is not enabled and built with reduced relocations. Done-with: Sune Vuorela <sune@vuorela.dk> Change-Id: Ib3fdba06fab6e8a93b75b4c6cf16cc973ab335db Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Make "nmake check" pass for corelib tests in Windows.Miikka Heikkinen2012-02-091-0/+3
| | | | | | | | | | | | | | | | | | - Marked four tests insignificant due to failures, these need to be fixed later and then re-enabled: - tst_qfilesystemwatcher - tst_qsettings - tst_qlibrary - tst_qsharedpointer - Skipped one invalid case (tst_QCoreApplication::argc()) - Ifdeffed around vsprintf issue in MSVC (tst_QByteArray::qvsnprintf()) Task-number: QTBUG-24157 Task-number: QTBUG-24146 Task-number: QTBUG-24128 Change-Id: I4db957a65fbf0093f5ae3dc1a04d792492818104 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com> Reviewed-by: Sergio Ahumada <sergio.ahumada@nokia.com>
* Fixed tst_qobject::property for clangRohan McGovern2012-02-091-0/+1
| | | | | | | | | | | | | | | | | | | | | The test was failing at: QCOMPARE(property.userType(), qMetaTypeId<CustomType*>()); The CustomType* metatype was not registered before this part of the test. qMetaTypeId<T> will register the metatype for T before returning it if it is not yet registered, while QMetaProperty::userType() returns 0 if the metatype is not yet registered. However, the order of evaluation of these two expressions in the above statement is technically undefined. Apparently, gcc evaluates the arguments in order from right to left, allowing the test to pass, while clang evaluates the arguments in order from left to right, causing the test to fail. Change-Id: I5059556e860cec29b57c31e4e26f46cf9e6055da Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
* Introduce Q_DECLARE_OPAQUE_POINTERJoão Abecasis2012-02-091-6/+2
| | | | | | | | | | | | To hide the IsPointerToTypeDerivedFromQObject monstruosity :-) Documentation for Q_DECLARE_METATYPE and qRegisterMetaType was updated to mention requirements on registered types and how they can be circumvented for pointer types with the new macro. Change-Id: If83b037a8e2f28761eb903525e87008107298801 Reviewed-by: Harald Fernengel <harald.fernengel@nokia.com> Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* Treat pointers to QObject derived types in QVariant specially.Stephen Kelly2012-02-081-6/+96
| | | | | | | | | | | | | | | | It is possible to do this for example: QVariant v = QVariant::fromValue<MyCustomQObject*>(); QObject *object = v.value<QObject*>(); This means that if a QVariant contains a pointer to a QObject derived type, third parties can extract a QObject* and use its properties without knowing the concrete type. This is a source compatible change. Change-Id: Iee9a9437e99cc2f40d1a4bfea47275482ef7161f Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
* Initialize dynamic meta object extradata.Andrew den Exter2012-02-081-0/+34
| | | | | | | | | | QMetaObject::invokeMethod attempts to deference the extradata for meta objects versions 6 and greater which is causing a crash in some of the qtquick1 tests. Change-Id: If5b2ca83b15de2cd558976c6b681dd5457c404d1 Reviewed-by: Chris Adams <christopher.adams@nokia.com> Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
* Detect incompatibilities in repeated type registrationJoão Abecasis2012-02-071-0/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | QMetaType used to register a typeName and factory functions for creation/destruction of objects. While it would be possible for a single type name to be registered matching different actual types and memory layouts, there was little that could be done about it. Now that QMetaType is tracking type information with a direct impact on data layout and ABI (size and type flags) it is important that we check and detect binary incompatibilities as early as possible. [Such incompatibilities could arise from type name re-use (technically, ODR violations) or, more commonly, as version mismatch between different shared libraries or plugins.] Only type size and flags are checked as function pointers to inline and template or otherwise non-exported functions could trivially differ across translation units and shared libraries. When registering typedef types, a check is made to ensure the same name doesn't get registered as different types. Change-Id: I8211c3de75d4854ce8fafdb620d3a931c206e0c3 Reviewed-by: Olivier Goffart <ogoffart@woboq.com> Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com> Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
* Remove QMetaType::unregisterType().Jędrzej Nowacki2012-02-071-23/+0
| | | | | | | | | | | | | | | | | | | | | | | The function hasn't been working properly. It was not well tested, for example it is undefined how QVariant should behave if it contains an instance of an unregistered type. Concept of unregistering types was inspired by plug-in system, but in most supported platforms we do not unload plug-ins. Idea of type unregistering may block optimizations in meta object system, because it would be not possible to cache a type id. QMetaType::type() could return different ids for the same name. Currently QMetaType::unregisterType() is not used in Qt. Change-Id: I878b6e8d91de99f9bcefeab73af2e2ba0bd0cba0 Reviewed-by: Prasanth Ullattil <prasanth.ullattil@nokia.com> Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com> Reviewed-by: João Abecasis <joao.abecasis@nokia.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
* Align QVariant::UserType and QMetaType::UserJędrzej Nowacki2012-02-072-8/+6
| | | | | | | | | | | | | | | | | | | | | | | There is no point in keeping separate values which should mean the same. QVariant::UserType was used also to construct a valid, null QVariant, containing an instance of unknown custom type. The concept was strange and useless as there was no operation that could be done on such QVariant. Therefore it was dropped. Please note that the patch slightly changes behavior of different functions accepting a type id as parameter. Before QVariant::UserType was an invalid type from QMetaType perspective (id 127 was not assigned to any built-in type), but QMetaType::User points to the first registered custom type. Change-Id: I5c7d541a9affdcdacf53a4eda2272bdafaa87b71 Reviewed-by: Kent Hansen <kent.hansen@nokia.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com> Reviewed-by: João Abecasis <joao.abecasis@nokia.com> Reviewed-by: Andrew Stanley-Jones <andrew.stanley-jones@nokia.com> Reviewed-by: Aaron Kennedy <aaron.kennedy@nokia.com>
* Bring qmetaobjectbuilder in sync with mocKent Hansen2012-02-031-13/+355
| | | | | | | | | | | | | | | | | | | qmetaobjectbuilder should generate meta-objects of the same version as moc; in the future, when the moc version is bumped, QMOB has to be adapted at the same time. QMOB was generating version 4 meta-objects. This patch makes it generate version 6 (the current version). This also fixes a bug with using qt_static_metacall with QMOB (setStaticMetacallFunction()); it was already using the version 6 qt_static_metacall signature, which isn't compatible with version 4. Also add tests that ensure that the QMOB-generated meta-object works with real objects; in particular we want to test the codepaths in Qt that check for version >= 4. Change-Id: I64a151ea5c947a6f8b7a00e85a39866446c735e9 Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
* Add the event loop quitlock feature to QtCore.Stephen Kelly2012-01-314-3/+197
| | | | | | | | | | | | | | | | A feature of a ref-counted quit (managed by a quit-lock class) is added to both QEventLoop and QCoreApplication. This allows, for example, an event loop to quit() when there is no more work for it to do. quitOnLastWindowClosed is implemented in terms of the refcount in QCoreApplication so that jobs can be completed before the application quits. Change-Id: I14c8f4e7ee12bbf81a6e5849290d4c8ff37fa110 Reviewed-by: David Faure <faure@kde.org> Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
* Allow function types to be registered without workaroundsJoão Abecasis2012-01-311-0/+13
| | | | | | | | | | | | | | | | | Commit 4b8ceb41aed352f10d36db5284453f425dbc5f3f added the requirement that pointed-to types need to be registered when registering pointer types. Unfortunately, the implementation also affects function pointer types. This change whitelists 0, 1, 2 and 3 argument functions as not deriving from QObject, forgoing the need to workaround details of the type registration implementation when registering those function pointer types. Change-Id: I4d855e9d70a8179a6e31b84623ad5bf063e0d6d8 Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com> Reviewed-by: Olivier Goffart <ogoffart@woboq.com> Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* Remove many deprecated methodsLars Knoll2012-01-311-4/+4
| | | | | | | | | | Remove methods that have been marked as deprecated before Qt 4.6. Keep others, but inline them where possible and mark them as QT_DEPRECATED_SINCE(5, 0). Change-Id: If881821ae095f054b31cc13464f19e2007c20ed7 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
* Remove type id/name conversion for QVariant::UserTypeKent Hansen2012-01-301-1/+3
| | | | | | | | | | | | | QVariant::UserType does not correspond to an actual type named "UserType". This logic didn't make sense. Change-Id: I369911e514f7902fc863cb05174011d6fc15c447 Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com> Reviewed-by: Jonas Gastal <jgastal@profusion.mobi> Reviewed-by: João Abecasis <joao.abecasis@nokia.com> Reviewed-by: Olivier Goffart <ogoffart@woboq.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
* Remove "All rights reserved" line from license headers.Jason McDonald2012-01-3020-20/+20
| | | | | | | | | | As in the past, to avoid rewriting various autotests that contain line-number information, an extra blank line has been inserted at the end of the license text to ensure that this commit does not change the total number of lines in the license header. Change-Id: I311e001373776812699d6efc045b5f742890c689 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Introduce QTypeInfo::sizeOf.Jędrzej Nowacki2012-01-291-4/+1
| | | | | | | | In QMetaType "void" is a regular type, lack of c++ sizeof operator force us to write a template specialization for the type. Change-Id: I9a56e135223b416b8031836d29ef33ef3fb750e4 Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
* Get rid of checks for Qt3 typesKent Hansen2012-01-291-1/+6
| | | | | | | | | | | | | | These types don't exist anymore, so it's pointless to check for them. Also remove the dead types from uic's type-to-header map. Change-Id: I7f0af5c337859f3da1c103157a802bbe5372df9f Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com> Reviewed-by: Jonas Gastal <jgastal@profusion.mobi> Reviewed-by: João Abecasis <joao.abecasis@nokia.com> Reviewed-by: Olivier Goffart <ogoffart@woboq.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Call connectNotify when connecting with function pointerOlivier Goffart2012-01-291-0/+14
| | | | | | | | Some objects expect connectNotify to be called in order the signal to be emitted. Change-Id: Id0460d9c2aef8f9c3618a2b62b2119a790e06f30 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Mark the single argument containers as movable.Stephen Kelly2012-01-261-0/+28
| | | | | | Change-Id: I1557b9f3c2d3ad805e1ab7bf4d49973f08664a79 Reviewed-by: João Abecasis <joao.abecasis@nokia.com> Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>