Commit Graph

7564 Commits

Author SHA1 Message Date
Mike FABIAN
e051819983 Pashto uses Arabic script and is written right to left
QLocale::textDirection() was missing Pashto as a
right to left language.

Change-Id: I1623abf711597a26f283a86708dc756696790b7d
Reviewed-by: Lars Knoll
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-06-02 12:26:31 +02:00
Girish Ramakrishnan
2a1b50d67c eglfs: Create mouse, keyboard and touch handlers by default
Prior to this change, input support for eglfs was loaded as plugins. With
this change, eglfs supports evdev based keyboard, mouse and touch input
out of the box.

The event dispatcher is created in the constructor because the evdev
code creates QSocketNotifiers in the constructor which requires an
event loop.

Change-Id: I4e08f4121b9381ee5b414d0886eae2b8a2925800
Reviewed-by: Johannes Zellner <johannes.zellner@nokia.com>
Reviewed-by: Romain Pokrzywka <romain.pokrzywka@kdab.com>
Reviewed-by: Donald Carr <donald.carr@nokia.com>
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
2012-06-02 10:25:31 +02:00
Corentin Jabot
6131b90953 Implement QXcbWindow::setWindowIcon
Change-Id: I1908cbef0c20d3725423b559f234bd6d3ddd4167
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
Reviewed-by: Uli Schlachter <psychon@znc.in>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2012-06-02 01:14:22 +02:00
Corentin Jabot
074224eca0 Implement QWidgetPrivate::setWindowIcon_sys()
* The widgets icon are correctly set, through the QPA plugins
 * Removing QTLWExtra::iconPixmap that was only used in some platforms
in Qt 4.7, so if that wariable is still needed somewhere, it sould be
declared in the concerned QPA plugins

Change-Id: I85f50726cce3578b66c09c327767111f09935075
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
2012-06-02 01:14:14 +02:00
Kent Hansen
42a6fb4090 Simplify the QObject::dumpObjectInfo() implementation
Use the new signal index-based API.

Change-Id: If44e02e71b718bca5c18c486ca9ab95f836cd0f1
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2012-06-01 20:34:31 +02:00
Kent Hansen
3057c4173b Simplify connectSlotsByName() implementation
Use the new signal index-based API.

Change-Id: I89263f5366726ef8213e45e5ab6575ebd6eab04a
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2012-06-01 20:34:31 +02:00
Oswald Buddenhagen
98c7afb8d6 avoid redundant tests
tryRun() already implies tryLink() and tryCompile(), so there is no
point in executing the stages separately ...

Change-Id: Id7321efaca474e8c5db2bc246ac26323d8a99e58
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-06-01 20:34:31 +02:00
Casper van Donderen
03fa5dfa27 QDoc: Don't put ditamaps in index file.
Change-Id: Id3ceb05d3c9c4424b767222850237755080b9879
Reviewed-by: Martin Smith <martin.smith@nokia.com>
2012-06-01 20:34:31 +02:00
Casper van Donderen
7739076849 QDoc: Do not put indexNodes in qt.ditamap.
Change-Id: I659a3a91aaa6da26f4f739428d79cccfab8ce076
Reviewed-by: Martin Smith <martin.smith@nokia.com>
2012-06-01 20:34:31 +02:00
Casper van Donderen
6c60fe20c2 QDoc: Use \page title with prev/next links in DITAXML.
Change-Id: I260998986752f5c8cc48279c04557c925af1cb14
Reviewed-by: Martin Smith <martin.smith@nokia.com>
2012-06-01 20:34:31 +02:00
Joerg Bornemann
6375cbf99a make syncqt work with MSys Perl and MSVC
The common root dir detection was broken, because
of an inconsistent root drive path style:
    <srcbase> = /c/dev/qt/5.0/qtbase
    <outbase> = C:/dev/qt/5.0/qtbase

Now we don't need ActivePerl anymore.
The Perl that comes with msysgit is enough.

After every Perl function call that returns a file path
we need to normalize it to bring it into a form that can
be used by
    - Perl functions that take a path as parameter,
    - C++ sources as include file path,
    - qmake's .pro files as include file path.

