Commit Graph

17709 Commits

Author SHA1 Message Date
Morten Johan Sørvig
4d56c86f80 Cocoa: Disable the zoom button when appropriate
Disable the zoom (maximize) button for fixed-size
windows and customized windows with the MaximizeButton
flag not set.

Task-number: QTBUG-37078
Change-Id: I6da88496474713de37b48aa65742203632ba99d6
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
2014-03-15 10:45:47 +01:00
BogDan Vatra
f9e1e595a9 Android: Delay the set of the BackingStore if window->handle() is null.
Task-number: QTBUG-37458

Change-Id: Idddfe1876aff3d14d8c6c060d04236c5dc611bce
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
2014-03-15 10:45:42 +01:00
Eskil Abrahamsen Blomfeldt
287fa94fe2 Android: Fix another "QApplication not on main() thread" crash
The assets file engine is created before main() is called, thus
prepopulate was called before main(). In this function, we created
a QDataStream which internally created a QBuffer which inherits
from QObject. This caused the main thread pointer to be initialized
early, and the old "QApplication is not on the main() thread" warning
and crash returned. The fix is to prepopulate the first time the
file engine is used instead.

Task-number: QTBUG-37444
Change-Id: I2c6e5f1a8ca88b5dc7d8e145fffeb7587dc0e623
Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
2014-03-15 10:45:36 +01:00
Richard Moe Gustavsen
de51854726 iOS: update keyboard rectangle when scrolling the screen
When we scroll, the keyboard will change position relative
to QScreen, even if it appears to stay put. For that
reason we also need to update the keyboard rect after
doing a scroll.

Change-Id: I9bda2ab5b5e4970f488d3e69e44cf58e273f8fcd
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
2014-03-15 10:45:31 +01:00
Friedemann Kleint
7b8d4cdb10 Windows native file dialog: Allow for omitting name filter description.
Task-number: QTBUG-37329

Change-Id: I644595a292e5b1890b2088b68be595bfcdba9d4d
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2014-03-15 10:45:24 +01:00
Friedemann Kleint
037bc9b638 Add verbose messages to tst_qnetworkreply.
Task-number: QTBUG-37449

Change-Id: Ib3802ddd51b908a68d8c893ce49010aeeb117db8
Reviewed-by: Peter Hartmann <phartmann@blackberry.com>
2014-03-15 10:45:17 +01:00
Laszlo Agocs
3d2160056e Resurrect QGLWidget::renderText()
The variant taking x, y, z has been broken in all Qt 5.x releases.
This is now corrected by making the GL2 paint engine capable of applying
a Z translation.

Task-number: QTBUG-31156
Change-Id: I119566e9e9577f6cdf7e8bae56cac1e34995e622
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
2014-03-15 10:45:10 +01:00
Morten Johan Sørvig
77bf302ce2 Prevent DrawTextItemDevice::metric warning on Mac
Implement PdmDevicePixelRatio.

Task-number: QTBUG-36419
Change-Id: I4d2822d01e08c80e9b829d5f524e8e761e694fba
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@digia.com>
2014-03-15 10:45:04 +01:00
Allan Sandfeld Jensen
19532eec2a Fix casting and overallocation in qregion.cpp
The POINTBLOCK struct in qregion.cpp is badly defined. By using ints
as the base storage of the internal array it forces not only bad casting
from int to QPoint, but also allocates an array four times too big.

This patch changes to char, since a char pointer may alias anything and
this gives the right size of the array.

Change-Id: I608eaf39ac7306c71314a139bed6e2352249c0ab
Reviewed-by: Gunnar Sletta <gunnar.sletta@jollamobile.com>
2014-03-15 10:44:56 +01:00
Gabriel de Dietrich
4b0016f045 Cocoa: Get rid of the forward window pointer asap
As soon as we receive an event not related to dragging
a QDockWidget out of its area (or a similar use case),
we no longer need the forward window.

Task-number: QTBUG-37265
Change-Id: I310e9cc2cf099c76e7a88427826d4b97ca0cd9b9
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
2014-03-15 10:44:52 +01:00
J-P Nurmi
49b14f7a8b Remove the _qt_filedialog_xxx hooks
These internal and obsolete hooks are no longer used. The correct way
to provide platform dialogs in Qt 5.x is to implement a platform theme
plugin, as was done for GTK+ 2.x.

