profile/ivi/qtbase.git
12 years agoMerge master into api_changes
Kent Hansen [Fri, 16 Mar 2012 09:01:29 +0000 (10:01 +0100)]
Merge master into api_changes

Conflicts:
src/corelib/kernel/qmetatype.cpp
src/gui/kernel/qplatformsurface_qpa.cpp
tests/auto/corelib/tools/qtimeline/qtimeline.pro

Change-Id: Iff3fff34eeeb06f02369767ddfce44cfde505178

12 years agoarch: Undefine possible architecture defines
Holger Hans Peter Freyther [Thu, 15 Mar 2012 16:42:07 +0000 (17:42 +0100)]
arch: Undefine possible architecture defines

Some compilers define the architecture to one leading to detecting
'1' as target architecture. Always undef the architecture name.

Compilers:
gcc version 4.6.3 (Debian 4.6.3-1) has '#define i386 1'
gcc version 4.5.3 (Broadcom stbgcc-4.5.3-1.3) has '#define mips 1'

Change-Id: I7af1bb743579be472467c74e6c08638648823ef3
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
12 years agoAdd deliberately non-documented qpa platform guard opt out
Donald Carr [Fri, 9 Mar 2012 00:22:27 +0000 (00:22 +0000)]
Add deliberately non-documented qpa platform guard opt out

Change-Id: Ia494976d3cd3c3983d455f130fdf5ab36591aba2
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agoUndeprecate operator casts on QByteArray.
Stephen Kelly [Thu, 15 Mar 2012 16:47:31 +0000 (17:47 +0100)]
Undeprecate operator casts on QByteArray.

This reverts part of commit 8397a44bedf542b53284674c87268819f4911d31.

Change-Id: I1d2ec018167faeb23a9343b209bb0ff2d8db311d
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
12 years agoUn-deprecate QPointer per mailing list discussion.
Robin Burchell [Thu, 15 Mar 2012 19:11:04 +0000 (20:11 +0100)]
Un-deprecate QPointer per mailing list discussion.

Now that QPointer is implemented in an efficient manner, there is really no need
to avoid it, deprecating it just adds a large amount of churn.

Change-Id: I32116faf14c3b07631d59ba9585f9ce422531646
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoFix invalid read, detected by valgrind
João Abecasis [Wed, 7 Mar 2012 13:09:45 +0000 (14:09 +0100)]
Fix invalid read, detected by valgrind

Commit 3fe1eed0 changed the QVERIFY in line 1354 to QCOMPARE. This was
done to work around a (not yet understood) compiler issue. That however
was wrong, as char pointers in QCOMPARE are assumed to point to
'\0'-terminated strings and will get dereferenced.

In this case the intent was to compare the actual pointer values, as the
pointers point past the end of the array and should not be dereferenced.

Explicitly casting to (void *) and using QCOMPARE will not only keep the
intent, it will hopefully also provide meaningful output on failures. As
such the fix was applied throughout the test.

Change-Id: Ib0968df492ccc11d7c391bb69037cd7241e55493
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
12 years agoQSharedPointer: remove two emtpy functions.
Debao Zhang [Wed, 14 Mar 2012 21:39:02 +0000 (14:39 -0700)]
QSharedPointer: remove two emtpy functions.

As the comments says:they are broken by design, and replaced with other
functions. The purpose of their existence is for BIC with Qt4.5.

Change-Id: I9453f816a7b7c6812499b89b7c60f0fd99dea27c
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoAdd a note to QTouchEvent docs about empty touchpoint lists
Laszlo Agocs [Thu, 15 Mar 2012 11:31:00 +0000 (13:31 +0200)]
Add a note to QTouchEvent docs about empty touchpoint lists

Change-Id: I65e9e3ed2069d9194f5e70fb9731d605e0979e6d
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
12 years agoMake more of QDBus bootstrapping-ready.
Stephen Kelly [Thu, 15 Mar 2012 11:57:25 +0000 (12:57 +0100)]
Make more of QDBus bootstrapping-ready.

The DBus metatype system and marshaller is required for determining
the dbus-signature of built-in Qt types, for example QPoint.

Change-Id: I8860ab3b88827aeb8063dfb79c4a9b28c0a20c0f
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoRevert "Disable 'check' target generation for network autotests for Windows."
Shane Kearns [Fri, 2 Mar 2012 11:18:43 +0000 (11:18 +0000)]
Revert "Disable 'check' target generation for network autotests for Windows."

Too broad disabling, will disable more selectively

This reverts commit 3efb0d50e590f6a1e8d67d0136a648cd3b97c37d.

Change-Id: I29e25816646194b6a4b7d8ff69e0c0d074ac2a19
Reviewed-by: Sergio Ahumada <sergio.ahumada@nokia.com>
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoFix QDnsLookup autotest failure in CI environment
Shane Kearns [Mon, 12 Mar 2012 18:46:21 +0000 (18:46 +0000)]
Fix QDnsLookup autotest failure in CI environment

The DNS server can legitimately include NS and A records for
the authoritative name server in addition to the DNS records
that were requested.
These are now ignored when checking the reply (we only check
results that match the query, rather than failing if a result
is for a different host name than the query).

Task-number: QTBUG-24698
Change-Id: I327f31d58cdca50c7df6b32b275d7f28b56405f0
Reviewed-by: Jeremy Lainé <jeremy.laine@m4x.org>
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
12 years agoFix QUdpSocket bindMode autotest regression
Shane [Wed, 14 Mar 2012 13:18:20 +0000 (13:18 +0000)]
Fix QUdpSocket bindMode autotest regression

When binding with the DefaultForPlatform bindmode, then don't set
options on the socket related to sharability, leave them at the
platform default.

This restores compatiblity with Qt 4

Change-Id: I612a3acb976f08446b4eef03ccdcdf84b3477c3c
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
Reviewed-by: Martin Petersson <Martin.Petersson@nokia.com>
12 years agoAdd missing private headers to .pri.
Xizhi Zhu [Thu, 15 Mar 2012 15:24:25 +0000 (16:24 +0100)]
Add missing private headers to .pri.

Change-Id: I7ba23f23c1e7cb19152f2c0cedec3549ddfb11c9
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
12 years agoAdded missing \since 5.0 and tweaked some docs in QtGui.
Samuel Rødal [Thu, 15 Mar 2012 14:55:46 +0000 (15:55 +0100)]
Added missing \since 5.0 and tweaked some docs in QtGui.

