profile/ivi/qtbase.git
12 years agoQWheelEvent high-resolution delta support.
Morten Johan Sorvig [Mon, 9 Jan 2012 10:25:40 +0000 (11:25 +0100)]
QWheelEvent high-resolution delta support.

Support pixel-based deltas as well as sending
dx and dy values in the same event. Keep source and
behavior compatibility with Qt 4.

New API:
QPoint pixelDelta() const
QPoint angleDelta() const

Deprecate delta() and orientation().

Both pixel-based deltas and combined updates are
necessary for smooth trackpad-based scrolling on
OS X.

Qt 4 compatible behavior is achieved by sending an
extra wheel event in cases where the initial event
has a combined dx and dy update. This extra event
sends dx in delta() and orientation(), with pixelDelta()
and angleDelta() set to null.

Modify the Cocoa implementation to provide pixel
deltas. It is expected that not all platforms can
provide these. Angle deltas will always be available.

Change-Id: I20c10f0df338ddcd6a3f7a4d40949ed5ae3b4795
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
12 years agoQHeaderView - change not needed if to Q_ASSERT
Thorbjørn Lund Martsum [Thu, 23 Feb 2012 08:56:12 +0000 (09:56 +0100)]
QHeaderView - change not needed if to Q_ASSERT

This removes an if that should always be false. If it isn't
false we had more logical indexes than sections.

Unless visualIndices and logicalIndices are both 0-sized
(meaning that visual and logical indexes are the same)
then they better have exactly as many indexes as sectionCount.
Otherwise there must be inconsistent data - some logicalindex
would refer to non-existing visual sections or some
visualindeces wouldn't be hit by logicalIndices.

Change-Id: I2dc92f40895438d912bba20612131baf63df4fbe
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
12 years agoQMimeMagicRule: declare as Q_MOVABLE_TYPE
Marc Mutz [Fri, 24 Feb 2012 12:21:26 +0000 (13:21 +0100)]
QMimeMagicRule: declare as Q_MOVABLE_TYPE

Change-Id: I3725696e7369eb59eeb08095ffe0b8aa7537b4f3
Reviewed-by: David Faure <faure@kde.org>
12 years agoMinor fixes for RelationFlag.
Jan-Arve Saether [Mon, 20 Feb 2012 14:00:47 +0000 (15:00 +0100)]
Minor fixes for RelationFlag.

* Document AllRelations
* Assigned new values (starting from 1) for the remaining members of
  the enum.

Change-Id: I55ec197f24ff7d43ff3c0d101edd33b9615f9287
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com>
12 years agoRemove unused QT_NO_QWS_SHARE_FONTS
Stephen Kelly [Wed, 22 Feb 2012 23:48:54 +0000 (00:48 +0100)]
Remove unused QT_NO_QWS_SHARE_FONTS

Change-Id: I47e8111d6caffd9b45096e52695acaa55945c612
Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
12 years agoRemove QT_NO_QWS_MULTIPROCESS
Stephen Kelly [Wed, 22 Feb 2012 23:47:54 +0000 (00:47 +0100)]
Remove QT_NO_QWS_MULTIPROCESS

Change-Id: I1d6731dc5268919d0c36d5d27285321742be708f
Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
12 years agoRemove unused define QT_NO_COP.
Stephen Kelly [Wed, 22 Feb 2012 23:45:22 +0000 (00:45 +0100)]
Remove unused define QT_NO_COP.

It used to relate to QCop and QWS, which are no more.

Change-Id: Ie70c64a3a6ef60664009108b79eed7f33ea59f32
Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
12 years agoFix the library names on MinGW.
Stephen Kelly [Thu, 23 Feb 2012 17:25:28 +0000 (18:25 +0100)]
Fix the library names on MinGW.

Change-Id: I6c2008a0e7a07ca0603b8aa9362d31fa4ef7310a
Reviewed-by: Andreas Holzammer <andreas.holzammer@kdab.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
12 years agoFix Windows -no-freetype build
Jonathan Liu [Fri, 24 Feb 2012 12:03:49 +0000 (23:03 +1100)]
Fix Windows -no-freetype build

The localizedName and getEnglishName functions were defined in
qwindowsfontdatabase_ft.cpp but used in qwindowsfontdatabase.cpp.
However if -no-freetype is specified during configure then
qwindowsfontdatabase_ft.cpp is not compiled which results in an
undefined reference. To resolve this, the functions are moved to
qwindowsfontdatabase.cpp which is always compiled whether -no-freetype
is specified or not.

Change-Id: I085d84cecb29065ba5e6495b52eef7a678947bdc
Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
12 years agoCreate target pkgconfig dir in qmake generated Windows Makefiles
Hib Eris [Tue, 7 Feb 2012 14:28:55 +0000 (15:28 +0100)]
Create target pkgconfig dir in qmake generated Windows Makefiles

Change-Id: Icea70987ee3c6040ca3ba278a578849cb74156f4
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agoAdd UDev helper class for evdev plugins
Johannes Zellner [Tue, 14 Feb 2012 12:09:46 +0000 (13:09 +0100)]
Add UDev helper class for evdev plugins

Adopt evdevkeyboard plugin to use new UDev helper

Change-Id: Ie914c77dde9a28a8cf7f7cd972acd963c13bc698
Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
12 years agoUse "OpenGL" instead of just "GL" in documentation.
Samuel Rødal [Tue, 21 Feb 2012 12:24:39 +0000 (13:24 +0100)]
Use "OpenGL" instead of just "GL" in documentation.

Change-Id: I81a0beebc0241b9699ce321174e13a93e76e45e8
Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
12 years agoXCB No longer lists ThreadedOpenGL capability
Alan Alpert [Fri, 24 Feb 2012 08:30:40 +0000 (18:30 +1000)]
XCB No longer lists ThreadedOpenGL capability