Change-Id: I3f1474fbf760130106b3c47173eaedd2f1a919bf
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
Reviewed-by: David Faure <david.faure@kdab.com>
2014-03-15 10:44:47 +01:00
Friedemann Kleint
51e5378113 Use QCommandLineParser in example dnslookup.
Show how use QCommandLineParser with additional
parameter checking for custom options and positional
arguments.

Also explain how to display help in GUI applications.

Change-Id: I03513e09b7dd5b150259593da0af2ef2a281cab2
Reviewed-by: David Faure <david.faure@kdab.com>
2014-03-15 10:44:41 +01:00
Oswald Buddenhagen
00fe7bd975 make property name doc match reality
it's QT_INSTALL_CONFIGURATION, not QT_INSTALL_SETTINGS.
probably the most useless of all properties, but anyway.

Change-Id: Ia1e739ab4ed59e2bcd3199914caed2b3db9070ee
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2014-03-15 10:44:34 +01:00
Lorenz Haas
4b0ad2fcc8 Doc: Fix syntax/compiler error in QThread snippet
Change-Id: If64e01099b50f15b5cf7cdb0890dfa4f7625126d
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
2014-03-15 10:44:29 +01:00
Kai Koehne
82fd626ded Document %{if-category} in default message pattern
Commit 15ddb91b introduced %{if-category}, and changed the default
message pattern. Adapt the documentation accordingly.

Change-Id: I1d500122300c4d62171de3607553b3a5a822d4a7
Reviewed-by: Jerome Pasion <jerome.pasion@digia.com>
2014-03-15 10:44:25 +01:00
Laszlo Agocs
7fba691110 Docs: Clarify QOpenGLFunctions::functions()
Change-Id: Ifb6fdc3de7f93a1632b396eaaa14078546cac4dd
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
2014-03-15 10:44:20 +01:00
Peter Hartmann
2bbdc6358f HTTP internals: keep consistent state in channel and protocol handler
It could be that the channel has its reply already reset to 0, while
the protocol handler thinks the reply is still active, which might
lead to weird behavior including hard to reproduce crashes.

Task-number: QTBUG-37424

Change-Id: I89b65d34caaa546a343edc2ee205aa76425de88f
Reviewed-by: Richard J. Moore <rich@kde.org>
2014-03-15 10:44:16 +01:00
Eskil Abrahamsen Blomfeldt
61fda89cd1 Android: Turn off thumb for armv5 again
The 4.8 compiler in the Android NDK sometimes produces uncompilable
code for armv5. In change b4252802b3
we reintroduced thumb instructions on armv5 with a work-around for
a particular case of this bug. However, the compiler now breaks
for Qt Script. There's no time to try to find a work-around for
this case, so we need to disable thumb again. It actually also
seems that this is completely broken with this compiler, so it would
probably be best to keep this disabled until the compiler is fixed.
Especially since armv5 will become part of the CI builds now, so the
compiler bug can end up blocking critical changes in the future if it's
re-enabled :/

Task-number: QTBUG-37376
Change-Id: I9e1b050ce596717ba1fa7ec2f5e8a3ce3581a3af
Reviewed-by: Paul Olav Tvete <paul.tvete@digia.com>
2014-03-14 22:40:49 +01:00
Laszlo Papp
c42ac8173e Fix a probably copy/paste issue from drawImage in the drawPixmap snippet
Change-Id: Ia2b34e3ee6954342501a805f9e047cb90078e9d5
Reviewed-by: Martin Smith <martin.smith@digia.com>
Reviewed-by: Topi Reiniö <topi.reinio@digia.com>
2014-03-14 22:40:40 +01:00
Friedemann Kleint
176342e70a QWindowsXP/VistaStyle: Fix detection of item view delegate line edits.
The old code tried to check the 2nd parent for inheritance from
QAbstractItemView. This also triggers for line edits on a QDialog parented
on the item view. Introduce convenience function that checks for
top levels in the chain.

Task-number: QTBUG-37504

Change-Id: I932f8efdb4764e9b1eea84c802bf7e8718338e1d
Reviewed-by: J-P Nurmi <jpnurmi@digia.com>
Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
2014-03-14 22:40:36 +01:00
Andrew Knight
9ceeaaac79 WinRT: Add debug message handler for winrtrunner
By placing debug messages in shared memory, the application can share
debug messages with winrtrunner (or any utility which passes -qdevel
to the app and opens the corresponding shared memory area).