Task-number: QTBUG-25912
Change-Id: If1cf56cc7246a9d6535cd3867222f225d1617712
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-06-01 18:26:18 +02:00
John Layt
c8b1f7c859 QtPrintSupport - Cleanup QPrintDialog header
Move QUnixPrintWidget from the header to the UNIX implementation as
it is not used anywhere else and doesn't need to be exported.

Make the private slots only compile under UNIX, remove the Mac and Win
stubs for them as unneeded.

Add some documentation to the UNIX dialog

Change-Id: I8f30504285df877e17ac8eeace875f666f43d94d
Reviewed-by: Teemu Katajisto <teemu.katajisto@digia.com>
Reviewed-by: John Layt <jlayt@kde.org>
2012-06-01 18:26:18 +02:00
Rohan McGovern
9ae3ec470c configure: pass -D options through to configure tests
We already do this for -I and -L compiler flags, but not -D.
This caused configure tests to give incorrect results in some cases.

Task-number: QTBUG-25963
Task-number: QTQAINFRA-523
Change-Id: Ib270a1dc67759e36bc439e80ab8136a64c405d26
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
Reviewed-by: Donald Carr <donald.carr@nokia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-06-01 18:26:18 +02:00
Debao Zhang
a86efb543d Fix QApplicationPrivate::pickMouseReceiver() crash
When a widget associate with a QWidgetWindow received a mouse event, but
another widget which is not a child of the widget has grabbed the mouse, the
application will crash. As QWidget::mapFrom() only works when mapping from
parent to child.

This is the side effect of SHA: f6c107d799

Task-number: QTBUG-25985
Change-Id: If2e6289e02d6d67c215694f2217221c9c7a0af46
Reviewed-by: Miikka Heikkinen <miikka.heikkinen@digia.com>
Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
2012-06-01 18:26:18 +02:00
Laszlo Agocs
4f27960dd8 Dispatch tablet events to widgets
Plus remove some platform-specific tablet leftovers from Qt4.

Change-Id: I376abc38d1fe4c253d8803cf0ce007e2d6c298bf
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2012-06-01 18:26:18 +02:00
Rohan McGovern
79a025b88a Marked expected failures in tst_qtextlayout on Windows
Task-number: QTBUG-25924
Change-Id: I24a8ab6a695bf76f19e9082e1d8b11d8ec03fc4f
Reviewed-by: Toby Tomkins <toby.tomkins@nokia.com>
2012-06-01 16:12:03 +02:00
Kent Hansen
37db43f1c2 Add private API for working with meta-methods in signal index range
Internally, QObject and QMetaObject already leave out non-signal
methods when working with signals. This is possible because the
signals always come before other types of meta-method in the
meta-object data. Ignoring irrelevant methods is faster and can
save memory.

QMetaObject provides internal indexed-based connect() and
disconnect() functions. However, these functions currently take an
absolute method index as the signal specifier, instead of an
absolute _signal_ index. Hence, QMetaObject and friends must convert
from the method index range to the signal index range.

By providing an API that only considers signal indices, clients of
the index-based QMetaObject::connect()/disconnect() can provide the
proper signal index directly. Similarly, for the qtdeclarative
integration (QDeclarativeData hooks) the signal index can be passed
directly. This will eliminate most of the conversions back and forth
between signal index and method index, and some other redundant work
done by qtdeclarative's custom connection implementation.

There are some places where the behavior can't be changed; for
example,  QObject::senderSignalIndex() will still need to return an
index in the method range, since that function is public API.

Changing QMetaObject::connect()/disconnect() to take an index in
the signal range will be done in a separate commit; this commit is
only an enabler for porting existing usage of those functions to
the new behavior.

Change-Id: Icb475b6bbdccc74b4e7ee5bf72b944b47159cebd
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
2012-06-01 16:04:04 +02:00
Martin Petersson
4189d07c83 QtNetwork: handle raw deflate compressed data in Http.
For raw deflate compressed data with no zlib or gzip header
we need to call initInflate2 with -MAX_WBITS.

The first call to inflate will asume that the data has a header,
but if that call fails with a Z_DATA_ERROR we can try once more
with changed windowBits incase the data was raw compressed data
without a header.

Task-number: QTBUG-25513
Change-Id: Ib37c286c6da6d5395581717d0e76a0dbd5df289c
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
2012-06-01 15:57:18 +02:00
Jonathan Liu
d744b24fab QNetworkReply: Change abort() function into a slot
It is useful for abort() to be a slot for connecting cancel and timeout
signals.

