qt:qt.git
9 years agoOn Symbian, use 16bit OpenGL if not enough GPU memory for 32bit 4.8.0-symbian
Murray Read [Fri, 4 May 2012 15:06:30 +0000 (16:06 +0100)]
On Symbian, use 16bit OpenGL if not enough GPU memory for 32bit

Using 32-bit config on Symbian only when the low-memory GPU is not used.
Otherwise apps that did run with this GPU and Qt 4.7, will not run with
Qt 4.8.

This is a follow up to 54613aec3bdac668d198923814873a9e622ad675

Task-number: ou1cimx1#997217
Change-Id: I945f10c68b40baa10e60b412b03c650d129b1dae
Reviewed-by: Juha Kukkonen <ext-juha.kukkonen@nokia.com>
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
(cherry picked from commit b889b3c8e83a56526eae04289ab9b1608d268b2a)

9 years agoRR scheduler error handling for deleted active objects
Murray Read [Fri, 17 Feb 2012 13:53:49 +0000 (13:53 +0000)]
RR scheduler error handling for deleted active objects

We have discovered that the active object ConnectionStarter could
potentially leave after deleteing itself in RunL. If that were to
happen, QtRRActiveScheduler::RunMarkedIfReady would have crashed when
it asked the deleted active object to handle the error.

Some active object deletion detection has been added to
QtRRActiveScheduler::RunMarkedIfReady to protect against crashes.

The ConnectionStarter active object has been modified so that even if
it does leave, when running in CActiveScheduler, it still won't cause
a crash and will clean itself up correctly.

Task-number: ou1cimx1#979241
Change-Id: Iafa10b96bbd8bedfec82d6d546c7ffaf0557fd8b
Reviewed-by: Shane Kearns <ext-shane.2.kearns@nokia.com>
(cherry picked from commit 5641d4539e60a09e8b85e82605f902d78bbdeae9)
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
9 years agoQNam: try to read the last CRLF when chunked encoding is used.
Martin Petersson [Wed, 28 Mar 2012 14:12:43 +0000 (16:12 +0200)]
QNam: try to read the last CRLF when chunked encoding is used.

When chunked encoding is used we should try to read the last CRLF after
the last zero-lenght chunk, with chunk size coded as 0.

Task-number: QTBUG-19480
Task-number: QTBUG-20924
Task-number: ou1cimx1#991682

Change-Id: I39c85f45c329246d6c53c29ba1511039b2503e13
Reviewed-by: Shane Kearns <shane.kearns@accenture.com>
(cherry picked from commit 2cfc2a2e9af97a2799e76868e4c6b302d55266e0)
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
9 years agoFix performance problem with NTLM auth in http POST
Shane Kearns [Thu, 22 Mar 2012 15:10:26 +0000 (15:10 +0000)]
Fix performance problem with NTLM auth in http POST

A combination of other fixes resulted in authentication credentials
with a blank username & password being incorrectly added to the
cache only for NTLM.
This caused authentication to be attempted with blank credentials
first (which would fail), before the authenticationRequired
signal was emitted.
It caused a performance issue because of the extra 2 requests to the
server (and possibly delays inserted by the server following a failed
login)

Task-number: ou1cimx1#985786
Change-Id: Ic588a20cfe7c24d5e60cd384caff0673a587e484
Reviewed-by: Martin Petersson <Martin.Petersson@nokia.com>
(cherry picked from commit 3c3ea9a869086ebb02a5d0c475754f6a184a50ab)
(cherry picked from commit 3e29d87844e1b6b0360ff05e38993567a85ac445)

9 years agoSymbian: drop OpenGL ES in non-supported hardware
Pasi Pentikainen [Wed, 21 Mar 2012 14:42:17 +0000 (16:42 +0200)]
Symbian: drop OpenGL ES in non-supported hardware

When hardware configuration has no OpenGL ES 2 support indicated, leave
OpenGL ES out of Qt compilation alltogether.

Task-number: ou1cimx1#987609
Change-Id: If43a8de059596fbdb52c97535436c441760c97ab
Reviewed-by: Gareth Stockwell <ext-gareth.stockwell@nokia.com>
Reviewed-by: Jani Hautakangas <jani.hautakangas@nokia.com>
(cherry picked from commit 327fa27f7d06d6328df2716eb7d78916fd0938cf)
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
9 years agoSymbian building: enable symbian platform autodetection
Pasi Pentikainen [Tue, 7 Feb 2012 15:30:37 +0000 (17:30 +0200)]
Symbian building: enable symbian platform autodetection

Enable Symbian platform autodetection to differentiate between platform
versions.

Change-Id: I9553d181952f011b162232cc8946d0dc0a64d92c
Reviewed-by: Juha Kukkonen <ext-juha.kukkonen@nokia.com>
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
(cherry picked from commit fb2b1d66ff503310f258f34ea667c1bf930b6c4e)

9 years agoOptimise QFile::seek that doesn't move the file pointer
Shane Kearns [Thu, 8 Mar 2012 11:45:05 +0000 (11:45 +0000)]
Optimise QFile::seek that doesn't move the file pointer

If the seek position matches the current file position, then
avoid doing an implicit flush that could be expensive.

Change-Id: I019858ffb36fe832b9aee8da0a7803cafc8f7f75
Reviewed-by: Jaakko Helanti <ext-jaakko.helanti@nokia.com>
Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
(cherry picked from commit a3a2ff59284840f1980197e3f6d06d99fcc0f512)
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
9 years agoSymbian: Support for apps on previous symbian release
Satyam Bandarapu [Mon, 27 Feb 2012 09:20:40 +0000 (11:20 +0200)]
Symbian: Support for apps on previous symbian release

Behaviour of API QKeyEvent::text is changed between Belle and
forthcoming releases in Symbian. This Fix is needed to support
the legacy Apps.

Task-number: ou1cimx1#978743
Change-Id: I87a9aa2e3d87cf61708196204dce00de4393011e
Reviewed-by: Murray Read <ext-murray.2.read@nokia.com>
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
9 years agoFix backspace on empty lines with custom QML editors
Aapo Haapanen [Fri, 24 Feb 2012 14:31:09 +0000 (16:31 +0200)]
Fix backspace on empty lines with custom QML editors

Symbian AknFEP doesn't return backspace keypresses to the editor if
the editor is empty. This causes problems for multiline editors,
because AknFEP can only see one line at a time. This issue has been
previously fixed by change a2709ef3f4410a1d1755e00353e6f969f8bb5613 so
that QCoeFepInputContext::DocumentLengthForFep returns lenght as 1
for empty lines. The fix was then refined by change
0ffd7fcc78e27f9184a6f1ee5a8a9cc5e6266998 so that the length is altered
only when the editor has multiple lines.

After the latest change, if a custom QML editor didn't have a lineCount
property, the code assumed it has only one line. This caused problems
for some custom multiline editors. This change alters the behaviour so
that if the code can't get the linecount from the editor, it assumes it
has multiple lines. This reverts the code to behave like before change
0ffd7fcc78e27f9184a6f1ee5a8a9cc5e6266998 for such custom QML editors.

Task-number: ou1cimx1#981078
Change-Id: I3551d1d3ca1984957465f894c8bc237544224468
Reviewed-by: Jaakko Helanti <ext-jaakko.helanti@nokia.com>
Reviewed-by: Murray Read <ext-murray.2.read@nokia.com>
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
(cherry picked from commit 708bbde16d74a1d4f51242002ac82999d0045f97)

9 years agoBuild break fix
Ari Lehtola [Mon, 13 Feb 2012 12:52:41 +0000 (14:52 +0200)]
Build break fix

Public SDK breaks because of missing definition of
GfxTransEffect in commit
Ia8d0544ec30741605efd6f7db035bcea2f36e67a
Symbian specific flag added

Task-Number: ou1cimx1#979239
Change-Id: I972bf207d7854be1bc77bba6ae4ef8155279b1b3
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
(cherry picked from commit 2d17086e3790953bb5a65e32c5e7ca5306ff67ea)

9 years agoAllowing symbian cleanup code in thread started and finished slots
Murray Read [Tue, 21 Feb 2012 16:13:10 +0000 (16:13 +0000)]
Allowing symbian cleanup code in thread started and finished slots

The run() function of QThread was inside a TRAP, but the started() and
finished() signals were emitted outside of a TRAP so could not contain
Symbian cleanup stack code. This broke compatability with some apps,
as the older pthread based implementation had the whole main thread
function running inside a TRAP.

The started and finished signals are now emitted inside TRAPs, with
enhanced leave/exception handling code.

