profile/ivi/qtbase.git
12 years agoBlackberry: Fix hardware button detection on the BB Dev Alpha
Thomas McGuire [Thu, 27 Sep 2012 12:34:09 +0000 (14:34 +0200)]
Blackberry: Fix hardware button detection on the BB Dev Alpha

The format of the PPS object has changed, it is now prefixed with
[n], so be more leninent in parsing to support both formats.

Change-Id: I54eb1502a6231acf2dd121531539435c59d7d668
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
12 years ago[Doc cleanup] Fix typos and style of QPushButton and QGroupBox
David Gil [Tue, 25 Sep 2012 21:46:34 +0000 (23:46 +0200)]
[Doc cleanup] Fix typos and style of QPushButton and QGroupBox

Fix some typos. Fix some sentences to make them clearer to understand.
Since both of them are widgets, there's no Qt4-centric info.

Change-Id: I5c3c4a23621505d47b00cf466e4daad9763c3076
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
12 years agoWindowsPlugin: Fix MinGW warnings
Kai Koehne [Thu, 27 Sep 2012 08:43:44 +0000 (10:43 +0200)]
WindowsPlugin: Fix MinGW warnings

Fix warnings:

Change-Id: Ia68607f72087c0085e528fee0e6270b80692e389
warning: enumeration value 'SynthesizeMouseFromTouchEvents' not handled in switch
warning: suggest parentheses around assignment used as truth value
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
12 years agoItemViews: Fix MinGW compiler warning
Kai Koehne [Thu, 27 Sep 2012 08:23:02 +0000 (10:23 +0200)]
ItemViews: Fix MinGW compiler warning

Fix compiler 'warning: "_WIN32_IE" redefined'

Change-Id: I70ada35027a2bab0a6c4f84dd1384028d2afbcc9
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
12 years agoQtWidgets auto tests: revise clipboard related tests
J-P Nurmi [Wed, 19 Sep 2012 08:12:40 +0000 (10:12 +0200)]
QtWidgets auto tests: revise clipboard related tests

Use PlatformClipboard::isAvailable() and omit relevant test
cases when QT_NO_CLIPBOARD is defined.

Change-Id: I7e7b20a0a18f1a82987564f0e5e6c76d9207bc4b
Reviewed-by: Caroline Chao <caroline.chao@digia.com>
12 years agoRevise QClipboard auto tests
J-P Nurmi [Wed, 19 Sep 2012 08:12:15 +0000 (10:12 +0200)]
Revise QClipboard auto tests

Use PlatformClipboard::isAvailable() and fix build
when QT_NO_CLIPBOARD is defined.

Change-Id: I18c3af42fe39cf7618c2530723149848a10db985
Reviewed-by: Caroline Chao <caroline.chao@digia.com>
12 years agoCheck in arch detection for qmake failures
Andreas Holzammer [Thu, 20 Sep 2012 19:40:39 +0000 (21:40 +0200)]
Check in arch detection for qmake failures

QMake can fail at arch detection, so remove
the silence here and fail when qmake does
not produce any Makefile.

Change-Id: I8826867952665a68f7205acf99ee6f1c9ead8513
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
12 years agoFail when Windows CE SDK not found
Andreas Holzammer [Fri, 21 Sep 2012 13:12:14 +0000 (15:12 +0200)]
Fail when Windows CE SDK not found

Add failing when crosscompile for Windows CE
and no matching SDK is found.

Change-Id: I359e792fe46bab46729788666679a16cb94f340e
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
12 years agoReturn correct accessible name when a label has rich text
José Millán Soto [Sun, 23 Sep 2012 09:46:21 +0000 (11:46 +0200)]
Return correct accessible name when a label has rich text

When a QLabel was displaying rich text, the raw html was being returned as
accessible name. Now the plain text is returned.

Task-number: QTBUG-27302
Change-Id: I169d5eff527a0aef810af11d7712a362148974a5
Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
12 years agoFix XCode generator for qmake in Qt 5 after recent changes
Andy Shaw [Mon, 24 Sep 2012 10:04:21 +0000 (12:04 +0200)]
Fix XCode generator for qmake in Qt 5 after recent changes

Due to all the changes recently it broke in some places, this now
gets it working again.

Change-Id: I879ca5684435289a61d8db248f2c3f64f6866a60
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
12 years ago(WINCE)Add failure for font outline function
Andreas Holzammer [Thu, 20 Sep 2012 11:40:13 +0000 (13:40 +0200)]
(WINCE)Add failure for font outline function

There is no outline function in Windows CE,
so add a failure to inform the user that, he
needs to switch the font rendering.

Change-Id: Ieceb68bec49a88c7f7eee99f1c62cf1701da6aec
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
12 years agoConfigure.exe: Fix auto-detection of ICU for MinGW
Kai Koehne [Wed, 26 Sep 2012 09:05:45 +0000 (11:05 +0200)]
Configure.exe: Fix auto-detection of ICU for MinGW

If one compiles ICU with MinGW the .lib files also have a lib prefix.
Take this into account when checking for ICU availability.

Upstream bug report: http://bugs.icu-project.org/trac/ticket/9603

Change-Id: Ia1ca49053b0ab41de45eec13799d94d5e934c42e
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
12 years agoconfigure.exe: Don't print warning about -c++11 option by default
Kai Koehne [Wed, 26 Sep 2012 13:37:03 +0000 (15:37 +0200)]
configure.exe: Don't print warning about -c++11 option by default

Make sure that defaultTo() and therefore autoDetect() actually keep
the "auto" setting for MSVC. We check for this later on in
verifyConfiguration.

Change-Id: Iebf1ef415161a09bbc871baa31ff9dc56d54acac
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
12 years agoQtPrintSupport: cleanup CUPS tmp files
Teemu Katajisto [Tue, 25 Sep 2012 11:15:07 +0000 (14:15 +0300)]
QtPrintSupport: cleanup CUPS tmp files

Set fd so that it gets closed in QPdfPrintEnginePrivate::closePrintDevice()

Task-number: QTBUG-14724