Even with the more recent libxcb, it's a bit flaky. Just don't list
having this capability until it is more stable.

Change-Id: I1c2b39d757803fc23295944bc9a00e39ff4e1bbf
Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
12 years agoClean up some Q_WS_WIN
Debao Zhang [Wed, 22 Feb 2012 19:41:28 +0000 (11:41 -0800)]
Clean up some Q_WS_WIN

Q_WS_WIN does not exist any more.

Change-Id: Icb7f542cfcd4d21e994f246ff665583cb6b57610
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
12 years agoCodeCoverage: Skip headersclean test.
Caroline Chao [Thu, 23 Feb 2012 09:41:50 +0000 (10:41 +0100)]
CodeCoverage: Skip headersclean test.

The code coverage tool adds #line when instrumenting the code using the gcc
syntax.

Since tst_headersclean now uses the -pedantic-errors flag (qtbase commit
7e970eb58c71dc089815), it causes a fatal error when the code is
instrumented with the coverage tool.

Change-Id: Icb1888d1c1f0a982c0c56aa168e70a76a246a18c
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoclean up qmake-generated projects
Oswald Buddenhagen [Tue, 21 Feb 2012 15:09:30 +0000 (16:09 +0100)]
clean up qmake-generated projects

remove "header" and assignmets which are defaults or bogus,
reorder some assignments.

Change-Id: I67403872168c890ca3b696753ceb01c605d19be7
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoReverted part of "Refactor input context tests"
Pekka Vuorela [Thu, 23 Feb 2012 13:49:11 +0000 (15:49 +0200)]
Reverted part of "Refactor input context tests"

This commit reverts partly 7401832a7d45de99562b94340375393a39267f41

There is something wrong with DummyWindow/XCB/Metacity, Metacity
crashes quite often when QWindow is activated.

Change-Id: I611af2678814f41c941cb697054135f561a77878
Reviewed-by: Joona Petrell <joona.t.petrell@nokia.com>
12 years agoAdd the QtMain windows library to the CMake files.
Stephen Kelly [Thu, 23 Feb 2012 16:05:41 +0000 (17:05 +0100)]
Add the QtMain windows library to the CMake files.

Change-Id: Iff8b9bdd4b069721103e1cd5854e56b6116d7549
Reviewed-by: Andreas Holzammer <andreas.holzammer@kdab.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Alexander Neundorf <neundorf@kde.org>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
12 years agoQSqlTableModel: rename parameter to avoid name clash with method
Mark Brand [Wed, 15 Feb 2012 00:31:07 +0000 (01:31 +0100)]
QSqlTableModel: rename parameter to avoid name clash with method

Change-Id: Ib8fa6b0ca71ffdd9f1f8416c448b5c830988ed08
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
12 years agoQSqlTableModel: avoid extra QMap lookup
Mark Brand [Wed, 15 Feb 2012 09:22:15 +0000 (10:22 +0100)]
QSqlTableModel: avoid extra QMap lookup

The consensus on #qt-labs seems to be that there is little or no
point in checking with contains() before using value(), even if
the map does not contain the key in most cases.

Change-Id: I34740a91d5c3af65e20937a5ae3b4bab32406440
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
12 years agofix style
Mark Brand [Wed, 15 Feb 2012 14:05:28 +0000 (15:05 +0100)]
fix style

Change-Id: I8ad0b4d15484662be7b38daa797a688727377c88
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
12 years agoQSqlTableModel: document edit strategy behavior
Mark Brand [Thu, 16 Feb 2012 13:21:07 +0000 (14:21 +0100)]
QSqlTableModel: document edit strategy behavior

Change-Id: Ib674288e950837aa343cf1206ed081386b1fff0d
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
12 years agoimprove documentation language style
Mark Brand [Mon, 20 Feb 2012 21:17:11 +0000 (22:17 +0100)]
improve documentation language style

Change-Id: Ic7daa90fff764578bd8122986a73c2ea6280e784
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
12 years agoFixed resolution of QMAKESPEC on Windows.
Rohan McGovern [Thu, 23 Feb 2012 00:43:25 +0000 (10:43 +1000)]
Fixed resolution of QMAKESPEC on Windows.

base_vars["QMAKESPEC_ORIGINAL"] is not guaranteed to be set the first
time resolveSpec is called, since an include() can wipe it out.  Change
it so that resolveSpec is called repeatedly until some
QMAKESPEC_ORIGINAL is set.