Task-number: ou1cimx1#979704
Change-Id: I9b4e50b1085494b5fd5e05efa11739ce19ff26fb
Reviewed-by: Shane Kearns <ext-shane.2.kearns@nokia.com>
(cherry picked from commit e7320d22ec04c6d14a38b2bc4172d7c0823f88b5)
Reviewed-by: Murray Read <ext-murray.2.read@nokia.com>
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
9 years agoFix for Shazam crash
Murray Read [Thu, 16 Feb 2012 15:19:35 +0000 (15:19 +0000)]
Fix for Shazam crash

QtRRActiveScheduler::RunMarkedIfReady was setting a flag in active
objects after RunL(). Active objects potentially delete themselves in
RunL(), and so this flag setting potentially corrupts memory. The flag
is unnecessary, so has been removed. Other flags are renamed to make
their roles clearer.

Task-number: ou1cimx1#947013
Change-Id: I1391c31b33074ee9d7fd02410fdb879afc455842
Reviewed-by: Juha Kukkonen <ext-juha.kukkonen@nokia.com>
Reviewed-by: Shane Kearns <ext-shane.2.kearns@nokia.com>
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
9 years agoFixed CustomDashLine drawing bug.
Samuel Rødal [Mon, 6 Feb 2012 17:19:46 +0000 (18:19 +0100)]
Fixed CustomDashLine drawing bug.

The bug was caused by attempting to stroke an empty subpath. If there
have been no line-to's emitted we should not try to join the start and
end of that line segment.

Task-number: QTBUG-23248
Change-Id: I38b7e955ed6683f8fc25f9551e93b4f472c022bf
Reviewed-by: Kim M. Kalland <kim.kalland@nokia.com>
(cherry picked from commit 593947ba70188df3d33efe031fab2fd255faa8b9)
Reviewed-by: Samuel Rødal <samuel.rodal@nokia.com>
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
9 years agoFix progress bar values >100% when http upload is retried
Shane Kearns [Tue, 31 Jan 2012 17:14:22 +0000 (17:14 +0000)]
Fix progress bar values >100% when http upload is retried

If a http upload (PUT or POST) fails, the IO device is reset
and the upload is retried a second time.
Now we also reset the progress counter in the wrapper class
QNonContigiousByteDevice.
That way the progress bar goes back to 0% and stops at 100%
Previously if the 1st attempt failed at 20%, the progress values
would carry on from 20% and finish at 120%.

Task-number: ou1cimx1#970373
Task-number: QTBUG-23993
Change-Id: Ifc9963595113cf3001ed45f94f525e2305ad479b
Reviewed-by: Markus Goetz <markus@woboq.com>
Reviewed-by: Richard J. Moore <rich@kde.org>
(cherry picked from commit f5ddeeca80983ad7579e0b7ba116f0250debdfcd)
Reviewed-by: Shane Kearns <ext-shane.2.kearns@nokia.com>
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
9 years agoChecking for directory exists in failed QDir::mkpath on Symbian
Murray Read [Mon, 13 Feb 2012 16:33:22 +0000 (16:33 +0000)]
Checking for directory exists in failed QDir::mkpath on Symbian

QDir::mkpath should return true if the directory already exists. In the
new native Symbian implementation, RFs returns KErrPermission denied
when you try to access some data caged directories such as C:\private.
This was being interpreted as failure, as the code expected
KErrAlreadyExists for the case where the directory exists.

In this circumstance we now check if the directory already exists.

Task-number: ou1cimx1#974477
Change-Id: Ie476219bc963c23d3c7e1773ebded8ecf137fd3c
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
(cherry picked from commit cdd09cc4ebab4e95f7c1286f09cef17a2c9cedf4)

9 years agoFix crash in positionInLigature
Jiang Jiang [Fri, 16 Dec 2011 13:21:49 +0000 (14:21 +0100)]
Fix crash in positionInLigature

Check boundary of pos before accessing attributes.

Task-number: QTBUG-23104
Reviewed-by: Eskil
(cherry picked from commit 9851e6da855357d6c1c17e956ba628aa975f92ce)

Change-Id: I01615d997b01a8d8c10ac5e63380b4a0fe946147
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
Reviewed-by: Jiang Jiang <jiang.jiang@nokia.com>
9 years agoSymbian: Fix for VKB default language to English in RTL variant
Satyam Bandarapu [Fri, 10 Feb 2012 11:58:21 +0000 (13:58 +0200)]
Symbian: Fix for VKB default language to English in RTL variant

Currently VKB default language to English in RTL variant is supported
only for email characters and url characters only. Now changed to
available for all input methods if application sets the flag.

Task-number: ou1cimx1#961176
Change-Id: I86e351ea0b829cc4f7c8163863102f9680fd7f55
Reviewed-by: Murray Read <ext-murray.2.read@nokia.com>
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
(cherry picked from commit 0aa20342693a954edabdbd8387d57610d931c3b5)

9 years agoAvoiding early deleteLater in Symbian with better loopLevel tracking
Murray Read [Wed, 8 Feb 2012 14:16:27 +0000 (14:16 +0000)]
Avoiding early deleteLater in Symbian with better loopLevel tracking

There have been a number of app crashes where deleteLater has been
triggering too early, causing an object to be deleted before it has
been finished with. This was happening when deleteLater was issued
then Symbian's active scheduler loop was nested. Qt keeps track of
loop nesting level to implement deleteLater correctly, but it was
only tracking the event loop in processEvents and QEventLoop correctly.

The wakeup and timer active objects were assuming they were always
run from processEvents and its round robin active scheduler and were
adjusting the loop level to account for this. However if they happened
to run in another event loop, eg the active scheduler, the loop level
adjustment meant that it looked like the event loop was re-running at
the same level, which allowed deleteLater to act.

The fix is to mark active objects as being run from the RR scheduler,
then the wakeup and timer active objects can be tested to see which
type of scheduler they are actually running in. With this knowledge,
the correct loop level adjustment can be made, and deleteLater runs
at the correct time.

Task-number: ou1cimx1#947013
Change-Id: Id05cd63ad10e100ea807cc276844aaa36c614351
Reviewed-by: Gareth Stockwell <ext-gareth.stockwell@nokia.com>
Reviewed-by: Shane Kearns <ext-shane.2.kearns@nokia.com>
(cherry picked from commit a13b2a248e5091ddf21e3c5ac08c9ddf0b940b5b)
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
9 years agoSymbian: Fix for blank window after taping Editing options.
Satyam Bandarapu [Wed, 8 Feb 2012 09:25:10 +0000 (11:25 +0200)]
Symbian: Fix for blank window after taping Editing options.

This happens in FlightInfo app when menu is opened, editor lost focus
and Fep manager looks for focused editor to do ccpu related tasks.
It also has some partially regression from fix
a2709ef3f4410a1d1755e00353e6f969f8bb5613. The regression is fixed in
QCoeFepInputContext::DocumentLengthForFep by returning size to 1 only
for multiline editors with no text and multiple lines presented.
And also set focused editor to last focused editor when Menu
is opened.

Opening EditOptions shows blank window if virtual keyboard is never
open before. This is because 'm_lastFocusedEditor' is null and it
will set to last focused editor only when virtual keyboard open.
Fixed in QCoeFepInputContext::setFocusWidget by setting
'm_lastFocusedEditor' to current editor.

Above fixes causes other issue, Qt application 'actions' are never
added to optionsMenu. This happens because Qt Symbian implementation
assumes that default menu items are less than or equal to one, but
in Qt 4.8.0 CCPU adds one more default menu item (EditOptoins) to
OptionsMenu in addition to 'Writing language' menu item. Fixed by
setting NumberOfItemsInPane<=2 in QS60MainAppUi::DynInitMenuPaneL.

Task-number: ou1cimx1#965675
Change-Id: Idd35cbc746f06f1c64d003c0a32ef1b8f8bc3c89
Reviewed-by: Sami Merilä <sami.merila@nokia.com>
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
(cherry picked from commit 0ffd7fcc78e27f9184a6f1ee5a8a9cc5e6266998)

9 years agoFix for effects in Qt-applications startup
Ari Lehtola [Tue, 7 Feb 2012 12:58:10 +0000 (14:58 +0200)]
Fix for effects in Qt-applications startup

This is part of the solution for reducing flickering
in Qt-applications startup. Fix is effective together
with changes in platform effects framework.

Task-Number: ou1cimx1#951526
Change-Id: Ia8d0544ec30741605efd6f7db035bcea2f36e67a
Reviewed-by: Murray Read <ext-murray.2.read@nokia.com>
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
(cherry picked from commit fd97c5a83f2baf9186fea39f000492099cba7644)