Change-Id: Ic9c02c92b07ece92911d7bc3eac79689b4864253
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
12 years agoBring subproject dependencies in line with Makefile generators
Andy Shaw [Wed, 25 Apr 2012 14:55:28 +0000 (16:55 +0200)]
Bring subproject dependencies in line with Makefile generators

When generating the solution file it should extract the
dependencies from the pro file as this will bring it in
line with the Makefile generators.

Task-number: QTBUG-22561
Change-Id: I8d5b6607712f2c77c87ef093480e64b9633817d8
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
12 years agoxcb: consistently check xcb_get_extension_data for extension inits
Shawn Rutledge [Mon, 24 Sep 2012 13:23:12 +0000 (15:23 +0200)]
xcb: consistently check xcb_get_extension_data for extension inits

This seems to fix the ability to run a Qt app across a forwarded X
connection (e.g.  ssh -X).

Change-Id: I2b7a26985cf11107e69b303337a5fbb369e38c9e
Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
Reviewed-by: Uli Schlachter <psychon@znc.in>
12 years agoImplement the missing raster operations that were in Qt 3
Andy Shaw [Thu, 13 Sep 2012 15:56:20 +0000 (17:56 +0200)]
Implement the missing raster operations that were in Qt 3

Although not widely used, the raster operations from Qt 3 were useful
and some of them were already implemented, this brings the rest of them
back for those who need them.

Change-Id: Id538611eaaba9be3d39bf2dd33b6c532f5d4aba8
Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
12 years agoAuto tests: add PlatformClipboard::isAvailable()
J-P Nurmi [Wed, 19 Sep 2012 08:11:54 +0000 (10:11 +0200)]
Auto tests: add PlatformClipboard::isAvailable()

Change-Id: Ie04060c2cae61ff8268644e9cd8001a1f5745f31
Reviewed-by: Caroline Chao <caroline.chao@digia.com>
12 years agotst_QDialog: fix Q_OS_WINCE & QT_NO_SIZEGRIP usage
J-P Nurmi [Wed, 26 Sep 2012 14:24:39 +0000 (16:24 +0200)]
tst_QDialog: fix Q_OS_WINCE & QT_NO_SIZEGRIP usage

Change-Id: I443381ef4f10492eeda0fc681c390e0cd4d4125e
Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
12 years agotst_qsidebar: remove duplicate code
J-P Nurmi [Wed, 26 Sep 2012 15:18:58 +0000 (17:18 +0200)]
tst_qsidebar: remove duplicate code

Change-Id: I8ee59022199fda7ea56891a2f924954cb4aefa42
Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
12 years agoDoc: update QMap's description following 5cb036851
Pierre Rossi [Tue, 25 Sep 2012 18:32:06 +0000 (20:32 +0200)]
Doc: update QMap's description following 5cb036851

Change-Id: I9dccb9f64578cf8c9da50524c5d4d1201ab488bd
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
12 years agoQMetaType build fix with Q_NO_CURSOR and friends.
Jędrzej Nowacki [Fri, 21 Sep 2012 11:45:07 +0000 (13:45 +0200)]
QMetaType build fix with Q_NO_CURSOR and friends.

QMetaType has a way to "switch off" some types from the build.
QtMetaTypePrivate::TypeDefinition<T>::IsAvailable is defined as false
for all unaccessible types. Sadly that information was never used by
gui and widget handlers. The patch implements it.

Change-Id: Ie5835be4c88cfbbca8a4e9199e31ddfc20cae190
Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
Reviewed-by: Jing Bai <jing.bai@digia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agodocumentation fixes
Marcel Krems [Fri, 27 Apr 2012 01:08:21 +0000 (03:08 +0200)]
documentation fixes

Change-Id: If165933df41e518f5ba6065792676260fd2492b6
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
12 years agotst_QMessageBox: fix Q_OS_MAC usage
J-P Nurmi [Wed, 26 Sep 2012 14:34:29 +0000 (16:34 +0200)]
tst_QMessageBox: fix Q_OS_MAC usage

Change-Id: I1a3c1c88956d85343e693588ca0522c4b7d62072
Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
12 years agoHTML template: Updated copyright information from Nokia to Digia Plc
Jerome Pasion [Mon, 24 Sep 2012 15:16:47 +0000 (17:16 +0200)]
HTML template: Updated copyright information from Nokia to Digia Plc

Change-Id: Ib4315aa0a7a92e3b36da855c2787b60cc3c332fe
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Reviewed-by: Sami Makkonen <sami.makkonen@digia.com>
Reviewed-by: Iikka Eklund <iikka.eklund@digia.com>
12 years agoFix typo in variable name.
Stephen Kelly [Tue, 25 Sep 2012 15:34:27 +0000 (17:34 +0200)]
Fix typo in variable name.

Change-Id: I3bd59982605d242c95278bfeb71a6071ec222d08
Reviewed-by: David Faure <faure@kde.org>
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
12 years agoFix spelling mistake
Thiago Macieira [Wed, 26 Sep 2012 18:47:07 +0000 (20:47 +0200)]
Fix spelling mistake

Task-number: QTBUG-27355

Change-Id: I77ecc01e2a3ea1cac94e7c99c688cfd7cab5319b
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
12 years agoRename a variable it -> childIt.
Stephen Kelly [Wed, 26 Sep 2012 08:55:05 +0000 (10:55 +0200)]
Rename a variable it -> childIt.

There is another iterator called it at the top of this function.

Change-Id: I8addf47d66f098c5d811eb54674525eddb4d4a1f
Reviewed-by: David Faure <faure@kde.org>
12 years agoqtypetraits.h: add is_signed/is_unsigned/not_/not_c predicates
Marc Mutz [Thu, 20 Sep 2012 13:01:09 +0000 (15:01 +0200)]
qtypetraits.h: add is_signed/is_unsigned/not_/not_c predicates

is_signed/is_unsigned check whether the type argument is signed
or unsigned, resp., and will be used in QFlags to select the
correct underlying integer type.

not_ is used in the implementation of is_signed