The code which attempted to remove all of the path up to the last / was
incorrect and must have been dead code (or its wrongness didn't matter)
until now.

Change-Id: I2b31ae10fc284ac7293c3cd95e5a2fd503ca7ab0
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
12 years agoAdded documentation for QOpenGLContext and QOpenGLContextGroup.
Samuel Rødal [Tue, 21 Feb 2012 11:46:44 +0000 (12:46 +0100)]
Added documentation for QOpenGLContext and QOpenGLContextGroup.

Change-Id: I00e3e3b3fd37b27b31d4705de3c8c34be9211707
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
12 years agoBump the moc output revision
Kent Hansen [Thu, 23 Feb 2012 12:52:16 +0000 (13:52 +0100)]
Bump the moc output revision

Commit aee1f6cc413f56bf4962324799ee3887c3dd037f changed the values of
some built-in meta-type ids. Since the ids of built-in types are
directly encoded -- not as the symbolic QMetaType::Type name, but as
a raw integer -- in the flags for meta-properties, the moc output
prior to that change is incompatible with the current output.

Change-Id: I970484825137a4f19c80726cfe2024e741e3e879
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
Reviewed-by: Roberto Raggi <roberto.raggi@nokia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoRevert "Escape project file name in makefile rebuild rules."
Andreas Hartmetz [Thu, 23 Feb 2012 14:05:39 +0000 (15:05 +0100)]
Revert "Escape project file name in makefile rebuild rules."

It was the result of miscoordination between Andreas Holzammer and me,
duplicating the functional change of commit
ea2c9f764fed654a57972223449f41e208e05863.
This reverts commit 8b7a9b4898c85e81d87cf642ec59ce85e917ee35.

Change-Id: I9a47746c1c12ca00b2dc5c5d50e99f9bf990e3f7
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agoUse new plugin system in plugin autotest.
Friedemann Kleint [Thu, 23 Feb 2012 12:51:12 +0000 (13:51 +0100)]
Use new plugin system in plugin autotest.

Fix up test use QFINDTESTDATA for shadow builds.

Change-Id: I64731baa44f446ce360631ed6a638cea098d78a0
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
12 years agoQSslSocket::verify certificates when on-demand loading is used
Martin Petersson [Tue, 21 Feb 2012 14:28:18 +0000 (15:28 +0100)]
QSslSocket::verify certificates when on-demand loading is used

Task-number: QTBUG-24350
Change-Id: I5a328efe6606f5d438bb4787a5c02a425ce42aca
Reviewed-by: Richard J. Moore <rich@kde.org>
12 years agoQWindowsPipeWriter could terminate the process to early
Martin Petersson [Thu, 23 Feb 2012 12:18:47 +0000 (13:18 +0100)]
QWindowsPipeWriter could terminate the process to early

When the QWindowsPipeWriter is deleted it will wait
for the thread to exit. This wait was set to 100 ms
which will not always be enough time for the thread
to exit, in that case the thread will be terminated.
This will increase the timeout to 30 seconds that
should be more then enough time for the thread to exit
by itself.

Task-number: QTBUG-4425
Change-Id: I9b1910c0213376c622c091be050df2a1c4c6b190
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
12 years agoQTextEngine - treat a fullstop (0x2E) as the same script as the preceeding text when...
John Tapsell [Wed, 8 Feb 2012 10:12:16 +0000 (10:12 +0000)]
QTextEngine - treat a fullstop (0x2E) as the same script as the preceeding text when dividing up strings

Many languages use a fullstop to indicate an abbreviation, making the
fullstop part of the word.  For languages like thai, it is required to
pass the fullstop along for correct word breaking.

Change-Id: I5ad0ddbc66ea96e08913446dad8fd3c5d5dd0905
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
12 years agoHarfbuzz-thai: Hide ZWJ and ZWNJ characters and show Inherited characters
John Tapsell [Wed, 8 Feb 2012 10:12:13 +0000 (10:12 +0000)]
Harfbuzz-thai: Hide ZWJ and ZWNJ characters and show Inherited characters

Thai is not supposed to have ZWJ and ZWNJ characters or any other of the
Inherited Unicode Scripts
(http://www.verisigninc.com/assets/idn-inherited-unicode-script.pdf)
- they don't have a mapping to the thai encoding tis620 which libthai
requires.  However it is an unfortunate fact that there are many websites
etc that liberally place these ZWJ and ZWNJ characters throughout thai text
to force word boundaries, so we must also deal with them.

We deal with all Inherited characters by mapping them to the invalid code ~0
in tis620 encoding, following what libthai does internally in its own tis620
encoding functions, and then replacing this character with the original
unicode and setting dontPrint to true to hide the ZWJ and ZWNJ
characters.

Includes a unit test to check the behaviour.

Change-Id: I1ee8388b650cb5fc61bcb265efb9843c73f327ac
Reviewed-by: Adrian Yanes <ext-adrian.yanes@nokia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
12 years agoRequire compiler support for deprecated constructors.
Stephen Kelly [Wed, 22 Feb 2012 13:25:33 +0000 (14:25 +0100)]
Require compiler support for deprecated constructors.

Change-Id: I1d4cdcbbddb7895e6529e4f6b5295312e9a3a0e6
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoRemove QT_ASCII_CAST_WARN_CONSTRUCTOR
Stephen Kelly [Wed, 22 Feb 2012 23:22:59 +0000 (00:22 +0100)]
Remove QT_ASCII_CAST_WARN_CONSTRUCTOR

GCC version < 3 which it was created for is not supported anymore.

Change-Id: I0b4df4c99600cacbaafbf0bc4270cd4978600956
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoRename QMetaTypeSwitcher::UnknownType to NotBuiltinType.
Jędrzej Nowacki [Mon, 13 Feb 2012 12:06:40 +0000 (13:06 +0100)]
Rename QMetaTypeSwitcher::UnknownType to NotBuiltinType.

UnknownType suggest that a type is unknown to QMetaType, but
QMetaTypeSwitcher is not checking for custom types.

Change-Id: I6b8b692e0f20bed286c713672b35fb15757d389e
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoUse -fPIE on QNX
Sean Harmer [Thu, 23 Feb 2012 12:42:17 +0000 (12:42 +0000)]
Use -fPIE on QNX

Change-Id: Iec065f528f5edd848be580807a607488dc2e401f
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoFix fontconfig.pri file to allow QPA plugins to build
Sean Harmer [Thu, 23 Feb 2012 11:41:47 +0000 (11:41 +0000)]
Fix fontconfig.pri file to allow QPA plugins to build

Change-Id: I5ebcffb7153f4216d69921d4818051e6b3d14d8a
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
12 years agoAdd the quitlock feature to QThread.
Stephen Kelly [Wed, 8 Feb 2012 14:55:29 +0000 (15:55 +0100)]
Add the quitlock feature to QThread.

Change-Id: Ib44ee9739499ba4c5f0fecbef3976251ea22836d
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoAdd WindowDoesNotAcceptFocus flag and use it in xcb
Jan Arne Petersen [Fri, 2 Dec 2011 14:20:04 +0000 (15:20 +0100)]
Add WindowDoesNotAcceptFocus flag and use it in xcb

Add window flag to support windows which should not get the input
focus.

Sets the input field in the WM_HINTS structure of the window to false
if the WindowDoesNotAcceptFocus flag is set on a window in xcb.

Change-Id: Ifbc10695b83484c17dca0eb13ea826d74f174833
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
12 years agocompile fix: missing #include <unistd.h>s
Marc Mutz [Thu, 23 Feb 2012 11:23:25 +0000 (12:23 +0100)]
compile fix: missing #include <unistd.h>s

Change-Id: I3bd34f67033fb921c49da97419c107811d8da6ff
Reviewed-by: David Faure <faure@kde.org>
12 years agoFleshed out the QWindow documentation to be less sparse.
Samuel Rødal [Tue, 21 Feb 2012 09:44:33 +0000 (10:44 +0100)]
Fleshed out the QWindow documentation to be less sparse.

Change-Id: Ia3873687a2c3e0dd85c56e4f9e34d2e194e2ff50
Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
12 years agoAdded documentation for QSurfaceFormat.
Samuel Rødal [Tue, 21 Feb 2012 12:40:57 +0000 (13:40 +0100)]
Added documentation for QSurfaceFormat.

Change-Id: I3b42b09e6e42092c098e4fc20c5ba7dd7e354116
Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
12 years agoUpdate tst_QTextEdit::fullWidthSelection
Eskil Abrahamsen Blomfeldt [Thu, 23 Feb 2012 09:13:41 +0000 (10:13 +0100)]
Update tst_QTextEdit::fullWidthSelection

Since we would add 1 to the height of script lines in the layout before
and there was no compensation for this in the box font engine, which is
used by this test, the selection rect in the test images was one pixel too
high. Now that the +1 has been removed from the height, the images have to
be updated.

Change-Id: Ic9ea0ace6b61be496846c7f757ae309756cd9f5f
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
12 years agoHandle theme change in QApplication/QGuiApplication.
Friedemann Kleint [Tue, 21 Feb 2012 13:45:07 +0000 (14:45 +0100)]
Handle theme change in QApplication/QGuiApplication.

Re-initialize palette and fonts.

Change-Id: Ib312747886a31e8370f8d99536d52cbcf8afe8a4
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
12 years agoFix conflict between QMainWindow::restoreState() and QWidget::setStylesheet()
Debao Zhang [Sat, 24 Dec 2011 16:47:41 +0000 (00:47 +0800)]
Fix conflict between QMainWindow::restoreState() and QWidget::setStylesheet()

If QMainWindow::restoreState() then QWidget::setStylesheet() were called
before the QMainWindow is shown, the size of QDockWidget can not be
restored.

QWidget::setStylesheet() will generate QEvent::StyleChange event, which will
cause the function QDockAreaLayout::fitLayout() to be called before the layout
of MainWindow is activated. Although the state info has been stored in
a QMainWindowLayoutState variable by QMainWindow::restoreState(), but
QMainWindowLayout::setGeometry() still isn't called at present. So
QDockAreaLayout::fitLayout() will force the size of dockwidgets
and centralwidget to be calculated using the wrong geometry, which will
break the state restored by QMainWindow::restoreState().

This is a side effect of 692e9103ebb85b90e79377206d5d03b704d43d42.

Task-number: QTBUG-15080

Change-Id: I8cda6a529d178f7467a59b780db80df0a44d4769
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoFix rounding error in QInputMethod::cursorRectangle().
Andrew den Exter [Thu, 23 Feb 2012 05:02:23 +0000 (15:02 +1000)]
Fix rounding error in QInputMethod::cursorRectangle().

Use QRectF consistently to avoid the rounding done in the conversion
to QRect.

Task-number: QTBUG-24463
Change-Id: If9ea858ebabf8c449ea058b9d379d4a57cb6c82d
Reviewed-by: Joona Petrell <joona.t.petrell@nokia.com>
12 years agoQMenuBar: Clean up Q_WS_WIN
Debao Zhang [Thu, 23 Feb 2012 02:29:51 +0000 (18:29 -0800)]
QMenuBar: Clean up Q_WS_WIN

 - Replace Q_WS_WIN with Q_OS_WIN
 - Remove useless #ifdef Q_OS_WINCE which located in another #ifdef
   Q_OS_WINCE

Change-Id: I6279b6d74902ab3ca6bdb7292c2936a76e3e6952
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
12 years agoHarfbuzz-thai - When calling HB_OpenTypePosition we must set doLogClusters to true...
John Tapsell [Wed, 8 Feb 2012 10:12:08 +0000 (10:12 +0000)]
Harfbuzz-thai - When calling HB_OpenTypePosition we must set doLogClusters to true for thai

This bug resulted in word wrapping not working correctly for thai.

Reviewed-by: Adrian Yanes <ext-adrian.yanes@nokia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
(cherry picked from commit 7495f2c7c55917a98c903547858be923028b7827)

Change-Id: Iedb26a10078c6cc4e90d090176ab63499293d69d
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
12 years agoHarfbuzz-thai - fix to_tis620 function for latin characters
John Tapsell [Wed, 8 Feb 2012 10:12:03 +0000 (10:12 +0000)]
Harfbuzz-thai - fix to_tis620 function for latin characters

This was an obvious typo - a missing "else" in a group of if statements.

Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
Reviewed-by: Adrian Yanes <ext-adrian.yanes@nokia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
(cherry picked from commit a784bdcabe895ab927cbc28118d427c6e932b9fc)

Change-Id: Icbd458034e42cf7f2af33c1ecc9b0e4f1aa8724a
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
12 years agoFix height of some Thai characters
Marko Kenttala [Tue, 31 Jan 2012 11:19:02 +0000 (13:19 +0200)]
Fix height of some Thai characters

Some Thai characters with two above glyphs were higher than fonts ascent. This
caused them to be clipped in for example qtcomponents buttons.

Added checking for this and calculation of new lower offset between glyphs if
needed.

Task-Number: ou1cimx1#898104
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Sami Merilä <sami.merila@nokia.com>
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
(cherry picked from commit d7c7bf721c93fe7629f725c181b52ad9ca645a7a)

Change-Id: Ie4ac69de75f50b68b2ba87353d83098846f319f4
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
12 years agoFixed tst_qobject signalbug silently not compiled in -fast builds.
Friedemann Kleint [Thu, 23 Feb 2012 07:53:04 +0000 (08:53 +0100)]
Fixed tst_qobject signalbug silently not compiled in -fast builds.

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>
12 years agoAdd src/concurrent/qtconcurrentversion.h to .gitignore
Bradley T. Hughes [Thu, 23 Feb 2012 07:17:22 +0000 (08:17 +0100)]
Add src/concurrent/qtconcurrentversion.h to .gitignore

Change-Id: I521d9809b5e7a67db1370dd178d3795beee2a388
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
12 years agoSilence coverity warning about sizeof(Node*) vs sizeof(Node) in QList
Andy Shaw [Wed, 22 Feb 2012 12:28:44 +0000 (13:28 +0100)]
Silence coverity warning about sizeof(Node*) vs sizeof(Node) in QList

Coverity was complaining about QList::node_copy using sizeof(Node *)
instead of sizeof(Node).  The complete message from Coverity is:

"Passing argument "from" of type "struct QList<QObject *>::Node *" and
argument "(to - from) * sizeof (struct QList<QObject *>::Node *) /*4*/"
to function "memcpy" is suspicious. Did you intend to use "sizeof(struct
QList<QObject *>::Node)" instead of "sizeof (struct
QList<QObject *>::Node *)" ? In this particular case sizeof(struct
QList<QObject *>::Node *) happens to be equal to sizeof(struct
QList<QObject *>::Node), but this is not a portable assumption."

