profile/ivi/qtbase.git
12 years agoAdd mkspecs for android cross compilation.
Robin Burchell [Tue, 1 May 2012 12:39:23 +0000 (14:39 +0200)]
Add mkspecs for android cross compilation.

Using these requires setting two environment variables, e.g, for me:

export ANDROID_NDK_ROOT=/Users/burchr/android-ndk-r7c
export ANDROID_NDK_HOST=darwin-x86
./configure -opensource -confirm-license -xplatform unsupported/linux-android-armeabi-v7a-g++ -nomake examples -nomake demos -nomake tests -v

These mkspecs are somewhat based on the work of the Necessitas crew, kudos to
them for their work in getting the NDK integration into qmake.

Change-Id: I591e423ed8dc70616009f681c81890c696110e62
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
12 years agoAdd framestrut mouse events.
Friedemann Kleint [Wed, 27 Jun 2012 14:20:18 +0000 (16:20 +0200)]
Add framestrut mouse events.

- Add infrastructure to QWindowSystemInterface.
- Add a setter for enabling framestrut events
  to QPlatformWindow.
- Add Windows implementation, pass keyboard modifiers.

QDockWidget relies on it for docking.

Task-number: QTBUG-26296
Change-Id: I9d84b356e9a5eb341f57b6f51f34b6b494ff7f87
Reviewed-by: Jørgen Lind <jorgen.lind@nokia.com>
12 years agoUpdate .gitignore
Giuseppe D'Angelo [Fri, 29 Jun 2012 12:23:08 +0000 (13:23 +0100)]
Update .gitignore

Change-Id: Iad041f3bc58544817b0a988875eed7b7973fa65b
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoQQnxWindow: properly scope a local variable
Marc Mutz [Fri, 29 Jun 2012 09:09:11 +0000 (11:09 +0200)]
QQnxWindow: properly scope a local variable

Change-Id: I71f1052f614f4e926acf2c2b76963770f7b35c96
Reviewed-by: Thomas McGuire <thomas.mcguire@kdab.com>
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
12 years agoFixed several unit tests to work in shadow builds
Kurt Korbatits [Fri, 29 Jun 2012 02:05:10 +0000 (12:05 +1000)]
Fixed several unit tests to work in shadow builds

- qlogging, qthreadstorage, qnetworkreply, qapplication, qfile, qprocess
  Added app_bundle and debug_and_release_target to CONFIG

Change-Id: I6212902c449520dc016da9590149a423069cc38c
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoAdd detection for C++11 noexcept
Thiago Macieira [Wed, 13 Jun 2012 13:23:12 +0000 (15:23 +0200)]
Add detection for C++11 noexcept

The Q_COMPILER_NOEXCEPT feature indicates whether this compiler has
support for noexcept. Note that the GCC C++11 status page does not
list this feature, but investigation into the source code as well as
testing reveals it's supported since GCC 4.6.

Also add Q_DECL_NOEXCEPT, to be used to declare that a function throws
no exceptions, and Q_DECL_NOEXCEPT_EXPR(x), which declares that the
function throws no exceptions if x evaluates to true. In C++98 mode,
these macros expand to empty -- the old C++98 and C++03 exception
specification is deprecated and considered harmful.

Change-Id: Ic84901d13eceb06dcc7f025a4b7fc8b250769be9
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoClean up the EXPORT macros in qglobal.h.
Thiago Macieira [Wed, 6 Jun 2012 18:04:41 +0000 (20:04 +0200)]
Clean up the EXPORT macros in qglobal.h.

QtPlatformSupport is a static library. It should never export
anything, so Q_PLATFORMSUPPORT_EXPORT is unnecessary.

QtSql, QtXml, QtDBus, QtOpenGL and QtPrintSupport now have the macros
on their own source trees. It's possible these modules might be
separated out from qtbase in the future. For QtDBus, the macros are
moving back to where they used to be. This also leaves qglobal.h only
creating the macros for QtCore, QtGui, QtWidgets and QtNetwork, the
core libraries.

Q_CANVAS_EXPORT, Q_OPENVG_EXPORT and Q_COMPAT_EXPORT aren't used
anywhere in the Qt sources, so simply delete them. And the
Q_QUICK1_EXPORT macro in the static section was wrong, so remove it
too.

Change-Id: I50bdf86e783338f814903b25979721f788a7becf
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agoRemove deprecated tentative commit from QInputMethodEvent
Pekka Vuorela [Tue, 26 Jun 2012 13:41:01 +0000 (16:41 +0300)]
Remove deprecated tentative commit from QInputMethodEvent

Introduced and deprecated during Qt5 development.
Change-Id: I5bceefcb5dfc13f8eae2ad22f04feeea5f87dcb3
Reviewed-by: Joona Petrell <joona.t.petrell@nokia.com>
12 years agoChange CONFIG += staticlib to CONFIG += static
Thiago Macieira [Tue, 29 May 2012 16:40:31 +0000 (18:40 +0200)]
Change CONFIG += staticlib to CONFIG += static

That's the targetted, correct way of defining a static library.

Change-Id: I43c23bf7e1bc5fb07bbb55720a320eaca680b038
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agoQNX: Don't detach when iterating over child windows
Thomas McGuire [Thu, 28 Jun 2012 09:44:47 +0000 (11:44 +0200)]
QNX: Don't detach when iterating over child windows

Change-Id: I55dcc1d188a2c45a11b0ab6a194625b50906eca9
Reviewed-by: Kevin Krammer <kevin.krammer@kdab.com>
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
12 years agoFix warning: returning non void by using Q_UNREACHABLE
Frederik Gladhorn [Thu, 28 Jun 2012 11:24:58 +0000 (13:24 +0200)]
Fix warning: returning non void by using Q_UNREACHABLE

Change-Id: I08e5b629582b1286c57f6c5f991e2adaf431daa4
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Mitch Curtis <mitch.curtis@nokia.com>
12 years agoMake QCalendarWidget use its locale's firstDayOfWeek.
Mitch Curtis [Thu, 21 Jun 2012 15:44:04 +0000 (17:44 +0200)]
Make QCalendarWidget use its locale's firstDayOfWeek.

QCalendarWidget currently uses Qt::Sunday as the default first day
of the week. It has been suggested that a better user experience
would see the calendar's locale be used instead.