not_c is for completeness (version of not_ that takes a bool
instead of an integral_constant).

Change-Id: I77cc445e8c6cf3181336505c9c13478fba3e7890
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoQFlags: fail for 64-bit enums
Marc Mutz [Wed, 26 Sep 2012 14:16:14 +0000 (16:16 +0200)]
QFlags: fail for 64-bit enums

An int is not enough to hold all values of a 64-bit enum, so
don't allow to compile QFlags for such enums.

Change-Id: Ia291c4a5e2160dfd6d5a35e61a7f71ab571b9d9a
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoFix QScreen::orientation() not always being updated after changing the update orienta...
Simon Hausmann [Wed, 26 Sep 2012 13:14:48 +0000 (15:14 +0200)]
Fix QScreen::orientation() not always being updated after changing the update orientation mask

The back-end might report screen orientation changes at any point and we
record it in screen.d->orientation. However QScreen::orientation()
returns the orientation filtered according to the mask.

Changing the mask sends a notification to the back-end, which might send
another update as a result of a possible subscription to system services
(accelerometer). However on platforms where no subscription is required, where
the platform plugin ignores the mask and always sends the latest orientation,
we should "simulate" the update by updating the filtered orientation according
to the new mask. The function is cheap to call as it won't emit any signals
unless the orientation actually changes.

This patch also adds missing flush() calls after handleScreenOrientationChange
calls in the tests to ensure that the (synthetic) window system events are
actually delivered to QScreen/QGuiApplication.

Change-Id: Iebdd050f947e658ff5bc388629aa4cb31ab497fe
Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
Reviewed-by: Laszlo Papp <lpapp@kde.org>
12 years agoFix initial window orientation with Qt on MeeGo 1.2 Harmattan
Simon Hausmann [Wed, 26 Sep 2012 10:42:38 +0000 (12:42 +0200)]
Fix initial window orientation with Qt on MeeGo 1.2 Harmattan

The window orientation changes are handled through a generic QPA plugin and
sends an initial window orientation change event on startup for the initial
orientation and subsequent updates when the device orientation changes.

Unfortunately the plugin was never loaded after the introduction of the new
plugin loading mechanism, because the factory key ("MeeGoIntegration") was
not provided to the plugin registry.

Change-Id: Ib7324561993abfbac1dccb0839aab0a8e870d231
Reviewed-by: Jocelyn Turcotte <jocelyn.turcotte@digia.com>
Reviewed-by: Laszlo Papp <lpapp@kde.org>
12 years agoFix events being processed on application start
Simon Hausmann [Wed, 26 Sep 2012 12:15:39 +0000 (14:15 +0200)]
Fix events being processed on application start

Commit ef2efafcc6b28791df6258fa1c5d565090a9577a introduced a call to
QWindowSystemInterface::sendWindowSystemEvents() in
QGuiApplicationPrivate::init(), which in its implementation ends up calling
sendPostedEvents() before flushing and processing any pending (internal) window
system events.

This patch changes the call in init() to use
QWindowSystemInterface::flushWindowSystemEvents() instead, which is more gentle
in that regard.

The provided unit test verifies that no posted events are processed during the
execution of the QGuiApplication constructor while at the same time verifying
what the original changed tried to do: Allow a generic plugin to provide window
system specific defaults that are implemented using the event queue of
QWindowSystemInterface.

Task-number: QTBUG-26886

Change-Id: I129a907c00d947df60fe1a02efc67857580fce24
Reviewed-by: David Faure <faure@kde.org>
12 years agoXCB: Correctly report the created OpenGL context version and profile
Sean Harmer [Tue, 18 Sep 2012 16:05:01 +0000 (17:05 +0100)]
XCB: Correctly report the created OpenGL context version and profile

This commit fixes the xcb qpa plugin such that it now correctly reports
the version and profile of the created OpenGL context in the
QOpenGLSurfaceFormat. To do this we have to create a temporary X window
so that we can make our new context current.

We also handle the buggy nVidia drivers which incorrectly report 0 for
the GL_CONTEXT_PROFILE_MASK query.

The reduced format is also copied back from qglx_findVisualInfo.

Change-Id: I6f34fe1c6130aebbb6b40c36df4acc216069d2b1
Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
12 years agoOpenGL: Fix QGLFormat::openGLVersionFlags() on OS X
Sean Harmer [Thu, 20 Sep 2012 14:55:46 +0000 (15:55 +0100)]
OpenGL: Fix QGLFormat::openGLVersionFlags() on OS X

OS X is limited to OpenGL 3.2 and we have to explicitly request a Core
profile context to get the full set of available versions as OS X does
not implement the Compatibility profile.

Change-Id: I8c2a6dc272416cbaf8fee44adbc4471417bf4510
Reviewed-by: Björn Breitmeyer <bjoern.breitmeyer@kdab.com>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
12 years agoqmake: fix overescaped defines in vcxproj files
Joerg Bornemann [Wed, 26 Sep 2012 07:20:50 +0000 (09:20 +0200)]
qmake: fix overescaped defines in vcxproj files

Task-number: QTBUG-27345

Change-Id: I00848d611163afb549191f41adff628622a899e0
Reviewed-by: Andy Shaw <andy.shaw@digia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
12 years agoDon't call parent() so often when processing a range.
Stephen Kelly [Wed, 26 Sep 2012 14:57:38 +0000 (16:57 +0200)]
Don't call parent() so often when processing a range.

Task-number: QTBUG-17732
Change-Id: Iefe5801f5941136f77001c532870e22f7fdd2c69
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
12 years agoQScrollBar: clean up wheelEvent() implementation
Marc Mutz [Tue, 25 Sep 2012 08:56:40 +0000 (10:56 +0200)]
QScrollBar: clean up wheelEvent() implementation

This code was moved from the general event() handler.
Remove comments and casting that were necessary there.