Task-number: QTBUG-37308
Change-Id: Id0e04cfd5f0f701d552a448f780788c7cbf9b438
Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
2014-03-14 22:40:32 +01:00
Richard Moe Gustavsen
60f0a97edd iOS: fix build failure __IPHONE_NA not defined
__IPHONE_NA was previously defined to 9999, but with
iPhoneOS7.1.sdk it is now undefined. From Availability.h:
"__IPHONE_NA is not defined to a value but is uses as a
token by macros to indicate that the API is unavailable"

This causes Qt to evaluate QT_MAC_PLATFORM_SDK_EQUAL_OR_ABOVE
to true when given __IPHONE_NA as argument. And then the
build will fail.

Change-Id: I11f1d0285329d90c633c00c0c4d446ef5cd8089b
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
2014-03-14 22:40:28 +01:00
Andrew Knight
42afaa992a d3dcompiler_qt: Remove control file semantics
This simplifies the compiler control semantics by always using the
packaged compiler if it is available. With no packaged compiler, the
service is assumed to be running if the directory structure is present.
Use of a packaged library can be overridden by setting the environment
variable QT_D3DCOMPILER_DISABLE_DLL to 1.

When the runtime compiler is used, the source will no longer be
logged, and the compilation output will no longer be cached.

Change-Id: Ib07f517e7043d7785bdfa9da55abd34df518eeed
Reviewed-by: Oliver Wolff <oliver.wolff@digia.com>
2014-03-14 22:40:24 +01:00
Samuel Gaist
bcfc68f9cd Use Uniform Type Identifiers to detect OS X bundles
Following Apple's documentation, the first step to identify a
bundle is to check if it has a known extension. Currently, it's
done using string comparisons ored in an if statement. The list
is not complete and new types, whether provided by a system update
or other means, can't be detected.

The new approach is to use Uniform Type Identifier which queries
the OS directly to check whether the extension conforms to
kUTTypeBundle. That includes e.g. applications, frameworks etc.

Task-number: QTBUG-31884
Change-Id: Ief73a83904adf27ccb71b0070e67cba081d1fd4a
Reviewed-by: Jake Petroules <jake.petroules@petroules.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2014-03-14 22:40:19 +01:00
Laszlo Agocs
6b56b2ddb2 Disable QtOpenGL in dynamicgl builds
Migrating this is out of scope for the time being.

Change-Id: Iac4a98d8db8e132a6ffa28075548fe2af76637fc
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2014-03-14 22:40:15 +01:00
Laszlo Agocs
f1f603bd0b Fix dynamic opengl build
Some ifdefs were slightly incorrect.

Change-Id: I5ffb162becb040c91ed56f36c6126c59f67c367a
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
2014-03-14 22:40:11 +01:00
Alejandro Exojo
d7eb0a632a Fix one bogus print to stderr: use toLocal8Bit()
Change-Id: I86341ccbd0251a9c858a5e1a9b7ea291d73cda01
Reviewed-by: Robin Burchell <robin+qt@viroteck.net>
Reviewed-by: Kai Koehne <kai.koehne@digia.com>
2014-03-14 22:40:07 +01:00
Dmitry Shachnev
d5dcd6d166 Add AArch64 support to qfilesystemwatcher_inotify.cpp
Based on a patch by Marcin Juszkiewicz <marcin@juszkiewicz.com.pl>,
licensed under CC0 (aka Public Domain) or BSD license.

Change-Id: I60815d6893c7a9d2873864ff626b865881ec5ee9
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
2014-03-14 22:40:02 +01:00
Janne Anttila
391c2c12ab Introduce GENERATED_TESTDATA variable and fix qresourceengine test.
testcase.prf cannot be loaded from pro file for various reasons,
see qtbase commit history for details.

Moved runtime testdata logic from pro file to testdata.prf, and
thus made is reusable in other test cases as well.