Task-number: QTBUG-19811
Change-Id: I4441bf9ffd52213ef622a4a7f498530b7cc9e110
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Denis Dzyubenko <denis.dzyubenko@nokia.com>
12 years agoQDoc: Allow '0' to be used as 2nd arg for \qmlclass.
Casper van Donderen [Thu, 28 Jun 2012 10:49:06 +0000 (12:49 +0200)]
QDoc: Allow '0' to be used as 2nd arg for \qmlclass.

There can be occurences of \qmlclass where there is no C++ class (for a
pure QML Type for example). QDoc will ignore searching for a C++ class
when '0' is specified as second argument to the \qmlclass command.

Change-Id: I09c8c7ad302daffb0723a49967951ca623e646e4
Reviewed-by: Martin Smith <martin.smith@nokia.com>
12 years agoCall QObject::disconnectNotify() when receiver is destroyed
Kent Hansen [Mon, 25 Jun 2012 18:19:11 +0000 (20:19 +0200)]
Call QObject::disconnectNotify() when receiver is destroyed

Store the signal index in QObjectPrivate::Connection, thereby making
it available in "implicit" disconnect contexts (i.e., receiver
deletion).

This change does not cause the size of QObjectPrivate::Connection
to grow (still 40 bytes on 32-bit Linux, 72 bytes on 64-bit Mac).

Valgrinding the new benchmark indicates that the percentage of the
time spent in the QObject destructor increased from 7.8% to 8.4%
on ia32, for that particular stress test; the increase is the
combined cost of calling metaObject(), QMetaObjectPrivate::signal(),
and disconnectNotify() for one connection. In practice, the measured
wallclock time increased by about 3ms for a 500ms run (which
repeatedly constructs, connects, and destroys an object).

Task-number: QTBUG-4844

Change-Id: I1beb01c753f31542fc0acb62edb4c6d165fcc5b4
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
12 years agoBasic tablet support in xcb through XI2
Laszlo Agocs [Tue, 5 Jun 2012 13:04:02 +0000 (16:04 +0300)]
Basic tablet support in xcb through XI2

The Maemo-specific function have been renamed a bit to prevent them
clashing with the more generic stuff.

Task-number: QTBUG-25865

Change-Id: Id55693159e15d5a0c679546eb48308feb48acac9
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
12 years agoqdoc: Report multiple topic commands as an error
Martin Smith [Thu, 28 Jun 2012 08:46:59 +0000 (10:46 +0200)]
qdoc: Report multiple topic commands as an error

Some documenters are using two topic commands in a single qdoc
comment. This is only allowed for \qmlproperty so that multiple QML
properties can be documented with a single comment. qdoc now reports
an error for all other combinations of multiple topic commands.

Task Nr: QTBUG-26345

Change-Id: I1f9a6d2502ccffa76c2d41f961be3750014a0a56
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
12 years agoQNX: Make geometry changes sync to fix QWidget::showFullScreen()
Thomas McGuire [Thu, 28 Jun 2012 09:34:41 +0000 (11:34 +0200)]
QNX: Make geometry changes sync to fix QWidget::showFullScreen()

These can't happen async, as otherwise the geometry of the widget is
changed too late, having the effect that QWidget::show_sys() would
overwrite the window geometry again.

Change-Id: Id60d009867a5b282ac14c112c872af1075660732
Reviewed-by: Kevin Krammer <kevin.krammer@kdab.com>
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
12 years agoQMetaType: Fix warnings about truncation from uint64 to int.
Friedemann Kleint [Thu, 28 Jun 2012 09:32:35 +0000 (11:32 +0200)]
QMetaType: Fix warnings about truncation from uint64 to int.

Triggers warnings with MSVC2010/64bit.

Change-Id: I90abdf4de416e0db554eb46e4b3cc7a0a38cb1db
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
12 years agofix QWidget::showFullScreen on Windows
Joerg Bornemann [Tue, 26 Jun 2012 12:56:31 +0000 (14:56 +0200)]
fix QWidget::showFullScreen on Windows

When calling SetWindowPos in QWindowsWindow::setWindowState_sys we must
inform the QWidget about the new size we have set.

Task-number: QTBUG-26226

Change-Id: I42b01125f50a94cdb97026c74f5445f9ff47d8ba
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
12 years agoFix configure.exe to build qmake before tests
Rafael Roquetto [Thu, 14 Jun 2012 14:17:11 +0000 (16:17 +0200)]
Fix configure.exe to build qmake before tests

qmake is needed by autoDetection()/tryCompileProject() to be able to build the
tests. This patch also add a new method - generateQConfigCpp() - which
generates qconfig.cpp, needed to build qmake.

Change-Id: Ic304a364a13a2b3c28433f2a299df222a56fed67
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agoFurther fixes to widget masking
Miikka Heikkinen [Wed, 27 Jun 2012 14:15:42 +0000 (17:15 +0300)]
Further fixes to widget masking

If mask was set to a widget before the widget was shown,
the mask was not applied.

Also, if toplevel widgets were set a mask in Windows, the mask was
applied to frame coordinates instead of client coordinates.

Ported relevant code from Qt4 to fix these issues.

Change-Id: Id6187cf4952b81b5b60c167e2fd284b7dc83ed9c
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
12 years agoMove QPlatformInputContextPlugin/Factory to QtGui
Weng Xuetian [Sun, 24 Jun 2012 11:16:21 +0000 (19:16 +0800)]
Move QPlatformInputContextPlugin/Factory to QtGui

PlatformSupport is no longer shared and there should be no plugin
factory in it otherwise it will break plugin loading.

Since PlatformInputContext is already in QtGui, so move QPlatformInput-
ContextPlugin/Factory to resolve the platforminputcontexts plugin
loading problem. And remove platformsupport-private dependency from
existing inputcontexts plugin.

Change-Id: If4cb766470b8f9c8b72157da86cb33b4e1ff09e3
Reviewed-by: Pekka Vuorela <pekka.ta.vuorela@nokia.com>
12 years agoSet window's surface format to support alpha channel.
Gatis Paeglis [Tue, 26 Jun 2012 17:14:45 +0000 (19:14 +0200)]
Set window's surface format to support alpha channel.

Task-number: QTBUG-26114
Change-Id: I33f191373327832fb9d3054366412ec5be855cff
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
12 years agoMove the QDataStream operator<< for QPair to qdatastream.h
Thiago Macieira [Wed, 13 Jun 2012 19:26:20 +0000 (21:26 +0200)]
Move the QDataStream operator<< for QPair to qdatastream.h

QPair is small and is no problem to include from
qdatastream.h. However, including QDataStream from qpair.h means
including QIODevice and QObject too.