Task-number: QTBUG-27308
Reported-by: chenjiexin
Task-number: QTBUG-21534
Reported-by: Martin Koller
Change-Id: I14ef4c6363002032895f6840a7c68c1f5f665384
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
12 years ago[QTBUG-27308][QTBUG-21534] Don't mouse-wheel-scroll QScrollBar when disabled
Marc Mutz [Tue, 25 Sep 2012 08:54:11 +0000 (10:54 +0200)]
[QTBUG-27308][QTBUG-21534] Don't mouse-wheel-scroll QScrollBar when disabled

This fixes a regression introduced in Qt 4 commit
e855b199319c932f2e9500235775f961bc32e41a.

The problem was that by handling the wheel event in event()
instead of wheelEvent(), we lack the guard clause in QWidget
that doesn't even call the handler if the widget is disabled,
and the code didn't handle this itself.

Fix by reimplementing wheelEvent() instead, which we can now
do because we can break BC.

This commit just moves the code. Another commit will clean
up the implementation of wheelEvent().

Task-number: QTBUG-27308
Reported-by: chenjiexin
Task-number: QTBUG-21534
Reported-by: Martin Koller
Change-Id: Ibe6b89a81fe889f839c205b859a1492b39a4ddc3
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
12 years agoFix compilation for Qt5: Avoid deprecated API
aavit [Wed, 26 Sep 2012 10:42:39 +0000 (12:42 +0200)]
Fix compilation for Qt5: Avoid deprecated API

Change-Id: Iba11d33dd4d81ed1a460dd3237cd1bb9e1ace106
Reviewed-by: Jason Barron <jason.barron@digia.com>
12 years agoCompile fix: Avoid deprecated functions
aavit [Wed, 26 Sep 2012 08:42:44 +0000 (10:42 +0200)]
Compile fix: Avoid deprecated functions

Change-Id: Ia7592997640d51ed98fdfa1a5e59d35954a0ef61
Reviewed-by: Jason Barron <jason.barron@digia.com>
12 years agoqdoc: retrying More refactoring of qdoc data structures
Martin Smith [Mon, 24 Sep 2012 07:54:42 +0000 (09:54 +0200)]
qdoc: retrying More refactoring of qdoc data structures

This commit is the second phase of a significant
overhaul of qdoc. Two new classes, QDocIndexFiles,
and QDocTagFiles, are added to encapsulate the
creation and use of the qdoc index files, and the
creation of the qdoc tag file.

Change-Id: I94651b10628e535ea7b26bd8256037cd819ccea7
Reviewed-by: Martin Smith <martin.smith@digia.com>
12 years agoReintroduce mention of QWidget in coordinate system docs.
Samuel Rødal [Wed, 19 Sep 2012 09:39:18 +0000 (11:39 +0200)]
Reintroduce mention of QWidget in coordinate system docs.

Change-Id: Ied67ec82ee66eea7d3255105cf0f635f1d7dd9e8
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
12 years agoQtPrintSupport: allow slight deviations from pre-defined paper sizes in tests
Teemu Katajisto [Tue, 21 Aug 2012 07:53:31 +0000 (10:53 +0300)]
QtPrintSupport: allow slight deviations from pre-defined paper sizes in tests

CUPS paper sizes may differ from Qt paper sizes slightly and thus fail
the strict comparison in qprinter tests. This is needed for the
followup patch which initializes the cupsplugin with CUPS/PPD defaults.

Change-Id: Ie66f77ead0204de0fc7c7913005fa516d57d34eb
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
12 years agoQtPrintSupport: use PPD defaults in CUPS plugin
Teemu Katajisto [Wed, 22 Aug 2012 09:05:53 +0000 (12:05 +0300)]
QtPrintSupport: use PPD defaults in CUPS plugin

Initialize CUPS plugin with default values from the PPD file. Implement
paper size handling when using CUPS paper sizes to make paper sizes to
map properly when used through QPrinter interface.

Change-Id: I84d20aa4b1c7250fca754aecde419467f57ef16b
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
12 years agoqtest.h: add missing QT_NO_DATESTRING guards
J-P Nurmi [Mon, 24 Sep 2012 13:04:21 +0000 (15:04 +0200)]
qtest.h: add missing QT_NO_DATESTRING guards

Change-Id: I04d8ec2e9d41399cffc610f943fc06e043831ceb
Reviewed-by: Caroline Chao <caroline.chao@digia.com>
12 years agoAuto tests: remove PlatformQuirks::isAutoMaximizing()
J-P Nurmi [Wed, 19 Sep 2012 12:57:15 +0000 (14:57 +0200)]
Auto tests: remove PlatformQuirks::isAutoMaximizing()

Use QStyleHints::showIsFullScreen() where necessary.
Notice that QWidget::show() already calls showFullScreen()
if appropriate, and Qt::X11BypassWindowManagerHint doesn't
do anything in the XCB platform plugin.

Change-Id: Ib8f61188c075170d646894388561cbb3f72daee8
Reviewed-by: Caroline Chao <caroline.chao@digia.com>
12 years agoMake QSignalTransition take a pointer-to-const QObject
Giuseppe D'Angelo [Thu, 13 Sep 2012 18:23:10 +0000 (19:23 +0100)]
Make QSignalTransition take a pointer-to-const QObject

The obvious idea is that a connect() happens behind the scenes.
As QObject::connect takes a pointer-to-const, QSignalTransition should
do that as well.

TODO: the API becomes asymmetric in that it takes
a "const QObject *" but returns a "QObject *". Reasoning is needed.

Change-Id: I18d0436e7036eee851fd36d5b8ccda4a4757938f
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
12 years agoFix MinGW/gcc warning about NOMINMAX being redefined
Kai Koehne [Mon, 17 Sep 2012 10:32:09 +0000 (12:32 +0200)]
Fix MinGW/gcc warning about NOMINMAX being redefined

Commit 5230d62fe added a #define NOMINMAX, which conflicts with a
NOMINMAX definition in the MinGW headers. Just use the same definition
as in MinGW to fix the gcc warning.

Change-Id: Ib21dd323ebbdca5d143e394c7631303e0c72541a
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoconfigure: Document the -widgets, -no-widgets arguments
Kai Koehne [Thu, 20 Sep 2012 09:08:48 +0000 (11:08 +0200)]
configure: Document the -widgets, -no-widgets arguments

