Commit Graph

26020 Commits

Author SHA1 Message Date
Oswald Buddenhagen
d3518b7525 Revert "use bindir instead of libdir when launching tools on windows"
proper prefix builds don't have the redundant .dlls in bin (the copy
step is simply omitted), so this is broken. the change would have to be
done atomically with making DLLDESTDIR sane.

This reverts commit 9b2e98245a.

Task-number: QTBUG-50065
Change-Id: I9ce0a2d1147a1a2d4bd2f22e619d5c737864a637
Reviewed-by: Romain Pokrzywka <romain.pokrzywka@gmail.com>
Reviewed-by: Tim Blechmann <tim@klingt.org>
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
2016-01-08 09:36:25 +00:00
Oswald Buddenhagen
c0efee2f26 add always_prepend mode to qtAddToolEnv()
this is just an optimization/clarification: variables which are known to
be never empty (like PATH) can be extended with less convoluted code.

Change-Id: Ib365bbec8301673ed1c874979b4de19bc983dab1
Reviewed-by: Romain Pokrzywka <romain.pokrzywka@gmail.com>
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
2016-01-08 09:36:20 +00:00
Oswald Buddenhagen
282f15feaa rewrite qtAddToolEnv()
the primary purpose is making env var prepend mode work for unset
variables on windows. this is achieved by using a conditional and delayed
variable expansion. however, the latter is disabled by default and can
be locally enabled only in batch files. therefore, write wrapper scripts
and substitute them for the actual commands. we do this also on unix,
both for consistency and simply because the commands look much less
confusing.

this change is slightly backwards-incompatible, as invoking
qtAddToolEnv() multiple times on the same command will now make a total
mess. also, invoking it on a command that contains 'make' macro
expansions isn't a good idea, so testcase.prf needed an adjustment. the
function is an undocumented internal, so Nobody Should Care (TM).

this also reverts 80ebedecf9, as it's obsolete now.

Change-Id: I8394b77868b495abcf27b688996ca74c40b80994
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
2016-01-08 09:36:13 +00:00
Simon Hausmann
c7797184f0 Prospective fix for running cmake tests with -no-widgets
Don't try to run test_interface when Qt is configured without QtWidgets.

Change-Id: If6c376c250215c1d639b06881d16c0141091f288
Reviewed-by: Stephen Kelly <ske@ableton.com>
2016-01-07 19:29:36 +00:00
Stephen Kelly
5001f6ceba Fix mac build with -no-widgets
Unused parameters are errors.

Change-Id: I79782a8094491a953d6e838e6b8c5b9d6327f30a
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
2016-01-07 15:34:52 +00:00
Laszlo Agocs
6f69a313bd Fix offset and size for native child rtt widgets
Render-to-texture widgets that are native children may have a non-zero
offset telling the position within the top-level widget. The size is
usually different (smaller) than the tlw's size as well.

An unfortunate optimization attempt led to ignoring the size for native
children with offset (0, 0). This resulted in interesting rendering
artifacts whenever such widgets were placed in the top-left corner of
the toplevel. This is now corrected.

Task-number: QTBUG-48130
Change-Id: If449610c3f3333cb73ae149efaefd7ef42953951
Reviewed-by: Paul Olav Tvete <paul.tvete@theqtcompany.com>
2016-01-07 15:17:00 +00:00
Shawn Rutledge
b2203b2490 doc: correct documentation of QT_AUTO_SCREEN_SCALE_FACTOR env var
Change-Id: I4fa57279b23911893a615fe8a3ce9854d0fec971
Reviewed-by: Topi Reiniö <topi.reinio@theqtcompany.com>
2016-01-07 15:07:57 +00:00
Błażej Szczygieł
7409e3a42b QtGui: Don't set screen to a child window when processing screen events
Setting a screen to a child window causes a warning message. This patch
prevents the debug message by catching incorrect behavior made by QPA
earlier.