Change-Id: Ib0146d66fffe3f57b683dfbce0863e378b8c076d
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
2012-06-01 15:47:10 +02:00
Laszlo Agocs
bb4e8e37d2 Add QEvdev prefix in evdevtouch and update readme
Now that the code is in platformsupport we need to avoid too generic
names so rename the classes a bit.

Change-Id: I7241aa1a3449be772de369ebd08df01e886dbfa3
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
2012-06-01 15:24:30 +02:00
Girish Ramakrishnan
5933205cfc eglfs: implement hardware cursor for the raspberry-pi
The cursor is rendered on a dispmanx layer and moved
around. This approach saves us from having to update the
underlying window each time the cursor moves.

Dispmanx layers cannot be moved to negative coords. As
a result, currently it is not possible to move to a
location less than the hostpot. A future commit will
fix this problem.

Change-Id: Ida5ee961d03a6929860c515e503482756a4913ed
Reviewed-by: Johannes Zellner <johannes.zellner@nokia.com>
Reviewed-by: Andy Nichols <andy.nichols@nokia.com>
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2012-06-01 15:22:49 +02:00
Shane Kearns
bae1613c4c QNAM - maintain a weak reference to the QNetworkSession
When handling signals from the session, a pointer is needed.
Also the QNetworkReplyImpl needs to access the manager's session.
So, the manager should have a strong and weak reference.
The strong reference is held during connection establishment.
The weak reference is held all the time, though it will become
null when the session is destroyed in idle.
The non static member function getNetworkSession() is used to
create strong references from the weak reference where required.

Task-number: ou1cimx#1004278
Change-Id: I4b5b36b1d996b98e659d993969006c61b4440c15
Reviewed-by: Martin Petersson <Martin.Petersson@nokia.com>
2012-06-01 15:19:42 +02:00
Shane Kearns
3580168c3e Track active network replies without qFindChildren
For bearer management to work correctly, we need to know when there
are no network replies active. Previously this was implemented
using qFindChildren, but that doesn't work when the user reparents
QNetworkReply.
QtWebkit does this (actually sets parent to 0).
Also the qFindChildren implementation was racy if multiple requests
were finished in parallel. Again, likely to be triggered by webkit
loading page elements.

Task-number: QTBUG-15812
Change-Id: I181a9ba6611c7c4b6fffa2d84fe4029d89e8f596
Reviewed-by: Martin Petersson <Martin.Petersson@nokia.com>
2012-06-01 15:19:33 +02:00
Jonas M. Gastal
5e9aebf0fc Socket FD are now of type qintptr.
This should've been done together with the bulk of other changes in:
bdce610022 and
bf7f170607

Task-number: QTBUG-19004
Change-Id: I6d95a29140c1de5e6800812add9d7882511b909a
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
2012-06-01 15:19:19 +02:00
Janne Anttila
6ddd8f6bd9 Put Windows NTLM stuff inside consistent preprocessor directives.
QNtlmWindowsHandles was placed inside Q_OS_WIN in some places and in
other places inside Q_OS_WIN32. It seems that Q_OS_WIN is correct
define everywhere.

In addition placed "InitSecurityInterfaceW" inside L macro to convert
argument to wide characters in WinCE. WinCE GetProcAddress takes
LPCWSTR instead of LPCSTR.

This fixes the QtNetwork build for WEC7, where Q_OS_WIN32 apparently
is not defined. Should it be defined, is another story...

Change-Id: Id309d20c46b66139e2cb2e62349067848d8ebb4e
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
2012-06-01 15:19:10 +02:00
Lars Knoll
79194978cd Fix a bug in the case conversion code
Chars that have a case conversion that converts
them into several characters can't be handled
by QChar::toUpper() etc and should get ignored. The code
didn't do that correctly.