Also add -gui, since we're always documenting the default ones, too.

Change-Id: I590af798d825f2933c6249663d4cad45fc23cb52
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
12 years agoCore: Silence gcc warnings about unitinialized members in qarraydata.cpp
Kai Koehne [Thu, 20 Sep 2012 08:41:09 +0000 (10:41 +0200)]
Core: Silence gcc warnings about unitinialized members in qarraydata.cpp

It's perfectly correct to leave members uninitialised, since they are zero initialized.

Change-Id: I0d0c737cf35793a2633d44ce194af7f489903c03
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@digia.com>
12 years agoqmake: Fix gcc warning about anonymous type linkage
Kai Koehne [Thu, 20 Sep 2012 08:18:37 +0000 (10:18 +0200)]
qmake: Fix gcc warning about anonymous type linkage

Fix "warning: anonymous type with no linkage used to declare variable
'<anonymous struct> dotNetCombo []' with linkage".

Change-Id: Iaff0d460df53fd6d0732d39bf633688805f5c653
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
12 years agoFix restore/minimize/close buttons for maximized MDI subwidows
Miikka Heikkinen [Mon, 17 Sep 2012 09:33:44 +0000 (12:33 +0300)]
Fix restore/minimize/close buttons for maximized MDI subwidows

The style code to display the restore/minimize/close buttons in menubar
for maximized MDI subwidows was removed in Qt5 as it was incorrectly
ifdeffed with just QT_NO_WORKSPACE where QT_NO_MDIAREA should
also have been used. Brought back the removed code with proper
ifdeffing.

Task-number: QTBUG-27235
Change-Id: I89607dd54eec00329e576c72b0e8b997f37cdb29
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
12 years agoTest: tst_QFile::writeLargeDataBlock() unstable failure as XFAIL
Caroline Chao [Wed, 26 Sep 2012 06:02:49 +0000 (08:02 +0200)]
Test: tst_QFile::writeLargeDataBlock() unstable failure as XFAIL

While the large data block can be written to a file, the test is
also showing instability while reading back the written block.

Adding another expected failure to address this instability.

Task-number: QTBUG-26906

Change-Id: I9704d441cf2bd6d7ef0f9023240ea61bb89561b6
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoCMake: Fix the generated location of static libraries.
Stephen Kelly [Tue, 25 Sep 2012 07:44:25 +0000 (09:44 +0200)]
CMake: Fix the generated location of static libraries.

We need to make sure to put the .lib file into the LOCATION property,
not the .dll file, when building a static library.

Change-Id: I8912abfd172d0939cd07ba02901ab58093ccefa1
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
12 years agoCMake: Specify the prl files when building with mingw.
Stephen Kelly [Tue, 25 Sep 2012 08:35:59 +0000 (10:35 +0200)]
CMake: Specify the prl files when building with mingw.

As was done in ae6d4c77eb338be3f2189bfaffdcd3c38cc57333, but that commit
missed the mingw branch.

Change-Id: I1d76ed2f8070dced2749aabe889fee48c4086744
Reviewed-by: Peter Kümmel <syntheticpp@gmx.net>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
12 years agoRemove Windows CE time conversion compatibility functions
Simon Hausmann [Wed, 8 Aug 2012 08:06:40 +0000 (10:06 +0200)]
Remove Windows CE time conversion compatibility functions

These files were used by WebKit for Windows CE, but they are not needed
anymore since https://bugs.webkit.org/show_bug.cgi?id=93446

Change-Id: Ic6808bf177ff18c668a5a281687a5b7842786ef0
Reviewed-by: Andreas Holzammer <andreas.holzammer@kdab.com>
Reviewed-by: Kevin Funk <kevin.funk@kdab.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
12 years agoIf accept fails, stop accepting new connections and emit error signal.
Jonas M. Gastal [Tue, 12 Jun 2012 01:27:03 +0000 (22:27 -0300)]
If accept fails, stop accepting new connections and emit error signal.

Task-number: QTBUG-24778
Change-Id: I6c5b685b3f861a0fafc1475c41bb35cede17d712
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoMisc. updates to the lancelot autotest framework
aavit [Mon, 13 Aug 2012 12:13:40 +0000 (14:13 +0200)]
Misc. updates to the lancelot autotest framework

Moving more logic into the protocol and framework, easening
the burden on the autotest implementation.
Implementing several new features in the server and
report, like fuzzy matching and static baselines.

Change-Id: Iaf070918195ae05767808a548f019d09d9d5f8c0
Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
12 years agoFix qstringlist autotest build for WinCE.
Janne Anttila [Tue, 19 Jun 2012 08:19:28 +0000 (11:19 +0300)]
Fix qstringlist autotest build for WinCE.

WinCE does not have setlocale, used SetUserDefaultLCID correspondingly
as it is done in qstring autotest for WEC7.

Change-Id: I7866bf0f365c7c6efbf3b439cdd9a281c6a1b2e0
Reviewed-by: Kevin Funk <kevin.funk@kdab.com>
Reviewed-by: Andreas Holzammer <andreas.holzammer@kdab.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
12 years ago[docs] QApplication: fix keyboardInputDirection() docs
Marc Mutz [Mon, 24 Sep 2012 11:05:23 +0000 (13:05 +0200)]
[docs] QApplication: fix keyboardInputDirection() docs

There were two documentation blocks: the first had the wrong class name,
the second was duplicate.

Change-Id: I241b3e6567376a46a6270837cce4aa380a6c8c49
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
12 years ago[docs] QInputDialog: document deprecated member getInteger()
Marc Mutz [Mon, 24 Sep 2012 11:02:53 +0000 (13:02 +0200)]
[docs] QInputDialog: document deprecated member getInteger()

Change-Id: I2ac24acbecd67db74f9474a7a2a1ee94b03282d4
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
12 years agotest:Remove QSKIP from tst_QPainter
Sergey Hambardzumyan [Mon, 24 Sep 2012 11:53:01 +0000 (13:53 +0200)]
test:Remove QSKIP from tst_QPainter