Task-number: QTBUG-24443
Change-Id: I583887a8b4177a224664065e14f8780a9586c9a3
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoReport failure to open deprecated header file
Matthew Vogt [Mon, 20 Feb 2012 00:23:26 +0000 (10:23 +1000)]
Report failure to open deprecated header file

If a deprecated header file is not writable, report the error message.
The existing error message statement is not processed due to an
operator precedence issue.

Change-Id: Ifb2d4e234c64e560d05c021c621966bce19ce215
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoUse the CMake definition of Windows for CMake macros.
Stephen Kelly [Thu, 23 Feb 2012 00:05:46 +0000 (01:05 +0100)]
Use the CMake definition of Windows for CMake macros.

Change-Id: I599ddaaf9176f76f2e144c893e607757957dfef2
Reviewed-by: Clinton Stimpson <clinton@elemtech.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
12 years agoSuppport up to 27 mouse buttons from DirectFB Plugin.
Rick Stockton [Fri, 17 Feb 2012 03:20:35 +0000 (19:20 -0800)]
Suppport up to 27 mouse buttons from DirectFB Plugin.

Previous to this update, our plugin accepts only 3 moue buttons
(from DirectFB, to be translated into Qt::MouseButton values.)
This update changes our Plugin, so that it will successfully
translate up to 27 mouse button numbers. It is unclear, to the
author, which configurations of DirectFB on Linux might be
capable of actually sending high-numbered mouse button Events
to Qt. But, if/when a DirectFB configuration does so, this
change makes Qt ready to recognize and work with the button event.