Change-Id: Idf3ac02290a18afc134f19c2b91348dc009ca4ca
Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
2016-01-07 11:02:35 +00:00
Błażej Szczygieł
7e28079484 QtGui: Fix obtaining the top level window at a point
Find the top level window on the primary virtual desktop first to avoid
obtaining a window which doesn't belong to the primary virtual desktop
when screen geometry is similar.

Change-Id: I78fdfa0b5146d0ba9b912338adeb612c102c4ac3
Reviewed-by: Adam Majer <adamm@zombino.com>
Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
2016-01-07 11:02:28 +00:00
Volker Krause
eb0b03c579 QPair<QRunnable*, int> is too large for QList to be efficient-ish.
Qt3D is making heavy use of this, causing the QList node allocations
to be among the top 10 per frame allocation sources. Switching to
QVector fixes that.

Change-Id: I3b4df329710f82bf8d6797ea1f0c79b288a08063
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
2016-01-07 07:59:37 +00:00
Ralf Habacker
d3fe4f066f dbus: Print out 'serial' and 'serial reply to' with DBusMessage operator<<.
The reply serial is displayed for method call returns and errors,
while the serial is displayed for all message types.

To see a message serial it is required to dump messages after
sending, not before.

Task-number: QTBUG-44490
Change-Id: I859f50d739ed059d5b2dfe1a2efdf04b906891a7
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2016-01-07 07:43:16 +00:00
Ralf Habacker
618e2cc081 dbus: Add method serial() and replySerial() to class DBusMessage.
This patch includes setup of class member 'msg' in
QDBusMessagePrivate::toDBusMessage() to be able to get the
serial after message sending.

Testcases for comparing the 'reply serial to' with the 'serial'
are included.

Task-number: QTBUG-44490
Change-Id: Iae7c48f5b0c70a6c5ae500904072b38b46dfd876
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2016-01-07 07:42:35 +00:00
YAMAMOTO Atsushi
c09412fcea Windows: Fix QWindowsInputContext for Japanese IME.
Change the QWindowsInputContext::composition if it is called
with lParam has flags GCS_RESULTSTR and GCS_DELTASTART,
it doesn't call endContextComposition.

Task-number: QTBUG-49955
Change-Id: I49de3f239bf8a77414e433b255db08f227141158
Reviewed-by: Tasuku Suzuki <stasuku@gmail.com>
Reviewed-by: Takumi ASAKI <takumi.asaki@gmail.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Andy Shaw <andy.shaw@theqtcompany.com>
Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
(cherry picked from qtbase/786984e7e47a63094ad64ec86a4892cc5c0ad6d4)
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2016-01-07 07:21:21 +00:00
BogDan Vatra
e9eb32f332 Android: Activate Qt::Popup windows
On Android, back button will send a CloseEvent to the focused window.
This change will activate (focus) the Popup windows when they'll become
visible.

Task-number: QTBUG-46419
Change-Id: I6787435b24502bbf9a78662a0c6fd159d4ee2e8d
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
2016-01-06 18:17:04 +00:00
Błażej Szczygieł
b50f0244c8 QDesktopWidget::screenNumber(QPoint): fix handling of virtual desktops
On X11, QXcbVirtualDesktop represents an X11 screen while QScreen
represents an X11 output.  In the case that there are multiple screens
(possibly with multiple outputs), calculate the screen number correctly:
Find the screen index on the primary virtual desktop first to avoid
obtaining a screen index which doesn't belong to the primary virtual
desktop when screen geometry is similar.

Change-Id: I4cbb29b7aa7cd2125759ffbbbe3db4e934feaeae
Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
2016-01-06 16:02:20 +00:00
Błażej Szczygieł
1606a0e508 QDesktopWidget::screenNumber(QWidget*): check virtual sibling screens
Find the root widget only when more than one virtual desktop exists
and find the screen index using virtual siblings from this root
widget.

Use intersecting rects instead of middle point to obtain the screen.
This can help to get the screen index when the middle point is outside
the screen geometry, but part of the window is still on the screen.

If the widget is completely outside the screen geometry, -1 is
returned.

This commit amends: a6b2a4642f