Removed QSKIP ("currently broken... ") from tst_qpainter.cpp.

Change-Id: I2a5af009198d26015779ca368ef82188ddf1b060
Reviewed-by: Caroline Chao <caroline.chao@digia.com>
Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
12 years agoxcb: better error handling if no randr or screen resources query fails
Shawn Rutledge [Fri, 21 Sep 2012 11:47:16 +0000 (13:47 +0200)]
xcb: better error handling if no randr or screen resources query fails

Marc Mutz already reported problems with ssh -X fowarding.  Now all
such errors are treated the same: if we can't get screen output
attributes, just assume there is only one.

Change-Id: I96802fc90072c623de3370ed2898893daf58198a
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Samuel Rødal <samuel.rodal@digia.com>
12 years ago[docs] QFlags: fix a whitespace error
Marc Mutz [Tue, 25 Sep 2012 11:30:49 +0000 (13:30 +0200)]
[docs] QFlags: fix a whitespace error

Change-Id: I316ceb3d630d6697466a46fa14bdbd8379079875
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoQFileSystemModel: fix permission mangling
Marc Mutz [Wed, 8 Aug 2012 10:42:06 +0000 (12:42 +0200)]
QFileSystemModel: fix permission mangling

The old code masked out write flags before returning permissions
from permissions() or data(FilePermissions) in order to force
QFileDialog to disable the rename and delete actions. This was to
fix Task 143519, but introduced QTBUG-20503.

Instead, revert to the pre-143519-bugfix code and do the necessary
check in QFileDialog directly.

Also add a testcase for 143519.

Reported-by: Gilles Pascual
Task-number: QTBUG-20503
Task-number: 143519

Change-Id: I140109341c0ed40722e3aac4327c2a740fb014c2
Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
12 years agoRemove duplicate words and punctuation from documentation.
Mitch Curtis [Mon, 24 Sep 2012 16:12:43 +0000 (18:12 +0200)]
Remove duplicate words and punctuation from documentation.

Change-Id: I5550c62d412510bc2c5acceb2cae7d2f2ef6a8d3
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
12 years agoQCharAttributes: add wordStart/wordEnd flags
Konstantin Ritt [Tue, 25 Sep 2012 20:55:54 +0000 (23:55 +0300)]
QCharAttributes: add wordStart/wordEnd flags

A simple heuristic is used to detect the word beginning and ending by
looking at the word break property value of surrounding characters.
This behaves better than the white-spaces based implementation used before
and makes it possible to tailor the default algorithm for complex scripts.

BIG FAT WARNING: The QCharAttributes buffer now has to have a length
                 of string length + 1 for the flags at end of text.

Task-Id: QTBUG-6498

Change-Id: I5589b191ffde6a50d2af0c14a00430d3852c67b4
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
12 years agotest: Mark tst_QMdiSubWindow failures as XFAIL
Sergio Ahumada [Wed, 19 Sep 2012 13:45:13 +0000 (15:45 +0200)]
test: Mark tst_QMdiSubWindow failures as XFAIL

The test has lots of failures, so mark these with QEXPECT_FAIL and
remove the QSKIP.

Task-number: QTBUG-22310
Task-number: QTBUG-27274
Change-Id: I0d38cedb581741b6edae5d1c3f4410714099a7fb
Reviewed-by: Caroline Chao <caroline.chao@digia.com>
12 years agofix incorrect uses of qmake in documentation
Joerg Bornemann [Tue, 25 Sep 2012 13:29:11 +0000 (15:29 +0200)]
fix incorrect uses of qmake in documentation

Assigning backslashes to qmake variables yields a warning
these days. Use forward slashes as they get automatically converted.

Task-number: QTBUG-27325
Change-Id: I804fa641064ce183e9794026ad1dbc91725d334d
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
12 years agoTest: Remove QSKIP from tst_QWidget::raise
Caroline Chao [Mon, 24 Sep 2012 07:57:15 +0000 (09:57 +0200)]
Test: Remove QSKIP from tst_QWidget::raise

Remove QSKIP("Not yet sure why this fails."), the test is passing
on Mac.

Task-number: QTBUG-22321

Change-Id: I5f09d067b1cc837c5e3ada5bbd34091fe1fd723d
Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
12 years agoTest: tst_QFile::writeLargeDataBlock() unstable failure as XFAIL
Caroline Chao [Tue, 25 Sep 2012 10:26:49 +0000 (12:26 +0200)]
Test: tst_QFile::writeLargeDataBlock() unstable failure as XFAIL

The current check is not enough to catch the unstable failure.
Update the test to catch the failure in all cases.

Task-number: QTBUG-26906

Change-Id: I2e37a1f6513df768cd410df7c91a9fd843150e57
Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
12 years agoTest: Remove QSKIP from tst_QLineEdit::taskQTBUG_7395_readOnlyShortcut
Caroline Chao [Fri, 21 Sep 2012 10:28:15 +0000 (12:28 +0200)]
Test: Remove QSKIP from tst_QLineEdit::taskQTBUG_7395_readOnlyShortcut

The test is passing on Ubuntu 11.10.

Adding qWaitForWindowExposed after the line edit show() call to ensure
the line edit is actually shown on the screen.

Task-number: QTBUG-24518
Change-Id: I2af65bef76d171b36032120738dfbd7cfff51d7f
Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
12 years agoqmake: support for Visual Studio 2012 project files added
Joerg Bornemann [Fri, 21 Sep 2012 14:28:11 +0000 (16:28 +0200)]
qmake: support for Visual Studio 2012 project files added

The differences to VS 2010 project files are the
version number (surprise!) and the PlatformToolSet tag which
sets the version of the toolchain.

Change-Id: If26f08fad1a69d7e6cd28cc5e860ff964f19b264
Reviewed-by: Andy Shaw <andy.shaw@digia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
12 years agoQFileInfoGatherer: general cleanups
Marc Mutz [Tue, 7 Aug 2012 17:45:16 +0000 (19:45 +0200)]
QFileInfoGatherer: general cleanups