Change-Id: I91564f7a61962f97b9fb78c96d94d5695a3924db
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
12 years agoqdoc: Structure the DITA map with a root node.
Martin Smith [Thu, 15 Mar 2012 12:55:37 +0000 (13:55 +0100)]
qdoc: Structure the DITA map with a root node.

The root topicref is now always index.dita, unless
there is no index.dita. But there is always a root
topicref that has the project name as its navtitle,
even if there is no index.dita file to map it to.

Task-number:  Mzilla bug - 7229
Change-Id: I0c9fdf1a2e3ba847fe8975a0745667189a77a755
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
12 years agoQSqlTableModel::removeRows() enforce edit strategy
Mark Brand [Thu, 15 Mar 2012 10:23:27 +0000 (11:23 +0100)]
QSqlTableModel::removeRows() enforce edit strategy

For OnFieldChange and OnRowChange, we don't want more than one row in
the cache with uncommitted changes. This could happen if deletion in
the database fails while other changes are pending.

Chosen solution is to return false if other rows have pending changes.
Also, we only allow 1 row removed at a time.

Updated test, changes and documentation.

Change-Id: I68baf6d221789b4754e891535070011c759a2155
Reviewed-by: Honglei Zhang <honglei.zhang@nokia.com>
12 years agoQSqlTableModel::setData(): no longer autosubmit for OnRowChange
Mark Brand [Tue, 13 Mar 2012 00:28:35 +0000 (01:28 +0100)]
QSqlTableModel::setData(): no longer autosubmit for OnRowChange

The model can never do a good job of knowing when user moves to a
new row in the view. Faking it by detecting when another row
is changed was not a good solution because it cannot detect
when the last edited row is left.

Either the view should automatically submit when the user leaves
a row or the application should provide a way to submit.

This change made it possible to reuse the logic of flags() in
setData().

Change-Id: I2550e5b113bceba1a852fc21203babeca07c5748
Reviewed-by: Honglei Zhang <honglei.zhang@nokia.com>
12 years agoQSqlTableModel: disallow insert if changes are pending
Mark Brand [Wed, 29 Feb 2012 00:51:23 +0000 (01:51 +0100)]
QSqlTableModel: disallow insert if changes are pending

For OnFieldChange and OnRowChange, inserting rows should not be
allowed if there are pending changes in cache.

Change-Id: Ia794332959a35a1de87e798ba1a74ace3dfae68f
Reviewed-by: Honglei Zhang <honglei.zhang@nokia.com>
12 years agoQSqlTableModel::setData()/setRecord(): fix incorrect row
Mark Brand [Tue, 28 Feb 2012 22:41:31 +0000 (23:41 +0100)]
QSqlTableModel::setData()/setRecord(): fix incorrect row

For OnFieldChange and OnRowChange, before submitting new changes,
setData() and setRecord() attempt to submit pending changes and
revert them upon failure. However, they fail to consider that
reverting pending insertions removes rows from the model. As a
result, the new change can be applied to a row higher than intended.

One possible solution would be to adjust the targetted index for the
removed rows, so that the intended row is affected by the new change.
But this still causes the strange editing experience as rows jump
up just as they are being edited.

It does not seem right in the first place for the model to initiate
reverting changes. It should be up to the application to decide what
to do when data cannot be committed. In particular, setData() and
setRecord() should not have the side effect of reverting already
pending changes.

The chosen solution is simply to refuse new changes that don't make
sense for the edit strategy. For OnFieldChange, flag() will
indicate read-only when editing is blocked by a pending change.

Since setData() and setRecord() submit data immediately for
OnFieldChange, it no longer makes sense to resubmit changes
automatically before a new change.

For OnRowChange, setData() keeps the behavior of automatically
submitting a pending row before starting on a new row. This is
historical behavior and is probably motivated by the fact that
QTableView does not automatically call submit() when editing leaves a
row. The obvious shortcoming of this is that the last row to be edited
will not be submitted automatically. It also prevents us from flagging
rows other than the pending row as read-only.

For OnRowChange, setRecord(), being row-oriented by nature, should
submit the change immediately rather than waiting for the next call
to setRecord(). This makes setRecord() consistent with insertRecord().

Change-Id: Icb4019d8b7c53a7ee48f8121a7a525e8bc35d523
Reviewed-by: Honglei Zhang <honglei.zhang@nokia.com>
12 years agoRemove Q_WS_X11
Frederik Gladhorn [Thu, 15 Mar 2012 14:15:07 +0000 (15:15 +0100)]
Remove Q_WS_X11

The define is removed and only added an include.

Change-Id: I85090023cb9eb33f83ccc7fe2ab69556b4ff89fb
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
12 years agoQSystemTrayIcon/Win: Fix compilation on MinGW
Jonathan Liu [Thu, 15 Mar 2012 14:10:02 +0000 (01:10 +1100)]
QSystemTrayIcon/Win: Fix compilation on MinGW

Define NOTIFYICON_VERSION_4 if it is not already defined.

Change-Id: Ic432cbebf18f8b1e8b4727659dcedd7063e126ee
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
12 years agoRemove all QWS centric examples
Donald Carr [Fri, 9 Mar 2012 01:07:26 +0000 (01:07 +0000)]
Remove all QWS centric examples

Change-Id: I1bd9c40c7cc70e088a23283d1c3e89d12c1c5f7d
Reviewed-by: Donald Carr <donald.carr@nokia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
12 years agoMake QWindow::isActive return false when the application loses the focus
Anselmo L. S. Melo [Thu, 8 Mar 2012 23:01:24 +0000 (20:01 -0300)]
Make QWindow::isActive return false when the application loses the focus

In QTBUG-24807 there is a test case that shows a case when a segmentation
fault happens inside isAncestorOf. When the whole application loses the
focus, e.g. when it is minimized or other application receives the focus,
QGuiApplication::focusWindow() returns a null pointer, so we need to
do a check before proceed inside of isActive.

Task-number: QTBUG-24807
Change-Id: I732c92bb9f236804ede5e89592f6e6609a4711b9
Reviewed-by: Jesus Sanchez-Palencia <jesus.palencia@openbossa.org>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
12 years agoUTF8-Codec test: Fix compilation with g++/C++0X.
Friedemann Kleint [Thu, 15 Mar 2012 13:08:54 +0000 (14:08 +0100)]
UTF8-Codec test: Fix compilation with g++/C++0X.