Change-Id: I344321e9f68438008ec329a165135c3a346c6058
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agoClean up the use of QT_NODLL
Thiago Macieira [Wed, 30 May 2012 11:03:56 +0000 (13:03 +0200)]
Clean up the use of QT_NODLL

QT_NODLL is replaced by QT_STATIC, but the latter is implied if
QT_BOOTSTRAPPED is already defined. Therefore, simply remove the
QT_NODLL definitions.

Change-Id: Iac7ec0b494b7a78197c25d59547f45eaf92d7465
Reviewed-by: Mark Brand <mabrand@mabrand.nl>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agoUpdate the macros for shared/DLL and static builds
Thiago Macieira [Wed, 30 May 2012 10:09:00 +0000 (12:09 +0200)]
Update the macros for shared/DLL and static builds

Up until now, we had a mess of different macros used for building
DLLs, for building shared libraries on Unix systems and for building
static libraries. Some of the macros were contradictory and did not
work. From now on, there shall be only:

 - QT_STATIC: indicates that it's a static Qt build and the export
   macros should expand to empty
 - QT_SHARED: indicates that it's a shared / dynamic Qt build and the
   export macros should expand to Q_DECL_EXPORT or Q_DECL_IMPORT,
   depending on whether the macro corresponds to the current module
   being built (the QT_BUILD_XXXX_LIB macro comes from the module's
   .pro file)

QT_BOOTSTRAPPED implies QT_STATIC since the bootstrapped tools link
statically to some source code.

QT_STATIC is recorded in qconfig.h by configure when Qt is configured
for static builds. Nothing is recorded for a shared / dynamic build,
so QT_SHARED is implied if nothing is defined. This allows for the
existence of a static_and_shared build: with nothing recorded,
defining QT_STATIC before qglobal.h causes the export macros to be
that of the static form. Linking to the static libraries is out of the
scope of this change (something for the buildsystem and linker to
figure out).

From this commit on, the proper way of declaring the export macros for
a module called QtFoo is:

    #ifndef QT_STATIC
    #  ifdef QT_BUILD_FOO_LIB
    #    define Q_FOO_EXPORT Q_DECL_EXPORT
    #  else
    #    define Q_FOO_EXPORT Q_DECL_IMPORT
    #  endif
    #else
    #  define Q_FOO_EXPORT
    #endif

The type of the Qt build is recorded in QT_CONFIG (in qconfig.pri) so
all Qt modules build by default the same type of library. The keywords
are "static" and "shared", used in both QT_CONFIG and CONFIG. The
previous keyword of "staticlib" is deprecated and should not be used.

Discussed-on: http://lists.qt-project.org/pipermail/development/2012-April/003172.html
Change-Id: I127896607794795b681c98d08467efd8af49bcf3
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoGet started with patching up the Qt GUI docs
Gunnar Sletta [Wed, 13 Jun 2012 19:45:44 +0000 (21:45 +0200)]
Get started with patching up the Qt GUI docs

Primary goal, make the front page of the Qt GUI module a bit more
clarifying and avoid downstream references inside the Qt GUI docs.

Change-Id: Icbcfbb64b93963add889bf83711daa9575885c02
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
12 years agoInclude QScopedPointer in qsettings.h
Thiago Macieira [Wed, 27 Jun 2012 15:32:01 +0000 (17:32 +0200)]
Include QScopedPointer in qsettings.h

qobject.h includes it, but only if QT_NO_QOBJECT isn't defined. It is
during the build of the bootstrapped tools.

Change-Id: I8fc921fb17c283358af263a6932b763a21209d40
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agodisabling largefile support for Win CE
Bjoern Breitmeyer [Wed, 27 Jun 2012 08:40:39 +0000 (10:40 +0200)]
disabling largefile support for Win CE

this was disabled before but
I2631ff687881278ba42edacd237a2130c103b69f
enabled it per default

Change-Id: Ic5a8e50d116cf6b15719668faf055967a6f34e06
Reviewed-by: Andreas Holzammer <andreas.holzammer@kdab.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agodoc: use correct snippet id for QObject::isSignalConnected
Kent Hansen [Wed, 27 Jun 2012 12:10:17 +0000 (14:10 +0200)]
doc: use correct snippet id for QObject::isSignalConnected

Copy-and-paste error; the doc was based on QObject::receivers.

Change-Id: I4f6ce716d388328e0345e8457cbc99fff323ce41
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agodoc: remove duplicate link
Kent Hansen [Wed, 27 Jun 2012 12:01:50 +0000 (14:01 +0200)]
doc: remove duplicate link

Since QStateMachine inherits QState, QStateMachine::finished() and
QState::finished() are the same thing.

Task-number: QTBUG-14553
Change-Id: I7df2f815be377c19aeee393e9a2ce124183dc5e1
Reviewed-by: Laszlo Papp <lpapp@kde.org>
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
12 years agodoc: add missing \sa tag
Kent Hansen [Wed, 27 Jun 2012 11:59:48 +0000 (13:59 +0200)]
doc: add missing \sa tag

Change-Id: I50580bfefdf556f116b7099946b047acd12d4563
Reviewed-by: Laszlo Papp <lpapp@kde.org>
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
12 years agoRemoved flags from SSPI calls which prevented the NTLM authentication from working
Adrian Carpenter [Wed, 27 Jun 2012 12:17:31 +0000 (13:17 +0100)]
Removed flags from SSPI calls which prevented the NTLM authentication from working

Change-Id: I87b085442ef301d9d92def0608a8baaa330522e6
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
12 years agoFixed qsslsocket_onDemandCertificates_{static,member}
Rohan McGovern [Wed, 27 Jun 2012 23:11:08 +0000 (09:11 +1000)]
Fixed qsslsocket_onDemandCertificates_{static,member}

This test had been XFAILing since August 2011, but recently started to
XPASS, possibly due to changes in the SSL setup on the tested host
(qt.nokia.com).

Removed QEXPECT_FAIL and replaced qt.nokia.com with
codereview.qt-project.org as a host expected to have working SSL.  (If
SSL on the latter were broken, it would immediately be detected by
any attempts at git over HTTPS.)

SSL setup can be verified as working by:

  openssl s_client -CApath /etc/ssl/certs \
    -connect codereview.qt-project.org:443 </dev/null