Change-Id: I281d122e90bf49187b6449088d2fccef2ef75e86
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-06-01 13:11:50 +02:00
Kim Motoyoshi Kalland
524d47b3f5 Remove unused isGLWidget variable.
Change-Id: I9d1a0edfce3d13ed56916b7301098aa5fbe0bc40
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2012-06-01 13:06:56 +02:00
Kim Motoyoshi Kalland
8dd443034d Add method to set size of QOpenGLPaintDevice.
Change-Id: Iecc72c64dbb5f35ee41bdeb960bc759cd43b8bcb
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2012-06-01 13:06:24 +02:00
Thiago Macieira
5a447502b5 Fix the QVector build with C++11 initialiser lists
Initialiser lists were not tested before in the QVector rewrite, so
the older malloc call was left behind.

Also, std::initializer_list has const iterators returning const data
and broke the build in a few places where const qualifiers were
missing.

Change-Id: I3c04e58361989aa7438621cda63c7df457d7dad8
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
2012-06-01 12:27:37 +02:00
Thiago Macieira
9c5a77f0ef Make QVector compile with QT_STRICT_ITERATORS again
Move the iterator classes into QArrayTypedData and add constBegin()
and constEnd() to that class.

I also had to add an operator T*() to the strict iterators, since
there are many places that expect the iterator to behave like a
pointer (including in QVector itself).

Change-Id: Icc5ed56ad47b013664a48eef9d31b5273aecb4e3
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
2012-06-01 12:27:32 +02:00
Kent Hansen
b60f6447d0 Avoid accessing QObjectPrivate::currentSender directly from QtDBus
In particular, currentSender->signal is about to be changed from
the method index range to the signal index range (i.e., excluding
non-signal methods). The public senderSignalIndex() function will
still return the index in the method range, so QtDBus will then
continue to work without change. If necessary, QtDBus can afterwards
be ported back to using the internal API again (including the new
QMetaObjectPrivate API for working with methods in the signal range).

Change-Id: I58212e859560a8e241adee99dd2da9ef009d4e5b
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2012-06-01 12:03:39 +02:00
Konstantin Ritt
cd95bcd7db Allow compare QLatin1String to QLatin1String
even if QT_NO_CAST_FROM_ASCII is defined.

Change-Id: I8c4deceedb6f3e3cd5bdf72d6e9d189c509c9ff3
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-06-01 03:16:17 +02:00
Konstantin Ritt
f19fbcf4e3 Add missing QT_NO_CAST_FROM_ASCII
to QLatin1String's compare operators that takes const char *s or QByteArray.
Such comparison leads to a potential misuse since QByteArray could contain any arbitrary data
in any arbitrary encoding and QLatin1String is used to only contain strings in UTF-8 -
they are just a different beasts aimed for different purposes, and since QT_NO_CAST_*_ASCII
disallow indirect conversions and require the user to know what he's doing,
let's be consistent here too.

Change-Id: I9bf5f326495157db8a6af064d6154961b7861a7e
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-06-01 03:16:17 +02:00
Pino Toscano
72bd1c3228 Unconditionally enable Q_OF_ELF for any ELF platform
Just enable ELF stuff on any platform which uses ELF format, instead of a selected subsets of those.

Change-Id: I0753c020c718bc67b4b50c3957fe8dc10afd2c61
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-06-01 03:16:14 +02:00
Rohan McGovern
9469e9fdeb Make tst_qabstractnetworkcache parallel-safe
Use a unique QTemporaryDir instead of a fixed path for the test cache.

Change-Id: Ib664033a509a6cefd7c323708f80ef595b202178
Reviewed-by: Kalle Lehtonen <kalle.ju.lehtonen@nokia.com>
2012-06-01 03:16:11 +02:00
Stephen Kelly
55d0c6c6cf Add clear() to QPointer for QWeakPointer compatibility.
Change-Id: I9efc162bf56775c7ebcff4e3b79a997edc4ceaeb
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-06-01 03:16:08 +02:00
Jiang Jiang
28dd6eda7b Make font fallback list for common script locale aware
Even in common script we may need to have a preferred font list
(which font should be used for CJK codepoints, Chinese, Japanese
or Korean? Since the codepoints they cover may overlap.) Adding
current default language into the pattern in that case will give
a better recommendation for the fallback list if the system have
configuration files like that.

Change-Id: Idbc7f7b0cf24108d6cc255a1add0b29b730588c0
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@nokia.com>
2012-06-01 03:16:08 +02:00
Konstantin Ritt
6615363e58 Fix some gcc warnings
These are:
"enumeral and non-enumeral type in conditional expression",
"comparison of unsigned expression >= 0 is always true",
and "address requested for 't', which is declared 'register'"