- fix typo in comment
- make translateDriveName file-static
- use QList::reserve()
- explicit ctor
- annotate functions called by owning thread/run()
- iconProvider() and resolveSymlinks() shouldn't be slots
- private instead of protected
- run() marked Q_DECL_OVERRIDE
- annotate which members are protected by 'mutex'

Change-Id: Ic176a030b0597c98f48185efd17260fd62532460
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
12 years agoFix default-constructed QFileSystemEntry
João Abecasis [Mon, 20 Aug 2012 11:09:55 +0000 (13:09 +0200)]
Fix default-constructed QFileSystemEntry

Member variables for lastSeparator, first and lastDotInFileName are now
initialized to -1 (non-existing), where the previous value of zero would
mean a separator/dot at that position and resulted in path() returning
'/', instead of '.'.

Tests were expanded for better coverage of empty state and
default-constructed instances.

Change-Id: Ie27547886b52224d38b5be0b4f920c9927fd440f
Reviewed-by: Andy Shaw <andy.shaw@digia.com>
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
12 years agoIgnore the QT_NAMESPACE for moc runs
Lars Knoll [Fri, 21 Sep 2012 09:37:31 +0000 (11:37 +0200)]
Ignore the QT_NAMESPACE for moc runs

Moc should not see a defined QT_NAMESPACE, to
keep the names of all symbols consistent with
an un-namespaced Qt.

Change-Id: Ia72afabaa0820b02a0863148510122ce942a5082
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoTest case for moc handling defines
Lars Knoll [Mon, 10 Sep 2012 19:15:25 +0000 (21:15 +0200)]
Test case for moc handling defines

Added some test cases that check that moc
correctly expands #defines

Change-Id: I7fe6eed129d46ca9281d73064571cae43b32410d
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoMoc: Correctly expand macros with arguments
Lars Knoll [Mon, 10 Sep 2012 13:56:33 +0000 (15:56 +0200)]
Moc: Correctly expand macros with arguments

Moc now supports full expansion of macros with arguments
with the exception of some keywords such as Q_OBJECT
and others that are used internally

Change-Id: I283d47152f75de81ec68a3df1f0f2273f11c5149
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoMoc: Make # and ## valid tokens in cpp parsing mode
Lars Knoll [Mon, 10 Sep 2012 11:57:23 +0000 (13:57 +0200)]
Moc: Make # and ## valid tokens in cpp parsing mode

This is required so preprocessing macros with arguments
can work correctly.

Change-Id: Ia30ede6a3579be13800bf1255d313748e2d696f9
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoCorrectly parse function macros
Lars Knoll [Sat, 8 Sep 2012 19:44:12 +0000 (21:44 +0200)]
Correctly parse function macros

Parse function macros and add it's list of arguments
to the Macro definition.

Change-Id: Id22f5cf4a1c098f7b4f5b72f002900cd40d03e0f
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoCorrectly expand macros without arguments in moc
Lars Knoll [Fri, 7 Sep 2012 13:13:03 +0000 (15:13 +0200)]
Correctly expand macros without arguments in moc

This helps e.g. cases where a namespace is defined
through a macro and moc doesn't see it at all.

Expanding macros with arguments is significantly more
work, and should happen in a separate commit.

Change-Id: Ic8d0443d06fab2ed343115d8c43022f2c67ec3cd
Reviewed-by: Qt Doc Bot <qt_docbot@qt-project.org>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoqdbusmetatype_p.h: add missing QT_NO_DBUS guards
J-P Nurmi [Mon, 24 Sep 2012 13:20:20 +0000 (15:20 +0200)]
qdbusmetatype_p.h: add missing QT_NO_DBUS guards

Change-Id: Idb459fe6300f710b959247cd9c1997a4d5774b2d
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoQSqlTableMode::selectRow(): lack of WHERE clause is an error
Mark Brand [Mon, 17 Sep 2012 13:49:31 +0000 (15:49 +0200)]
QSqlTableMode::selectRow(): lack of WHERE clause is an error

Since we only want one row, never ever run a SELECT without a WHERE
clause.

Change-Id: I40a78935f5573111faa3922eae97e6d5961be5f2
Reviewed-by: Andy Shaw <andy.shaw@digia.com>
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
12 years agoQSqlTableModel::selectRow(): reduce scope of QSqlQuery
Mark Brand [Mon, 17 Sep 2012 12:23:17 +0000 (14:23 +0200)]
QSqlTableModel::selectRow(): reduce scope of QSqlQuery

It's good to clean up the query before emitting signals about the
updated row. It's possible that connected slots will call selectRow()
again for other rows.

Change-Id: I482fe2dd58218f53567ce8725ee591ce2eeda348
Reviewed-by: Andy Shaw <andy.shaw@digia.com>
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
12 years agoQSqlTableModel::selectRow(): fix failure on uncached rows
Mark Brand [Mon, 17 Sep 2012 12:22:29 +0000 (14:22 +0200)]
QSqlTableModel::selectRow(): fix failure on uncached rows

This method was originally intended for refreshing rows after
submitting changes. It should also work for refreshing rows
that are unchanged (i.e., not cached), but did not because
constructing the primary values depended on the cache. As a
consequence, the WHERE clause for the query was not created.

Fixed by deriving primary values for uncached rows from the
query record. Note that the cache is still authoritative for rows
it holds. This is important because the prmary values there may
differ from the original query record due to changes to columns
of the primary key.

Includes new test.

Change-Id: I41cca2cbf26019d4b495ffa6d876e2b55ec57803
Reviewed-by: Andy Shaw <andy.shaw@digia.com>
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
12 years agoFixed crash in moc on big endian platforms.
Konstantin Tokarev [Sun, 16 Sep 2012 18:47:55 +0000 (22:47 +0400)]
Fixed crash in moc on big endian platforms.

Change-Id: Icaa38eb4b404e5f52248fdeaf9180a5d70d0f5f2
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
12 years agoFixed QJsonDocument::fromBinaryData on big endian platforms.
Konstantin Tokarev [Sun, 23 Sep 2012 21:34:01 +0000 (01:34 +0400)]
Fixed QJsonDocument::fromBinaryData on big endian platforms.