Task-number: QTBUG-24335

Change-Id: I8839ed386eb3d261a187355a244e80d511399ea8
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
12 years agoRemove unneeded code to convert to ASCII/Latin1.
Robin Burchell [Mon, 13 Feb 2012 15:27:36 +0000 (17:27 +0200)]
Remove unneeded code to convert to ASCII/Latin1.

This isn't used, and isn't wanted with the upcoming utf8 switch.

Change-Id: Ibec0fa7f36549df6a1c240353ffcd44beb2976f0
Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoDon't do macro self-expansion for moc anymore.
Stephen Kelly [Wed, 22 Feb 2012 17:17:53 +0000 (18:17 +0100)]
Don't do macro self-expansion for moc anymore.

Change-Id: Ia34cc244a160c6c4abe6dacd7a2ce29bc4fc7bfb
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoRemove unused Q_CANNOT_DELETE_CONSTANT
Stephen Kelly [Tue, 21 Feb 2012 16:25:28 +0000 (17:25 +0100)]
Remove unused Q_CANNOT_DELETE_CONSTANT

Change-Id: I697f3f786d84fa766b3bc48d93fc265deee5fdcf
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoAdd the QT_LIBINFIX to the CMake config files.
Stephen Kelly [Tue, 21 Feb 2012 22:00:57 +0000 (23:00 +0100)]
Add the QT_LIBINFIX to the CMake config files.

Change-Id: If7bec54eca2d28cba314ce94a1ab1831c024ad31
Reviewed-by: Alexander Neundorf <neundorf@kde.org>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
12 years agoRemove detection of GCC versions which are not supported anywhere.
Stephen Kelly [Tue, 21 Feb 2012 16:26:45 +0000 (17:26 +0100)]
Remove detection of GCC versions which are not supported anywhere.

Change-Id: If254af51880e20be486b14f5237e6e1d4e4d6af3
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoRemove use of Q_BROKEN_DEBUG_STREAM.
Stephen Kelly [Tue, 21 Feb 2012 21:18:26 +0000 (22:18 +0100)]
Remove use of Q_BROKEN_DEBUG_STREAM.

No supported compiler defines it, and it was not used consistently
so it didn't work anyway.

Change-Id: Icc9e911e22daaedaee3d9316c15d19be26cd2e72
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoUse QMAKE_SUBSTITUTIONS conditionals
Stephen Kelly [Tue, 21 Feb 2012 18:45:05 +0000 (19:45 +0100)]
Use QMAKE_SUBSTITUTIONS conditionals