Task-number: QTBUG-20983
Change-Id: I9b4146da6545ab4115d6308044b1d242dd52b7f9
Reviewed-by: Kalle Lehtonen <kalle.ju.lehtonen@nokia.com>
12 years agoWidgets: Apply masks to native windows only.
Friedemann Kleint [Wed, 27 Jun 2012 12:02:00 +0000 (14:02 +0200)]
Widgets: Apply masks to native windows only.

Do not go searching for a parent window handle in
setMask_sys() as this causes for example MDI areas
to set masks that show the child only.
Fix breakage introduced by 8e280d1e187b09651c7036bd76272342d52ce401 .

Change-Id: I57de41d16985ebc8d3fc81153a671f2e2807b1eb
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
12 years agoQNX: Add support for window states
Thomas McGuire [Wed, 27 Jun 2012 08:38:13 +0000 (10:38 +0200)]
QNX: Add support for window states

Now QQuickView::showFullscreen() works as expected.
QQuickView has no fallback for platforms without window state support,
as opposed to QWidget.

Change-Id: I9c41fe563ea1f6d117eaebd3ea1db87465142b85
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
12 years agoQNX: Flush after changing rotation
Thomas McGuire [Wed, 27 Jun 2012 08:52:41 +0000 (10:52 +0200)]
QNX: Flush after changing rotation

This fixes a painting glitch where the window would stay in the old
position with the old rotation until it got repainted.

Change-Id: Id9de256b525760e8b32e55a87549efeccca151e0
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
Reviewed-by: Kevin Krammer <kevin.krammer@kdab.com>
12 years agoAlso use x11FilterEvent for auto repeat key in xcb.
Weng Xuetian [Tue, 26 Jun 2012 15:02:23 +0000 (23:02 +0800)]
Also use x11FilterEvent for auto repeat key in xcb.

filterEvent for QPlatformInputContext is already used for auto repeat
key, x11FilterEvent also need to be filtered.

Task-number: QTBUG-25795
Change-Id: I3db87fdffdb5b01404047e905793ae6e10bb1e90
Reviewed-by: Pekka Vuorela <pekka.ta.vuorela@nokia.com>
12 years agoAdd const & to foreach 'iterators'
Albert Astals Cid [Sat, 23 Jun 2012 09:06:43 +0000 (11:06 +0200)]
Add const & to foreach 'iterators'

Change-Id: I8c0600dfd919f45d14a0011f2da9b9fe0b9a0df3
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
12 years agoDocument that the object of a plugin must be default-constructible.
Stephen Kelly [Tue, 26 Jun 2012 14:11:06 +0000 (16:11 +0200)]
Document that the object of a plugin must be default-constructible.

Change-Id: Iaaf56ec3bb0d2423c8ab5deb0627dc1357cee830
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
12 years agoRefactor the creation of imported targets into a macro.
Stephen Kelly [Sun, 24 Jun 2012 17:28:43 +0000 (19:28 +0200)]
Refactor the creation of imported targets into a macro.

This will make it easier to handle cases where the Qt installation
and the build do not match exactly. For example, on Windows, it
would be possible to do:

  ./configure -debug
  make
  make install
  make release
  make release_install

In which case, both debug and release libraries would be installed
even though it was only configured with -debug. On non-Windows, the
debug and release libraries would overwrite each other, so it is
not necessary to support it.

Similarly, we want to handle cases in the future where (on
non-Windows) both static and shared libraries would be
installed (again, not described with a single build configuration).

Change-Id: Ib7916c9664a0f72e40156a03bdfc79a4a6c24350
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
12 years agoRemove .values() call in foreach
Albert Astals Cid [Sat, 23 Jun 2012 07:55:43 +0000 (09:55 +0200)]
Remove .values() call in foreach

foreach already knows how to iterate over the values without the need to create an intermediate qlist

Change-Id: I4622a36fbdbf536a75f26b42e32488a77d078f02
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
12 years agoRemove deprecated method from new class.
Thiago Macieira [Wed, 20 Jun 2012 16:56:22 +0000 (18:56 +0200)]
Remove deprecated method from new class.

I'm pretty sure I've caught all uses of deprecated methods throughout
the Qt codebase, except for the ItemViews changes and for QtWebKit
(which must still compile with Qt 4).

Change-Id: Ic17801b71434fa41c647f97c9e5e4234ad4f9af0
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
12 years agoRemove the extra warnings and -Werror from tst_qmimetype
Thiago Macieira [Mon, 25 Jun 2012 18:50:18 +0000 (20:50 +0200)]
Remove the extra warnings and -Werror from tst_qmimetype

Those belong in headersclean and nowhere else.

Change-Id: Ib7078ef3071266e4c03e3580068f978a9418cbf1
Reviewed-by: David Faure <faure@kde.org>
12 years agoAdd QPA prefix and version number to QPA plugin factory interfaces.
Friedemann Kleint [Mon, 25 Jun 2012 10:25:50 +0000 (12:25 +0200)]
Add QPA prefix and version number to QPA plugin factory interfaces.

The interfaces may change in Qt minor versions.

Change-Id: I43bc6245ddbba8232e00313bdc64e8e60c7eab6f
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
12 years agoFix raising and lowering native widgets
Miikka Heikkinen [Wed, 27 Jun 2012 08:01:11 +0000 (11:01 +0300)]
Fix raising and lowering native widgets

Raising or lowering a native widget needs to raise or lower the
associated platform window, too.

Task-number: QTBUG-26344
Change-Id: Ib847d97df86857d92bcc4c9c0dd51219575d8db1
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
12 years agoAdd QGuiApplication::setApplicationDisplayName.
David Faure [Sat, 23 Jun 2012 12:08:25 +0000 (14:08 +0200)]
Add QGuiApplication::setApplicationDisplayName.

This is for use in window titles.

Change-Id: I0070a08abd379ae2edcfab4413c182bd9e840678
Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
12 years agoAdd \since 5.0 to QDir::removeRecursively
Shane Kearns [Fri, 15 Jun 2012 12:53:10 +0000 (13:53 +0100)]
Add \since 5.0 to QDir::removeRecursively

Change-Id: I2392f26e666d5e01e71932f1afa48a65704f6d48
Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
12 years agoRemove debug output
ABBAPOH [Sun, 26 Feb 2012 11:00:44 +0000 (15:00 +0400)]
Remove debug output

Change-Id: I07270211ee6f0439dc7249c8946795a68025828f
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: David Faure <faure@kde.org>
12 years agoWorkaround to compile configureapp.cpp with MSVC2010 x64
jian liang [Mon, 25 Jun 2012 15:18:37 +0000 (23:18 +0800)]
Workaround to compile configureapp.cpp with MSVC2010 x64