Change-Id: I704f8d1b07ca371c36e4eecc52c80ac783e3da3c
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoFix compiling with --no-accessibility
Jerome Leclanche [Thu, 15 Mar 2012 00:41:15 +0000 (00:41 +0000)]
Fix compiling with --no-accessibility

Adds missing QT_NO_ACCESSIBILITY checks where required to build
without accessibility support.

Change-Id: Id98ecdcb9b351289b21dc2d382100d0b63857db9
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com>
12 years agoImplement cocoa clipboard support.
Morten Johan Sorvig [Mon, 12 Mar 2012 11:07:51 +0000 (12:07 +0100)]
Implement cocoa clipboard support.

Add QCoccoaClipboard which wraps the existing
QMacPasteboard implementation. Remove unused
QClipboard integration code from qmacclipboard.mm

Change mime type cleanup from using qAddPostRoutine
to using an explicit call to destroyMimieTypes in
the cocoa platform integration destructor. This is
necessary to ensure cleanup happens in the correct
order on app shutdown.

Change-Id: Ief0e0d996b04c8e84e9fd2cd3a17fb5bd73bb761
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
12 years agotst_qsharedpointer: Fix auto test fail under Windows 7
Debao Zhang [Tue, 13 Mar 2012 17:46:39 +0000 (10:46 -0700)]
tst_qsharedpointer: Fix auto test fail under Windows 7

The tst_QSharedPointer generate another Process to test some invalid
codes, and it expect that the prcoess will crash and return a non-zero
value.

The process which is a console application was linked to windows
subsystem, and QProcess seems can not get its return value. This
cause the unit test fail.

In addition, when the process crash under debug mode, a debug error
report-dialog will appear, which is very annoying, so I suppress it too.

Task-number: QTBUG-24160
Change-Id: Ia1c872d4515c83b0aa516bcfe3783f59797d2d49
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
12 years agoMake sure QGlobalNetworkProxy is created for QNetworkProxy.
Xizhi Zhu [Thu, 15 Mar 2012 09:26:39 +0000 (10:26 +0100)]
Make sure QGlobalNetworkProxy is created for QNetworkProxy.

Otherwise, you don't have any socket engine handler created when
directly setting a proxy to a socket.

Change-Id: I35cd7f52331672a6d3e7bcdf817c0fe1fd1e7de3
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
12 years agoFixed incorrect reporting of child window geometry in xcb plugin.
Samuel Rødal [Thu, 15 Mar 2012 09:18:27 +0000 (10:18 +0100)]
Fixed incorrect reporting of child window geometry in xcb plugin.

We should only query the position for top levels, otherwise trust the
position given in the event.

Change-Id: Ic29f25983af3e2c2f27eeb527c08069435ac938c
Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
12 years agoAdd Qt Widgets opt out support to build system
Donald Carr [Wed, 7 Mar 2012 00:11:44 +0000 (00:11 +0000)]
Add Qt Widgets opt out support to build system

There should be a clear QWidget free path for people with no interest in
legacy QWidget functionality. Adding this option to configure makes this
path readily accessible and hence testable.

Change-Id: If87c1063fcf4c46f5280836126c11999feaa9f8a
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agoRemove unmaintained and broken uikit platform plugin
Johannes Zellner [Wed, 14 Mar 2012 13:11:28 +0000 (14:11 +0100)]
Remove unmaintained and broken uikit platform plugin

There was no development done to make this working on Qt 5

Change-Id: Ia08d53c6680a65cb1e60a30e55caa992eaa54bc7
Reviewed-by: Eike Ziller <eike.ziller@nokia.com>
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
12 years agoImproved qWaitForWindowShown().
Samuel Rødal [Wed, 14 Mar 2012 11:16:45 +0000 (12:16 +0100)]
Improved qWaitForWindowShown().

Made faster by actually waiting for the window to be exposed, using
similar waiting logic as qWait(). Should speed up autotests that use it
quite a bit.

Change-Id: I628c6110a554fdbbf5bed7e91f57c2fe341113ed
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
12 years agoUse pointers for QAccessibleEvent.
Frederik Gladhorn [Thu, 8 Mar 2012 15:10:10 +0000 (16:10 +0100)]
Use pointers for QAccessibleEvent.

At least on mac g++ badly wants to copy the event and
cannot use the copy ctor. The sensible solution is thus
to use pointers. This is in line with QCoreApplication::sendEvent.

Change-Id: Icb58852be351ab04ffa17069989d7a07d4b377da
Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
12 years agoQPlatformSurface: add missing virtual dtor
Marc Mutz [Tue, 6 Mar 2012 21:47:33 +0000 (22:47 +0100)]
QPlatformSurface: add missing virtual dtor

Change-Id: Ia7630cf33380badfe4ec7bdb59a9b86320257978
Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
12 years agoUpdate QtSql module name according to the new naming convention
Honglei Zhang [Wed, 14 Mar 2012 10:05:03 +0000 (12:05 +0200)]
Update QtSql module name according to the new naming convention

According to the new module name convention, QtSql should be replaced
with Qt SQL in documentation.

Task-number: QTBUG-24775
Change-Id: I712ef17c8245d30fe5e3cf879ef6e3e6aa2ff75c
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
12 years agoRe-enable native print/pagesetup dialogs on Mac OS X
Bradley T. Hughes [Mon, 5 Mar 2012 14:01:55 +0000 (15:01 +0100)]
Re-enable native print/pagesetup dialogs on Mac OS X

Since QtPrintSupport does not have access to the internals of the print
engine on Mac OS X (it lives in the platform plugin). We instead use the
NSPrintInfoFromPrintEngine() invokable method in
QPlatformNativeInterface to return an NSPrintInfo* that we can use where
needed, or we use QPrintEngine::property()/setProperty() to communicate
with the engine.

This commit disables the generic UNIX dialogs and CUPS support on
Mac OS X, ensuring that the default format on Mac OS X is the
QPrinter::NativeFormat (previously qprinter.cpp would force PdfFormat as
default on Q_OS_UNIX which is also defined on Mac OS X).

The rest of the changes are straight forward porting. The methods:

extern void macStartInterceptWindowTitle(QWidget *window);
extern void macStopInterceptWindowTitle();