Instead of generating CMake conditionals.

Change-Id: I3d987cc08666270e618222be9292558e73bc961e
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agoFix breakage in dead code
Richard Moore [Tue, 21 Feb 2012 22:44:08 +0000 (22:44 +0000)]
Fix breakage in dead code

Change-Id: Ibcddfb711a3f47bf957a4b010330e8a775f1a2e8
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoAdd further theme hints to QPlatformTheme.
Friedemann Kleint [Tue, 21 Feb 2012 14:36:01 +0000 (15:36 +0100)]
Add further theme hints to QPlatformTheme.

- Add hints for QDialog/QDialogButtonBox.
- Add hint for available popup-menu area.
- Add keyboard scheme hint replacing
  QGuiApplicationPrivate::currentKeyPlatform()

Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
Task-number: QTBUG-24204
Task-number: QTBUG-24315

Change-Id: I6653786b0dcb49a6fc264d3b9891dbfee502bd3e
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
12 years agoQEasingCurve: fix a missing */
Marc Mutz [Wed, 22 Feb 2012 14:29:05 +0000 (15:29 +0100)]
QEasingCurve: fix a missing */

Change-Id: I344342e950158c9dc832f1cd181d92899ddb1651
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoFail with #error early if the compiler does not support bool or explicit.
Stephen Kelly [Tue, 21 Feb 2012 16:27:39 +0000 (17:27 +0100)]
Fail with #error early if the compiler does not support bool or explicit.

The fail mode for bool is moved from later in qglobal.h, and explicit is
used unguarded throughout Qt, so the macro is already useless.

Change-Id: Iff26892b025ba155e360a1f2dc93a67a6622dbc1
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoRemove custom text codec for C strings.
Robin Burchell [Mon, 30 Jan 2012 12:23:22 +0000 (14:23 +0200)]
Remove custom text codec for C strings.

This setting is extremely harmful, as code cannot know whether or not to expect
it. It also made the behaviour of QString::fromAscii and ::toAscii unintuitive,
and caused a lot of people to make mistakes with it.

Change-Id: I2f429fa7ef93bd75bb93a7f64c56db15b7283388
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
12 years agoUpdated QApplication / QGuiApplication to match Qt 5 reality.
Samuel Rødal [Mon, 20 Feb 2012 13:11:29 +0000 (14:11 +0100)]
Updated QApplication / QGuiApplication to match Qt 5 reality.

Removed obsolete Q_WS_X11/WIN/MAC stuff as well.

Change-Id: I8b65a0348a8cb170f3f060023fc6d9d982949b7e
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
12 years agoFix typos
Pekka Vuorela [Thu, 16 Feb 2012 12:24:22 +0000 (14:24 +0200)]
Fix typos

Change-Id: Ic0389d36bad001935376fb29d8c925b7ff908e4f
Reviewed-by: Joona Petrell <joona.t.petrell@nokia.com>
12 years agoRefactor input context tests
Pekka Vuorela [Wed, 22 Feb 2012 09:34:37 +0000 (11:34 +0200)]
Refactor input context tests

Combined test input context instances and adapted changed
interfaces a bit.

Change-Id: Id5422cac5967d45dcaf2eb71b941d9c45e3b4dee
Reviewed-by: Joona Petrell <joona.t.petrell@nokia.com>
12 years agoFix QJson autotest on Windows.
Friedemann Kleint [Wed, 22 Feb 2012 08:26:27 +0000 (09:26 +0100)]
Fix QJson autotest on Windows.

- Fix warning: "Character represented by universal-character-name
  '\uFFFF' cannot be represented in the current code page (1252).
- Fix character conversion
- Change source file to plain ASCII, add defines for special
  characters.

Change-Id: I8557e6ba7488f746247f0d78181f14bfb7d5aaae
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
12 years agoMigrate evdev plugins to the new plugin system
Laszlo Agocs [Wed, 22 Feb 2012 07:25:01 +0000 (09:25 +0200)]
Migrate evdev plugins to the new plugin system

Change-Id: I7eb283646b7529080c8c2f41c267b0135c8f57e4
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
12 years agoCodeCoverage: Move installCoverageTool call.
Caroline Chao [Fri, 17 Feb 2012 08:37:15 +0000 (09:37 +0100)]
CodeCoverage: Move installCoverageTool call.

Call it from qtest_qParseArgs() instead of qExec(). This will allow to
remove the code coverage calls from quicktest.

Both the installation and the saving of code coverage data are now
gathered in testlib.

Change-Id: If3baedb0cff9d894e6f232b947af7e3158703d9d
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
12 years agoFixed tst_qlogging app silently not compiled in some -fast builds.
Rohan McGovern [Wed, 22 Feb 2012 00:07:01 +0000 (10:07 +1000)]
Fixed tst_qlogging app silently not compiled in some -fast builds.

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.

Task-number: QTBUG-21168
Change-Id: Ic51941db497d7b8fb004f3c50f5ea24d90ff3114
Reviewed-by: Toby Tomkins <toby.tomkins@nokia.com>
12 years agoQtCore: add constexpr to geometric classes
Marc Mutz [Fri, 17 Feb 2012 11:02:14 +0000 (12:02 +0100)]
QtCore: add constexpr to geometric classes

This turns code like QPoint(12, 12) into a compile-time
expression, under a C++11 compiler, and allows to define
arrays of these types that end up in read-only memory,
just like PODs would.

Some constructors and QLine::pointAt() needed to be
adjusted to fit into the empty-body/only-return-expression
requirement for constexpr constructors/functions.

Change-Id: Id11ee2752c948930c3e40a91d1f6d7c97db7a373
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoFlag QGraphicsView test as unstable on Mac.
Toby Tomkins [Tue, 21 Feb 2012 04:55:13 +0000 (14:55 +1000)]
Flag QGraphicsView test as unstable on Mac.