9 years agoPrevent crashing on Symbian in case EGL surface creation fails.
Pauli Jarvinen [Fri, 3 Feb 2012 12:14:05 +0000 (14:14 +0200)]
Prevent crashing on Symbian in case EGL surface creation fails.

It is possible in environment with limited resources, that EGL
surface creation fails. When this happens, the QPainter doesn't
get properly activated, which in turn caused a crash later in
the drawing code.

Now, a check has been added into qapplication_s60.cpp to abort
window drawing immediately, if surface creation has failed. The
EGL surface is then tried to be recreated on the next time when
the window becomes visible, which usually allows the application
to recover.

In most cases, the crash happened in the function qDrawBorderPixmap,
which didn't check the validity of the QPaintEngine pointer before
accessing it. This method is analogous with the public methods of
the class QPainter where, on the other hand, availability of
QPaintEngine was always checked. To be in line, and to prevent
ptential crashes, a similar safety check and warning message have
now been added to method qDrawBorderPixmap.

Furthermore, a null-check was added to qwindowsurface_gl.cpp for the
QGLContext pointer. The same pointer was already previously
null-checked in the other branch of the same function, indicating
that the null-check is probably necessary.

Task-number: ou1cimx1#969923
Change-Id: I6d78be72b9c2308ef74b1119d8c8ec34ec015195
Reviewed-by: Jaakko Helanti <ext-jaakko.helanti@nokia.com>
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
(cherry picked from commit f0d703557322d1b536e72bbba8209f6a615f6dc1)

9 years agoFix Qt to use font with simplified chinese characters as default if needed
Marko Kenttala [Wed, 8 Feb 2012 13:35:47 +0000 (15:35 +0200)]
Fix Qt to use font with simplified chinese characters as default if needed

Qt defaulted to use a font with traditional chinese characters even if system
language was set as ELangPrcChinese. Fixed qfont_s60 to use a font with
simplified chinese characters in this case.

Task-Number: ou1cimx1#915614
Change-Id: I0258a95f6630b4fa07acc9340bb38fc67bea7b1d
Reviewed-by: Sami Merilä <sami.merila@nokia.com>
Reviewed-by: Murray Read <ext-murray.2.read@nokia.com>
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
(cherry picked from commit 0983a18a29903ecac6dc870ffbde519db1b65e20)

9 years agoChanges in Symbian CleanupStack use to allow dodgy app start
Murray Read [Mon, 6 Feb 2012 15:33:30 +0000 (15:33 +0000)]
Changes in Symbian CleanupStack use to allow dodgy app start

Some important apps were found to invoke Qt code using the Symbian
CleanupStack during static data initialization. This is not legal Qt
code, but due to the importance of maintaining compatability with these
apps, Qt has been modified to avoid the problem.

In one case by removing unnessary use of CleanupStack. In the other
by creating a temporary CleanupStack.

Task-number: ou1cimx1#960665
Change-Id: Iff631a638dceec10aa38add88ba93a63a831a574
Reviewed-by: Shane Kearns <ext-shane.2.kearns@nokia.com>
(cherry picked from commit f343fc7c0844fc33886f3e25d49e043062c06e7a)
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
9 years agoHandling adopted thread death with active timers on Symbian
Murray Read [Mon, 6 Feb 2012 11:33:07 +0000 (11:33 +0000)]
Handling adopted thread death with active timers on Symbian

Timers are thread local objects on Symbian. When the adopted thread
monitor tries to tidy up a thread, any existing qt timers will be
cleaned up. But that has to be done very carefully without touching the
underlying symbian timer objects.

Checks are added to make sure the Symbian timers are only touched in
the correct thread.

Task-number: ou1cimx1#960478
Change-Id: If16750b455aa576aa9f2d93657a3627d18060272
Reviewed-by: Shane Kearns <ext-shane.2.kearns@nokia.com>
(cherry picked from commit 4490850b9286d9b01fab9bc8900deb1598398f2e)
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
9 years agoFix height of some Thai characters
Marko Kenttala [Tue, 31 Jan 2012 11:19:02 +0000 (13:19 +0200)]
Fix height of some Thai characters

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

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

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

9 years agoFix pinch-zoom problem when application is deactivated
Jarkko T. Toivonen [Tue, 24 Jan 2012 13:12:07 +0000 (15:12 +0200)]
Fix pinch-zoom problem when application is deactivated

Deactivation can happen for example if some notification dialog opens
on top of the application. In this case the PinchFinished signal was not
emitted.

It is fixed so that when the QDeclarativePinchArea component receives
QEvent::WindowDeactivate event, the ongoing touch activity is cancelled,
which causes the pinch to finish. Also if QEvent::TouchUpdate event is
received without receiving QEvent::TouchBegin event first, the
QEvent::TouchUpdate event will not cause the updatePinch() method to be
called.

Task-number: ou1cimx1#948030
Change-Id: Ib8b9e1a022415be06f1a8e778b887418f32c75ef
Reviewed-by: Murray Read <ext-murray.2.read@nokia.com>
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
(cherry picked from commit e4073fdea521c4b6c36461b51fc16f818c502cc3)

9 years agoChange QUrl::toLocalFile to return path for relative urls
Aapo Haapanen [Thu, 26 Jan 2012 14:11:40 +0000 (16:11 +0200)]
Change QUrl::toLocalFile to return path for relative urls

This change reverts the behaviour of QUrl::toLocalFile to the state
it was before 4.8. After this change the function returns the path if
the url is relative. Before this change an empty QString was returned.
A relative url can refer to a local file, but that can't be determined
from the url alone. Thus, it makes sense to return the path for such
urls.

Added documentation to explain that the function works like this to
maintain backward compatability in 4.x, but the handling of relative
URLs will change in 5.0.

Task-number: QTBUG-19827
Change-Id: I8bb8f4603a5936c0359afc1b6ff98824fad6cbc9
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
(cherry picked from commit 182acb541a7b8ac0edca842fdc867751df723f50)
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
9 years agoPrevent data loss when an ssl socket is closed by remote
Shane Kearns [Mon, 30 Jan 2012 15:52:27 +0000 (15:52 +0000)]
Prevent data loss when an ssl socket is closed by remote

SSL context was destroyed on disconnect. This makes it impossible to
decrypt buffered encrypted data. So if there is encrypted data in the
receive buffers, then don't destroy the ssl context until the socket is
destroyed.

Task-Number: QTBUG-23607
Change-Id: I16a7b4fa006647ec73049c90cdbc72686696850f
Reviewed-by: Jonas Gastal <jgastal@profusion.mobi>
Reviewed-by: Richard J. Moore <rich@kde.org>
(cherry picked from commit c5aba0ac17ae6ed8f3847bd30325acdbd1ecaa80)
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
9 years agoqt demos and qt examples config in symbian package definition
Roy Mickos [Wed, 1 Feb 2012 10:02:30 +0000 (12:02 +0200)]
qt demos and qt examples config in symbian package definition

Symbian package definition has been changed so that the build filter
definition in package_definition.xml is identical. This allows them
to be built in a separate build phase.

Change-Id: Ie29f2358a6c6d796a32b78d9439ed899c43a49ad
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
(cherry picked from commit 9ad459913c8a277f3a6fbc7ee50937f126fe87ef)

9 years agoFix exception handling in Symbian event dispatcher
Murray Read [Thu, 26 Jan 2012 12:33:39 +0000 (12:33 +0000)]
Fix exception handling in Symbian event dispatcher

The Symbian event dispatcher handles exceptions from active objects
as well as leaves. But if the active object throws while it has
something pushed on the cleanup stack, the exception must be converted
to a leave for the cleanup to happen and the cleanup stack balance to
be maintained.

Task-number: ou1cimx1#970701
Change-Id: I6c8eed61cb1666e36eb4858a2c72ad0d8c6b0c8f
Reviewed-by: Shane Kearns <ext-shane.2.kearns@nokia.com>
(cherry picked from commit 8c5614dda55ed7b539e06a3846618df8255dd18c)
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
9 years agoFix exception handling testing on Symbian
Murray Read [Thu, 26 Jan 2012 12:31:35 +0000 (12:31 +0000)]
Fix exception handling testing on Symbian

The Symbian autotest tst_qmainexceptions has been upgraded to run on
hardware.

Task-number: ou1cimx1#970701
Change-Id: Ia96ebdafb92c986599032c59528ed8633e3bec6c
Reviewed-by: Murray Read <ext-murray.2.read@nokia.com>
Reviewed-by: Shane Kearns <ext-shane.2.kearns@nokia.com>
(cherry picked from commit dd36b63ccac0026ac0a22681052e88cff8258923)
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
9 years agoSymbian: fix qml file paths in building of demos
Pasi Pentikainen [Tue, 24 Jan 2012 09:16:29 +0000 (11:16 +0200)]
Symbian: fix qml file paths in building of demos