Change-Id: Ia9bab2e1e2c212a2889197e8dd5f7295dda9dadd
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-06-01 03:16:04 +02:00
Rohan McGovern
8eed0ce930 Mark tst_qfreelist as parallel-safe
This autotest appears to be parallel-safe.

Change-Id: I12f9202633941e9339de0709353efb2b41df4fa1
Reviewed-by: Kalle Lehtonen <kalle.ju.lehtonen@nokia.com>
2012-06-01 03:16:04 +02:00
Rohan McGovern
26ea987a66 Fixed compile on Windows without precompiled headers
Added missing header.

Compile failure is only reproducible when precompiled headers are
disabled.

Change-Id: I0fb2e51b3352ebad3b7b5b58898347605b8d5090
Reviewed-by: Toby Tomkins <toby.tomkins@nokia.com>
Reviewed-by: Kalle Lehtonen <kalle.ju.lehtonen@nokia.com>
2012-06-01 03:16:01 +02:00
Morten Johan Sorvig
ad33f3639c Fix QFileDialog crash on show with the GTK style.
Call createWinId on modal_widget to make sure
it has a valid QWindow.

Change-Id: Ieaec2bcaceb2ac28032cb42e5f8bcaf7a33828ca
Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
2012-06-01 03:15:58 +02:00
Donald Carr
698e5b376d Remove all references to X11 session management
There is no session management currently implemented for the xcb QPA
backend. Update the build system to reflect this.

Change-Id: I3486de5741f1fb7e09330ca142b8235a84d3b91d
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
2012-06-01 03:15:55 +02:00
Laszlo Agocs
22ef98c0b1 Migrate tslib to new plugin format
Also rename the binary and avoid crashes when tslib initialization
fails.

Change-Id: Ia7ccf7c997e1b1484bd475626ca16c9a9642466e
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
2012-06-01 03:15:52 +02:00
Donald Carr
dacc3f2852 set OUTDIR for consistency with config.test
We depend on this being set correctly set in device_config.prf

Change-Id: Iee69c5ce35af26f9ecd6edacdd70e13ae4a9aa90
Reviewed-by: Girish Ramakrishnan <girish.1.ramakrishnan@nokia.com>
2012-06-01 03:15:50 +02:00
Friedemann Kleint
cd91f1cc10 Get rid of MSVC compiler warnings from QVector code
Change-Id: I39b849721f3ba790c4a9197d69ac48e98cc2f5bd
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@nokia.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
2012-06-01 03:15:46 +02:00
Jędrzej Nowacki
7b737b172d Remove debugging code from QVector
It was depending on internals of Q_ASSERT

Change-Id: I3dfc0ae0438135a30961f36808dbfc3e663a5538
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2012-06-01 01:22:10 +02:00
Chris Adams
fbee9834dc Fix crash in QStringBuilder when concatenating data-less QLatin1String
Previously, the append functions in QConcatenable in the QStringBuilder
dereferenced the data() pointer of the argument QLatin1String without
performing null check.

Change-Id: I629f19fbce3113f1f80f4272fa7ae34e1dbc6bee
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2012-06-01 01:22:06 +02:00
Kent Hansen
1e778ebd06 Move implementation of QObject::senderSignalIndex() to QObjectPrivate
In preparation of changing the implementation to return an index in
the signals-only range, not all-methods range.

Change-Id: Ib743a4bc9da27ad776ade262b215ebf988e7ab28
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2012-06-01 01:21:43 +02:00
Kent Hansen
87d7545cd0 Fix To-Do in qstatemachine (use QObject::senderSignalIndex())
Change-Id: Id8a541878918f27a34595ff297d0f41b79275a96
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2012-06-01 01:21:40 +02:00
Girish Ramakrishnan
3aac6768f8 Move evdev to platformsupport
Also wraps various string literals with QLatin1String.

Change-Id: Ia0681bfae00006d9e9ad51f05d0e0d0f45cf2cec
Reviewed-by: Laszlo Agocs <laszlo.p.agocs@nokia.com>
Reviewed-by: Donald Carr <donald.carr@nokia.com>
2012-06-01 01:21:24 +02:00