don't exist anymore, so don't use them. QMacCocoaAutoReleasePool also
doens't work, so use NSAutoreleasePool directly.

Change-Id: I341609e5efa53cadf8d174e4b282cbcae93e39e8
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
12 years agoAdd method to get NSPrintInfo* from QPrintEngine in Cocoa plugin
Bradley T. Hughes [Mon, 5 Mar 2012 13:42:53 +0000 (14:42 +0100)]
Add method to get NSPrintInfo* from QPrintEngine in Cocoa plugin

Add an invokable method that takes the QPrintEngine (which will
always be a QMacPrintEngine) and return the NSPrintInfo* from the
QMacPrintEnginePrivate. This will be used by the native dialogs in
QtPrintSupport to get/set printer settings.

Change-Id: If1e49027e8f0d505656db51be1f40a23f60e8e57
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
12 years agoDon't keep PMPrint* state separate from NSPrintInfo
Bradley T. Hughes [Mon, 5 Mar 2012 13:40:00 +0000 (14:40 +0100)]
Don't keep PMPrint* state separate from NSPrintInfo

When we need to use PMPrintSession, PMPrintSettings, and PMPageLayout,
get these directly from the NSPrintInfo when needed. This avoids us
needing to keep the settings in sync. The native dialogs can then only
rely on getting a pointer to NSPrintInfo (to be done in a future
commit).

Change-Id: I4720284dcf999e454f86766b4291fbda7bf3c537
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
12 years agoAdd a QPlatformPrinterSupportPlugin for Cocoa
Bradley T. Hughes [Wed, 29 Feb 2012 14:23:22 +0000 (15:23 +0100)]
Add a QPlatformPrinterSupportPlugin for Cocoa

This is used to create the actual QPrintEngine and to query the system
about printer information.

The QCocoaPrinterSupport actually lives in the Cocoa platform plugin,
so the QCocoaPrinterSupportPlugin uses the
createPlatformPrinterSupport() function in the QPlatformNativeInterface
(since the latter is a QObject). This is done to avoid adding a printing
related virtual function to QPlatformIntegration (since we have plans
to do a new printing API in the future).

Change-Id: I8bf9be668ff8ae1d07840e2af1e0846dc3299334
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
12 years agoPort QMacPrintEngine and QCoreGraphicsPaintEngine from Qt 4 to Qt 5
Bradley T. Hughes [Fri, 2 Mar 2012 11:17:24 +0000 (12:17 +0100)]
Port QMacPrintEngine and QCoreGraphicsPaintEngine from Qt 4 to Qt 5

Copy qprintengine_mac_p.h, qprintengine_mac.mm, qpaintengine_mac_p.h,
and qpaintengine_mac.cpp (as qpaintengine_mac.mm) from src/gui/painting/
in the 4.8 branch of http://git.gitorious.org/qt/qt.git at commit
e6bd33d4aef0e4538d7918e7ab130624c911b553.

The following changes are necessary to port these files to the Qt 5 API:

- The copyright notice on these files has been updated to match the
  header.LGPL template.

- Fix #includes for qprintengine_mac* and qpaintengine_mac*, as some
  headers have moved in Qt 5.

- Remove extern forward declarations for functions that no longer exist.

- Remove friend declarations for classes/functions that are not part of
  the Cocoa platform plugin.

- Remove QT_MAC_USE_COCOA blocks. Qt is always using Cocoa now, there
  is no need to keep the non-Cocoa code paths anymore. The
  QMacPrintEngine::shouldSuppressStatus() method was also removed,
  since it is no longer used.

- Do not use Qt::UniteClip, it was removed in commit
  01b72952c38b9193138eabdab6bdab632cd75ebd

- Use QCocoaAutoReleasePool in qprintengine_mac.mm

- Use QPlatformPrintSupport::convert*() functions in QMacPrintEngine,
  since we cannot use non-exported functions from QtPrintSupport in the
  Cocoa plugin.

- Use qt_mac_image_to_cg_image() to convert QPixmap to CGImageRef. First
  convert QPixmap to QImage (cheap, since the Cocoa platform plugin
  uses QRasterPlatformPixmap), and then convert the QImage to CFImageRef
  using the existing helper function.

- Copy qt_mac_cg_context() to the Cocoa platform plugin from
  qmacstyle_mac.mm, adding a note at each location about the
  duplication.

- Add qt_mac_QRegionToHIMutableShape() helper. Adapt the Qt 4.x code for
  QRegion::toHIMutableShape(), and use this in QCoreGraphicsPaintEngine.

- Add qt_mac_drawCGImage() and qt_mac_get_scalefactor() helper. These
  functions are copied directly from the 4.8 branch of
  http://git.gitorious.org/qt/qt.git at the same revision shown above.

- Add qt_mac_create_imagemask() helper in qpaintengine_mac.cpp.  This
  helper is based on the function with the same name from the 4.8
  branch of http://git.gitorious.org/qt/qt.git at the same revision
  shown above. The correctness of the implementation has not yet been
  verified.

Since these files use the QPrinter API from QtPrintSupport, the Cocoa
plugin now needs to link to that library as well.

Change-Id: I90b9bbe201327489ef9e1b3294e68e91ddda27bd
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
12 years agoRemove QtWidgets dependencies
Harald Fernengel [Tue, 13 Mar 2012 20:00:57 +0000 (21:00 +0100)]
Remove QtWidgets dependencies

Remove references to libQtOpenGL, and use QGuiApplication instead of
QApplication

Change-Id: If8f652223492cf758175a260c27b687f3af1c4ad
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
12 years agoimprove processing stylesheet properties
Mark Brand [Mon, 12 Mar 2012 20:05:31 +0000 (21:05 +0100)]
improve processing stylesheet properties

By scanning the properties in reverse order we don't have to save
properties in the list only to remove them later when the occur
again. It's also unnecessary to cache the values since they can
be easily plucked out of decls. Various other tests can be done
once per property instead of once per property occurence in decls.

Change-Id: I81cf60c59efaeed57fc9c12df98279d6cae116cd
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
Reviewed-by: Rick Stockton <rickstockton@reno-computerhelp.com>
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
Reviewed-by: John Brooks <john.brooks@dereferenced.net>
12 years agoimplement virtual destructor in QPlatformSurface
Gunnar Sletta [Wed, 14 Mar 2012 14:33:18 +0000 (15:33 +0100)]
implement virtual destructor in QPlatformSurface