The location of included QML files in demos had changed at some point,
but the symbian specific QML deployment parts were not updated to
reflect the new locations, thus breaking compilation.

Change-Id: Id01a685ca1de75cf73d32170b9f404c6619da7f5
Reviewed-by: Shane Kearns <ext-shane.2.kearns@nokia.com>
(cherry picked from commit 3aef11802c5f4ca0f3bde121e1704594f775bc33)

9 years agoAdd a public API for releasing cached GPU resources on Symbian
Gareth Stockwell [Tue, 24 Jan 2012 11:42:55 +0000 (11:42 +0000)]
Add a public API for releasing cached GPU resources on Symbian

Task-number: ou1cimx1yyy964181

Change-Id: I2f24d1d0f988bfe029e24fd29d59e6421301b670
Reviewed-by: Jani Hautakangas <jani.hautakangas@nokia.com>
Reviewed-by: Shane Kearns <ext-shane.2.kearns@nokia.com>
(cherry picked from commit c6618ef6e6d1b6b7ca7b52bfcda0f1489cc79198)
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
9 years agoCatch exceptions inside QSymbianControl::Draw
Jaakko Helanti [Tue, 24 Jan 2012 14:37:44 +0000 (16:37 +0200)]
Catch exceptions inside QSymbianControl::Draw

Code added to catch C++ exceptions and Symbian leaves
inside QSymbianControl::Draw. This is a cosmetic fix
to remove CONE 6 crashes currently in Symbian port.
We'll still study the root cause of those crashes.

Task-number: ou1cimx1#952828
Change-Id: I7b62309dd205d3b5dbad3d5477b47451dd7ff397
Reviewed-by: Pauli Järvinen <ext-pauli.p.jarvinen@nokia.com>
Reviewed-by: Murray Read <ext-murray.2.read@nokia.com>
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
(cherry picked from commit b5a0aeb4b26e709e0b6c15b3b9d5fdf58f3db3dd)

9 years agoFix BC break with QAbstractFileEngine "mount points"
Shane Kearns [Tue, 17 Jan 2012 19:51:39 +0000 (19:51 +0000)]
Fix BC break with QAbstractFileEngine "mount points"

File system cached metadata can't be trusted when custom file engines
are in use, because the custom file engine may want to override the
metadata. (e.g. present an archive file as a directory)

Therefore, check if a file engine should be instantiated for each
result in QDirIterator. This is a fast check if no custom file engines
are registered.
When pushing a directory (using QDirIterator::SubDirectories) the
file engine needs to be instantiated also.

Task-number: QTBUG-23688
Task-number: ou1cimx1#965023
Change-Id: I0114c8df6258535553783a2486131c4194926649
Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
(cherry picked from commit 3864ad09d578210b52e5f58fca2ee8a1144f5be2)
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
10 years agoFix QAbstractFileEngine autotest failure on windows/symbian
Shane Kearns [Tue, 17 Jan 2012 19:15:23 +0000 (19:15 +0000)]
Fix QAbstractFileEngine autotest failure on windows/symbian

File size does not match when CRLF translation occurs.
Added .gitattributes file to fix this.

Change-Id: I86ab538d17534b51177486ef1c4626ec52f55c5b
Reviewed-by: João Abecasis <joao.abecasis@nokia.com>
(cherry picked from commit 4e7b29b6f4175c70e1aefad8216e80aae70f9099)
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
10 years agotests: allow unstable tests to be marked with CONFIG+=insignificant_test
Sergio Ahumada [Mon, 9 Jan 2012 11:04:40 +0000 (12:04 +0100)]
tests: allow unstable tests to be marked with CONFIG+=insignificant_test

Marking a test with CONFIG+=insignificant_test will cause the exit code
of the test to be discarded during `make check'. This is intended to be
used for tests which are valuable to run, but are known to be unstable
and are not feasible to immediately fix.

Task-number: QTQAINFRA-428
Change-Id: Idd45b04200182e3673195858ec08d31357dcdfaf
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
(cherry picked from commit 4c2d2b4cde3fef76056e528b87391f62acc8d928)
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
10 years agotests: eliminated usage of qttest_p4.prf [part 3]
Sergio Ahumada [Thu, 29 Dec 2011 10:00:37 +0000 (11:00 +0100)]
tests: eliminated usage of qttest_p4.prf [part 3]

qttest_p4.prf was added as a convenience for Qt's own autotests in Qt4.
It enables various crufty undocumented magic, of dubious value.
Stop using it, and explicitly enable the things from it which we want.

Change-Id: I65ba34a59db7aa15bc6304e690c825a4d6cd1037
Reviewed-by: Sergio Ahumada <sergio.ahumada@nokia.com>
(cherry picked from commit 6974cc0a9ea2911a9ffd097f05955c1ca73e184a)
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
10 years agotests: eliminated usage of qttest_p4.prf [part 2]
Sergio Ahumada [Wed, 28 Dec 2011 19:59:35 +0000 (20:59 +0100)]
tests: eliminated usage of qttest_p4.prf [part 2]

qttest_p4.prf was added as a convenience for Qt's own autotests in Qt4.
It enables various crufty undocumented magic, of dubious value.
Stop using it, and explicitly enable the things from it which we want.

Change-Id: I8a0bed9161ea9ac010ef3269f2e9baed7bbc2f41
Reviewed-by: Rohan McGovern
Reviewed-by: Sergio Ahumada <sergio.ahumada@nokia.com>
(cherry picked from commit 5991bc3b3b7c638592ec5e7060e467f4838201d8)
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
10 years agotests: allow unstable tests to be marked with CONFIG+=insignificant_test
Sergio Ahumada [Sat, 26 Nov 2011 20:08:42 +0000 (21:08 +0100)]
tests: allow unstable tests to be marked with CONFIG+=insignificant_test

Marking a test with CONFIG+=insignificant_test will cause the exit code
of the test to be discarded during `make check'.  This is intended to be
used for tests which are valuable to run, but are known to be unstable
and are not feasible to immediately fix.

Change-Id: Id7b2407d0a13c8de19a58badb78fa7c018c9b50a
Reviewed-by: Jo Asplin
(cherry picked from commit a8469f14c26b6db70b97578655b22e4b3ec93cfc)
Reviewed-by: Jo Asplin <jo.asplin@nokia.com>
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
10 years agotests: eliminated usage of qttest_p4.prf
Sergio Ahumada [Tue, 25 Oct 2011 01:26:19 +0000 (11:26 +1000)]
tests: eliminated usage of qttest_p4.prf

qttest_p4.prf was added as a convenience for Qt's own autotests in Qt4.
It enables various crufty undocumented magic, of dubious value.
Stop using it, and explicitly enable the things from it which we want.

Change-Id: If1f16810614f7965dc7d5bf680effed911bee114
Reviewed-by: Jason McDonald
(cherry picked from commit 45335cba963c41ab73d471ee1c18e37dd6b2a5b8)
Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
10 years agoselftests: eliminated usage of qttest_p4.prf
Sergio Ahumada [Tue, 6 Dec 2011 20:35:11 +0000 (21:35 +0100)]
selftests: eliminated usage of qttest_p4.prf

qttest_p4.prf was added as a convenience for Qt's own autotests in Qt4.
It enables various crufty undocumented magic, of dubious value.
Stop using it, and explicitly enable the things from it which we want.

Change-Id: Ib6f0a59fa54d1e002a05587362f95678c3b3fc26
Reviewed-by: Jason McDonald
(cherry picked from commit 81aa7f44143376b4d52fb4bcd2f0ae4158eae62e)
Reviewed-by: Jason McDonald <jason.mcdonald@nokia.com>
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
10 years agoSymbian: qmake: Fix emulator deployment destinations
Jaakko Helanti [Mon, 16 Jan 2012 10:48:39 +0000 (12:48 +0200)]
Symbian: qmake: Fix emulator deployment destinations

This fix affects how qmake generates "bld.inf" file.
Earlier, all emulator deployments went to
epoc32/winscw/c, which is the C-drive of the emulator.
However, emulator implementation expects often to find
deployments from epoc32/release/winscw/udeb/z, which is
the ROM drive of the emulator. For this reason many things,
including QML deployments, did not work in the emulator.
Now the fixed deployment is as follows:
- If pro-file deployment has no path value, it goes to
  emulator ROM drive.
- If pro-file deployment has path variable with no drive letter,
  it goes to emulator ROM drive.
- If pro-file deployment has path variable with drive letter,
  it goes to the given emulator drive.
- If pro-file deployment has path variable with '!' as drive letter,
  it goes to emulator C drive.