Change-Id: I1786b6222867c8780f6768e5220e7ddff952b28e
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
12 years agoFixed ifdef condition in QJson resulting in big endian breakage.
Konstantin Tokarev [Sun, 23 Sep 2012 14:02:55 +0000 (18:02 +0400)]
Fixed ifdef condition in QJson resulting in big endian breakage.

Change-Id: I3d36d75ff95ad2fe2fcbbe262f9782f0709d7041
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
12 years agoAdd a manual test for QMacCocoaViewContainer
Andy Shaw [Sun, 10 Jun 2012 20:59:24 +0000 (22:59 +0200)]
Add a manual test for QMacCocoaViewContainer

Added a test for QMacCocoaViewContainer which will enable the testing
of the fixes coming

Change-Id: I73e9540bc58411634f0da7d398eca4b7ffafba8e
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
12 years agoTest: Enabled tst_QFile::invalidFile
Caroline Chao [Mon, 24 Sep 2012 06:56:56 +0000 (08:56 +0200)]
Test: Enabled tst_QFile::invalidFile

The test is not hanging on Windows anymore.

On Windows, add an expected failure for the failing case.

Task-number: QTBUG-22801
Task-number: QTBUG-27306

Change-Id: Iede95766504f3e8a278a4554a5967ca333aae3bf
Reviewed-by: Sergio Ahumada <sergio.ahumada@digia.com>
12 years agoFixed instances of "to to" in qtbase.
Samuel Rødal [Mon, 24 Sep 2012 14:23:03 +0000 (16:23 +0200)]
Fixed instances of "to to" in qtbase.

Really it should just be "to".

Change-Id: I7d0fff334bac3f0ac78adb8131e3bf3df1f1b242
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
12 years agoAdd some tests for compatible and incompatible custom deleters
Thiago Macieira [Mon, 24 Sep 2012 15:51:15 +0000 (17:51 +0200)]
Add some tests for compatible and incompatible custom deleters

Change-Id: I2bb7f597aab0f00a250881602e6a6bb7bfe42e18
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoMove the fetch and store pixel functions to qdrawhelper.cpp
Thiago Macieira [Sun, 23 Sep 2012 08:46:05 +0000 (10:46 +0200)]
Move the fetch and store pixel functions to qdrawhelper.cpp

These functions have begun showing in the tst_symbols unit test as
"symbol does not start with q". Since they're never called directly,
they're never inlined. Since they were inline, the compiler was probably
deciding to not export them.

Something changed and it could be anything (new compiler version, new
options, etc.). So mark them static.

Change-Id: I838dfc94edd7f09c202743bff0daf9d20c10c3a6
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
12 years agoIntroduce an option to disable stripping during installation
Thiago Macieira [Fri, 14 Sep 2012 14:04:59 +0000 (16:04 +0200)]
Introduce an option to disable stripping during installation

The default is the current behaviour: strip on installing release, no
strip on installing debug. This option does not change the
installation of debug builds because qmake does not support that.

Change-Id: Ic208d5ffe860d5f1ee1cafdc944e12001673d33f
Reviewed-by: Davide Pesavento <davidepesa@gmail.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
12 years agoCentralise handling & ignoring of SIGPIPE in qcore_unix_p.h
Thiago Macieira [Tue, 11 Sep 2012 13:53:17 +0000 (15:53 +0200)]
Centralise handling & ignoring of SIGPIPE in qcore_unix_p.h

We had two instances of this function in the Qt source code, one clearly
a copy of the other, so both had the same thread-safety issue. Instead,
let's have one copy and have both write_nosignal() and sendto() call
them.

Q_NO_POSIX_SIGNALS is also gone. It was only used with Symbian.

Change-Id: I0f1354a8e9df8e6b10a02f86a940e3c6d1222087
Reviewed-by: Peter Hartmann <phartmann@rim.com>
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
12 years agofix build failure for MinGW using "system" freetype
Mark Brand [Mon, 24 Sep 2012 13:12:32 +0000 (15:12 +0200)]
fix build failure for MinGW using "system" freetype

The configure script correctly detects freetype and sets
"system-freetype" in QT_CONFIG. However, the project file did not
consider this possibility.

Change-Id: I9ce90e7cd032a12ed7d06d3858b16c5a8d90c073
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
12 years agoTry to auto-detect the font rendering for WinCE
Andreas Holzammer [Fri, 21 Sep 2012 06:33:57 +0000 (08:33 +0200)]
Try to auto-detect the font rendering for WinCE

Native font rendering is broken for QML applications, use free type
rendering for those scenarios. Use native rendering for all other
applications.

Use a workaround to find out if we are running a QML application on the
target.

Related to QTBUG-24205.

Change-Id: I653ea579098db1e58af8176cb2c3f943be0b9602
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
12 years agoQModelIndex: add constexpr
Marc Mutz [Fri, 24 Feb 2012 16:41:31 +0000 (17:41 +0100)]
QModelIndex: add constexpr

The functions dealing with the void* internalPointer() can't be
constexpr on GCC 4.6 and Clang 3.2-trunk, even though GCC 4.8-trunk
accepts it, because of the casts required.

Change-Id: Id04105312da3d0c7632f7df06a34bc5a71120b32
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
12 years agoQModelIndex: store quintptr instead of void*
Marc Mutz [Mon, 24 Sep 2012 13:21:19 +0000 (15:21 +0200)]
QModelIndex: store quintptr instead of void*

Rationale:
1. Comparing pointers that don't point the same array is undefined behaviour, IIRC,
   and op== and op< did that.
2. The functions that cast to/from the storage type can't be constexpr. It makes
   more sense to have the quintptr functions be constexpr (they have a fighting
   chance to actually get passed something constant) than it is to have the void*
   functions constexpr. Thus, the storage type should be quintptr.

Also prepare op< to be constexpr-compatible.

Change-Id: I4b2d4a0ec8ca80d619d272bf07c57887cbd11c2f
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>