Change-Id: Iaadd9c3cd7c2e2022066ca859cbe1e912050c561
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
12 years agoAdd new plugin metadata description and eglfs.json file
Johannes Zellner [Tue, 13 Mar 2012 16:46:22 +0000 (17:46 +0100)]
Add new plugin metadata description and eglfs.json file

Change-Id: Ia594c18ba24e5fccf9fa59b9be6efcbeae00fad6
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
12 years agoVerify expected warnings in QSettings autotest.
Jason McDonald [Tue, 13 Mar 2012 06:36:38 +0000 (16:36 +1000)]
Verify expected warnings in QSettings autotest.

Use QTest::ignoreMessage() so that the warnings don't appear in the test
output and so that the test will fail if the warnings are not produced.

Change-Id: I418d78819fc9dbfd7da2a8b6c0a1ebfa967347e2
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoRemove unmaintained and broken VNC platform plugin
Johannes Zellner [Tue, 6 Mar 2012 11:23:31 +0000 (12:23 +0100)]
Remove unmaintained and broken VNC platform plugin

Change-Id: Ie0a07c3a6822870b095a20d997b63fb1635f20be
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Robert Griebl <robert.griebl@nokia.com>
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
12 years agoheadersclean: omit -Wcast-align also on MIPS
Rohan McGovern [Wed, 14 Mar 2012 22:29:17 +0000 (08:29 +1000)]
headersclean: omit -Wcast-align also on MIPS

These issues are permitted to go unfixed for ARM and MIPS, for the time
being.

Change-Id: Ibdf33dc42e3de19ef20e9dc50f12f451ea6dbf23
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoUse strlen to determine length of returned path
João Abecasis [Wed, 14 Mar 2012 15:11:27 +0000 (16:11 +0100)]
Use strlen to determine length of returned path

Change-Id: I8603f032bacdbb060be043f8720bd2b8c34d7ec6
Reviewed-by: David Faure <faure@kde.org>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
12 years agoMark tst_qtimeline as insignificant on Windows
Rohan McGovern [Wed, 14 Mar 2012 23:17:23 +0000 (09:17 +1000)]
Mark tst_qtimeline as insignificant on Windows

This test has been repeatedly unstable.

Task-number: QTBUG-24796
Change-Id: I603965c0189ad6da0cdf48527c4919c55e1918b4
Reviewed-by: Toby Tomkins <toby.tomkins@nokia.com>
12 years agoUse the LSB linker to link
Harald Fernengel [Tue, 13 Mar 2012 19:51:00 +0000 (20:51 +0100)]
Use the LSB linker to link

Fixes those cases where things would magically link, although they were
everything but LSB compliant.

Also fix a linker error, it seems we need to explicitly link to -lrt,
otherwise, the non-LSB compliant system lib will be taken into account.

Change-Id: I40e278f1c4d2e02084c4c5f15b9bbff8c5901d32
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoLSB requires an explicit header include
Harald Fernengel [Tue, 13 Mar 2012 19:59:59 +0000 (20:59 +0100)]
LSB requires an explicit header include

Makes the plugin build in the LSB environment

Change-Id: Ic9a54b984f7fc1f393853ec01e32886f49a041c6
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
12 years agoCompile in the LSB env
Harald Fernengel [Tue, 13 Mar 2012 20:05:59 +0000 (21:05 +0100)]
Compile in the LSB env

madvise is not part of the LSB, use posix_madvise instead

Change-Id: I661e8c5aece5a764a2a9032fcfab49241ab96dd8
Reviewed-by: Giuseppe D'Angelo <dangelog@gmail.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoRename qdoc index file to qdoc-index.html
Casper van Donderen [Wed, 14 Mar 2012 13:29:34 +0000 (14:29 +0100)]
Rename qdoc index file to qdoc-index.html

Change-Id: I74fcbce7d2929c31031db379d5e0b4b0d2f48800
Reviewed-by: Martin Smith <martin.smith@nokia.com>
12 years agoRename all occurences of qdoc3 to qdoc in the qdoc manual.
Casper van Donderen [Wed, 14 Mar 2012 14:01:36 +0000 (15:01 +0100)]
Rename all occurences of qdoc3 to qdoc in the qdoc manual.

Change-Id: I84cfab5a7130aff9ed8a6eb568d78f29167e1ac8
Reviewed-by: Martin Smith <martin.smith@nokia.com>
12 years agoqdoc3: Change suffix of DITA files to .dita
Martin Smith [Wed, 14 Mar 2012 12:10:08 +0000 (13:10 +0100)]
qdoc3: Change suffix of DITA files to .dita

The files output by the DITA XML generator now
have .dita on the end instead of .xml, but the
ditamap files still use .ditamap .

Task-number:  Mzilla bug - 7291
Change-Id: Idb8b70c5d3f2ac2c4fdf195e385393f7ac68b7ba
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
12 years agoBuild with the LSB build env
Harald Fernengel [Tue, 13 Mar 2012 20:03:57 +0000 (21:03 +0100)]
Build with the LSB build env

LSB doesn't define some functionality that we expect on Linux, so
fall back to the generic code.

Change-Id: I19e09908b9e9002140535f159ae0745d7ca80b70
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoAdd a way to query for global handles in QPlatformNativeInterface
Jørgen Lind [Wed, 14 Mar 2012 12:05:33 +0000 (13:05 +0100)]
Add a way to query for global handles in  QPlatformNativeInterface

Change-Id: I4f29f40a3d6d4237f7da092bb34b8e596321b47d
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
12 years agoQHttpNetworkConnectionChannel: Warn if bytesAvailable and no reply
Martin Petersson [Wed, 14 Mar 2012 09:44:31 +0000 (10:44 +0100)]
QHttpNetworkConnectionChannel: Warn if bytesAvailable and no reply

If there are no bytesAvailable and no reply then the channel
can be closed without any need for this warning.

Task-number: QTBUG-9315
Change-Id: Ifbb1f4732d3173a7807ac5bd0dc78fb5144faaf3
Reviewed-by: Markus Goetz <markus@woboq.com>
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
12 years agoQTableView: call model->submit() on row change
Mark Brand [Tue, 13 Mar 2012 10:40:25 +0000 (11:40 +0100)]
QTableView: call model->submit() on row change

