If we can not get online when the request is made then we are in the
WaitingForSession state. This will happen for example if the device
is in flight mode. This fix follows the same logic as in
_q_networkSessionFailed, but we should look into why we have the
WaitingForSession check in finished().
Task-number: QT-4747
Reviewed-by: Markus Goetz
(cherry picked from commit 0c9cb9a34d6b472cb53bf1af4616af55b593b616)
Currently, an attempt to compile Qt even with -no-gui on a Linux box
that doesn't have libX11 installed fails becaue of the XLib
functionality check in configure.
This check can be turned off in -no-gui mode, since QtCore, QtXml,
QtNetwork and friends don't use libX11.
Merge-request: 1214
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@nokia.com>
(cherry picked from commit 912b6804bcacbf1b4f356d947986df8156a545a4)
as a side effect, don't use QDir for path resolution - it doesn't buy us
anything.
Task-number: QTBUG-1371
Reviewed-by: joerg
(cherry picked from commit 9cd62e4f7b23894a672297f6eebda64cdbd53cb0)
QAbstractSocketEngine::createSocketEngine can return 0 as well as throw.
In two cases the pointer was being used before the null check, in a 3rd
case the null check was missing.
Reviewed-by: Markus Goetz
(cherry picked from commit 19edac88af53eea7f733cabbaee77f9b725b7ea9)
Do the easy checks first, will avoid a crash in the HTTP code
if request is serviced from the cache.
Task-number: QTBUG-18770
Reviewed-by: Peter Hartmann
(cherry picked from commit d03a28a289cf0665290e6ea0375b31cbb2d6649e)
The application main window defaults to fullscreen size when initially
constructed, even if softkeys are specified for it, as the screen
furniture is constructed later in show_sys. This resulted in the main
window being partially under softkeys.
Fixed by invoking handleClientAreaChange() explicitly in show_sys in
fullscreen with softkeys case.
Task-number: QTBUG-19043
Reviewed-by: Sami Merila
(cherry picked from commit e8fc93973a41f193665baa5fdc26cba951bd692f)
Widgets are left in a transitional (and incosistent) state while being
re-parented, which caused QWidget::effectiveWinId() to crash in certain
circumstances. See patch for more details.
Auto test included.
Reviewed-by: ogoffart
(cherry picked from commit 6db0153cd7e35e4a919a76ae2aadbf2d2510bfb7)
select code for open C file/socket descriptors was crashing in FD_SET
if a QSocketNotifier was created with an invalid descriptor.
Added two autotests to QSocketNotifier, one to check notifiers with
bogus socket descriptors don't crash, the other to check that notifiers
with posix socket descriptors do work. (symbian socket engine doesn't
use them so they are not implicitly tested)
Reviewed-by: mread
Task-Number: QTBUG-18138
(cherry picked from commit 8a9a6afcf02f089f932bc81431ab46a60af32134)
In Symbian, the OS function to get the size of a pending datagram also
includes the size of the packet header (which is different for IPv4 and
IPv6). We were reading the datagram with the "peek" flag set to
implement pendingDatagramSize, then reading again normally when the
client called read/readDatagram.
This change removes the "peek" flag, and buffers the datagram in the
socket engine, returning it and clearing the buffer when read or
readDatagram is called.
If there is no buffered data, the existing code path is followed - it
isn't mandatory to call pendingDatagramSize before reading from the
socket.
Reviewed-by: Markus Goetz
(cherry picked from commit dd8de4c2437397748daba49569cbc7f89a8bfbee)
The generic layer calls setReadNotificationEnabled(false) on sockets
after they are closed. This no longer causes a warning from the symbian
socket engine. A warning will only be emitted if trying to enable
notifications on a closed socket.
Task-number: QTBUG-18713
Reviewed-by: Markus Goetz
(cherry picked from commit 0aa780235c24ed724fcf6a9095a6467e34b9346e)
Ignore warning when the test intentionally sets an invalid socket descriptor.
Make sure to set content type on all http post tests in tst_qnetworkreply.
Run test with enough capabilities to avoid platsec errors when accessing
certificate store.
Reviewed-By: Markus Goetz
(cherry picked from commit 9632fdefa9012ca11cd1345d66bafd6f417de88e)
* 'master' of git://scm.dev.nokia.troll.no/qt/qtbase-staging:
Fix tst_QVariant::invalidColor
Move QTextCursor::MoveStyle to Qt namespace
Add some QRawFont related low level functions to avoid extra copying
Since a423ff5474b89028eeca95b254f5184311c8223b, the warning message is
no longer produced.
Reviewed-by: Samuel Rødal
(cherry picked from commit 8a5e82732be3aac37d14ef85c6974add46c6b65f)
We cannot use QTextCursor::MoveStyle enums in QTextLine because
QTextCursor is not a QObject, while referring to that enum in
Q_PROPERTY requires it to be. That's why we need to move the
enums in Qt namespace.
Reviewed-by: David Boddie
(cherry picked from commit 5eba82b752e85a5d6cb3a893214ed2646d75f362)
tst_lancelot did QT+=svg, but didn't actually use QtSvg.
qlocalsocket/lackey uses QtScript, which is not available when compiling
qtbase.
Change-Id: Ic3cc5a6f74a58ee8f2fdc48b9c852d9551b85f68
* 'master' of git://scm.dev.nokia.troll.no/qt/qtbase-staging:
tests: fix private header inclusion in qtbase autotests
tests: disable tests in qtbase which depend on qtsvg
tests: make benchmarks compile or disable those which don't compile
tests: remove references to benchmark directories which don't exist
tests: enable compilation of autotests for qtbase by default
tests: make tst_qrawfont compile for QGlyphs -> QGlyphRun API change
tests: mark some tests as using private API
Any test which needs private headers from some Qt module must do:
QT += modulename-private
Reviewed-by: Jason McDonald
Change-Id: I6924a577a960e4990f4379b02bca4822d8248fb4
Tests are now treated like examples and demos: compiled by default,
unless you configured with `-nomake tests'. (They are still not
installed by default, however.)
Reviewed-by: Jason McDonald
Change-Id: Ifc56f6763bb2aafe6fe57b684751f99ec82ea26f
These autotests are all using private symbols, available only when Qt is
configured with -developer-build. So, gracefully disable them when
the private symbols are not available.
Reviewed-by: Jason McDonald
Change-Id: Iafd1c7af486feeee810110bc021e75984827f78a
Commit 4b75ceea08 changed
qcoreapplication_p.h to include qsettings.h, which undefines Status.
This breaks the xlib platform plug-in (and its includes).
* 'master' of git://scm.dev.nokia.troll.no/qt/qtbase-staging: (142 commits)
ifdef out mac/no_coreservices path more cleanly
fix build on symbian
Allow different text for undo actions and items in QUndoView
Allow using not only prefixes for undo command text
QFileSystemEngine::currentPath(): use QFileSystemEntry() also for the no-PATH_MAX case
Massively update the hurd-g++ mkspec.
Do not allow multiple threads to acquire a QMutex
Ensure that QDateTimeEdit::calendarWidget() will always return a valid widget.
don't crash in QProcessEnvironment::systemEnvironment()
HTTP backend: do not load resources from cache that must be revalidated
Compile fix for QLocale on Symbian.
Added Kazakh language to the QLocale mapping table on Symbian.
Added support for QLocale::uiLanguages on Symbian.
Fix drawing text in item view:
Add enablers for Symbian App Booster
Don't rely on uninitialized data
Don't realloc user-provided buffer
qmake: Introduce new template type
Make autotest more resilient against network timeout (cherry picked from commit 50be38737507f5c23b4d050e635a200024164a13)
Do not filter adhoc clients (cherry picked from commit 4fe5307af44a76b99cc8c70aa330180c1985eabc)
...
Now the texts used for undo actions and for items in QUndoView can
be set separately. This introduces an extended format of text that
can be passed to QUndoCommand::setText or QUndoCommand constructor.
The action text can now contain two strings separated by a "\n". The
first string (that goes before "\n") is then returned by
QUndoCommand::text() and used as name of item in QUndoView.
The second string (that goes after "\n") is returned by
QUndoCommand::actionText() and used when the text properties of the
undo and redo actions are updated.
If the text passed to QUndoCommand does not contain "\n", everything
works as before, and both QUndoCommand::text() and
QUndoCommand::actionText() return the same string.
Even though action text in English usually does not need different forms
for undo actions and QUndoView item, translators can employ this new
command text format, for example to adjust the grammatical case used in
command text to match the context of "Undo %1"/"Redo %1".
Merge-request: 2610
Reviewed-by: ossi
(cherry picked from commit 9b784789c75d59b27530bbf1d12676cc44f64f46)
Functions QUndo{Group,Stack}::create{Undo,Redo}Action() now use action
text templates "Undo %1" and "Redo %1" if no custom prefix was provided.
This makes more flexible translations possible. The surrounding text
(like "Undo" and "Redo") can now be suffixed to the command name as
German and Korean languages require ("%1 rueckgaengig machen" for German).
Also, now the default action text (when no command can be undone) can be
translated differently from the prefix. For example, it can be
translated as "Undo action", not just "Undo".
When a non-empty prefix is passed to QUndo*****::create****Action(),
those functions work as before, and the features described above become
unavailable.
Task-number: QTBUG-14442
Merge-request: 1212
Reviewed-by: ossi
(cherry picked from commit 213c25ad24e4f3b0a44f82f23d34746cd294f8d6)