Change-Id: I80247fc1956a82c487ee6f728d1576bf48b28748
Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
2016-01-06 16:02:13 +00:00
Błażej Szczygieł
f3114120f2 QtGui: Don't set a screen to a child window
This is a partial revert of eaa3a9d010

Task-number: QTBUG-50081
Change-Id: Ic3dc4daa90d7a968a4ebf45d3029c99a12985686
Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
2016-01-06 15:58:36 +00:00
Marc Mutz
14a5a175ae QFontDialog: optimize allocation of QFontDialogOptions
Use QSharedPointer::create(), to fuse control block and
payload into a single memory allocation.

Change-Id: I8d87c73566c3be960e957ec0b5419a77da2fc8c9
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2016-01-06 13:54:59 +00:00
Marc Mutz
caee8f6107 Unbreak ubsan developer-build
GCC 5.3's undefined-behavior sanitizer checks that the
declared type of the object is a base class of the
dynamic type of the object on each access to a member
of a class type.

It therefore requires the typeinfo for these types,
which for polymorphic types is emitted in the TU where
the vtable is emitted, too.

QFileDialogPrivate is a polymorphic non-exported class,
so this failed at link-time. Ditto for the other cases.

Fix by autotest-exporting the classs.

Also, where applicable, de-inline the dtors, so the
vtable (and typeinfo) are pinned to one TU, and the
ctor, just because it's the correct thing to do.

Change-Id: I2b7dba776282a2809c80eb2bc36440d7d698f926
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2016-01-06 13:54:45 +00:00
Oliver Wolff
6060ffff88 Fixed recently added "excess colon in front of brace" qmake warning
Change-Id: I3a650bb4e27cad00f639e6445c36fa8b69edb5b9
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2016-01-06 13:47:40 +00:00
Joerg Bornemann
6e823d2832 WinCE: Remove QIncrementalSleepTimer from QProcess::waitForFinished
Remove a superfluous loop and thus the usage of QIncrementalSleepTimer
from QProcess::waitForFinished. We just wait for the process handle.
There's no need for a loop that checks multiple wait conditions.
This enables us to remove QWindowsPipeWriter from the Windows CE port in
a subsequent commit.

Change-Id: If6a82405227cf145263dba3726bae959e6871d0e
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2016-01-06 13:07:50 +00:00
Marc Mutz
50ab7c16d4 QString: prevent resize() from shedding capacity
...even if reserve() hasn't been called before.

[ChangeLog][QtCore][QString] resize() will no longer shrink the
capacity. That means resize(0) now reliably preserves capacity().

Change-Id: If499a20990bbf3a20553da14e50a42918d310c9f
Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
2016-01-06 13:07:31 +00:00
Harald Meyer
81ee6e763e Fixed crash on iOS devices due to unsupported selector.
Added check for traiCollection selector.

Task-number: QTBUG-50159
Change-Id: Ie3efafe9e22e59aef862a681ad733f2bb0a5ba49
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
2016-01-06 13:06:16 +00:00
Friedemann Kleint
a62132b22c Diaglib: Output more information about QWindow.
Output surface class/type, screen name and scaling factors.

Task-number: QTBUG-50206
Change-Id: I88d3494962b29985cd9e492c1761361b73e0172e
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
2016-01-06 13:04:59 +00:00
Edward Welbourne
4f7a72c1ef Remove doc for non-existent QTest::qCompare() variant.
There's no variant with bool first argument.

Change-Id: Ib18b50ed6271d21253d075dc72b6e2b8744cf131
Reviewed-by: Topi Reiniö <topi.reinio@theqtcompany.com>
2016-01-06 10:03:49 +00:00
Friedemann Kleint
e8747d9e9f Windows/DirectWrite: Dynamically load GetUserDefaultLocaleName().
The function is not available on Windows XP.

Task-number: QTBUG-50188
Change-Id: I4ded1a4eb37af84979c3ce1a9af0d95da60b56ac
Reviewed-by: Kai Koehne <kai.koehne@theqtcompany.com>
2016-01-06 10:00:57 +00:00
Volker Krause
b1dcdc4064 Avoid unnecessary detaching of the pending deletions list.
This code seems to be hit three times per frame in a hybrid QQ2/Qt3D app,
quickly generating thousands of allocations here via the detach in begin().

