summaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
...
* Fix 3 digit day being displayed by QDateEdit.Mitch Curtis2012-09-054-10/+294
| | | | | | | | | | | | | | | | | | | | | | | | | | When a QDateEdit has its display format set to "yyyy/MM/dd", its day set to 31 and its month set to 2, it will display 291 as the day until the cursor is moved or the focus changed. This is because QDateTimeParser::parse calls sectionSize() for the day section, which will sometimes return an incorrect size. There are also other display formats affected by this bug (e.g. long day names). For example, (in the context of sectionSize()) when text is "2000/01/31" and displayText() is "2000/2/31", there is a difference between displayText() and text - text is the previous value and displayText() is the new value. The size difference is always due to leading zeroes. This patch makes QDateTimeParser keep track of the quantity of zeroes added to each section and then factors this value into the result of sectionSize() if there is a size difference between text and displayText(). Task-number: QTBUG-26847 Change-Id: I3823cc41167ec920f742cb6a20d39fc5f433c915 Reviewed-by: Mitch Curtis <mitch.curtis@nokia.com> Reviewed-by: Gabriel de Dietrich <gabriel.dietrich-de@nokia.com> Reviewed-by: aavit <qt_aavit@ovi.com>
* Doc: Missing documentation added and doc errors fixed.aavit2012-09-057-13/+132
| | | | | | Change-Id: I573bf9622e38b54f2cb8c32fd402d477a1deb5c2 Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org> Reviewed-by: Kim M. Kalland <kim.kalland@nokia.com>
* Don't use string comparison to figure out how to use the clipboardJorgen Lind2012-09-051-3/+4
| | | | | Change-Id: I36738b3808ebed0d108882ebdc74ee7dd1899bfd Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Move assignment of mousePressed variable in QWidgetTextControlJorgen Lind2012-09-051-1/+2
| | | | | | | | Or else we never hit the path where middle button click pasts selection on X11. This is also how it worked in Qt 4. Change-Id: Ia090c465db0e5e8cb249f5d752e0bb86951e2eb0 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* restore support for QMAKE_LIBDIR_FLAGSOswald Buddenhagen2012-09-051-5/+7
| | | | | | | | unexpectedly, this internal variable is documented. grumble. Change-Id: I272c1f553b56f253d2f59f875de78d5bc279186a Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com> Reviewed-by: Daniel Teske <daniel.teske@nokia.com>
* bypass configure bootstrap for non-git buildsOswald Buddenhagen2012-09-051-0/+5
| | | | | Change-Id: Ifa56297db0c5f198080a728f033393ab60eb1b74 Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
* remove pretenses of supporting projects on stdinOswald Buddenhagen2012-09-056-28/+13
| | | | | | | | | | this may have worked a decade ago, but now it only produces funny Makefiles (and needs hacking main.cpp). the feature doesn't seem *too* important, so just clean it out. Change-Id: I50a60b0e30341f0b523e4a5731c770c9c1013f8b Reviewed-by: Daniel Teske <daniel.teske@nokia.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
* make QMakeMetaInfo a little less inefficient with libtool .la filesOswald Buddenhagen2012-09-056-13/+10
| | | | | | | | | don't read the spec from scratch for every library just to get QMAKE_LFLAGS_RPATH. we can perfectly use our current project for that purpose. Change-Id: I4e408b3fd5de81652181df032aa53cd8f2f8f806 Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
* pre-initialize more invariant propertiesOswald Buddenhagen2012-09-051-6/+4
| | | | | Change-Id: I0add2e7ead5a3d63124ef7ff85362895dd64bd23 Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
* remove QMAKE_MKSPECS property from qmake -query's viewOswald Buddenhagen2012-09-052-6/+3
| | | | | | | | | | it's a dynamic property which is something between meaningless and misleading when used outside a project file. also, experience from creator shows that people would consistently abuse it (not handling it as the list it is). Change-Id: Id52cd40da5c38c0c74535d0701fdae53dfa39cad Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
* Use true and false in preference to TRUE and FALSESergio Ahumada2012-09-0526-73/+73
| | | | | | | | The TRUE and FALSE macros are obsolete and should be replaced with true and false (all lower case) respectively. Change-Id: Iee352e8173500683e6319be0abbf5bacf29016e0 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* test: Check for null string comparisonSergio Ahumada2012-09-051-6/+6
| | | | | | | Do not compare a QString to QString(). Instead use the .isEmpty() method. Change-Id: I8bb5e64563bf173abe7288bb9e35375bee1fe445 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Optimize QTextLayout/QTextEngine usage outside of QTextDocument.Milian Wolff2012-09-053-23/+61
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When QTextLayout is used in a QTextDocument, many code paths use special caches and thus greatly outperform the raw QTextLayout version that operates directly on a QString. This patch brings some of these optimizations also to the raw version. We now also use a QFormatCollection in such cases and enable the functionality of QTextEngine::indexAdditionalFormats() and QTextEngine::resolveAdditionalFormats(). Thanks to that, we can greatly speed up QTextEngine::format(), which now uses an amort O(1) hash table lookup instead of a O(N) linear search. The added benchmark shows a gain in the order of one magnitude: ./tst_bench_QText formattedLayout:long-many before applying the patch: 378.19 msecs per iteration (total: 37,820, iterations: 100) after applying the patch: 25.80 msecs per iteration (total: 2,580, iterations: 100) Note: This change is source-incompatible for applications using the private QTextEngine API. Task-number: QTBUG-8389 Change-Id: Ifcf7a8902a394428979ea06a6d955f886ee739c7 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: Olivier Goffart <ogoffart@woboq.com> Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Fix Windows platform plugin narrowing conversion compile errorsJonathan Liu2012-09-052-2/+2
| | | | | | | | Implicit conversions from int to BYTE (unsigned char) result in compile errors when compiling with the GCC -std=c++0x option. Change-Id: Iaf8190426207bf15ab4b337300510596d70659ed Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* Remove custom sort implementation in QTriangulator in favour of std::sort.Robin Burchell2012-09-041-126/+3
| | | | | | | | | | | | | | qSort has terrible performance, especially on mostly-sorted input, which is presumably why a custom implementation was created. However, std::sort has much better performance than qSort in many cases. Benchmarking shows that std::sort beats out the custom sort by a very narrow margin (21-22ms for qSort, 14-15ms for sort, 14ms for std::sort) in a simple benchmark of sorting. Change-Id: If7e57fdfaf98e741d1621969461537c82f9169fe Reviewed-by: Kim M. Kalland <kim.kalland@nokia.com> Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
* Correct the QFileDialog's delete warning message.Mitch Curtis2012-09-041-3/+3
| | | | | | | | | | | "Are sure you want to delete '%1'?" should be: "Are you sure you want to delete '%1'?" Title of the message box should be Delete, not Open. Task-number: QTBUG-26851 Change-Id: I40933c5e1b231d3d2e3274b4d669267d26ba8cfc Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com>
* Clarify QDateTime::secsTo and QDateTime::msecsTo documentation.Mitch Curtis2012-09-041-2/+2
| | | | | | | | | | | Changed: "Returns 0 if either time is invalid." to: "Returns 0 if either datetime is invalid." Change-Id: I52d291459f215c1bb7fc78e70eaac90b2498158b Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com>
* QNX: Move qpa-based mkspecs out of the unsupported directorySean Harmer2012-09-048-6/+6
| | | | | | | | | | | | RIM is committed to supporting Qt on its platforms and the port works well. Change-Id: Id6bfea2dbc178800adad89d436ce31c40d3eb652 Reviewed-by: Nicolas Arnaud-Cormos <nicolas@kdab.com> Reviewed-by: Andreas Holzammer <andreas.holzammer@kdab.com> Reviewed-by: Thomas McGuire <thomas.mcguire@kdab.com> Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* fix QT_{BEGIN,END}_INCLUDE_NAMESPACE mixupOswald Buddenhagen2012-09-041-0/+2
| | | | | Change-Id: Id25b6aa56681b5bb5989472a96128789c0c4e73a Reviewed-by: hjk <qthjk@ovi.com>
* Auto test for 'qmake -project' use case.Rafael Roquetto2012-09-047-4/+205
| | | | | Change-Id: Ifb6d64828ba1cb42fd64299438b7eec302112edf Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Fix indentation.Morten Sorvig2012-09-049-9/+9
| | | | | Change-Id: I0e53df9e1903c8cdc79d50c16cfe7f90ae6e1d6f Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* QWizard/Win: Fix vista helper cache state invalidationJonathan Liu2012-09-041-1/+2
| | | | | | | | | | If the cached state is not dirty and the instanceCount is zero, when the instanceCount is incremented the cached state will not be correct. To fix this, reset the cached state to dirty if the instanceCount is incremented from zero. Change-Id: Ic49eef7f83b1289a939f998817b1b2b5f5a2a45f Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
* graphicsview: use std::sort instead of qSortRobin Burchell2012-09-045-15/+15
| | | | | | | | | | | | In almost all cases, std::sort is wildly faster than qSort - but especially in the case where the input data is already sorted. in some stress tests which ran through the index with a lot of items, this commit provides huge speedup (684ms down to 10ms for painting 15001 empty items on the provided benchmark), for me. Task-number: QTBUG-11022 Change-Id: I5551f8e320c33ba13d464bf22047a665c81f3b74 Reviewed-by: Peter Kümmel <syntheticpp@gmx.net> Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
* Doc: fix yet more errors reported by qdocaavit2012-09-045-17/+90
| | | | | Change-Id: I67ac081ce95235912784bbbc347dd8f80fdebbde Reviewed-by: Kim M. Kalland <kim.kalland@nokia.com>
* QNX: Tidy up QMAKE_LFLAGS in qnx mkspecsSean Harmer2012-09-032-5/+1
| | | | | | | | | | | | We do not need to include -lang-c++ more than once in QMAKE_LFLAGS* variables. The fact that this was not appearing more than once was due to QMAKE_LFLAGS being overwritten (rather than appended to) in qcc-base-qnx.conf and a weird coincindence in qmake's code to dedupe libraries passed in to QMAKE_LFLAGS. The deduping was working based upon options beginning with "-l", including the -lang-c++ option here. Change-Id: I983f216c0e362a9fe6a924074c5d84aaa659a14f Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Generate includes for Qt containers used as auto-metatypes.Stephen Kelly2012-09-033-0/+119
| | | | | | | | | | | | Otherwise the containers might be forward declared in the moc file, and when the moc file is compiled in a standalone translation unit, the full definition of it would not be available. This results in odd compile errors, so instead generate the includes if required. Change-Id: Ie01c5a5d45314daad0b00dec03b3e1e18cdbae64 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Volker Krause <volker.krause@kdab.com> Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* remove handling of QMAKE_FILETAGSOswald Buddenhagen2012-09-033-26/+0
| | | | | | | | it was unused for a decade. and broken, of course. Change-Id: I9713d595d95c5b074ef96dfe9b1c314b9198bd7e Reviewed-by: Daniel Teske <daniel.teske@nokia.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
* remove unnecessary QMAKESPEC fallback codeOswald Buddenhagen2012-09-031-5/+0
| | | | | | | | QMAKESPEC is now always set Change-Id: Ib3f7356a9260d42315747095e28db6604b2dcfe9 Reviewed-by: Daniel Teske <daniel.teske@nokia.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
* remove pretenses of manual dependenciesOswald Buddenhagen2012-09-031-5/+5
| | | | | | | | now that "make depend" actually works again, just clean out the gunk. Change-Id: Ia1858a2474c9a4544ae16c53349aa7ae09e0c685 Reviewed-by: Daniel Teske <daniel.teske@nokia.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
* unbreak "make depend" for shadow buildsOswald Buddenhagen2012-09-031-6/+13
| | | | | | Change-Id: Ib79ba79e41cfeac9350852395b03c331dc4fe2a3 Reviewed-by: Daniel Teske <daniel.teske@nokia.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
* unify c*flags in the hand-written makefiles somewhatOswald Buddenhagen2012-09-033-15/+17
| | | | | Change-Id: I7a7139fd71bce879b3ee4d9e26e30d2ca63da69e Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
* fix assignment of MSVCPROJ_TARGETOswald Buddenhagen2012-09-031-4/+1
| | | | | | | i'm only guessing what was intended here. Change-Id: I72bfa3b5fad63f5b144d34762152e4dd851197ac Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
* Cleaner support for window flags in QCocoaWindowGabriel de Dietrich2012-09-032-37/+75
| | | | | | | | | Window flags were not properly forwarded to the platform window instance. Particularly in the use cases found in QtQuick desktop components. Change-Id: Ibeadfee7de95ba497e9c0f765acee77c84884466 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@nokia.com>
* Use QStringList::join(QChar) overload where applicable [QtSql]Marc Mutz2012-09-033-3/+3
| | | | | | | | | | | This is an automated change performing the following replacements: join\("(.)"\) -> join('\1') join\(QLatin1String\("(.)"\)\) -> join(QLatin1Char('\1')) join\(QStringLiteral\("(.)"\)\) -> join(QLatin1Char('\1')) Change-Id: Ie395d82d17710683968d006d22de313ef49dc6e5 Reviewed-by: Harald Fernengel <harald.fernengel@nokia.com> Reviewed-by: Mark Brand <mabrand@mabrand.nl>
* Clarify QDateTime documentation re timeSpec conversion.Mitch Curtis2012-09-032-2/+52
| | | | | | | | | Clarify the documentation for setTimeSpec, toTimeSpec, toUTC and toLocalTime, to be clear on which ones return the same point in time, and which one simply changes the timezone. Change-Id: Ic47dd8876ea733f1df0f64eca5bdf00d04f8d0d4 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Need #include <string.h> to use memcpyShawn Rutledge2012-09-031-0/+1
| | | | | | | | Caused a compile failure in qtmultimedia. Change-Id: I73652d93848c2005c0132d24bb0d269e7b450396 Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com> Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
* configure: Fix infinite loop displaying config.summaryJonathan Liu2012-09-031-1/+1
| | | | | | | | | Displaying config.summary sometimes results in an infinite loop because the loop condition only checks that failbit and badbit are not set. The eofbit may be set with failbit and badbit not set. Change-Id: I209480fbf114365fd4fdf1289c988a386f9f2562 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Fix docs of qAbs to have the correct function signature.Jan-Arve Saether2012-09-031-1/+1
| | | | | Change-Id: I984032dc58387ae8f28318beeb053af28ccc8885 Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
* fix a mismatch of using QT_NO_NETWORKPROXYJing Bai2012-09-031-0/+3
| | | | | | | | To fix a compile error when QT_NO_NETWORKPROXY is defined. Change-Id: If0433387cff2e6574fe24721a0ce2bfc41b0eb47 Reviewed-by: Markus Goetz <markus@woboq.com> Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* QStandardPaths should still work without desktop serviceJing Bai2012-09-031-4/+0
| | | | | | | | | To fix a compile problem when QT_NO_DESKTOPSERVICES is defined. We should enable QStandardPaths on Mac even without desktop service, since it doesn't rely on desktop service and it is used in other files. Change-Id: I29267ebfe81b79c598043f8287fd2bb419573570 Reviewed-by: David Faure <faure@kde.org>
* QDBusPendingCallPrivate: save 8 bytes on 64-bit archsMarc Mutz2012-09-031-2/+1
| | | | | | | | | | Moved waitingForFinished out from between two large-type variables to save eight bytes per QDBusPendingCallPrivate on 64bit platforms. Many a mickle makes a muckle. Change-Id: I5612ad8bb907c6770be0245e667bdb2add30d38b Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QDBusPendingCall: remove unneeded volatile qualificationMarc Mutz2012-09-031-1/+1
| | | | | | | | The variable waitingForFinished is only ever read under mutex protection, so a volatile qualification isn't necessary. Change-Id: I17ce3fbfb090c8ae5e43dd2a93e4f48810dbbff3 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QDBusPendingCall: add a missing QWaitCondition::wakeAll() callMarc Mutz2012-09-031-0/+1
| | | | | | | | | | In QDBusConnectionPrivate::waitForFinished(), threads that see pcall->waitingForFinished == true go to sleep on pcall->waitForFinishedCondition, but there was no call to waitForFinishedCondition.wakeAll() anywhere in the code, so add it. Change-Id: I8d068dc0cc4f20786eb40fd7e2bb9840d8b70c7f Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QStringList::join: add an overload taking a single QCharMarc Mutz2012-09-033-5/+55
| | | | | | | | | | | | | | This overload avoids the needless heap allocation that the traditional overload incurs due to the implicit QChar -> QString conversion involved there. In order to share the implementation between the two overloads, QStringList_join now takes the separator as a (Char*,int) tuple instead of as a QString. Change-Id: I92961f13a3f19099de2a6e2df9f4789a12fc83a0 Reviewed-by: João Abecasis <joao.abecasis@nokia.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Rename MAC_CONFIG_TEST_COMMANDLINE to MAC_SDK_FLAGDanny Boelens2012-09-031-7/+8
| | | | | | | | The Mac OS X SDK is the only thing that variable is used for, so give it a name that better fits its use. Change-Id: Ifd9866bc19edda0e9f0bcb17270eb26a8849401e Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
* Remove the package macros from qglobal.hThiago Macieira2012-09-032-43/+17
| | | | | | | It's the wrong place to have these. Change-Id: I3b716317ba02ea2baf0f7053c8b16128e4c88e17 Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
* Change SChar to metatype id 40.Stephen Kelly2012-09-033-5/+4
| | | | | | | | | This fills the gap left by QWidgetStar, making the sequence between FirstCoreType and LastCoreType contiguous, which some benchmarks assume to be true anyway. Change-Id: I2d5d202b6246a9065fdf77f325a4a04279dbe4b7 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Command-line-only examples should not build as .app bundles on OSXShawn Rutledge2012-09-038-0/+8
| | | | | | | | It's confusing when you double-click it and nothing happens. Task-number: QTBUG-26976 Change-Id: I50c5625a41881bdbcbf29001197ed15da4ee0a28 Reviewed-by: Gabriel de Dietrich <gabriel.dietrich-de@nokia.com>
* fix docsFrederik Gladhorn2012-09-034-12/+14
| | | | | | Change-Id: Id57b7932afb89fe9d3f4f6e6c3b558265475d77b Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com> Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
* doc: fix example linkFrederik Gladhorn2012-09-031-1/+1
| | | | | Change-Id: Ie0235281c3a4d5e5dadc6e5823bbf722b7ca411f Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>