Remove a non-ascii character from configureapp.cpp to let it to be
compiled successfully with MSVC2010 x64.

Change-Id: I0b016630be49e8731cc438abca4ef959124138be
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoRemove all references to XLFD fonts
Lars Knoll [Sun, 24 Jun 2012 22:18:10 +0000 (00:18 +0200)]
Remove all references to XLFD fonts

XLFD fonts are no longer supported in Qt 5.

Change-Id: I83400dab417c933d5cd956c0d168c45b9d79dab7
Reviewed-by: Casper van Donderen <casper.vandonderen@nokia.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
12 years agodon't compile the host tools for wince already in configure
Oswald Buddenhagen [Fri, 22 Jun 2012 17:52:41 +0000 (19:52 +0200)]
don't compile the host tools for wince already in configure

qmake can now produce proper mixed-target projects

Change-Id: I797f055f6e1487b9aefb75eee91d6c2cc4e6e56e
Reviewed-by: Andreas Holzammer <andreas.holzammer@kdab.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agoConvert QPA menus to use QIcon, and enable icons.
James Turner [Tue, 26 Jun 2012 13:43:20 +0000 (14:43 +0100)]
Convert QPA menus to use QIcon, and enable icons.

Icon support was disabled in QPA menus, now QIcon is in QtGui, convert the QPA interface, enable setting the icon in QMenu, and make the Cocoa implementation use it. (And fix a ref-counting leak if an icon is actually set)

Change-Id: Ica203bf6826b79d8beee58f39febc851b9633a66
Reviewed-by: Christoph Schleifenbaum <christoph.schleifenbaum@kdab.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
12 years agoImplement RFC6265 test suite
Shane Kearns [Fri, 8 Jun 2012 12:26:20 +0000 (13:26 +0100)]
Implement RFC6265 test suite

Tests against the test data from the IETF working group
https://github.com/abarth/http-state

The test data is in the parser.json file, imported from that repository
and with one patch applied to make the ordering0001 test case data match
the raw files which are used by their python test server.

Task-number: QTBUG-18920
Change-Id: I17c1a8d92aef2850907f009667c6574e4c8d0cdb
Reviewed-by: Richard J. Moore <rich@kde.org>
12 years agoQNetworkCookie - ignore unparsable expires attribute
Shane Kearns [Fri, 8 Jun 2012 16:49:54 +0000 (17:49 +0100)]
QNetworkCookie - ignore unparsable expires attribute

As required by RFC6265, if the date can't be parsed then the
attribute should be ignored but not the whole cookie.

Task-number: QTBUG-15794
Task-number: QTBUG-16798
Change-Id: I2ed2fbbaf2d00b194995349c24b174032a599703
Reviewed-by: Richard J. Moore <rich@kde.org>
12 years agoIgnore empty domain attribute in cookies
Shane Kearns [Fri, 8 Jun 2012 16:04:35 +0000 (17:04 +0100)]
Ignore empty domain attribute in cookies

As recommended by RFC6265.
This fixes the optional-domain0042 test case.

Task-number: QTBUG-15794
Change-Id: I6dd459797afcb52fa2a78437f8481f5abc6f3105
Reviewed-by: Richard J. Moore <rich@kde.org>
12 years agoUse RFC6265 rules for cookie path & path matching
Shane Kearns [Fri, 8 Jun 2012 13:56:11 +0000 (14:56 +0100)]
Use RFC6265 rules for cookie path & path matching

Url encoding of paths is no longer used. This matches the
current release behaviour of Firefox, Chrome and MSIE browsers.
RFC6265 does not allow this type of encoding.

This fixes remaining path test cases in the IETF test suite.
Currently the path0027 test is passed by Firefox but failed by
Chrome and MSIE, so there is a potential compatibility issue.
However it is a corner case with a malformed cookie.

Task-number: QTBUG-15794
Change-Id: I9b02bb5adc32d614f512d314d06f2c60894aa2b0
Reviewed-by: Richard J. Moore <rich@kde.org>
12 years agoQNetworkCookie: Use RFC6265 rules for parsing Set-Cookie
Shane Kearns [Fri, 8 Jun 2012 11:01:27 +0000 (12:01 +0100)]
QNetworkCookie: Use RFC6265 rules for parsing Set-Cookie