Heaptrack confirms they are all gone now.

Change-Id: I7d09f3f5c2b24a2590b701216715055751306e82
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
2016-01-06 09:43:19 +00:00
Timur Pocheptsov
daeed4631a Blacklist failing tst_QFile tests (OS X)
openStandardStreamsFileDescriptors and openStandardStreamsBufferedStreams
fail on OS X: lseek somehow works on sequential streams (standard streams)
but QFile has pos() == 0 (since it's sequential).

Change-Id: I6a6161c012a91de189f59c533880fb8fe7a66d37
Task-number: QTBUG-49841
Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
Reviewed-by: Tony Sarajärvi <tony.sarajarvi@theqtcompany.com>
2016-01-06 09:38:55 +00:00
Edward Welbourne
e5724533e4 Remove declaration of method nowhere defined
Change-Id: Ia95aac626803a85fea0bc0bc99972eb34215d351
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@theqtcompany.com>
2016-01-06 09:10:38 +00:00
Takumi ASAKI
83dedc5b74 Fix potential crash in FreeType font database for WinCE
Change-Id: Iea922c2561d59a67cc26c300325a3f198baaafa7
Reviewed-by: Andy Shaw <andy.shaw@theqtcompany.com>
2016-01-06 01:14:57 +00:00
Błażej Szczygieł
0b3da1907d xcb: fix drag and drop when window is hidden
This patch fixes drag and drop operation on XCB platform when window
will be hidden. The window can be hidden during dnd operation by
switching virtual desktops or by minimizing all windows (show desktop)
using key shortcut.

The ShapedPixmapWindow must grab mouse before dnd operation if mouse is
not grabbed by other window (like in Qt4).

Task-number: QTBUG-46243
Change-Id: I807bc842719a2d0ea0f4dcb733c06c1fd08813e1
Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
2016-01-05 21:12:34 +00:00
Shawn Rutledge
2d8b0d1cd5 xcb: don't select XInput events on the root window
If we select XInput events, then when the mouse is clicked, there will
not be a fallback to a core pointer event. But a typical Qt application
doesn't own the root window.  If the window manager (such as OpenBox,
Awesome or fvwm) relies on receiving core pointer click events, e.g.
to show a desktop menu, then each time a device is hotplugged while a
Qt application is running, we would select XI2 events and thereby
prevent the window manager from receiving them.

QDesktopWidget's native window is added to m_mapper, even when
it isn't mapped.  Then after hotplugging there's a hierarchy event,
and that calls xi2Select for every window in m_mapper.  The assumption
with this patch is that the root window does need to be in m_mapper
in case the QDesktopWidget is shown (that was done already in Qt 5.1: 
fca94fa5ed), but xi2Select must avoid 
selecting XI2 events on it to fix this bug.

Task-number: QTBUG-49952
Change-Id: I5c160e879d93fadfce14120ef2e89a4f71d4f599
Reviewed-by: Uli Schlachter <psychon@znc.in>
Reviewed-by: Paul Olav Tvete <paul.tvete@theqtcompany.com>
2016-01-05 17:10:43 +00:00
Orgad Shaneh
bddccfb839 Do not use gold linker on Windows
Gold only supports ELF binaries, not Windows PE.

Change-Id: I72b0f944566bbc8713c71b5cd01f217ab55c8103
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2016-01-05 17:07:54 +00:00
Joerg Bornemann
6d6707c8c3 Fix access after delete in GTK2 dialog helpers
Each QGtk2*DialogHelper class owns a QGtk2Dialog. It is possible that
QGtk2Dialog's parent window is destroyed before QGtk2*DialogHelper.
Then the QGtk2Dialog is destroyed, because of the QWindow parent/child
relationship. Before destroying QGtk2*DialogHelper,
QQuickPlatformFileDialog calls QGtk2*DialogHelper::hide, which will
then operate on the already destroyed QGtk2Dialog.
  Break the parent/child relationship when QGtk2Dialog's parent is