Change-Id: I500d08dc4951e4eda862071e4ddd3e0f6de8c3d2
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
2014-03-14 22:39:58 +01:00
Fabian Bumberger
02abe7921b QNX: Fix touch position
Change-Id: I8e4f83f58fbb31f7cffdf74b0ce431a6fd46f13b
Reviewed-by: Bernd Weimer <bweimer@blackberry.com>
Reviewed-by: Rafael Roquetto <rafael.roquetto@kdab.com>
2014-03-14 22:39:54 +01:00
Bernd Weimer
2aee54c738 BlackBerry: Add button color to dark palette
Change-Id: I35191841e4d606042375ab8af442a339d6a701dd
Reviewed-by: Fabian Bumberger <fbumberger@rim.com>
2014-03-14 22:39:51 +01:00
Paul Olav Tvete
80d4a19f51 Android: Use proper empty strings in key events
A key event with no unicode would get a text of "\0" instead of
the empty string. This would lead to various widgets interpreting
the Key_Back event as text input, meaning that it would be grabbed
by the widget instead of being propagated.

Task-number: QTBUG-35784
Change-Id: Ibdb0e491572e41dd1aaf3b03ae1a780731f0559a
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
2014-03-14 22:39:48 +01:00
Paul Olav Tvete
1567699c0e Handle key release events correctly
Properly ignore key events that we don't actually handle.

Task-number: QTBUG-35784
Change-Id: Ibd3e72c76367a1dc3b1f2d39538fcf8441082ff2
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
2014-03-14 22:39:44 +01:00
Paul Olav Tvete
08ba111719 Don't block Key_Back in file dialog
Update the 10 year old FIXME hack to allow Key_Back (which will
close the dialog on Android). Also clean up nearby code that has
been dead for seven years.

Task-number: QTBUG-35784
Change-Id: I609858afb2caefe7025e421406288ae56717fea5
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com>
2014-03-14 22:39:39 +01:00
Oswald Buddenhagen
61f865be00 properly replace windows paths in installed plugin prl files
amends 53f48a4b.

Task-number: QTBUG-37399
Change-Id: I599ba612af760891cd99283560ccc9240125db39
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2014-03-14 22:39:35 +01:00
Oswald Buddenhagen
2c90d97a7b enable path replacement in installed plugin prl files on all platforms
amends 08a2d8df4.

Task-number: QTBUG-37399
Change-Id: I113ddf632d2ce3f7f2c92e079fd2fa3a1a640c1a
Reviewed-by: Joerg Bornemann <joerg.bornemann@digia.com>
2014-03-14 22:39:31 +01:00
Friedemann Kleint
f83ce63fe3 Add GL information to qpainfo.
Task-number: QTBUG-31611
Change-Id: Ibf9bcb74ed8dbf8625e77ef0870d758a77ea65cb
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
2014-03-14 22:39:27 +01:00
Markus Goetz
f202cd8408 iOS: Create folder for SUBDIR projects
In case of a SUBDIR qmake project, it tried to cd into a directory
that did not exist yet. I needed to run qmake twice to get it working.
This fixes it.

Change-Id: I6d322e9a7c96a9d82df77b9ba5f19711a8180ed0
Task-number: QTBUG-37429
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@digia.com>
2014-03-14 22:39:23 +01:00
Friedemann Kleint
08f0dbd13c Fix spurious XPASS in tst_QGraphicsAnchorLayout.
Seen on Windows:

XPASS  : tst_QGraphicsAnchorLayout::stability() QCOMPARE(sameAsPreviousArrangement, true) returned TRUE unexpectedly.
tst_qgraphicsanchorlayout.cpp(1399) : failure location

Move check into loop with descriptive message on fail, do not error
out if it actually passes. This now typically prints:

XFAIL  : tst_QGraphicsAnchorLayout::stability() The layout has several solutions, but which solution it picks is not stable ( QRectF(30,0 0x10) != QRectF(30,0 10x10) , iteration 3 , item 4 )

Change-Id: Iae8553dbbcedeb70d5d672e3cefbd1f06a63d27d
Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
2014-03-14 22:39:19 +01:00
Jorgen Lind
fde6450b59 Add workaround for bug in the Mesa glsl optimizer
Change-Id: I23251f5288b41f5b7f86406984fdd854127797a9
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
2014-03-14 22:39:15 +01:00
Gabriel de Dietrich
9cd2dac348 Vista Style: More menu item pixel fixes for QtQuick Controls
Includes a one-pixel fix for widgets, where the menu item text
would be one pixel too far away from the vertical gutter.