QTreeView already does this in the exact same way. It's necessary to
call submit() so edit strategy OnRowChange in QSqlTableModel will
work as expected.

Change-Id: Ib430143e8a71f3b0bcd842fcc772cc7ee4525f0a
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoQSqlTableModel bugfix: consider uncached rows submitted
Mark Brand [Tue, 13 Mar 2012 01:26:29 +0000 (02:26 +0100)]
QSqlTableModel bugfix: consider uncached rows submitted

Change-Id: I7ec0529b88fd8e3ae0cf8dadfcb5899579e52745
Reviewed-by: Honglei Zhang <honglei.zhang@nokia.com>
12 years agoRefactor theme plugin loading.
Friedemann Kleint [Wed, 14 Mar 2012 12:50:14 +0000 (13:50 +0100)]
Refactor theme plugin loading.

In the old implementation, the QPlatformIntegration was asked
for the theme first, so there was no way of overriding that
by a custom plugin. Also, there was a memory leak in case
the platform theme was actually created by a plugin.

QGuiApplication now asks the QPlatformIntegration for a list
of potential theme names first, tries to load them using
the plugin loader and finally invokes a factory method of
QPlatformIntegration in case that fails. The theme is now
owned by QGuiApplication.

In the XCB plugin, the environment variable DESKTOP_SESSION
is queried and appended to the list of themes, making it possible
to load plugins for other session types.

Change-Id: I1a4b4e061815bca16c65b23e591bb7563a3e44e2
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
12 years agoQRegularExpression: support for QString overloads
Giuseppe D'Angelo [Sun, 12 Feb 2012 01:04:16 +0000 (01:04 +0000)]
QRegularExpression: support for QString overloads

Added support for QString overloads taking a QRegularExpression.

Change-Id: I8608ab0b66e5fdd2e966992e1072cf1ef7883c8e
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoSimplify QMetaObject::newInstance
Jędrzej Nowacki [Tue, 13 Mar 2012 15:36:49 +0000 (16:36 +0100)]
Simplify QMetaObject::newInstance

To create space on stack for a QObject pointer QVariant is not really
essential.

Change-Id: Iaf04a4f77005e33823f0e14bfdc6fe927cb59867
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
12 years agoReimplement QMetaType::create method.
Jędrzej Nowacki [Tue, 6 Mar 2012 12:47:52 +0000 (13:47 +0100)]
Reimplement QMetaType::create method.

The method was reimplemented using QMetaTypeSwitcher. That should
reduce maintenance costs, because types list is populated automatically
now.

Change-Id: I6637f7b928218ce60b2ec7436079a44089f0e00f
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoCocoa: Improve basic window handling.
Morten Johan Sorvig [Fri, 16 Dec 2011 12:12:39 +0000 (13:12 +0100)]
Cocoa: Improve basic window handling.

Refactor NSWindow creation into createNSWindow and
setNSWindow. This is necessary to support QMacNativeWidget
where we re-use an already created window.

Implement popup window handling. Make sure the window
is displayed correctly and closes when it should.

Take control over window activation in order to prevent
infinite loops involving the QtCreator "cmd-k" window.
Activation events are for now not sent to popup-type
windows.

There is now a different set of test failures: add
and remove some QEXPECT_FAILs.

Change-Id: I229761b59f90c9815b968eacc2cbc9c20cc5047e
Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
12 years agoAdd QByteArray overload for the QLatin1String ctor.
Stephen Kelly [Wed, 14 Mar 2012 14:36:50 +0000 (15:36 +0100)]
Add QByteArray overload for the QLatin1String ctor.

This increases source compatibility when QT_NO_CAST_FROM_BYTEARRAY
is used.

Change-Id: Ie1a1cfa8acac2fa91aa8f217d91e22289be8b38f
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoMake some DBus classes bootstrapping-ready.
Stephen Kelly [Thu, 8 Mar 2012 17:49:51 +0000 (18:49 +0100)]
Make some DBus classes bootstrapping-ready.

Change-Id: Ib7611fb0bf8e226a36064a100280e1ab7a0e159d
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoAdd an overload to Moc to allow reading from a QIODevice.
Stephen Kelly [Thu, 8 Mar 2012 20:34:14 +0000 (21:34 +0100)]
Add an overload to Moc to allow reading from a QIODevice.

This allows external code to provide the input data, such
as a bootstrapped version of qdbuscpp2xml.

Change-Id: I163062efc6495b3ab92573f94523967a67601191
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoFix a memory leak in QMetaObject::connectSlotsByName function.
Jędrzej Nowacki [Wed, 14 Mar 2012 08:06:32 +0000 (09:06 +0100)]
Fix a memory leak in QMetaObject::connectSlotsByName function.

QObjectPrivate::Connection time life should be controlled by
QMetaObject::Connection handle.

Change-Id: Ie7fcd950082a3e6cebc29ecc0622007470914edb
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoFix compilation of the Windows accessibility code for MinGW.
Friedemann Kleint [Wed, 14 Mar 2012 11:17:11 +0000 (12:17 +0100)]
Fix compilation of the Windows accessibility code for MinGW.

Temporarily disable the code for MinGW.

Change-Id: I435305167e06af05b9a78901e6e3a35347c5c3f5
Reviewed-by: Jan-Arve Sæther <jan-arve.saether@nokia.com>
12 years agoAdd QGuiApplication::platformName.
Friedemann Kleint [Wed, 14 Mar 2012 13:51:19 +0000 (14:51 +0100)]
Add QGuiApplication::platformName.

Store the name of the QPA plugin as platformName.

Change-Id: Id87cab2a189743c0dd727c86080f7d4595a852bb
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
12 years agoExplicit use of null namespace breaks namespaced build
Donald Carr [Mon, 12 Mar 2012 16:29:59 +0000 (16:29 +0000)]
Explicit use of null namespace breaks namespaced build

These changes are currently required to successfully build Qt when it is
configured with a namespace via the configure -qtnamespace argument

Change-Id: I9f3ab30579c16085c4d3d05705336b810466c331
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoRemove unused forward declaration.
Sergio Martins [Sat, 10 Mar 2012 17:50:35 +0000 (17:50 +0000)]
Remove unused forward declaration.