When making emulator ROM-drive deployment, two deployments
are made, one to udeb and one to urel emulator.

Task-number: ou1cimx1#954237
Change-Id: I62d3f5b479ee0c0c547e824bb45ae8c0a6484d87
Reviewed-by: Jaakko Helanti <ext-jaakko.helanti@nokia.com>
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
(cherry picked from commit bb5cba5dcc3f3453ccbfea2667adc3a12c4ba92b)

10 years agoRemove "Reviewed-By" from the commit template
Shane Kearns [Tue, 17 Jan 2012 19:20:55 +0000 (19:20 +0000)]
Remove "Reviewed-By" from the commit template

Reviewed-By lines are now added by gerrit code review, so they
are not required in the commit template as well

Change-Id: I1d19189968923ec498c7579c6054eb6b025e596d
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
(cherry picked from commit d558a2c85f61ad2c634531b06cfc75581e2e2e2b)
Reviewed-by: Shane Kearns <ext-shane.2.kearns@nokia.com>
10 years agoUsing samples=0 to turn multisampling off
mread [Tue, 10 Jan 2012 16:20:18 +0000 (16:20 +0000)]
Using samples=0 to turn multisampling off

Change 54613aec was using the value 1 for QGLFormat::samples when it
wanted multisampling off. But this was actually resulting in
multisampling being turned on. It should have been using 0, which it
now does.

Task-number: ou1cimx1#951223
Change-Id: Ie68367f083f7ab4bae4143a59996c71add3e5c06
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
(cherry picked from commit 0ce52668616eba11de6c8255ec5319db3405483a)
Reviewed-by: Juha Kukkonen
10 years agoFix for player application exit crash
Satyam Bandarapu [Fri, 13 Jan 2012 15:15:45 +0000 (17:15 +0200)]
Fix for player application exit crash

Crash is a regression from the commit
7cd29ef169b94b0182b4207b37715f7427e4e4d6.
The commit 7cd29ef169b94b0182b4207b37715f7427e4e4d6 creates two
fep contexts, another one is created while first one being created.
When application exit, other fep context is deleted
after coeEnv destroyed. Fep context destructor uses method from
coeEnv and when second fep Context deleted application crashes.
To fix the crash, flaged fep context creation while being created.

Change-Id: I3079179df2c3a59a0117d5de775116e06d7e3cff
Reviewed-by: Satyam Bandarapu <ext-satyam.bandarapu@nokia.com>
Reviewed-by: Murray Read <ext-murray.2.read@nokia.com>
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
(cherry picked from commit 8a2c25945e8458a0b8582ad0860d08e3572170f4)
Reviewed-by: Juha Kukkonen
10 years agoRecovering from draw failures after EGL surface creation failure
mread [Mon, 9 Jan 2012 15:04:18 +0000 (15:04 +0000)]
Recovering from draw failures after EGL surface creation failure

The Qt drawing system is not designed to handle failures in beginPaint
and endPaint. But the Symbian port is creating EGL contexts and surfaces
on demand in these functions. These can fail, eg in the defect reported
the app gets a visibile=true event for such a short period that it
fails to create the surface before it is invisible again. These failures
have to be coped with.

Brush image drawing is failing if the app is asked to draw
while in the background, because the EGL surface cannot be created.
After this, if the app comes to the foreground at the wrong time, the
failed drawing is shown on the screen as a flat colored area.

A failedToAlloc variable in the openvg paint engine was locking in this
failed drawing, so that it would never redraw. This is fixed by removing
all use of that variable.

Failed surface creation during a draw in response to a visibility
change event was also leaving the window backing store with bad content.
This is now cleared on a surface creation failure so that drawing
is retried when the next visibility change event arrives.

The retry mechanism for creating a surface on failure also
makes the problem circumstances more likely to occur and can block the
app unnecessarily. Now, instead of blocking for 1 second every time on
failed surface creation, it only blocks on the first failure in a
sequence thereby allowing other parts of the app to run freely while
it is in the background.

Task-number: ou1cimx1#951921
Change-Id: I1e27746957ff624b0d9a1cdc9b319d0a3477135d
Reviewed-by: Gareth Stockwell <gareth.stockwell@accenture.com>
Reviewed-by: Shane Kearns <ext-shane.2.kearns@nokia.com>
(cherry picked from commit 854e72538426b32f72acd6c6c76af04bc8b78994)
Reviewed-by: Juha Kukkonen
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
10 years agosymbian - fix lockup when a network session is opened from its error
Shane Kearns [Fri, 13 Jan 2012 13:20:46 +0000 (15:20 +0200)]
symbian - fix lockup when a network session is opened from its error

When QNetworkAccessManager::get is called from the slot connected to
QNetworkAccessManager::finished, this is equivalent to calling
QNetworkSession::open from the slot connected to QNetworkSession::error.

Close handles before emitting the error signal, instead of afterwards.
Otherwise the session start would be silently cancelled in the above
situation.

Task-number: ou1cimx1#960395
Change-Id: I48cb376722e0169721fd33614a0b9280c17bdd62
Reviewed-by: Murray Read <ext-murray.2.read@nokia.com>
Reviewed-by: Pasi Pentikäinen <ext-pasi.a.pentikainen@nokia.com>
(cherry picked from commit d46446044fd7c5aca86c63cacad2706718d457c5)
Reviewed-by: Juha Kukkonen
10 years agoMerge commit 'c5ddcb33' into 4.8.0-symbian
Pasi Pentikainen [Thu, 12 Jan 2012 20:41:28 +0000 (22:41 +0200)]
Merge commit 'c5ddcb33' into 4.8.0-symbian

* commit 'c5ddcb33':
  Fix http authentication to a different realm on the same server
  Fix race in http connection channel
  Don't fetch credentials from cache following a failed proxy authentication
  Handle plain socket write errors in SSL
  Fix for assertion failure
  Fix faulty logic in http connection pipelining
  Test case for QTBUG-22875
  QThreads on Symbian are named to allow them to be opened externally
  Symbian: Fix exporting and importing of some functions for autotests
  Symbian: Fix SRCDIR usage in qlayout autotest.
  Symbian: Fix qcssparser autotest
  Symbian: Fix qscriptextensionplugin autotest
  Fix missing part from commit dae052cb11c0018121f2c4028aed9db17769fd77
  Fix m_longTapDetector causing crash.
  Fix to incorrect ApplicationActivate event in QtOpenGL
  Symbian - Fix QFile::map with non page aligned offsets
  Symbian: fix tst_QMenuBar::task256322_highlight() regression
  Default to QDir::homePath() in Symbian native file dialogs
  Fix NTLM authentication with email address
  Fix null pointer dereference in NTLM authentication

Change-Id: Ie087fce22bb0c6605de308975eba483885708bb3

10 years agoFix http authentication to a different realm on the same server
Shane Kearns [Thu, 22 Dec 2011 14:08:17 +0000 (14:08 +0000)]
Fix http authentication to a different realm on the same server

This is a regression caused by the NTLMv2 authentication patch.
I have manually tested NTLMv2 authentication against MS IIS and reverting
these two lines does not break it.

Task-number: QT-5209
Change-Id: I64159cbe468e1a7f834f8726fd0c9d4ab4c54b38
Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
(cherry-picked from 4954f71648aa7f74a4cb8b1dd26470b5da44459e)

10 years agoFix race in http connection channel
Shane Kearns [Mon, 19 Dec 2011 15:35:52 +0000 (15:35 +0000)]
Fix race in http connection channel

When authentication is cancelled, close the channel instead of the
underlying socket.
The previous behaviour could result in further requests being sent
on the closed socket, which caused errors in case of https over a proxy.

Change-Id: I3dbfc164de4fb29a426c06acaac8f29b9da1d705
Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
(cherry picked from commit a7b99151f4445755c91d5227607d9ea2f785301f)

10 years agoDon't fetch credentials from cache following a failed proxy authentication
Shane Kearns [Thu, 15 Dec 2011 17:32:47 +0000 (17:32 +0000)]
Don't fetch credentials from cache following a failed proxy authentication

Add variable to QAuthenticatorPrivate for tracking failure
Track authentication success/failure in http proxy socket engine
Track authentication success/failure in http connection channel

Task-number: QTBUG-22875
Change-Id: Id5d39e839428271ad687e9da12fbbdea9c478f4f
Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
(cherry-picked from d24aad82896addce88f1ffb4040560e406acf083)

10 years agoHandle plain socket write errors in SSL
Shane Kearns [Mon, 19 Dec 2011 15:10:45 +0000 (15:10 +0000)]
Handle plain socket write errors in SSL

When an ssl socket is closed during connecting, and it is using a proxy
then it is possible for the plain socket to be in pending close state
when transmit() is called.
As errors were not handled, this caused the socket (and https request)
to "hang".
It now propagates the error from plain socket.