The ';' separator takes priority even inside a quoted string.
Quotation marks have no special meaning, they are not parsed and
regenerated anymore. This means it is not possible to include
the ';' character inside a cookie value.
Other characters are returned transparently, including [",\]

Task-number: QTBUG-15794
Task-number: QTBUG-26002
Task-number: QTBUG-11641
Change-Id: I4eefef5c6ac7753d5a21c226169e264578521fe9
Reviewed-by: Richard J. Moore <rich@kde.org>
12 years agoQNetworkCookie - use RFC6265 rules for max-age
Shane Kearns [Thu, 7 Jun 2012 14:41:39 +0000 (15:41 +0100)]
QNetworkCookie - use RFC6265 rules for max-age

If unparsable, ignore the max-age attribute but process the rest of
the cookie normally.
If max age <= 0, set expiration time to "earliest representable time"
To keep this a safe value for conversions, time_t of 0 is used.

This fixes cases 0019 and comma0005 in the test suite.
Due to this change, cookies may be sent after they should have expired
in case the max-age was malformed. Previously they would have been
discarded immediately, which is more likely to break web services.

Task-number: QTBUG-15794
Change-Id: I7882af8eb37db156785e4e358ca639e90c94f8d0
Reviewed-by: Richard J. Moore <rich@kde.org>
12 years agoQNetworkCookie - ignore unknown attributes
Shane Kearns [Thu, 7 Jun 2012 14:28:26 +0000 (15:28 +0100)]
QNetworkCookie - ignore unknown attributes

RFC6265 clarifies that unknown cookie attributes should be ignored,
including the version attribute which was defined by RFC2109 but
not used correctly in practice.

This fixes case 0008 in the test suite with minimal risk.

Task-number: QTBUG-15794
Change-Id: I6f15e8e5e2e5f1ed168fc733a5c84d606a452252
Reviewed-by: Richard J. Moore <rich@kde.org>
12 years agoqget test - fix null pointer dereference
Shane Kearns [Thu, 7 Jun 2012 14:26:29 +0000 (15:26 +0100)]
qget test - fix null pointer dereference

If the server sends a redirect with no body, the file is null

Change-Id: I49fd1d8a4cdd404497ebef4c7f3b478960776896
Reviewed-by: Richard J. Moore <rich@kde.org>
12 years agoChange invalid test case (two cookies separated by ,)
Shane Kearns [Fri, 8 Jun 2012 17:59:40 +0000 (18:59 +0100)]
Change invalid test case (two cookies separated by ,)

Two cookies in a single Set-Cookie header are no longer allowed.
Check that this header is parsed according to RFC6265 rules instead

Change-Id: Ice48bbe78a9886208f7d1186cf1d8c37f46f1252
Reviewed-by: Richard J. Moore <rich@kde.org>
12 years agoQNetworkRequest autotest: adapt to new cookie parsing (re. commas)
Peter Hartmann [Tue, 27 Sep 2011 11:59:17 +0000 (13:59 +0200)]
QNetworkRequest autotest: adapt to new cookie parsing (re. commas)

Cookies cannot be separated by commas anymore, but are separated by
new lines.
See "Remove support for multiple cookies in one Set-Cookie header to
follow RFC6265."

Reviewed-by: Martin Petersson
Task-number: QTBUG-21456
(cherry-picked from 5d809703aa2d2a08ae7e9610fd42025b081d3d0c)

Change-Id: If7d1b4e58399a5d678495af6ff280409ba220e86
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
12 years agoRemove support for multiple cookies in one Set-Cookie header to follow RFC6265.
Jocelyn Turcotte [Wed, 14 Sep 2011 14:12:10 +0000 (16:12 +0200)]
Remove support for multiple cookies in one Set-Cookie header to follow RFC6265.

This also allows cookie values to contain commas to increase compatibility like
most popular browsers do even though the RFC still reserves them for future uses.

Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
Task-number: QTBUG-21456
(cherry-picked from 8ba781b01e900148fec2e9d26485369b3295487f)

Change-Id: Ib09ab2411dddf7f99de1c0c31680428b7412fc7e
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
12 years agoAdd a method for querying window activation status from QPA.
Morten Johan Sorvig [Thu, 3 May 2012 20:15:38 +0000 (22:15 +0200)]
Add a method for querying window activation status from QPA.

Add QPlatformWindow::isActive(), where the platform
can do further isActive tests, and Windows implementation for it.

Change-Id: I1acfc44d3a4ab36a3aaee52fb7b5f5b40661095e
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
12 years agoFixed missing way of choosing EGL renderable type with QSurfaceFormat.
Samuel Rødal [Sat, 23 Jun 2012 15:24:37 +0000 (17:24 +0200)]
Fixed missing way of choosing EGL renderable type with QSurfaceFormat.

This has been long overdue, since EGL now lets you choose between
desktop and ES based OpenGL. We also add OpenVG for those who want to
use raw OpenVG with a QOpenGLContext. The underlying EGL API for using
OpenGL / OpenVG is the same, with eglMakeCurrent() and eglSwapBuffers().

Change-Id: Ib0146b3fde5fe632069ebf99e7712f496ee7ea4d
Reviewed-by: Gunnar Sletta <gunnar.sletta@nokia.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
12 years agoRemove some unused variables from QAccessibleWidgetPrivate
Jan-Arve Saether [Wed, 23 May 2012 08:11:58 +0000 (10:11 +0200)]
Remove some unused variables from QAccessibleWidgetPrivate

Change-Id: I22fd67d63131d48356023c26eb0689587ce96967
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@nokia.com>
12 years agoFix QCOMPARE for QIcon in QtGui
Giuseppe D'Angelo [Tue, 26 Jun 2012 18:18:07 +0000 (19:18 +0100)]
Fix QCOMPARE for QIcon in QtGui

There's no need of QtWidgets for using QCOMPARE on two QIcons, as
QIcon lives in QtGui.

Change-Id: I40c3d4aeb15fb95876449383d9e2dd1ad39aa5f9
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
12 years agoClarified documentation for QStandardItem::parent()
Markku Heikkila [Tue, 26 Jun 2012 10:05:17 +0000 (13:05 +0300)]
Clarified documentation for QStandardItem::parent()

Task-number: QTBUG-18785

Change-Id: I91ee8c3dc10c1484376a17e3f13794038d4a648f
Reviewed-by: Stephen Kelly <stephen.kelly@kdab.com>
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
12 years agoAdd QAbstractDeclarativeData::isSignalConnected hook
Kent Hansen [Fri, 15 Jun 2012 08:47:49 +0000 (10:47 +0200)]
Add QAbstractDeclarativeData::isSignalConnected hook

Similar to QAbstractDeclarative::receivers. This hook will allow
QObject::isSignalConnected(QMetaMethod) to return true when there are
QML-managed connections.

It's important that the hook is called from
QObjectPrivate::isSignalConnected(uint), since QML calls that
function.

Change-Id: I9c5e42f2b3e7f985af02905985a3a47101cdee05
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Michael Brasser <michael.brasser@nokia.com>
12 years agotst_qtextscriptengine: make it compilable under MSVC2010
Debao Zhang [Wed, 6 Jun 2012 06:44:56 +0000 (23:44 -0700)]
tst_qtextscriptengine: make it compilable under MSVC2010

Source files which contain UTF-8 literals can not be compiled
by MSVC with Chinese/Japanese locale.

Change-Id: I5daa2e45c5e1ceb86da91e72288c24018c49c0f6
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
12 years agoFix compilation for XCB-without-Xlib
Giuseppe D'Angelo [Tue, 26 Jun 2012 18:04:59 +0000 (19:04 +0100)]
Fix compilation for XCB-without-Xlib

Commit 6481218da13539529b87626a352a17f42c57be61 broke the build by
removing the #ifdef XCB_USE_XLIB guards, but forgetting to port
Button1 to the XCB equivalent.

Change-Id: I9102feceb4deb0135ce0df318e46b35d1134a0b9
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
12 years agomkspecs: Use the right variable name to find the qdevice.pri
Holger Hans Peter Freyther [Tue, 26 Jun 2012 17:59:44 +0000 (19:59 +0200)]
mkspecs: Use the right variable name to find the qdevice.pri

Commit 8b822825c5066957622194acf0fc267a6bf473fd introduced the
/get version but used the wrong variable name. Fix it by using
QT_HOST_DATA.

Change-Id: Ia4759b8c6ff2de9726f3aebae2f2f39c6644d4ec
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agoDon't try build devicediscovery if evdev is not available.
Robin Burchell [Fri, 22 Jun 2012 13:43:31 +0000 (15:43 +0200)]
Don't try build devicediscovery if evdev is not available.

Fixes build on Android.

Change-Id: I1e6af972e8c29dd4c38773985e8f201064c2164f
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
12 years agoFix QIODevice warning when running rcc.
Mitch Curtis [Mon, 11 Jun 2012 11:32:17 +0000 (13:32 +0200)]
Fix QIODevice warning when running rcc.

When opening a QFile on stdout, for example,
we must not call seek as it is a sequential device.
This has been flagged as a warning since commit Ie3a96d3a
and has resulted in spurious warnings being emitted.

In the case of opening a QFile in Append mode, QIODevice::open
already sets the position marker, so calling seek is redundant.
This is also true for the file engine's open function (called
through openExternalFile()), which also ensures the handle or
descriptor is repositioned appropriately.