destroyed.

Change-Id: Ie2bda234f759e7bf4d0642accd82fdc38e0379c2
Task-number: QTBUG-49203
Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
2016-01-05 16:09:22 +00:00
Sérgio Martins
a1702da020 Don't detach QGradientStops
Change-Id: I1ae84d0ae825e9fb474d4fab45b0c475a3878b25
Reviewed-by: David Faure <david.faure@kdab.com>
2016-01-05 15:00:49 +00:00
Maurice Kalinowski
e0cc6e5b8e winphone: Invoke windeployqt twice unconditionally for vcproj
In 50bf54c invoking windeployqt was only required in release mode as
MDILXapCompile was not invoked for debug builds with Visual Studio 2013.
However, Visual Studio 2015 invokes MDILXapCompile for debug and
release. Hence we have to use this workaround unconditionally.

Also we cannot limit this to msvc2015 host specs only, as older projects
still might be loaded with Visual Studio 2015 causing the build to
break.

Task-number: QTBUG-49815
Change-Id: Ia120a392967319b945a9746ad489f2db0eed7156
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
2016-01-05 13:05:00 +00:00
Maurice Kalinowski
3c086e50d3 winrt: handle PrelaunchActivated property to pass certification
Windows 10 requires apps to handle the PrelaunchActivated property. This
enables a faster startup by launching an app and immediately suspending
it. This happens by the system and at the time the user launches the app
no library loading or initialization is required.

By default we opt-out of this and return early. The reason is that we
cannot know the type of application written in Qt and whether it breaks
the guidelines by using prelaunch. For further details check here:
https://msdn.microsoft.com/en-us/library/windows/apps/mt593297.aspx

Task-number: QTBUG-50292
Change-Id: I4d0b0b95a03f93b99211d042895404a88ea7cb9d
Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
2016-01-05 13:04:09 +00:00
Oliver Wolff
275f182872 winrt: Added timeout to await function
Instead of using a "custom wait function" in cases,
where a timeout is needed (like in qhostinfo_winrt.cpp)
we should have the timeout as part of our await
function.

By having one common place to handle this, we can avoid
unnecessary warnings, that might be caused by custom
functions. The current implementation in qhostinfo
for example causes at least 1 "originate error"
exception per call.

Change-Id: I7b6cfdfd861af2b0d271465eecaefe4a93e3109b
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@theqtcompany.com>
2016-01-05 08:14:37 +00:00
Oliver Wolff
452a27e1f0 Winrt: Show message when command line processing fails/usage should be shown
Change-Id: If8f69906beb22f632ccbde92aab5caf914dcb31b
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
2016-01-05 08:14:35 +00:00
Oliver Wolff
47b5b5d106 winrt: Use "await" with its timeout for dns queries
By using await instead of using a custom wait function we
get rid of a lot of "function was called at an unexpected
time" warnings and use the default way of waiting for an
asynchronous function to complete.

Change-Id: I6c5bf73ccf68a219b8f3facd3531873d7e8d4c67
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@theqtcompany.com>
2016-01-05 08:14:32 +00:00
Oliver Wolff
190c76f685 winrt: Use winsock2 API for hostname resolution on WinRT/WinPhone
That API has been available for WinRT and Windows
Phone for some time now. By using it to get the
machine name and for hostname resolution we can get
rid of some winrt-only code and use qhostinfo_win.cpp
on WinRT and Windows phone as well.

Additionally the required capability was added to
tst_qhostinfo so that this auto test can be run without
any manual editing.

Change-Id: I63fa5521bf8cdb0c919bd5a0100ea977c865622a
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@theqtcompany.com>
2016-01-05 08:14:31 +00:00
Samuel Nevala
2ca20724dd WinRT: Add camera button events on Windows Phone
Windows Phone 8.1 provides access to the camera button and press/release
events get passed as Key_CameraFocus and Key_Camera. Unfortunately a
release does not provide what has been pressed before, hence this
information needs to be cached when the press happens.