Change-Id: Ib207e0036226dd7131195244bf49bbfae142cd22
Reviewed-by: Sean Harmer <sh@theharmers.co.uk>
Reviewed-by: Kevin Krammer <kevin.krammer@kdab.com>
Reviewed-by: Harald Fernengel <harald.fernengel@nokia.com>
12 years agobootstrap: remove QtXml dependency
Giuseppe D'Angelo [Wed, 29 Feb 2012 00:48:43 +0000 (00:48 +0000)]
bootstrap: remove QtXml dependency

Only qdoc is now using QtXml classes, so just add them to qdoc.pro
and drop them from the bootstrap library.

Change-Id: I821839396141d1d7a2ada565a513aa46c54c9620
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoFix warning about unused parameter.
Stephen Kelly [Wed, 14 Mar 2012 13:15:50 +0000 (14:15 +0100)]
Fix warning about unused parameter.

Side effect of 3bb902495291c50a2f06e8e03a62a647db3e5cd4

Change-Id: Idd6127832c4af26d3e1dad7b4994001b05bc2be8
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
12 years agoQDirIterator, QDataStream: remove virtual dtor
Marc Mutz [Tue, 6 Mar 2012 21:47:07 +0000 (22:47 +0100)]
QDirIterator, QDataStream: remove virtual dtor

These two classes are not meant to be polymorphic,
and have no other other virtual functions besides
the destructor, so remove the overhead of the
vtable completely.

Change-Id: I08b93898312c2fbbe4db92d4f1c444c6417fe19a
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
12 years agoRemove QTEST_NO_SPECIALIZATIONS
Olivier Goffart [Sat, 25 Feb 2012 12:52:31 +0000 (13:52 +0100)]
Remove QTEST_NO_SPECIALIZATIONS

We don't support these compiler anymore

Change-Id: I0eb73535b6c11703299430e5fc24c8e17fed1653
Reviewed-by: Samuli Piippo <samuli.piippo@digia.com>
Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
12 years agoQtNetwork: make some constructors explicit
Marc Mutz [Tue, 6 Mar 2012 21:35:01 +0000 (22:35 +0100)]
QtNetwork: make some constructors explicit

This is a semi-automatic search, so I'm
reasonably sure that all the exported ones
have been caught.

Change-Id: Ia00eb9194a5f64002bd7e7b894abf6333d1b825e
Reviewed-by: Jonas Gastal <jgastal@profusion.mobi>
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
12 years agoQStyleSheetStyle: Fix icon properties.
Friedemann Kleint [Wed, 14 Mar 2012 09:53:00 +0000 (10:53 +0100)]
QStyleSheetStyle: Fix icon properties.

Convert icon structure returned by the CSS parser.

Change-Id: I19b846c6cb0ec19045b6d07b3caa5ecfac75ca86
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
12 years agoQHeaderView - documentation update. Prefer hideSection over 0-resize.
Thorbjørn Lund Martsum [Sun, 11 Mar 2012 09:52:25 +0000 (10:52 +0100)]
QHeaderView - documentation update. Prefer hideSection over 0-resize.

There is a different behavior on 0 sections and hidden sections
e.g with scrollbars. Normally people want to use hideSection.

Change-Id: Id99de30ea46906bb4ef7720ed12d4ac9615c9743
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
12 years agoDisconnect slots from the old sourcemodel in QIdentityProxyModel
kb [Fri, 9 Mar 2012 11:29:09 +0000 (12:29 +0100)]
Disconnect slots from the old sourcemodel in QIdentityProxyModel

When setting a new sourcemodel QIdentityProxyModel::setSourceModel
tries to disconnect from signals belonging to the NEW model instead of
from the existing sourceModel(). QIdentityProxyModel thus receives
signals from both the old model(s) and the new model. This results in
ASSERTS triggering in various slots, for example:
"Q_ASSERT(topLeft.isValid() ? topLeft.model() == model : true);"
in QIdentityProxyModelPrivate::_q_sourceDataChanged.

Change-Id: Ic6f65a9ee10981d00206335f2edef78272fadc1a
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
12 years agoUse QRect::united(), QRect::unite() is deprecated.
Sergio Martins [Thu, 8 Mar 2012 20:41:12 +0000 (20:41 +0000)]
Use QRect::united(), QRect::unite() is deprecated.

Change-Id: Ia7aac74596c2f251c96fecf157d2aa4a935cf602
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
12 years agoQHeaderView - renaming functions in Qt5
Thorbjørn Lund Martsum [Sat, 3 Mar 2012 05:05:54 +0000 (06:05 +0100)]
QHeaderView - renaming functions in Qt5

This patch renames the functions in Qt5 according to the
notes. It also renames resizeMode to be consistent.

The old functions are both marked with both QT_DEPRECATED
and '### Qt 6 - remove'

All usage of the function within the qtbase are also
changed to use the new functions.

Change-Id: I9e05fa41d232e9ca43b945fcc949987017f3aedd
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
12 years agoFix LSB build
Harald Fernengel [Tue, 13 Mar 2012 20:02:41 +0000 (21:02 +0100)]
Fix LSB build

Fix compliation in LSB by removing legacy calls and adding an explicit
header.

Change-Id: I13a73211c07457195b5d5aad0854643da1e25f9b
Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
12 years agoAdd two (forgotten) since 5.0
Thorbjørn Lund Martsum [Sat, 10 Mar 2012 13:31:15 +0000 (14:31 +0100)]
Add two (forgotten) since 5.0

SHA for QWidget::hasHeightForWidth change:
466107107a85e7211c4b7f77b36ec50625657061

SHA for QAbstractItemDelegate::destoryeditor change
15f253a46aa45e2a9fa1055799fa2768ba49b9a3

Change-Id: Ic7e38c15f62eef22ab95414fad6e7b6c9c7d4f59
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
12 years agoUse the lazily-queried families for all QPA multi font engines.
Pierre Rossi [Wed, 7 Mar 2012 12:59:21 +0000 (13:59 +0100)]
Use the lazily-queried families for all QPA multi font engines.

This is the approach introduced together with the  WebKit "backdoor"
that lets us use QRawFont with QTextLayout. We could use it all
over the place and share more code.

Change-Id: Ie1963679755f37ba9204d67554a163f1d1115604
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
12 years agoQRegExp: remove docs about RegExp2 being default in Qt5
Giuseppe D'Angelo [Mon, 12 Mar 2012 18:41:34 +0000 (18:41 +0000)]
QRegExp: remove docs about RegExp2 being default in Qt5