Change-Id: I6fb86815a2a63e197cea582f4b153e487543477c
Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
Reviewed-by: Richard J. Moore <rich@kde.org>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
(cherry picked from commit 2cc78885b0b7d08f965998d156945a077e56c1d8)

10 years agoFix for assertion failure
Shane Kearns [Thu, 15 Dec 2011 17:31:52 +0000 (17:31 +0000)]
Fix for assertion failure

Change-Id: I97b9ecc37e938a3050793fc746288243a1cb40b7
Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
(cherry picked from commit 96cda705dcbeb79429055c1acca91f149d318820)

10 years agoFix faulty logic in http connection pipelining
Shane Kearns [Thu, 22 Dec 2011 13:35:34 +0000 (13:35 +0000)]
Fix faulty logic in http connection pipelining

The code which prevents pipelining of requests when authentication is
in use had || where && should have been used.
Also check for blank user with a password.

Change-Id: Ic278cedd370c9d81377f49a0af43aef415cb49ad
Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
(cherry picked from commit 058fb94afff8a1a9989ab6d18dacc1fe43769fdb)

10 years agoTest case for QTBUG-22875
Shane Kearns [Tue, 13 Dec 2011 15:50:59 +0000 (15:50 +0000)]
Test case for QTBUG-22875

Test the authentication cache works properly with "cancelled dialogs"
or if the user enters username/password incorrectly.
Expected behaviour is based on web browsers:
If cancelled, current request fails, and prompt again the next time.
If wrong password is given, prompt again and retry the current request.
If bad credentials are in the cache, prompt again

Task-number: QTBUG-22875
Change-Id: Ic02ccac8dbeb3f2580ca4ffe47d0773982c4ab25
Reviewed-by: Peter Hartmann <peter.hartmann@nokia.com>
(cherry picked from 4be2430)

10 years agoQThreads on Symbian are named to allow them to be opened externally
mread [Wed, 4 Jan 2012 15:19:49 +0000 (15:19 +0000)]
QThreads on Symbian are named to allow them to be opened externally

The Qt 4.7 implementation of QThread on Symbian used libpthread. This
automatically generated a random name for a thread. The Qt 4.8
implmentation was leaving threads unnamed. This is a change in
behaviour, in that unnamed/anonymous threads cannot be opened outside
of the owning process. This was causing a bug in some client/server
situations.

The fix is to generate a name for the RThread underlying the QThread
as follows:

QThread object name + QThread object address + random number

Task-number: ou1cimx1#959586
Reviewed-by: Shane Kearns
10 years agoSymbian: Fix exporting and importing of some functions for autotests
Miikka Heikkinen [Wed, 21 Dec 2011 13:47:17 +0000 (15:47 +0200)]
Symbian: Fix exporting and importing of some functions for autotests

Symbian builds seem more strict about properly declaring exports than
other builds, so added proper exporting and importing to some
function declarations.

Task-number: ou1cimx1#957184
Reviewed-by: mread
10 years agoSymbian: Fix SRCDIR usage in qlayout autotest.
Miikka Heikkinen [Wed, 21 Dec 2011 10:24:39 +0000 (12:24 +0200)]
Symbian: Fix SRCDIR usage in qlayout autotest.

SRCDIR was not defined at all in Symbian builds.

Task-number: ou1cimx1#957098
Reviewed-by: mread
10 years agoSymbian: Fix qcssparser autotest
Miikka Heikkinen [Wed, 21 Dec 2011 09:51:19 +0000 (11:51 +0200)]
Symbian: Fix qcssparser autotest

No need to deploy "c:/windows/fonts/times.ttf" into Symbian devices,
as they already have that font by default. The code that loads this
file is only executed in WinCE, so it was never used in Symbian,
anyway.

Task-number: ou1cimx1#957049
Reviewed-by: mread
10 years agoSymbian: Fix qscriptextensionplugin autotest
Miikka Heikkinen [Wed, 21 Dec 2011 09:05:19 +0000 (11:05 +0200)]
Symbian: Fix qscriptextensionplugin autotest

- Linking of static library needed to be explicitly stated in Symbian.
- Plugin deployment was added.
- Had to rename the simpleplugin in Symbian builds as the name
  was too generic and was causing conflict in /sys/bin.

Task-number: ou1cimx1#956851
Reviewed-by: mread
10 years agoFix missing part from commit dae052cb11c0018121f2c4028aed9db17769fd77
Jani Hautakangas [Mon, 19 Dec 2011 18:10:26 +0000 (20:10 +0200)]
Fix missing part from commit dae052cb11c0018121f2c4028aed9db17769fd77

Forgot to amend commit before pushing, sorry.

Task-number: QTBUG-23252
Reviewed-by: TRUSTME
10 years agoFix m_longTapDetector causing crash.
Jani Hautakangas [Mon, 19 Dec 2011 11:36:56 +0000 (13:36 +0200)]
Fix m_longTapDetector causing crash.

GL shared widget calls null poiter m_longTapDetector.
These call shouldn't happen because GL shared widget
isn't part of UI stack anymore. This patch adds null
pointer checks

Task-number: QTBUG-23252
Reviewed-by: TRUSTME
10 years agoFix to incorrect ApplicationActivate event in QtOpenGL
Jani Hautakangas [Fri, 16 Dec 2011 09:08:46 +0000 (11:08 +0200)]
Fix to incorrect ApplicationActivate event in QtOpenGL

QEvent::ApplicationActivate is sent incorrectly when application
goes to background if OpenGL graphics system is used. The problem
is that hidden global shared QGLWidget used by QtOpenGL for root
context is added to CONE stack. Qt destroys shared GL widget
when application goes to background and underlying CCoeControl
is removed from CONE stack which causes CONE to handle
stack changes. CONE tries to focus next control in stack which
causes incorrect focus events in Qt leading to
ApplicationActivate event. GL global share widget must not
be added to CONE stack because it's hidden utility widget
and don't belong to UI widget stack.

Task-number: QTBUG-23195
Task-number: ou1cimx1#946477

Reviewed-by: Murray Read
10 years agoSymbian - Fix QFile::map with non page aligned offsets
Shane Kearns [Thu, 15 Dec 2011 13:29:30 +0000 (13:29 +0000)]
Symbian - Fix QFile::map with non page aligned offsets

Although it is not documented, RFileMap native API requires the offset
into the file to be a multiple of the page size.
Round down the offset requested by the user to the page size.
Add back the difference before returning the base address to the user.

e.g. if the offset passed to QFile::map was 5000:
The offset passed to RFileMap will be 4096
The address returned to the user will be the RFileMap::Base() + 904

The modified address is used to key the hash of file mappings, so that
QFile::unmap() can be passed the modified address without needing changes.

Reviewed-by: mread
Task-number: ou1cimx#953054

10 years agoSymbian: fix tst_QMenuBar::task256322_highlight() regression
Satyam Bandarapu [Thu, 15 Dec 2011 09:15:15 +0000 (11:15 +0200)]
Symbian: fix tst_QMenuBar::task256322_highlight() regression

This fixes Symbian-only regression caused by
ab0a2466d7e3998caad226197355b729f523764a.

Reviewed-by: Miikka Heikkinen
10 years agoDefault to QDir::homePath() in Symbian native file dialogs
Gareth Stockwell [Tue, 13 Dec 2011 12:24:14 +0000 (12:24 +0000)]
Default to QDir::homePath() in Symbian native file dialogs

Symbian places restrictions on the directories in which the native file
dialog can browse.  If the path passed to QFileDialog::getXxxFileName()
is inaccessible, the implementation defaults to a path which is
accessible.

Previously, this default path was QDir::rootPath().  Changes to the
Symbian file engine in Qt 4.8 mean that this now returns "C:\" which is
inaccesible to the file dialog.  This patch changes the default path to
QDir::homePath(), which returns "C:\data".

Task-number: ou1cimx1#947939
Reviewed-by: Miikka Heikkinen
10 years agoMerge branch 'master' of scm.dev.nokia.troll.no:qt/qt-symbian-staging into master...
Qt Continuous Integration System [Mon, 12 Dec 2011 21:56:05 +0000 (07:56 +1000)]
Merge branch 'master' of scm.dev.nokia.troll.no:qt/qt-symbian-staging into master-integration

* 'master' of scm.dev.nokia.troll.no:qt/qt-symbian-staging:
  Revert "Fix memory leaks in OpenVG and OpenGL resource pools"

10 years agoFix NTLM authentication with email address
Shane Kearns [Fri, 9 Dec 2011 12:06:04 +0000 (12:06 +0000)]
Fix NTLM authentication with email address