Task-number: QTBUG-26104
Change-Id: I71040c399efe54e7538f54433368b432e959e08d
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
12 years agoclean up specdir()
Oswald Buddenhagen [Tue, 26 Jun 2012 13:32:17 +0000 (15:32 +0200)]
clean up specdir()

the only callers which used non-default arguments are gone now, so remove
the arguments entirely. this also enables us to re-enable result caching.

Change-Id: I62f76e17e531a4eeafddb9b29716ca0a0eb3dbea
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
12 years agofix -spec/-xspec argument re-assembly
Oswald Buddenhagen [Tue, 26 Jun 2012 13:29:35 +0000 (15:29 +0200)]
fix -spec/-xspec argument re-assembly

the specs in Option are now only fixifiable absolute paths if an actual
path was passed on the command line - otherwise these are just names,
and we should pass them on verbatim.

Change-Id: I5b3535dadf2d6b2b3116331e6636f6e363a5361f
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
12 years agoAdd missing subdirs (the new QUrl unit tests were not compiled and run)
David Faure [Sat, 23 Jun 2012 09:26:35 +0000 (11:26 +0200)]
Add missing subdirs (the new QUrl unit tests were not compiled and run)

Change-Id: I1b39d92b8a14d5aeca957180858e1980a534894b
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
12 years agoFix PCRE build under non-__GNUC__ compilers
Giuseppe D'Angelo [Thu, 21 Jun 2012 19:14:33 +0000 (21:14 +0200)]
Fix PCRE build under non-__GNUC__ compilers

PCRE's JIT has several paths that end in a #error under compilers that
don't #define __GNUC__.

This is because either
- those platforms were unavailable to PCRE devs so they were not tested;
- the #ifdef guards inline assembly fragments in GCC (AT&T) syntax;
- the #ifdef guards functions present f.i. in ARM's EABI and unavailable
  f.i. under WinCE.

This commit disables PCRE's JIT under ARM and MIPS unless __GCC__ is
defined. The MIPS #define from MSVC (_M_MRX000) is also dropped.

Change-Id: I59f959c321413845ffbdf1ac32740b400422e0ee
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Björn Breitmeyer <bjoern.breitmeyer@kdab.com>
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
Reviewed-by: Andreas Holzammer <andreas.holzammer@kdab.com>
12 years agoRemove toRect_normalized().
Robin Burchell [Sat, 23 Jun 2012 19:28:22 +0000 (21:28 +0200)]
Remove toRect_normalized().

Seems to have been unused since qt4's fde7475bcf9c10522a8170e6eb8fb9a8fadc21cd.

Change-Id: I7ec88fb4ca8c1ffda469a1c048b4fea17ff042bc
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
12 years agoFix warning when ibus is not available.
David Faure [Sat, 23 Jun 2012 20:50:14 +0000 (22:50 +0200)]
Fix warning when ibus is not available.

This is perfectly ok on a linux desktop, so no reason to abort when
setting QT_FATAL_WARNINGS.

Change-Id: I64ba987679195741631fb204af57ae3d283bb516
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
12 years agoQPlatformWindow: Add Window masks.
Friedemann Kleint [Mon, 25 Jun 2012 11:58:41 +0000 (13:58 +0200)]
QPlatformWindow: Add Window masks.

Add functionality for window masks to QPlatformWindow, which is
required to implement QWidget::setMask() in order to fix
the regression in functionality from Qt 4.8.

Change-Id: I2c2d5629f0b4c6d90e52595ad70b13559aab1f41
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
12 years agoMake QRegion not need to be friends with QVector
Thiago Macieira [Tue, 19 Jun 2012 15:36:10 +0000 (17:36 +0200)]
Make QRegion not need to be friends with QVector

This hack was introduced in Qt 4.5 and the intention was to resize
(hopefully, shrink) the QVector without causing it to reallocate
memory. We can accomplish the same by reserving the size: until we
clear() or squeeze(), the container will not free memory.

Change-Id: I03a09537a617be0ce865eefa043005e4051e8706
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
12 years agomake using testlib automatically "promote" all modules to -private
Oswald Buddenhagen [Mon, 25 Jun 2012 15:18:26 +0000 (17:18 +0200)]
make using testlib automatically "promote" all modules to -private

autotests often need private headers (especially with qpa headers now
being private) and have no compatibility requirements, so it makes sense
to just use the privates of requested modules.

this also suppresses the useless warning about using privates, in case
they are still explicitly specified.

Change-Id: I9e499bedcf6ef25777283ff1432cef7254e9093a
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
12 years agoignore mkspecs/modules-inst/
Oswald Buddenhagen [Sun, 24 Jun 2012 19:30:49 +0000 (21:30 +0200)]
ignore mkspecs/modules-inst/

only generated files in there

Change-Id: I6eb327fc686af08d46d343066420525bc2e0dde5
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoMake QGtkStyle build with QT_NO_FILEDIALOG
Sukhyun Kim [Wed, 20 Jun 2012 09:22:11 +0000 (18:22 +0900)]
Make QGtkStyle build with QT_NO_FILEDIALOG

Fix compilation failure with qconfig large

Change-Id: I8ae14f01879b94430dcbb5c85c61d14e922f6eb9
Reviewed-by: Lincoln Ramsay <lincoln.ramsay@nokia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agoFactorize the cmake test infrastructure to be reusable.
Stephen Kelly [Sat, 23 Jun 2012 07:48:19 +0000 (09:48 +0200)]
Factorize the cmake test infrastructure to be reusable.

This makes it easy to add cmake module tests for all modules.