Task-number: QTBUG-24296

Change-Id: I9f748c368fbc0cc2b272be9400da95d774d51bde
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoDrop file-engine abstraction from public API
João Abecasis [Fri, 17 Feb 2012 19:09:17 +0000 (20:09 +0100)]
Drop file-engine abstraction from public API

This abstraction imposed serious performance penalties and is being
dropped from the public API.

In particular, by allowing file names to be arbitrarily hijacked by
different file engines, and requiring engines to be instantiated in
order to decide, it imposed unnecessary overhead on all file operations.

Another flaw in the design with direct impact on performance is how
engines have no way to provide (or retain) additional information
obtained when querying the filesystem. In many places this has meant
repeated operations on the file system, where useful information is
immediately discarded to be queried again subsequently.

For Qt 4.8 a major refactoring of the code base took place to allow
bypassing the file-engine abstraction in select places, with
considerable performance gains observed. In Qt 5 it is expected we'll be
able to take this further, reaping even more benefits, but the
abstraction has to go.

[Dropping this now does not preclude that virtual file systems make an
appearance in Qt at a later point in Qt 5's lifecycle. Hopefully with a
new and improved abstraction.]

Forward declarations for QFileExtension(Result) were dropped, as the
classes were never used or defined.

Tests using "internalized" classes will only fully run on developer
builds. QFSFileEngine was removed altogether from exception safety test,
as it isn't its intent to test internal API.

Change-Id: Ie910e6c2628be202ea9e05366b091d6d529b246b
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
12 years agoCorrect pkg-config usage to respect sysroot
Donald Carr [Mon, 6 Feb 2012 15:28:19 +0000 (15:28 +0000)]
Correct pkg-config usage to respect sysroot

Direct use of pkg-config variables disregards the sysroot offset pkg-config
factors into consideration with the dedicated variables:

--cflags-only-I
--libs-only-L

these parameters exist exactly for this reason.

Change-Id: Ieecf31ebe0640f64b272b84fba22701aacf8f966
Reviewed-by: Johannes Zellner <johannes.zellner@nokia.com>
Reviewed-by: Donald Carr <donald.carr@nokia.com>
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agoFix potential race condition in data structure of adopted thread watcher
jian liang [Sun, 19 Feb 2012 14:09:44 +0000 (22:09 +0800)]
Fix potential race condition in data structure of adopted thread watcher

Fix potential race condition in data structure of adopted thread watcher
in Windows. Since QVector is not thread safe, it is not safe to read and
append data to qt_adopted_thread_handles or qt_adopted_qthread
simultaneously in qthread_win.cpp. This patch fix this race condition.

Change-Id: I2d0c7a4cdde5390d38d15c98343f0fc6ddd24aba
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
12 years agoMerge overloads
Richard Moore [Sun, 19 Feb 2012 15:55:29 +0000 (15:55 +0000)]
Merge overloads

Fixes ### Qt 5

Change-Id: I2846593616635440e17c8a9ce518780561992b84
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoMerge overloads.
Richard Moore [Sun, 19 Feb 2012 16:52:24 +0000 (16:52 +0000)]
Merge overloads.

Fixes a Qt 5 TODO

Change-Id: Ide3159a5b979bd8e8a1edefff7fccb98dbe9a78e
Reviewed-by: Pierre Rossi <pierre.rossi@nokia.com>
12 years agoQElapsedTimer/Win: Fix 64-bit integer overflow
Jonathan Liu [Tue, 21 Feb 2012 04:54:25 +0000 (15:54 +1100)]
QElapsedTimer/Win: Fix 64-bit integer overflow

The ticksToNanoseconds function in qelapsedtimer_win.cpp multiplies
ticks from performance counter with 1000000000 which can sometimes
result in 64-bit integer overflow. This can cause the elapsed time to
reset or jump around.

Task-number: QTBUG-23150
Change-Id: I464503e03cbe64e13906e773beafbf88e7dc256a
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
(cherry picked from commit f30a91ba9d98de1a0ebee5608ba289ac35871a8c)

12 years agoFix the qlocalsocket test
Andrew Stanley-Jones [Tue, 21 Feb 2012 07:11:49 +0000 (08:11 +0100)]
Fix the qlocalsocket test

This test is broken in a couple of ways. A few one line fixes
combined into a single patch.

1. Linux is the only OS that does
abstract unix domain sockets by prepending a null as the first
character.  Don't test this on non-Linux platforms and expect
it to pass.

2. Change QVERIFY2 to QCOMPARE so we can see why this
fails in CI but no on the local system.  Use QCOMPARE
where possible.

Change-Id: Ic3d2cf9696730dc4d6589539fdfe8a48ccf28de5
Reviewed-by: Alex <alex.blasche@nokia.com>
12 years agoEnable qlocalsocket auto test
Andrew Stanley-Jones [Wed, 15 Feb 2012 12:58:29 +0000 (13:58 +0100)]
Enable qlocalsocket auto test

Due to recent changes in the test it should now compile
and run properly.  This re-enables the test.

Change-Id: I6c647d99fa1f1b1c53e006fef2865d6be08ec16c
Reviewed-by: Alex <alex.blasche@nokia.com>
12 years agoFix error in addrlen field
Andrew Stanley-Jones [Tue, 21 Feb 2012 20:37:57 +0000 (21:37 +0100)]
Fix error in addrlen field

addrlen must be initialize to the amount of space available
in the buffer.

Change-Id: I52945d780bba9d22aeaa7ac5a35a0e54dbea60dc
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoGive the compile flags an EXECUTABLE_ prefix.
Stephen Kelly [Tue, 21 Feb 2012 11:06:54 +0000 (12:06 +0100)]
Give the compile flags an EXECUTABLE_ prefix.