When using "user@dns-domain" for NTLM authentication, the whole string
should be sent as the username, and the domain should be set to an
empty string.
The domain sent by the server is still reflected if the username
does not contain an '@' character.

Manually tested using MS IIS on a domain-joined PC.

Task-number: QTBUG-19894
Task-number: ou1cimx1#949951
Change-Id: Ie1f81172e71cb7cce7b8c909062be990c24aea47
Reviewed-by: Martin Petersson <Martin.Petersson@nokia.com>
(cherry picked from commit f74ff46c7a333d771b07d8ff38df10d9fd13bbcf)

10 years agoFix null pointer dereference in NTLM authentication
Shane Kearns [Fri, 9 Dec 2011 11:49:50 +0000 (11:49 +0000)]
Fix null pointer dereference in NTLM authentication

If NTLM authentication is required for the URL with an empty path,
then QNetworkAuthenticationCache::findClosestMatch(url.path()) returns 0.
e.g. "http://10.1.2.3".
Return a default constructed credential in this case.

Change-Id: I84ad3b308ee3f74fbbac9ad0f11dbdc66047b50b
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
Reviewed-by: Martin Petersson <Martin.Petersson@nokia.com>
(cherry picked from commit b830c9cededf995fab1b0919a81658ceaec8d422)

10 years agoMerge branch 'master' of git://scm.dev.nokia.troll.no/qt/qt-symbian-team
Qt Continuous Integration System [Mon, 12 Dec 2011 13:45:54 +0000 (23:45 +1000)]
Merge branch 'master' of git://scm.dev.nokia.troll.no/qt/qt-symbian-team

* 'master' of git://scm.dev.nokia.troll.no/qt/qt-symbian-team:
  Revert "Fix memory leaks in OpenVG and OpenGL resource pools"

10 years agoRevert "Fix memory leaks in OpenVG and OpenGL resource pools"
mread [Mon, 12 Dec 2011 13:10:28 +0000 (13:10 +0000)]
Revert "Fix memory leaks in OpenVG and OpenGL resource pools"

This reverts commit 8752faf0564bed86396b01529dc8ef5064150f4c.
Also Revert "Fix def files"
This reverts commit d2a3b9ee8c9329cac96b5e509df0e6a69dbef91c.
This was found to cause a crash in QMLGallery app.
It is not necessary to delete these resource pools at app
exit, as the OS should automatically release the resources
at this point.

Reviewed-by: Jani Hautakangas
10 years agoMerge branch 'master' of scm.dev.nokia.troll.no:qt/qt-symbian-staging into master...
Qt Continuous Integration System [Mon, 12 Dec 2011 10:20:22 +0000 (20:20 +1000)]
Merge branch 'master' of scm.dev.nokia.troll.no:qt/qt-symbian-staging into master-integration

* 'master' of scm.dev.nokia.troll.no:qt/qt-symbian-staging:
  Fix window surface config on OpenGL graphics system.
  Symbian: Fix a case sensitivity issue with QMAKE_EXTRA_COMPILERS
  Symbian: Fix double deletion of selected text when using predictive

10 years agoMerge branch 'master' of git://scm.dev.nokia.troll.no/qt/qt-symbian-team
Qt Continuous Integration System [Fri, 9 Dec 2011 20:36:51 +0000 (06:36 +1000)]
Merge branch 'master' of git://scm.dev.nokia.troll.no/qt/qt-symbian-team

* 'master' of git://scm.dev.nokia.troll.no/qt/qt-symbian-team:
  Fix window surface config on OpenGL graphics system.

10 years agoMerge branch 'master' of scm.dev.nokia.troll.no:qt/qt-qa-staging into master-integration
Qt Continuous Integration System [Fri, 9 Dec 2011 18:24:50 +0000 (04:24 +1000)]
Merge branch 'master' of scm.dev.nokia.troll.no:qt/qt-qa-staging into master-integration

* 'master' of scm.dev.nokia.troll.no:qt/qt-qa-staging:
  tests: fixed compile of qscriptextensionplugin test with high -jN

10 years agoMerge remote-tracking branch 'qt-qa-review/master'
Sergio Ahumada [Fri, 9 Dec 2011 18:01:30 +0000 (19:01 +0100)]
Merge remote-tracking branch 'qt-qa-review/master'

10 years agoFix window surface config on OpenGL graphics system.
Jani Hautakangas [Fri, 9 Dec 2011 12:40:29 +0000 (14:40 +0200)]
Fix window surface config on OpenGL graphics system.

QtOpenGL uses 16-bit configs by default but on Symbian
it should use 32-bit config.

Task-number: QTBUG-23082
Task-number: ou1cimx1#951223
Reviewed-by: Murray Read
10 years agoMerge branch 'master' of git://scm.dev.nokia.troll.no/qt/qt-symbian-team
Qt Continuous Integration System [Fri, 9 Dec 2011 15:07:46 +0000 (01:07 +1000)]
Merge branch 'master' of git://scm.dev.nokia.troll.no/qt/qt-symbian-team

* 'master' of git://scm.dev.nokia.troll.no/qt/qt-symbian-team:
  Symbian: Fix a case sensitivity issue with QMAKE_EXTRA_COMPILERS

10 years agoMerge branch 'master' of scm.dev.nokia.troll.no:qt/qt-symbian-staging into master...
Qt Continuous Integration System [Fri, 9 Dec 2011 13:18:40 +0000 (23:18 +1000)]
Merge branch 'master' of scm.dev.nokia.troll.no:qt/qt-symbian-staging into master-integration

* 'master' of scm.dev.nokia.troll.no:qt/qt-symbian-staging:
  Symbian: improving diagnostics for QWaitCondition

10 years agoSymbian: Fix a case sensitivity issue with QMAKE_EXTRA_COMPILERS
Miikka Heikkinen [Fri, 9 Dec 2011 10:12:28 +0000 (12:12 +0200)]
Symbian: Fix a case sensitivity issue with QMAKE_EXTRA_COMPILERS

The case of the drive letter generated to the absolute paths seems to
have changed between 4.7 and 4.8, which led into regression with
projects that utilize $$PWD in target name, as that still returns the
path with drive letter in same case as previously.
Fixed the critical check to be case insensitive in windows.

Task-number: ou1cimx1#951456
Reviewed-by: Murray Read
10 years agoMerge branch 'master' of git://scm.dev.nokia.troll.no/qt/qt-symbian-team
Qt Continuous Integration System [Fri, 9 Dec 2011 09:29:10 +0000 (19:29 +1000)]
Merge branch 'master' of git://scm.dev.nokia.troll.no/qt/qt-symbian-team

* 'master' of git://scm.dev.nokia.troll.no/qt/qt-symbian-team:
  Symbian: Fix double deletion of selected text when using predictive

10 years agoSymbian: Fix double deletion of selected text when using predictive
Miikka Heikkinen [Fri, 9 Dec 2011 09:07:01 +0000 (11:07 +0200)]
Symbian: Fix double deletion of selected text when using predictive

The selected text replacement was done incorrectly, leading to removal
of additional text equal to the lenght of the original selection.
Fixed by not doing any explicit replacement, but instead faking a
preedit character that is immediately removed, which triggers selected
text removal in the input method handling of the underlying edit
control.

Task-number: ou1cimx1#938665
Reviewed-by: Sami Merila
10 years agoMerge branch 'master' of scm.dev.nokia.troll.no:qt/qt-fire-staging into master-integr...
Qt Continuous Integration System [Fri, 9 Dec 2011 09:09:10 +0000 (19:09 +1000)]
Merge branch 'master' of scm.dev.nokia.troll.no:qt/qt-fire-staging into master-integration

* 'master' of scm.dev.nokia.troll.no:qt/qt-fire-staging:
  Fix stretched font positions in Lion
  Backport writingSystems support code for Cocoa from Qt 5

10 years agoMerge branch 'master' of git://scm.dev.nokia.troll.no/qt/qt-qa-team
Qt Continuous Integration System [Fri, 9 Dec 2011 08:47:37 +0000 (18:47 +1000)]
Merge branch 'master' of git://scm.dev.nokia.troll.no/qt/qt-qa-team

* 'master' of git://scm.dev.nokia.troll.no/qt/qt-qa-team:
  tests: fixed compile of qscriptextensionplugin test with high -jN
  Updated WebKit to 83439de78841f9569ad78e3a84b7b888337b5d18
  Symbian: Fix language mappings for localize_deployment
  Symbian: Only localize the application .rss that needs it, not all .rss
  Revert "Fix sqlite driver memory eating due to close failure"
  Revert "Fix sqlite driver memory eating due to close failure"
  Reduce unnecessary QtCore DLL loads during Symbian app thread creation
  Fix HarfBuzz Thai character SARA AM handling