Change-Id: I303bf7674ca6ae7a8544488f96e8e02afbaa6ff0
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoAvoid macro re-definition after 1838a6c2fb5e3b4368c871aa330d028b255b83af
Konstantin Ritt [Thu, 21 Jun 2012 20:33:07 +0000 (23:33 +0300)]
Avoid macro re-definition after 1838a6c2fb5e3b4368c871aa330d028b255b83af

Change-Id: I2631ff687881278ba42edacd237a2130c103b69f
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
12 years agoQIODevice: free memory when buffer is cleared
Martin Petersson [Mon, 11 Jun 2012 13:35:04 +0000 (15:35 +0200)]
QIODevice: free memory when buffer is cleared

The QIODevicePrivateLinearBuffer does not deallocate any data on
readAll or clear. This fix will change the buffer so that
data is deallocated on clear, readAll and when read emptied the
buffer.

This is needed for QAbstractSockets that don't have
readBufferMaxSize set, as the buffer will grow but never
decrease in size when you read from it.

Change-Id: Iab42e40182f9ebe0739c99b2d1e820ce287dc931
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agoQAbstractSocket: Enable readNotifier on read from buffer
Martin Petersson [Mon, 4 Jun 2012 14:34:13 +0000 (16:34 +0200)]
QAbstractSocket: Enable readNotifier on read from buffer

This is needed for the QSslSocket. When we read on that socket we will
only read from the QIODevice buffer to get the unencrypted data.
So when the readNotifier has been turned off on the plainsocket there
is nothing to trigger it to be turned on again.

This will add a readData with zero size when we have read everything
from the buffer. This is so that we get a call into the socket to
check if the readNotifier should be turned on again.

Change-Id: I3b63e33de007db823e964480903186eb1b8caac2
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years agoQtNetwork: remove double buffering on sockets
Martin Petersson [Wed, 30 May 2012 15:03:57 +0000 (17:03 +0200)]
QtNetwork: remove double buffering on sockets

Removes the readBuffer from the QAbstractSocket since data is already
buffered in the QIODevice.

Change-Id: I4e50b791fd2852455e526fa2c07089d4d3f0b2a4
Reviewed-by: Prasanth Ullattil <prasanth.ullattil@nokia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
12 years ago[QNX] Enable MT screen event handling on Blackberry
Rafael Roquetto [Wed, 20 Jun 2012 09:22:32 +0000 (11:22 +0200)]
[QNX] Enable MT screen event handling on Blackberry

Consuming incoming screen events through the BPS event
dispatcher on its current incarnation has proven to be
very inefficient since it cannot put up with the screen
event throughput. This patch enables the screen event
thread also for Q_OS_BLACKBERRY platforms, in addition
to stock QNX. This behavior can still be configured
through the project file, though.

Task-number: QTBUG-26177
Change-Id: I98a3b22549c9fbf0c16b5a8c39a55c1eaa6ec1f4
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
Reviewed-by: Kevin Krammer <kevin.krammer@kdab.com>
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
12 years agoFixed inputMethodQuery() for Qt::ImHints
Tasuku Suzuki [Mon, 21 May 2012 23:14:34 +0000 (08:14 +0900)]
Fixed inputMethodQuery() for Qt::ImHints

to return QWidget::inputMethodHints()

Change-Id: I46735c553e0cb4689cd0c53a69d07ed61ba56bf6
Reviewed-by: Joona Petrell <joona.t.petrell@nokia.com>
12 years agoQTBUG-26035: Remove positive sign from start of string
Tarja Sundqvist [Fri, 8 Jun 2012 08:33:41 +0000 (11:33 +0300)]
QTBUG-26035: Remove positive sign from start of string

Updated removeGroupSeparators(QLocalePrivate::CharBuff *num) so that it
removes also positive sign ('+') at the start of the string. Auto test
included.

Task-number: QTBUG-26035

Change-Id: I8e0e071d6c682d9192a8c6bb2f282510e21b3c48
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Denis Dzyubenko <denis.dzyubenko@nokia.com>
12 years agofix somewhat common edge case in $$shadowed()
Oswald Buddenhagen [Sun, 24 Jun 2012 15:22:23 +0000 (17:22 +0200)]
fix somewhat common edge case in $$shadowed()

if source and build dir are direct children of the common root and we
are shadowing the top-level source dir, there is of course no trailing
slash to match.

Change-Id: I8a34a6a72d16cb21d77d056e037235af9b32a008
Reviewed-by: Davide Pesavento <davidepesa@gmail.com>
Reviewed-by: Andreas Hartmetz <ahartmetz@gmail.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@nokia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agoUse valSeen since it results in unused warning otherwise
Girish Ramakrishnan [Wed, 20 Jun 2012 01:27:54 +0000 (18:27 -0700)]
Use valSeen since it results in unused warning otherwise

Change-Id: Iccfa4b895d9e50227efa1747ea20ce07ce70327e
Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
12 years agoDon't re-evaluate the lib location.
Stephen Kelly [Sat, 23 Jun 2012 14:31:48 +0000 (16:31 +0200)]
Don't re-evaluate the lib location.

Rely on the DESTDIR variable being set correctly by qt_module_config.

Change-Id: I1a166124024722ec5a189a7402b38646179aa890
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agoFix the DEFINITIONS for Qt modules.
Stephen Kelly [Sat, 23 Jun 2012 14:30:31 +0000 (16:30 +0200)]
Fix the DEFINITIONS for Qt modules.

As the DEFINITIONS to be used for QtAddOns is different to essential
modules, rely on the logic in qt_module_config setting this variable
correctly.

Change-Id: I64485ccd6df093216cac4a97fb1cfaac0122a218
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
12 years agoQGraphicsItem::setAcceptsHoverEvents is deprecated, replace it
Thiago Macieira [Mon, 25 Jun 2012 18:05:58 +0000 (20:05 +0200)]
QGraphicsItem::setAcceptsHoverEvents is deprecated, replace it

It is replaced by setAcceptHoverEvents (note the lack of s), even
though the original name made more sense -- "set (if this item)
accepts hover events".

Change-Id: Ia6137c0e37b0a5932836f1d08fb8fa436f736eed
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
12 years agoReplace the QGraphicsItem deprecated transforming functions
Thiago Macieira [Mon, 25 Jun 2012 17:44:44 +0000 (19:44 +0200)]
Replace the QGraphicsItem deprecated transforming functions

The scale(), rotate() and translate() functions are replaced with
QGraphicsItem::setTransform.

Change-Id: Icb81c71b1513c049e2fd607995ca3a868108ee30
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Andreas Aardal Hanssen <andrhans@cisco.com>