summaryrefslogtreecommitdiffstats
path: root/src/corelib
Commit message (Collapse)AuthorAgeFilesLines
...
* Doc: Add docs for rvalue references and move constructorsGeir Vattekar2013-09-2721-0/+302
| | | | | | | | | These members were introduced in 4.8, but left undocumented. Because we consider undocumented API to be internal, the members are \since 5.2. Change-Id: I52e2840a8cfaa7f59f410b3e2a06c0942ea06539 Reviewed-by: Jerome Pasion <jerome.pasion@digia.com> Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* iOS: Add explicit dependency on the Foundation framework for QtCoreTor Arne Vestbø2013-09-271-1/+1
| | | | | | | | | | | First of all it needed on both OSX and iOS, and secondly it's required for our Qt APIs, now that we provide conversion functions to Foundation types such as NSURL and NSString, so it should be part of LIBS, not LIBS_PRIVATE. Change-Id: Ida4977d6aa0e76b3d1b8b565672c00a8526e3381 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com> Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* Android: Handle new QtTraceMsg in message handlerPaul Olav Tvete2013-09-271-0/+1
| | | | | Change-Id: I3eb6fa42044ff4bdd0219925abf9d18cad60de7c Reviewed-by: hjk <hjk121@nokiamail.com>
* QVarLengthArray - doc fix.Thorbjørn Martsum2013-09-271-2/+2
| | | | | | | | | QVarLengthArray actually does support iterators. It was added in Qt 4.8. Change-Id: I9f714a09eab1d2e5dc023bd701ab7c743b078ec0 Reviewed-by: Olivier Goffart <ogoffart@woboq.com> Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
* Use a pimpl in QLoggingCategoryhjk2013-09-272-9/+26
| | | | | | | | With the usual pros/cons. Cleans up the publicly visible interface and gives some headroom for further extensions. Change-Id: I7237b1fd2a22c66574d1b7e532d99137bb56ce1d Reviewed-by: Kai Koehne <kai.koehne@digia.com>
* Win: Fixed namespaced build with QT_NO_FILESYSTEMWATCHEROliver Wolff2013-09-271-2/+2
| | | | | | Change-Id: I70049b90d2071c7a23a8a2804842d70d0f583f19 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com> Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
* Doc: remove duplicate \externalpage definitionsTopi Reinio2013-09-261-20/+0
| | | | | | | | Delete all duplicate \externalpage definitions from corelib, printsupport and testlib sources. Change-Id: I7dc5358861f4dad3e8ce080619b61ca3da64ec85 Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
* QLocale - Fix Mac date format code translationJohn Layt2013-09-261-29/+76
| | | | | | | | | | | | | | | | | | | | Mac uses the CLDR format codes which need to be translated into their Qt equivalent. The existing code mistranslates the year code, is outdated for a number of new codes introduced in recent versions of CLDR, and by default accepted any codes it didn't recognize. This change updates support to the latest version of CLDR, fixes the treatment of years, and defaults to ignoring any new format codes added in the future. Note that this change cannot have auto tests written as the system locale formats change between versions of OSX. Testing must be done manually by changing system locale and formats. Task-number: QTBUG-25057 Change-Id: I69dda25b4a0b38d3971995644546306876922d57 Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
* QString::reserve fix to avoid truncationMarko Pellikka2013-09-261-2/+2
| | | | | | | | | | In case of implicit memory sharing, QString::reserve caused data truncation if given size was smaller than size of data. Task-number: QTBUG-29664 Change-Id: If2da5ad051385635ebb829c18b5ebaa349f08e8a Reviewed-by: Olivier Goffart <ogoffart@woboq.com> Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
* Make QCoreApplicationPrivate::appName() thread-safeTor Arne Vestbø2013-09-261-0/+3
| | | | | Change-Id: Iea0d208e3e4721fff8a6667e0df1203a887c29d3 Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* Don't assume QCoreApplication::applicationName() will never changev5.2.0-alpha1Tor Arne Vestbø2013-09-252-6/+9
| | | | | | | | | Tests will typically create multiple QCoreApplications, some of them with different argv[0] than others, so we can't use a static variable to keep the cached application name. Change-Id: Icd97527730558944473a71373326b4a82f1b7cf7 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Allow QDir::mkpath() to work on QNX QNet pathsMatt Hoosier2013-09-251-1/+8
| | | | | | | | | | | | | | | | Due to a quirk in the way that QNX's mkdir() implementation reports return values when the requested pathname is the mountpoint of a QNet filesystem, the usual recursive directory creation algorithm used by QDir fails if the destination directory happens to exist inside QNet. This is an artificial failure; the desired directory can still be created with the normal mkdir() algorithm. There just needs to error handling in place to allow the recursive creation of parents to recognize this situation. Change-Id: I350fd9cb39858570032f9146c1154a9287701569 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Android: Use the application's class loader when loading Java classes.Christian Strømme2013-09-253-4/+33
| | | | | | | | | Previously the system class loader was used, which meant only system Java classes where available. With this change it's no longer necessary to add a JNI_OnLoad() to get a handle to application specific classes. Change-Id: Ic8fe35b4e525bfeb1d317d5ba6b496e39bf9bb30 Reviewed-by: Yoann Lopes <yoann.lopes@digia.com>
* Add tracing to logging frameworkhjk2013-09-259-6/+617
| | | | | | | | | Change-Id: I4d5b9a24a214785019ff1238c1790ead79205b15 Reviewed-by: Leena Miettinen <riitta-leena.miettinen@digia.com> Reviewed-by: Topi Reiniö <topi.reinio@digia.com> Reviewed-by: Robin Burchell <robin+qt@viroteck.net> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
* Fix WinCE/MSVC2008 build errors related to std::lower_bound patches.Sérgio Martins2013-09-251-0/+5
| | | | | | | See QTBUG-33473 for more information about this compiler bug. Change-Id: I13b945350fdc38165c1515f0cdd75a53cf37cd6c Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
* Fix truncation and conversion warnings on MSVC2010.Mitch Curtis2013-09-251-1/+1
| | | | | Change-Id: I44845e13b97753333a7c80a80ead0b352b8906b0 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Fix configure warnings on Windows 7 with MSVC2010.Mitch Curtis2013-09-251-1/+1
| | | | | Change-Id: I5c4e27d6437cdf7b0dfd17df812d4506d1be4fb9 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
* Fix warning about uninitialized variableLars Knoll2013-09-251-1/+1
| | | | | | Change-Id: I9c1a04556d4c77183d7025ca33314e7dfbf953ab Reviewed-by: John Layt <jlayt@kde.org> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Fix a crash in QProcess signal handling on Mac.Friedemann Kleint2013-09-251-1/+2
| | | | | | | | On Mac, SA_SIGINFO can be set while the handler is SIG_DFL. Change-Id: Ibaeaa1612e27217826841d7400309c45b5a101ea Initial-patch-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Fixed QJNIEnvironment reference counting.Yoann Lopes2013-09-251-3/+5
| | | | | Change-Id: I02369e0c6472375efeffed577d39b764c591e025 Reviewed-by: Christian Stromme <christian.stromme@digia.com>
* Fix WinCE/MSVC2008 build.Sérgio Martins2013-09-242-0/+6
| | | | | | | See QTBUG-33473 for a similar problem. Change-Id: Ib446618945dc1e7e1e7d43819cfae5f3c411f1bb Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* Add QKeySequenceEditIvan Komissarov2013-09-241-0/+8
| | | | | Change-Id: I497309d3e6cbf38b298afb5ff3cb1ed6a0e82000 Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
* Remove some qSort usages from QTimeZoneGiuseppe D'Angelo2013-09-241-3/+5
| | | | | | | | This is done per the mailing list discussion at http://www.mail-archive.com/development@qt-project.org/msg01603.html Change-Id: I974d41e986c67d1883c7d8dec879edd1fcbd08c2 Reviewed-by: John Layt <jlayt@kde.org>
* Add newlines to qEmergencyOut output on stderr.Robin Burchell2013-09-241-2/+2
| | | | | | | | | | | | | | qt_message, in the regular case, calls qt_message_print, which invokes the default message handler (qDefaultMessageHandler), which uses qMessageFormatString to construct a string, and then platform-dependent methods to print this out. This means that qMessageFormatString's newline is the one that separates debug messages. Unfortunately, in the emergency case, we don't have this luxury of doing formatting: so just make sure to add a newline so output is readable. Change-Id: I8f7bbceb9347b6312748f0f426feebaf04f6a226 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Remove qBinaryFind usages from QtCoreGiuseppe D'Angelo2013-09-233-8/+11
| | | | | | | | This is done per the mailing list discussion at http://www.mail-archive.com/development@qt-project.org/msg01603.html Change-Id: I6207982c08c92f3e01fb236d2e7546a1c9acd287 Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
* Fix conversion from 8-bit to QString without proper encodingThiago Macieira2013-09-231-1/+1
| | | | | | | | Found by ICC. Change-Id: Icd89e7df828afdb2acf2c46e00698ef04d5d94c9 Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com> Reviewed-by: John Layt <jlayt@kde.org>
* Fixed build issue on BlackBerryBernd Weimer2013-09-231-1/+1
| | | | | | | | | BlackBerry build was missing QTzTimeZonePrivate implementation. Change-Id: Ieaf6148a67c66f330e846c93f829ca17a4494359 Reviewed-by: Mehdi Fekari <mfekari@blackberry.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Wolfgang Bremer <wbremer@blackberry.com>
* QDateTime - Add QTimeZone supportJohn Layt2013-09-238-15/+411
| | | | | | | | | | | Add support to QDateTime for time zones using the new QTimeZone class. [ChangeLog][QtCore][QDateTime] Add support for a new Qt::TimeZone spec to be used with QTimeZone to define times in a specific time zone. Change-Id: I21bfa52a8ba8989b55bb74e025d1f2b2b623b2a7 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QTimeZone - Add Windows backendJohn Layt2013-09-234-1/+731
| | | | | | | Add backend implementation for Windows times zones. Change-Id: I30946f6672488c3f1d1d05754e9479aa62cce46f Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QTimeZone - Add Mac backendJohn Layt2013-09-234-2/+318
| | | | | | | Add Mac backend support Change-Id: Iafa2dbd925e18431f571e3eac62983015f8bc977 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QTimeZone - Add TZ File BackendJohn Layt2013-09-224-3/+1006
| | | | | | | | | | Add a backend for TZ Files. If available uses ICU for the display names and translations, otherwise the abbreviation is used. Change-Id: I58c777462810b1a76ea7bd95886836b70b8a3db5 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QTimeZone - Add ICU supportJohn Layt2013-09-224-1/+561
| | | | | | | Add ICU backend for QTimeZone Change-Id: I92e53a848477e366591102064b093e936f0b49d2 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QTimeZone - Define new class and apiJohn Layt2013-09-226-0/+3029
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Implement the new QTimeZone class based on the Olsen Time Zone ID's. This is the base implementation and does not include the Platform backends which are implemented separately. This change does include a default UTC backed to be used if no Platform backend is available, i.e. if QT_NO_SYSTEMLOCALE is set and ICU is not configured. This backend also provides a default set of time zones in the standard "UTC+00:00" offset format that are guaranteed to always exist regardless of the Platform backend. This change includes conversion functions between the Olsen ID's and Windows ID's using a conversion table based on Unicode CLDR data. This is implemented for all platforms for scenarios such as a Linux program needing to communicate with a Windows Exchange Server using the Windows ID. The CLDR conversion table is included under the UNICODE license, see http://unicode.org/copyright.html for details. [ChangeLog][QtCore][QTimeZone] Added new QTimeZone class to support time tone calculations using the host platform time zone database and the Olsen time zone ID's. Change-Id: Ibb417d08cf2663a0979d2be855d2c6ad6ad01509 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* Q_STATIC_ASSERT: use __COUNTER__ instead of __LINE__ if the compiler supports itMarc Mutz2013-09-221-0/+5
| | | | | | | | | | | When using __LINE__ to construct unique names, use of Q_STATIC_ASSERT is limited to one instance per line of code. On compilers that support __COUNTER__ (GCC and MSVC, probably others), we can get around that limitation by using that one to always get a new unique number, so use it. Change-Id: I89bcfaa32376b7a665f03e4275e89b13fa3e650d Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
* QFutureInterface: wrap a pair of {release,reserve}Thread() calls with RAIIMarc Mutz2013-09-211-3/+14
| | | | | | | | | | | | Rationale: a wait on a condition-variable is usually a cancellation point. On Posix, and probably in C++ at some point, a thread cancellation is done by (a kind of) exception unwinding the stack. To ensure that we call reserveThread() in all cases, wrap the function pair in a RAII class. Even if we currently don't seem to support exceptions in QtCore, this is low-hanging fruit, and no worse than what we had before. Change-Id: Ifb0f428ea50f9ac12be14e620615f46e00d3dd91 Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
* Merge "Merge branch 'stable' into dev" into refs/staging/devSergio Ahumada2013-09-217-125/+58
|\
| * Merge branch 'stable' into devSergio Ahumada2013-09-217-125/+58
| |\ | | | | | | | | | Change-Id: I37d85631ab1165ab91457d8880c4da907a9df73b
| | * Fix QFileSystemWatcher inotifyRiccardo Ferrazzo2013-09-192-5/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | On linux using QFileSystemWatcher with inotify backend when a watched file is moved and added again to the watched files its path is not replaced with the new one. This behavior prevents the emission of the fileChanged signal with the wrong file path. Task-number: QTBUG-33211 Change-Id: Ib45d8efdf5afbf8b8f6b4b26e43f3d6ee740aca6 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| | * Fix sigchld-HandlerH. Rittich2013-09-171-9/+31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Changed the sigchld-Handler such that the SA_SIGINFO flag is handeled correctly. Furthermore the signal mask is preserved such that the original signal handler is not interrupted when not allowed. Task-number: QTBUG-32979 Change-Id: Iec7663e7289ea5d95155f52cf8788ebf646cfabd Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| | * Doc: Remove duplicated Qt Concurrent overviewSze Howe Koh2013-09-164-111/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | - The "Concurrent Programming" page is an exact duplicate of the Qt Concurrent module landing page. - The "qtconcurrent intro" target is not referenced anywhere. Change-Id: Ice9b4360783013fe972258ca54a0004be43b8766 Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
* | | Fix some doc errors.Frederik Gladhorn2013-09-218-10/+11
|/ / | | | | | | | | | | | | Change-Id: Ib874d7e9671d9cee75fe41f4dac5d0de7b09245e Reviewed-by: Thiago Macieira <thiago.macieira@intel.com> Reviewed-by: Topi Reiniö <topi.reinio@digia.com> Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
* | Mark most of the contents of QtAlgorithms as deprecated.Robin Burchell2013-09-212-93/+223
| | | | | | | | | | | | | | | | | | This is done per the mailing list discussion at http://www.mail-archive.com/development@qt-project.org/msg01603.html Change-Id: Ic31c052e7f35c576250bf11826ca82e371142c82 Reviewed-by: Olivier Goffart <ogoffart@woboq.com> Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
* | Remove qFind usage from QCoreApplicationGiuseppe D'Angelo2013-09-211-1/+1
| | | | | | | | | | | | | | | | This is done per the mailing list discussion at http://www.mail-archive.com/development@qt-project.org/msg01603.html Change-Id: I1a067a4262d5442fb118089b859cad4dc1748c40 Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
* | Port of Qt 4's Windows session managementSamuel Gaist2013-09-211-0/+19
| | | | | | | | | | | | | | | | | | | | This patch aims to implement the session management for Windows. Based on the Qt 4 QApplication windows specific code Task-number: QTBUG-28228 Task-number: QTBUG-33032 Change-Id: I7059298ad9661aebd51e77a03f55a7a04f461479 Reviewed-by: Kai Koehne <kai.koehne@digia.com>
* | Add Mac type conversion functions to QtCoreMorten Johan Sørvig2013-09-2111-2/+287
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | New API: static QString QString::fromCFString(CFStringRef string); CFStringRef QString::toCFString() const; static QString QString::fromNSString(const NSString *string); NSString *QString::toNSString() const; static QUrl QUrl::fromCFURL(CFURLRef url); CFURLRef QUrl::toCFURL() const; static QUrl QUrl::fromNSURL(const NSURL *url); NSURL * QUrl::toNSURL() const; Add Q_OS_MAC-protected function declarations to header files, add implementation to _mm files. CF and NS types are forward-declared in the header files to avoid including the CoreFoundation and Foundation headers. This prevents accidental use of native types in application code. Add helper macros for forward- declaration to qglobal.h Add cf_returns_retained/ns_returns_autoreleased attributes to toCFString() and toNSURL(). These attributes assists the clang static analyzer. Add Q_DECL_ helper macros to qcompilerdetection.h. Add test functions (in _mac.mm files) to the QString and QUrl tests. Split out the test class declarations into a separate headers files. Change-Id: I60fd5e93f042316196284c3db0595835fe8c4ad4 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* | Use the correct identifier for the OS X operating system.Jake Petroules2013-09-211-3/+3
| | | | | | | | | | | | | | | | This is consistent with other areas of Qt: qmake, Qt.platform.os (QML), qbs.targetOS (QBS), and #define Q_OS_OSX. Change-Id: Ibf98e6ba3556a14187dadae1b0235e9c907c9001 Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
* | Merge "Merge remote-tracking branch 'origin/stable' into dev" into ↵Sergio Ahumada2013-09-215-212/+178
|\ \ | | | | | | | | | refs/staging/dev
| * | Merge remote-tracking branch 'origin/stable' into devFrederik Gladhorn2013-09-165-212/+178
| |\| | | | | | | | | | | | | | | | | | | Conflicts: src/corelib/tools/qstring.cpp Change-Id: Ifc6cd3a0f1cf14cc0fe6cf30afb0c7f40cfdbc3e
| | * Doc: Remove section about how to start threadsSze Howe Koh2013-09-141-36/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - Incomplete: It doesn't talk about how to use a raw QThread, or QRunnable, or Qt Concurrent. - Redundant: Its contents are already presented in QThread's class ref, and the line before this section links to the "Multithreading Technologies in Qt" overview page which provides a more complete intro Also remove snippet markers that are no longer used. Change-Id: I89b7bd72f10c8ffdfd9b7772e2493050aafc9c88 Reviewed-by: Jerome Pasion <jerome.pasion@digia.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
| | * Doc: Remove page about how to start QThreadsSze Howe Koh2013-09-143-114/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Multiple issues: - Incomplete: It doesn't talk about instantiating a raw QThread - Redundant: Its contents are already presented in QThread's class ref - Incorrect: It is legal to create a QThread before a QCoreApplication - Irrelevant: The bit about QCoreApplication::exec() and the etymology of "GUI thread" is unrelated to the topic of starting threads Also remove snippets that are no longer used Change-Id: Ice1819845b5b2cf843719edaa7b0f4bbb1e8bd97 Reviewed-by: Olivier Goffart <ogoffart@woboq.com> Reviewed-by: Jerome Pasion <jerome.pasion@digia.com> Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>