10 years agotests: fixed compile of qscriptextensionplugin test with high -jN
Rohan McGovern [Tue, 31 May 2011 00:11:16 +0000 (10:11 +1000)]
tests: fixed compile of qscriptextensionplugin test with high -jN

Dependencies between this test and some helper projects were not
declared, so aggressively parallel builds would fail semi-randomly.

Reviewed-by: Jason McDonald
(cherry picked from commit f567467a3ac4182a4c6bb592e4ec596ec458c11b)

Change-Id: If5b1998e18009ffac58637f6723c0a2ddd49c85d

10 years agoMerge branch 'master' of scm.dev.nokia.troll.no:qt/qt-air-staging into master-integration
Qt Continuous Integration System [Thu, 8 Dec 2011 16:43:58 +0000 (02:43 +1000)]
Merge branch 'master' of scm.dev.nokia.troll.no:qt/qt-air-staging into master-integration

* 'master' of scm.dev.nokia.troll.no:qt/qt-air-staging:
  Updated WebKit to 83439de78841f9569ad78e3a84b7b888337b5d18

10 years agoMerge branch 'master' of git://scm.dev.nokia.troll.no/qt/qt-symbian-team
Qt Continuous Integration System [Thu, 8 Dec 2011 15:56:45 +0000 (01:56 +1000)]
Merge branch 'master' of git://scm.dev.nokia.troll.no/qt/qt-symbian-team

* 'master' of git://scm.dev.nokia.troll.no/qt/qt-symbian-team:
  Symbian: improving diagnostics for QWaitCondition

10 years agoSymbian: improving diagnostics for QWaitCondition
mread [Thu, 8 Dec 2011 14:00:46 +0000 (14:00 +0000)]
Symbian: improving diagnostics for QWaitCondition

If a QWaitCondition was deleted while it was waiting, it would crash in
the wait() function while trying to use its internal mutex. This crash
is not particularly obvious in its cause.

QWaitCondition can detect this delete-while-waiting case, issue
appropriate warnings and avoid a crash in its internal state.

In the app crash case where this problem was found, there is a further
crash after this one due to an externally deleted mutex. The app is
clearly at fault. But at least there's now more debug info about
what the app is doing wrong.

Task-number: ou1cimx1#946509 partial fix
Reviewed-by: Shane Kearns
10 years agoUpdated WebKit to 83439de78841f9569ad78e3a84b7b888337b5d18
Zeno Albisser [Thu, 8 Dec 2011 12:31:02 +0000 (13:31 +0100)]
Updated WebKit to 83439de78841f9569ad78e3a84b7b888337b5d18

10 years agoMerge branch 'master' of scm.dev.nokia.troll.no:qt/qt-symbian-staging into master...
Qt Continuous Integration System [Thu, 8 Dec 2011 12:10:49 +0000 (22:10 +1000)]
Merge branch 'master' of scm.dev.nokia.troll.no:qt/qt-symbian-staging into master-integration

* 'master' of scm.dev.nokia.troll.no:qt/qt-symbian-staging:
  Symbian: Fix language mappings for localize_deployment
  Symbian: Only localize the application .rss that needs it, not all .rss
  Revert "Fix sqlite driver memory eating due to close failure"

10 years agoMerge branch 'master' of scm.dev.nokia.troll.no:qt/qt-qa-staging into master-integration
Qt Continuous Integration System [Thu, 8 Dec 2011 01:45:25 +0000 (11:45 +1000)]
Merge branch 'master' of scm.dev.nokia.troll.no:qt/qt-qa-staging into master-integration

* 'master' of scm.dev.nokia.troll.no:qt/qt-qa-staging:
  tests: make tests compile or disable those which don't compile

10 years agoMerge branch 'qt-4.8-from-4.7' of scm.dev.nokia.troll.no:qt/qt-integration into maste... v4.8.0
Qt Continuous Integration System [Wed, 7 Dec 2011 21:22:48 +0000 (07:22 +1000)]
Merge branch 'qt-4.8-from-4.7' of scm.dev.nokia.troll.no:qt/qt-integration into master-integration

* 'qt-4.8-from-4.7' of scm.dev.nokia.troll.no:qt/qt-integration:
  Reduce unnecessary QtCore DLL loads during Symbian app thread creation
  Fix HarfBuzz Thai character SARA AM handling

10 years agoMerge branch 'master' of git://scm.dev.nokia.troll.no/qt/qt-fire-team
Qt Continuous Integration System [Wed, 7 Dec 2011 21:22:44 +0000 (07:22 +1000)]
Merge branch 'master' of git://scm.dev.nokia.troll.no/qt/qt-fire-team

* 'master' of git://scm.dev.nokia.troll.no/qt/qt-fire-team: (37 commits)
  Fix declarative examples and demos issue on Windows
  Symbian: allow apps to disable GL multisampling
  QSqlRelationalTableModel doesn't follow relations on the first column
  symbian - don't export qsymbianbearer.qtplugin twice
  Correct client rect calculation for MCL
  qmlplugindump: Fix missing flush for objects that don't fit a line.
  qmlplugindump: Avoid reporting types as attaching to themselves.
  Fix QtDemo declarative examples
  Correct image paths for dynamicscene
  Fix stretched font positions in Lion
  Symbian: Fix CBA display on application with multiple windows
  Fix def files
  Fix stack overwrite in QDBusDemarshaller
  Qt Linguist: Fix crashes
  fixed error generating wrong introspection string in header output file
  doc - document symbian behaviour of QFile::link
  Symbian - prefer sessions started by this process to choose proxy
  Backport SMP safe initialisation of QNetworkConfigurationManager
  Remove more "unused variable" warnings
  QTreeView: fix crash when starting a drag with hidden columns.
  ...

10 years agoMerge branch 'master' of git://scm.dev.nokia.troll.no/qt/qt-symbian-team
Qt Continuous Integration System [Wed, 7 Dec 2011 15:40:45 +0000 (01:40 +1000)]
Merge branch 'master' of git://scm.dev.nokia.troll.no/qt/qt-symbian-team

* 'master' of git://scm.dev.nokia.troll.no/qt/qt-symbian-team:
  Symbian: Fix language mappings for localize_deployment
  Symbian: Only localize the application .rss that needs it, not all .rss

10 years agoSymbian: Fix language mappings for localize_deployment
Miikka Heikkinen [Wed, 7 Dec 2011 13:08:50 +0000 (15:08 +0200)]
Symbian: Fix language mappings for localize_deployment

Some Qt language codes now map to two Symbian language codes. Also added
the missing en_in mapping.

Task-number: ou1cimx1#947060
Reviewed-by: Pasi Pentikainen
10 years agoSymbian: Only localize the application .rss that needs it, not all .rss
Miikka Heikkinen [Mon, 5 Dec 2011 10:37:37 +0000 (12:37 +0200)]
Symbian: Only localize the application .rss that needs it, not all .rss

Move LANG statement into proper RESOURCE block inside generated .mmp
file, so it doesn't affect _reg.rss, which doesn't need to be
localized.

Task-number: ou1cimx1#947060
Reviewed-by: Pasi Pentikainen
10 years agoMerge remote-tracking branch 'qt-mainline/4.8'
aavit [Wed, 7 Dec 2011 13:56:36 +0000 (14:56 +0100)]
Merge remote-tracking branch 'qt-mainline/4.8'

10 years agoMerge remote-tracking branch 'origin/4.7' into qt-4.8-from-4.7
Liang Qi [Wed, 7 Dec 2011 13:45:19 +0000 (14:45 +0100)]
Merge remote-tracking branch 'origin/4.7' into qt-4.8-from-4.7

Conflicts:
src/s60main/newallocator_hook.cpp

10 years agoMerge branch 'master' of scm.dev.nokia.troll.no:qt/oslo-staging-1 into master-integration
Qt Continuous Integration System [Wed, 7 Dec 2011 12:48:49 +0000 (22:48 +1000)]
Merge branch 'master' of scm.dev.nokia.troll.no:qt/oslo-staging-1 into master-integration

* 'master' of scm.dev.nokia.troll.no:qt/oslo-staging-1:
  Revert "Fix sqlite driver memory eating due to close failure"

10 years agoRevert "Fix sqlite driver memory eating due to close failure"
Sinan Tanilkan [Wed, 7 Dec 2011 12:39:56 +0000 (13:39 +0100)]
Revert "Fix sqlite driver memory eating due to close failure"

Introduced a problem for the SDK (QTBUG-23036).

This reverts commit 9a5fb6bd5f0fb3b37897bf722e4cc1673309623c.