Change-Id: I37f4086d53ce6f2d6774ab204808d0d678a68349
Reviewed-by: Andy Shaw <andy.shaw@digia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
12 years agoFix build error when QT_NO_FILESYSTEMWATCHER is set
sh kim [Wed, 14 Mar 2012 06:38:10 +0000 (15:38 +0900)]
Fix build error when QT_NO_FILESYSTEMWATCHER is set

QPollingFileSystemWatcherEngine inherits from QFileSystemWatcherEngine.
This class should be covered by !QT_NO_FILESYSTEMWATCHER.

Change-Id: I053a873018cf3c9c443435c9b3f44240b0965c24
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
12 years agoQRegularExpression: QMetaType and QVariant support
Giuseppe D'Angelo [Sun, 11 Mar 2012 00:26:17 +0000 (00:26 +0000)]
QRegularExpression: QMetaType and QVariant support

Removed the Q_DECLARE_METATYPE in favour of first-class support
inside QMetaType and QVariant.

Change-Id: I904236822bfab967dc0fbd4d4cc2bcb68c741adc
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
12 years agobuild fix for -no-freetype in Windows
jian liang [Tue, 13 Mar 2012 14:52:51 +0000 (22:52 +0800)]
build fix for -no-freetype in Windows

Don't use QWindowsFontDatabaseFT::systemDefaultFont() and
QWindowsFontDatabaseFT::LOGFONT_to_QFont() in qwindowsfontdatabase.cpp and
qwindowstheme.cpp because it is not available when building with
-no-freetype.

Change-Id: I11075475ff435c55b0c641540f95a4d3861b79da
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
12 years agoMade sure first created xcb window still receives focus.
Samuel Rødal [Tue, 13 Mar 2012 15:50:05 +0000 (16:50 +0100)]
Made sure first created xcb window still receives focus.

Change 50ca45f059524293790 caused mapped windows to not receive focus by
default. The _NET_WM_USER_TIME spec says that if the user time is set to
0 (or CurrentTime), the window will not be initially focused. Thus, if
the connection time has not yet been set, we skip this part to restore
the old behavior.

Change-Id: I19de3602c78629ad2bc65f5e1976313949c82c4c
Reviewed-by: Jan Arne Petersen <jpetersen@openismus.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
12 years agoUnify QMetaType::TypeFlags detection.
Jędrzej Nowacki [Tue, 13 Mar 2012 13:15:53 +0000 (14:15 +0100)]
Unify QMetaType::TypeFlags detection.

Duplicated code was removed. As an side effect:
- one runtime flag check was replaced by a compile time check.
- is enum flag can be used together with built-in types.

Change-Id: I54173e7b07ce7e487d3cc21ba24dcccd28b5d049
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoAdd bin/qdoc to .gitignore
Giuseppe D'Angelo [Tue, 13 Mar 2012 04:25:00 +0000 (04:25 +0000)]
Add bin/qdoc to .gitignore

Changing .gitignore to match qdoc* instead of qdoc3*.

Change-Id: I94e41e6e4371c40e0dbc33639ca02523986149b0
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
12 years agoremove obsolete qudevhelper and adopt mouse and touch plugins
Johannes Zellner [Mon, 12 Mar 2012 16:52:27 +0000 (17:52 +0100)]
remove obsolete qudevhelper and adopt mouse and touch plugins

The QUDevHelper class is now replaced by QUDeviceHelper class.
All evdev input plugins are using the new udev helper now to enable
hotplugin for keyboard and mouse input.

EvdevTouch plugin still only uses the first detected device by udev,
this cannot be tested on my side, due to the lack of multiple touch input devices.

Change-Id: I01a4cfe1a80000bfb27c67a2f53faf560906b73c
Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
12 years agoQtGui: make some constructors explicit
Marc Mutz [Tue, 6 Mar 2012 21:41:26 +0000 (22:41 +0100)]
QtGui: make some constructors explicit

This is a semi-automatic search, so I'm
reasonably sure that all the exported ones
have been caught.

Change-Id: I5b122db2498dbb2aee50c7ad95c67e708aade45b
Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
12 years agoUncomment disabled code in QResourceEngine autotest.
Jason McDonald [Tue, 13 Mar 2012 07:06:09 +0000 (17:06 +1000)]
Uncomment disabled code in QResourceEngine autotest.

Resource files are expected to be readable.

Change-Id: Ife2b624e69b58e2fb996bc3e210a6e6c5c6852fe
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoTidy the QSettings autotest.
Jason McDonald [Tue, 13 Mar 2012 05:12:54 +0000 (15:12 +1000)]
Tidy the QSettings autotest.

- remove unnecessary includes
- remove undefined private functions
- remove commented-out test function
- fix indentation
- clarify why part of tst_QSettings::setValue() is commented-out

Change-Id: I09e1a33896536e702f7ba65f266415536b4f9e0b
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoRemove commented code from qtconcurrentmap autotest.
Jason McDonald [Tue, 13 Mar 2012 04:33:14 +0000 (14:33 +1000)]
Remove commented code from qtconcurrentmap autotest.

The removed code was already commented out when the test was added to
the Qt repository and does not compile when uncommented as it calls
non-existant overloads of QtConcurrent::FunctionWrapper1::operator().

Change-Id: I5a02efae4b89e2815b077474aa7cd0192dcb2730
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoRemoved invalid assert in BMP loader code.
Kim Motoyoshi Kalland [Tue, 13 Mar 2012 14:25:36 +0000 (15:25 +0100)]
Removed invalid assert in BMP loader code.

Task-number: QTBUG-24505

Change-Id: I2e369b6d92f072caadeda41125303856ddfabd48
Reviewed-by: aavit <qt_aavit@ovi.com>
12 years agoFix a Typo in evdevkeyboard.pro
Rick Stockton [Fri, 17 Feb 2012 06:23:27 +0000 (22:23 -0800)]
Fix a Typo in evdevkeyboard.pro

bad was: /qevdevkeybaord_defaultmap.h
good is: /qevdevkeyboard_defaultmap.h

Change-Id: Ic29bf94df0012e7ed3f05c0f258198d1b561d99a
Reviewed-by: Marius Storm-Olsen <marius.storm-olsen@nokia.com>
Reviewed-by: Johannes Zellner <johannes.zellner@nokia.com>