Task-number: QTBUG-37451
Change-Id: I2539233814a427c5bed66a5c07584717eb3df418
Reviewed-by: Jens Bache-Wiig <jens.bache-wiig@digia.com>
Reviewed-by: Mitch Curtis <mitch.curtis@digia.com>
2014-03-14 22:39:12 +01:00
James McDonnell
ff7f3aba39 Complete support for no-fullscreen parameter
Change the code so that it doesn't force application windows to full
screen when the no-fullscreen parameter is used in the QT_QPA_PLATFORM
environment variable.

Task-number: QTBUG-37456
Change-Id: If9612cc2ca69f829d45e7fd4b83338c3a41cf986
Reviewed-by: Kevin Krammer <kevin.krammer@kdab.com>
Reviewed-by: Fabian Bumberger <fbumberger@rim.com>
2014-03-14 22:39:09 +01:00
Gatis Paeglis
530f985651 [XCB] Fix crash in QML drag-and-drop
Use QPointer to make sure that we are not trying to destroy already
deleted object.

Task-number: QTBUG-35702

Change-Id: Ib746996787488e636f25e6ea5be0571607ee2ded
Reviewed-by: Laszlo Agocs <laszlo.agocs@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2014-03-14 22:39:05 +01:00
Frederik Gladhorn
df757e30f8 Fix compilation with QNATIVESOCKETENGINE_DEBUG enabled
Change-Id: Ie60b70aaa1fe11de613ba99427be00e307b6769d
Reviewed-by: Peter Hartmann <phartmann@blackberry.com>
2014-03-14 22:38:59 +01:00
David Faure
c4650779c4 Fix tst_qthreadpool under high load.
The tasks might not have run yet at the time of the QCOMPARE, so we need
to acquire on the semaphore in order to ensure that this is the case,
just like in the previous testcase.

Change-Id: I1da72bb07c2f53760b3bf912fc26aaf10ed18d48
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@digia.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2014-03-14 22:38:49 +01:00
Marcel Krems
b14e4eb5f0 Add missing \since 5.0 to QProcess::{program,arguments}.
Change-Id: Ie2ce1860e1c63c0955b0a2bee7f8b33c91b9f628
Reviewed-by: Christian Kandeler <christian.kandeler@digia.com>
2014-03-14 18:26:12 +01:00
Marcel Krems
2954d51579 Add compiler name for Clang in QLibraryInfo::build()
Change-Id: I88490f01edc00f5d3c9570fa630915a11c843311
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
2014-03-14 18:26:03 +01:00
Gatis Paeglis
ecb7fd9ff7 [XCB] Fix drag-and-drop segfault
QXcbDrag inherits QBasicDrag which takes care of calling
updateAction() when needed, we don't need to call it explicitly.

Task-number: QTBUG-33057

Change-Id: I754408f74f56de36ace8ffa40a61bd7c64619899
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
2014-03-14 18:24:59 +01:00
Risto Avila
0a24d653b6 Fix Direct2D clipping when Qt::WA_OpaquePaintEvent is true
Changed clip rectangle handling from bounding rect to region. Now also
sub region rectangles are taken in to account.

Task-number: QTBUG-37199
Change-Id: I9e09376e2c6d3fee8f85db753295a6138a03096f
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
Reviewed-by: Janne Koskinen <janne.p.koskinen@digia.com>
Reviewed-by: Louai Al-Khanji <louai.al-khanji@digia.com>
Reviewed-by: Andrew Knight <andrew.knight@digia.com>
2014-03-14 18:24:12 +01:00
Morten Johan Sørvig
d9c34e9cdd Repaint widgets on screen change.
Add a screenChanged handler slot to QWidgetWindow,
which calls markDirty() on the backing store with
the BufferInvalid and UpdateNow flags set.

Update CocoaBackingStore to create a new buffer on
window devicePixelRatio change. Use the
QCocoaWindow::devicePixelRatio() implementation instead
of a duplicate implementation in the backing store.

The plan is to replace this implementation with one
based on QUpdateWindowRequestEvent for Qt 5.4

Change-Id: I8e521c53df4ac90815613e730fe821996334721f
Reviewed-by: Jørgen Lind <jorgen.lind@digia.com>
2014-03-14 18:23:25 +01:00