The fPIE flag should only be used with executables.

Change-Id: If799ae4a7fe2492af3aac67651659a52d365024a
Reviewed-by: Alexander Neundorf <neundorf@kde.org>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
12 years agoAdd GL_BGR to the list of defined GL constants, right next to GL_BGRA
Simon Hausmann [Tue, 21 Feb 2012 15:38:00 +0000 (16:38 +0100)]
Add GL_BGR to the list of defined GL constants, right next to GL_BGRA

We use this one in WebKit's OpenGL texture mapper and it would be
convenient to have it here if it's not defined by the platform.

Change-Id: Idae33e49773e21c6290b164bccd4f209cf9820a2
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
12 years agomake resolution of default spec less inefficient
Oswald Buddenhagen [Wed, 1 Feb 2012 21:25:04 +0000 (22:25 +0100)]
make resolution of default spec less inefficient

resolve only once, in particular on unix.

Change-Id: I090698fc6029322a3a16d179d461af3e8336f6ad
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
12 years agorevamp reading of bootstrap variables
Oswald Buddenhagen [Tue, 31 Jan 2012 11:49:53 +0000 (12:49 +0100)]
revamp reading of bootstrap variables

make the "evaluator" able to process simple variable expansions.
cache the processed spec, so it is not re-read for every variable.

Change-Id: I20e69ec7b65faa7d571e68dbfea6c21c79a62641
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
12 years agoregenerate unicode tables after rittk's patches
Oswald Buddenhagen [Tue, 21 Feb 2012 19:59:43 +0000 (20:59 +0100)]
regenerate unicode tables after rittk's patches

Change-Id: I60b416fc2dc2f0ccbcf13288a9ba2a42547269ec
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agooptimize QString::toLower()/toUpper() for special cases, step 2
Konstantin Ritt [Tue, 18 Oct 2011 17:12:21 +0000 (19:12 +0200)]
optimize QString::toLower()/toUpper() for special cases, step 2

from now, QUnicodeTables::specialCaseMap[] starts with a placeholder; so,
if somethingCaseSpecial is true, then somethingCaseDiff is always greater than 0

Change-Id: Ibb1870512836eee71b1521564c0745096c05b2f9
Merge-request: 70
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Olivier
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agooptimize QString::toLower()/toUpper() for special cases, step 1
Konstantin Ritt [Tue, 18 Oct 2011 17:12:20 +0000 (19:12 +0200)]
optimize QString::toLower()/toUpper() for special cases, step 1

reorganize QUnicodeTables::specialCaseMap as follows:
specialCaseMap contains sequence entries in form { length, a, b, .. }

Change-Id: Iea1f80bc2f4dc1f505428dad981cde26daaa52c7
Merge-request: 70
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Olivier
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agooptimize QString::toCaseFolded()
Konstantin Ritt [Tue, 18 Oct 2011 17:12:19 +0000 (19:12 +0200)]
optimize QString::toCaseFolded()

use the codepath similar to QString::toLower()

Change-Id: Ica1948c5e9c82199307d9f823e07d42b50d59480
Merge-request: 70
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Olivier
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agooptimize handling of surrogate pairs in toLower()/toUpper()
Konstantin Ritt [Tue, 18 Oct 2011 17:12:19 +0000 (19:12 +0200)]
optimize handling of surrogate pairs in toLower()/toUpper()

high surrogate part never changes on upper/lower casing
(which tested explicitly in the qunicodetables generator),
thus we can copy the high surrogate part in the loop

Change-Id: I24642b35eea7596c6ad494f2a7bc670f10b759a8
Merge-request: 70
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Olivier
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoreplace 'const QChar &' with 'QChar ' where appropriate
Konstantin Ritt [Tue, 18 Oct 2011 14:44:54 +0000 (16:44 +0200)]
replace 'const QChar &' with 'QChar ' where appropriate

as QChar is actually an ushort and there is no point in taking its
address.

Merge-request: 69
Change-Id: Idcc9d621e5627514ade006aa12a789a88929d48b
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoMove QSysInfo out of qglobal.h and into a separate header
Bradley T. Hughes [Mon, 20 Feb 2012 08:41:09 +0000 (09:41 +0100)]
Move QSysInfo out of qglobal.h and into a separate header

qsysinfo.h is still included by qglobal.h, but it may be possible
to remove the include from qglobal.h and instead include qsysinfo.h
only where needed (e.g. qendian.h, qdatastream.h).

Change-Id: Ifa2c72e0dae206d88eaa192e15a906297673c048
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoQEasingCurve: implement copy assignment operator inline
Marc Mutz [Sun, 19 Feb 2012 19:55:09 +0000 (20:55 +0100)]
QEasingCurve: implement copy assignment operator inline

Implement the copy-assignment operator inline, using the
copy-swap idiom. This makes assignment strongly exception
safe, but also simplifies maintainence, because op= is
formulated in terms of the copy constructor now.

Change-Id: I803c9100a520d659b685992237cb76fd114222c8
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoPrint out the try_compile output for tests expected to fail.
Stephen Kelly [Tue, 21 Feb 2012 11:40:38 +0000 (12:40 +0100)]
Print out the try_compile output for tests expected to fail.

This way, ctest -V shows that it fails for the expected reason.

Change-Id: I97589d4e90d889ea0b10dbd6192526712dbfdd8e
Reviewed-by: Alexander Neundorf <neundorf@kde.org>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
12 years agoremove bizarre late feeding of user_configs into base_vars
Oswald Buddenhagen [Thu, 2 Feb 2012 17:08:19 +0000 (18:08 +0100)]
remove bizarre late feeding of user_configs into base_vars

there is no obvious reason why this should happen. if base_vars is used
again, the user configs will be parsed again, too.

Change-Id: Ib56e01a468cdb5e81d610bcaf0163bf730cbae05
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>