Done-with: Maurice Kalinowski<maurice.kalinowski@theqtcompany.com>
Task-number: QTBUG-39115
Change-Id: I6ce58a1f07a6bf7183b8d99a26e5cd7b0d32d6db
Reviewed-by: Topi Reiniö <topi.reinio@theqtcompany.com>
Reviewed-by: Samuel Nevala <samuel.nevala@intopalo.com>
Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
2016-01-05 08:14:28 +00:00
Timur Pocheptsov
4ed8733d90 tst_Gesture - fix failing tests on OS X 10.11
This test seems to be quite broken on OS X: qWaitForWindowExposed returns
too early (while no window is on screen) so gestures can not be dispatched
QApplication::topLevelAt(pt) - returns null.
Use qWait + isExposed combo instead (similar to qWaitForWindowExposed, but
there is no isExposed test before the loop).

Change-Id: I85fbd773ccce0ca92b2dceb1749d67ef767aa0cf
Task-number: QTBUG-49849
Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
2016-01-05 06:08:18 +00:00
Timur Pocheptsov
60c333caba QMacPanGestureRecognizer - stop timer on 'reset'
_panTimer has a target - for example, widget. 'reset' should stop this timer.
The problem (quite subtle and difficult to reproduce) found in tst_QTouchEvent:
widgets created/destoryed by different tests but we still can have a timer
waiting for event dispatcher to 'processEvents', firing with now-invalid
dangling pointer - 'target'.

Change-Id: Iccaf3368a8ee6a0a2f60e9dcdf5d40fb7392ca21
Task-number: QTBUG-49844
Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
2016-01-05 06:08:03 +00:00
Mauro Persano
0cee94017f QOpenGLTexture: fix target for compressed textures
Trying to set data for a compressed cubemap texture face fails, because
the code incorrectly tries to bind to a cubemap face target.

This was already fixed for uncompressed textures. Instead of duplicating
the code, moved the texture binding/unbinding code to a RAII class.

Change-Id: I8f1cb7fc661b919200f85c3465d6e6e3c22d0871
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
2016-01-04 19:49:34 +00:00
Friedemann Kleint
0c60dda872 QWindowsTheme: Fix return type of helper dWordSystemParametersInfo().
QApplication::wheelScrollLines() was always 1 due it being a bool.

Task-number: QTBUG-49561
Change-Id: I83e97da3507c31dfd024db7bf543c4e6a3b4a98b
Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
2016-01-04 16:28:31 +00:00
Mitch Curtis
c19216cbea Fix QPainter::rotate() documentation
Change-Id: I5d11f84181cad9be644e850c83459b47ec2f2f15
Reviewed-by: Topi Reiniö <topi.reinio@theqtcompany.com>
2016-01-04 16:25:58 +00:00
Edward Welbourne
374d35d5ba Make use of preprocessor easier to understand.
The #if had a condition that was needlessly hard to understand;
and was widely separated from its #else clause.

Change-Id: I43f4282993f4f2e8c4b5ad07dc2c2e06a6b95aa9
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@theqtcompany.com>
2016-01-04 13:59:14 +00:00
Błażej Szczygieł
eaa3a9d010 Fix crash because of NULL screen in QXcbWindow
Change-Id: If7bbe3ad1656dadcb098bcd3ece2e7b064eeb44d
Task-number: QTBUG-50081
Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
2016-01-04 13:22:39 +00:00
Samuel Nevala
7fdfaad43f Fix deadlock when setting environment variables.
Qt uses QHash as the container for faking environment variables on
Windows Runtime and CE. Environment variable manipulation functions are
protected by mutex. Accessing the QT_HASH_SEED environment variable
inside QHash can lead to situation where qputenv() call leads to
qgetenv() call and that leads to a deadlock. Change the container
from QHash to QVector to avoid deadlock.

Task-number: QTBUG-49529
Change-Id: I550ead4ab12e7abebc044f52339063a44fcf0170
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@theqtcompany.com>
2016-01-04 13:12:19 +00:00