The C++ standard says it must, but some badly-configured toolchains seem
to be lacking support.
In particular, for some 32-bit platforms without native support for
them, GCC implements 64-bit atomics via out-of-line functions in
libatomic. If that library is missing... well, then std::atomic 64-bit
doesn't work and we mustn't try to use it.
This was found when trying to compile Qt 5.6 for MIPS 32-bit:
Linking library libQt5Core.so.5.6.0
.obj/qsimd.o: In function `std::__atomic_base<unsigned long long>::load(std::memory_order) const':
/opt/poky/1.7/sysroots/mips32r2-poky-linux/usr/include/c++/4.9.1/bits/atomic_base.h:500: undefined reference to `__atomic_load_8'
.obj/qsimd.o: In function `std::__atomic_base<unsigned long long>::store(unsigned long long, std::memory_order)':
/opt/poky/1.7/sysroots/mips32r2-poky-linux/usr/include/c++/4.9.1/bits/atomic_base.h:478: undefined reference to `__atomic_store_8'
Yocto bug report: https://bugzilla.yoctoproject.org/show_bug.cgi?id=8274
Change-Id: I42e7ef1a481840699a8dffff140224d6614e5c36
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
(cherry picked from commit 3d7586b760)
Reviewed-by: Dmitry Shachnev <mitya57@gmail.com>
[ChangeLog][Platform Specific Changes][OS X] Configure with -no-rpath
will now yield Qt dynamic libraries and frameworks with an absolute
install name (based in -libdir).
OS X package managers like Homebrew install Qt in a fixed location. This
change simplifies deployment for such package managers and is consistent
with the default expectation on Apple platforms for libraries with a
fixed location to also have absolute install names.
While a relocatable installation (the default) also works in this
scenario, it requires all software that depends on Qt to be aware of
this and to embed a suitable RPATH into application binaries (which is
not automatic for non-qmake builds). This might not be true for some
select fallback search locations, but as package managers on OS X tend
not to use those, embedding an RPATH becomes practically mandatory. In a
default Homebrew installation, Qt is configured such that the frameworks
end up in /usr/local/Cellar/qt5/<version>/lib and that will be later
symlinked to /usr/local/opt/qt5/lib, both of which are not searched by
the dynamic linker by default.
Task-number: QTBUG-48958
Change-Id: I4395df98771e06a2ce8a293d11dc755bdc50757f
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
The ifdef gave an impression of the code path being hit only when
texture-backed widgets are present and OpenGL-based compositing is
active. This is false. Asserting on having a context current is
wrong (as shown by autotests on the 5.6 branch).
Change-Id: I2539f0aac75b26597f49f63edcd9580428be79b7
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
Set the DXGI_MWA_NO_ALT_ENTER to suppress the Alt-Enter shortcut
causing the window to become full screen.
Task-number: QTBUG-44904
Change-Id: Ia4156ddee37a8a3da6e9e3130022c63a674f4429
Reviewed-by: Andrew Knight <andrew.knight@intopalo.com>
Ideally all printer drivers would add beyond DMPAPER_USER for their custom
sizes. However some printer drivers add beyond DMPAPER_LAST instead so we
need to check if the value is past DMPAPER_LAST and consider those as a
custom size.
Task-number: QTBUG-47272
Change-Id: I1bcb01c08fe605cc484769b0301cfcd7b8f66157
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
The change 8c0f47cfae17a39137dec47aa0b9f3f9bedad introduced a problem
where if the widget was being reparented had a valid HWND then it would
cause the focus to change inside the already active window. Therefore we
need to limit the times it does this to the case where we know it needs to
be done which is the ActiveQt case.
Change-Id: Ia85f5136661142b25952e0ebf66f8a43d9500d58
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Andy Shaw <andy.shaw@theqtcompany.com>
SSLSetProtocolVersionMin/Max were introduced _only_ in 10.8 and
we need a workaround for 10.7 - use SSLSetProtocolVersion or SSLSetProtocolVersionEnabled.
Change-Id: I4b7ed9fda21e2c374a98fd777253280e8013ffde
Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
On OS X SSLCreateContext is quite recent - it requires OS X/SDK version
>= 10.8. Since SecureTransport back-end is the default one in Qt 5.6,
make it also work on OS X 10.7.
Change-Id: I364feff9dd95772fcea926494b2d4edaffd2dde1
Reviewed-by: Morten Johan Sørvig <morten.sorvig@theqtcompany.com>
Neither the default nor the eglfs-specific backingstore release the OpenGL textures
that are in use when render-to-texture widgets are involved.
The result can be fatal on embedded devices that run out of GPU memory at after showing
and closing dialogs and popups a certain number of times.
Task-number: QTBUG-49363
Task-number: QTBUG-49399
Change-Id: Ia7471b037f147bcca0a4f1db5808ca348e230547
Reviewed-by: Lars Knoll <lars.knoll@theqtcompany.com>
Reviewed-by: Andy Nichols <andy.nichols@theqtcompany.com>
When we changed sending key events through QPA instead of directly to
the focus object, we only flushed from deleteBackward (06be9f026). The
reason was to avoid unnecessary flushes, as this in general can be a
source to recursion problems.
It turns out that this is also needed when sending Qt::Key_Return. The
reason is that we sometimes resign first responder when the return key
is pressed, which will also change the focus object in Qt. And without
flushing the key event first, it will be processed after the change and
therefore end up at the wrong object.
It seems like the most sensible thing is to always flush upon receiving
spontaneous key/text events from iOS, which is also how it was before.
Task-number: QTBUG-49021
Change-Id: I44885a11275dee5039ef6a8abbcbdadc092695e7
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
Wrap related code in QNativeSocketEngine and the tuiotouch
plugin in conditionals.
Change-Id: Ic6861b1c6a9e041fa8a50f96149f7280473a9fba
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This is follow-up for QTabBar fix ea47d152b3.
In native OS X applications using mouse wheel on combo boxes have absolutely no
effect. We should bring the same behavior to Qt based OS X apps too, as users
are complaining of unexpected behavior, eg. randomly switching Qt Creator
sidebar mode when scrolling file list and moving mouse pointer little bit
above. Moreover inertial mouse behavior on OS X makes combo box usually move
several indexes, rather than single one on slight finger slide.
This also applies to iOS apps so the change affects all Apple platforms.
Task-number: QTBUG-10707
Change-Id: I6582265039198707ad8c2f54de96ee2a0b0e0b47
Reviewed-by: Adam Strzelecki <ono@java.pl>
Reviewed-by: Jake Petroules <jake.petroules@theqtcompany.com>
When inheritedMask is 0, the font inherits just everything; in this case
`inheritedFont.resolve(baseFont)` could be replaced with `baseFont`.
Change-Id: Ic3ed8ef174493544ada32037e7bdded46eb4bd43
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@theqtcompany.com>
The "previous" value is always 1 when the compare-and-swap succeeded,
instead of the previous value.
Instead of fixing this, let's just remove this file a bit earlier than
the rest. All of them will be removed in Qt 5.7 anyway, so let's leave
MIPS atomics to the compiler.
Task-number: QTBUG-49168
Change-Id: Idba8c29717f34c70a58fffff14133304595165f5
Reviewed-by: Dmitry Shachnev <mitya57@gmail.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Lisandro Damián Nicanor Pérez Meyer <perezmeyer@gmail.com>
A QAbstractSocket can be close()'d at any time, independently of its
current connection state. being closed means that we cannot use it to
read or write data, but internally it might still have some data to
send or receive, for example to an http server. We can even get a
connected() signal after close()'ing the socket.
We need to catch this condition and mark any pending data not yet
written to the socket for resending.
(cherry picked from commit 0df5d07929)
Task-number: QTBUG-48326
Change-Id: I67d9ad36f7288c9c6bef51aa6253d7b187737601
Reviewed-by: Ulf Hermann <ulf.hermann@theqtcompany.com>
Reviewed-by: Markus Goetz (Woboq GmbH) <markus@woboq.com>
glslang_tab.cpp was not created in the right subdirectory.
This amends commit 69167189.
Change-Id: I031499baa53b72a1923883c58eb5ddfc2a02789a
Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
After canceling the asynchronous read operation, the
notified() slot receives ERROR_OPERATION_ABORTED.
We must not handle this situation as an error.
This amends commit 5ce567c5.
Task-number: QTBUG-48336
Change-Id: Iff948ceb3ad1f805a9de8c188fbc39ed4c76ba82
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
A recent change uses an accessibility function even if accessibility
is disabled.
Change-Id: Ibf9afbb90120772065743b2f9dd3615e4e6a2f37
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>
Move touch device initialization code to QWindowsContext and
replace the assert on the touch device in QWindowsMouseHandler
by a call to the initTouch().
Task-number: QTBUG-48849
Change-Id: If8573b8283ef94e7fd015f6edc626e3c8cc0b139
Reviewed-by: Joni Poikelin <joni.poikelin@theqtcompany.com>
Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
Reviewed-by: Andreas Holzammer <andreas.holzammer@kdab.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Since there are circumstances where the session is not yet created after
start() is called then we should check if the session is valid before
connecting to it.
Change-Id: I94236f76e4be2433a8c96eb91ce2d4b4d42f2fd9
Reviewed-by: Richard J. Moore <rich@kde.org>
- On NetBSD, the defines were not properly defined;
- On all other BSD systems, we use statfs which does not have f_frsize
member, revert to using f_bsize there.
Task-number: QTBUG-48267
Change-Id: Ia1ed484ac61a615fcbb5b45affb516b5e86a64b0
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Lisandro Damián Nicanor Pérez Meyer <perezmeyer@gmail.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The flex and bison rules generated the same files for debug and release.
This conflicts in parallel builds, e.g. when using jom.
Task-number: QTBUG-49003
Change-Id: I6f64760d83292e8bfad6fd0b4f8fbdd386e2213b
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
[ChangeLog][QtCore][Android]
Fixed the opening of a local file using QDesktopServices::openUrl().
For a local file to be viewed with
QDesktopServices::openUrl(), Android needs to be given
the MIME type otherwise it does not start an Intent to view the file.
Task-number: QTBUG-45585
Change-Id: Ifcfce4bff35011f205cfadbdb2b37a1780dac87d
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
Do not emit _q_notified when we're in a wait function. Otherwise,
the queued signals could pile up in the event queue.
Task-number: QTBUG-48653
Change-Id: I071863e2356e17c7004e3b7ca359967cb115e343
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
That is the case on Hurd, where the code currently breaks because Hurd
does not have WEXITED or WNOWAIT defined.
Change-Id: I4b13633612b1168d36c949d9e8b35bc05bca7d5c
Reviewed-by: Lisandro Damián Nicanor Pérez Meyer <perezmeyer@gmail.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The QSslSocket::addCaCertificates() variant that takes a path
argument uses QSslCertificate::fromPath() in its implementation.
Edit the description of the former to match that of the latter.
Fix minor issues in QSslCertificate::fromPath() documentation;
add a missing word, limit code snippet line width.
Task-number: QTBUG-47359
Change-Id: Ibead74c998503e60a67d0b8eb551536bd20feff8
Reviewed-by: Venugopal Shivashankar <venugopal.shivashankar@digia.com>
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@theqtcompany.com>
Reviewed-by: Richard J. Moore <rich@kde.org>
Compare against isVisibleTo() in QLineEditIconButton::actionEvent()
so that action events received before show() are handled correctly.
Fix a regression introduced by change
4dccb2ca67 for handling action
events causing side widgets to overlap when added before the widget was
shown. Use QAction::isVisible() to determine visibility.
Task-number: QTBUG-48806
Task-number: QTBUG-48899
Task-number: QTBUG-39660
Change-Id: I7a39a3b9a094f2c74cde09544f1158deb2b81cf2
Reviewed-by: David Faure <david.faure@kdab.com>
Remove the insignificant_tests CONFIG option in favor of a BLACKLIST
file. The test blacklisted have been found using CI builds logs.
Change-Id: Iac07316862cff9b5085dacdf9f35e691cff09384
Task-number: QTBUG-27571
Reviewed-by: Janne Anttila <janne.anttila@digia.com>
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com>
Without QT_BEGIN/END_NAMESPACE, the qt_mac_socket_callback is not resolved as
a friend function of QCFSocketNotifier, which is required due to access to
private members of QCFSocketNotifier.
Change-Id: Ief89e18f8b4f7fc4cb013a33959db1dd90eb9efe
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
Don't call showSoftInput() if the state is set to _HIDDEN or
_ALWAYS_HIDDEN by the user.
Task-number: QTBUG-46528
Change-Id: I5dbaf612cf4f339c5288d6d3292c27cc6217f3af
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
Removing and adding a view each time the layout parameters changes is
triggering unnecessary layout updates. The affect of this is not very
visible since there are few views in the layout, but the procedure is
never the less wasteful.
Change-Id: I2540ab519b12c6d3e10457e2e518b439118b966d
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
Don't use gst_is_initialized(). It was added in 0.10.31, but we don't
actually require that version.
Change-Id: If5d662e18511cf636861bf93eeccc1f5b69e26f1
Reviewed-by: Christian Stromme <christian.stromme@theqtcompany.com>
After calling connectToHost(), the socket enters HostLookup state. At this
stage, the socket engine was not created yet, and writing to the socket
should result in either data buffering or an error. So, add a check for
d->socketEngine to prevent a crash on unbuffered sockets.
Task-number: QTBUG-48356
Change-Id: I15ea9ce7de97ce6d7e13e358eca5350745b556bb
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Richard J. Moore <rich@kde.org>
In case of a lock failure, we potentially pollute the errno value
before printing it. Also, switch to qt_error_string, as strerror
is not reentrant.
Change-Id: I952aac14204637155726bcefc0ed8a21d7fcd501
Reviewed-by: David Faure <david.faure@kdab.com>
Calculation was working as long as one didn't use per pixel scrolling.
Task-number: QTBUG-48579
Change-Id: Ie02e28b008c5c81ed45d7dd17fed96148c23b598
Reviewed-by: Thorbjørn Lindeijer <bjorn@lindeijer.nl>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: David Faure <david.faure@kdab.com>
If QT_NO_CURSOR is defined then changeCursor() is not implemented in
QPlatformCursor which means that it isn't really being overridden in the
offscreen plugin. Therefore the same define is checked for to prevent a
compiler from having a problem with it.
Change-Id: Id7c104292354cb7462b3161602fc8d382a6dd390
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>