This patch is a forward-port from 4.8 branch
(d869e1ad4b0007757e97046609de2097cd9e9c5d).
Change-Id: I6ae36a5417d1176fbecf775668f6033b1cb22a94
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Adds a configure check for System V and POSIX IPC.
System V takes precedence over POSIX IPC, and if both
are not supported, QT_NO_SHAREDMEMORY and
QT_NO_SYSTEMSEMAPHORE are defined.
This patch is a forward-port from 4.8 branch
(6ef4abaa9cd7d465cbae5cbf8cb4664bef387d10).
Change-Id: I3ec20342f0f0266843479634109b67c6989dd296
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This removes one of the last references to 10.6.
Change-Id: Ie23d9aba698714460e7478a421e85d4ad50d4ec9
Task-number: QTBUG-43505
Reviewed-by: Liang Qi <liang.qi@theqtcompany.com>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
Exposes two options from libjpeg: the optimize option and progressive scan option.
These are both lossless operations, so they do not change the image's quality.
Using these switches can result in smaller jpeg files.
Task-number: QTBUG-20075
Change-Id: I8d0bd6a712b8a365265b7bd517e136b0755b90cb
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
Reviewed-by: aavit <eirik.aavitsland@theqtcompany.com>
Do not include other headers from the main qlibinputhandler_p.h that
serves as the external interface to the generic plugin for example.
This way the clients do not need to care about xkbcommon headers and
such.
Task-number: QTBUG-43498
Change-Id: I56335cb19200fee830bdf4b1d203904f741f7489
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
Detect OS kernel version 10.0 as Windows 10.
Task-number: QTBUG-43413
Change-Id: I39307cf8cc2e7cc209d6a88b8576db87086fa20e
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
And only export those functions which are actually out-of-line.
This prevents exporting all the inline methods of QVersionNumber,
so we can more freely tune the implementation after its release.
Change-Id: Ie0c5e3f95fea9ec9b3dd481058db6c9f5ef2653c
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Following c61f8df404, we now prefer overloading
toString() in the type's namespace over specializing the primary template.
Let the docs reflect that and add an example. Also suggest to delegate the messy
raw char pointer handling to the existing toString(QString)/toString(QBA)
overloads.
Change-Id: Id76181faba86aea52588611ea64ea9b95371a733
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The member functions are a bit more complicated, since they require
<type_traits> support, so they're left for another commit.
Change-Id: Icb792468e35c63eb1ae97f62ed023266fb86b89b
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This greatly increases the value of qSwap(), since not only does it
automatically do the parallel std+ADL lookup of swap(), but also
now centralizes the rather messy code involved to create a correct
noexcept specification.
Other code now can simply use
Q_DECL_NOEXCEPT_EXPT(noexcept(qSwap(lhs, rhs))).
Change-Id: Ia35df4876b143e86c4150ac452a48c3775c3702b
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This is mostly straight-forward, but some things are worth noting:
1. Yes, this is necessary. The noexcept operator looks for noexcept tagging,
not at the contents of the function to determine whether to return true.
The more conditionally-noexcept functions are used, the more important it
becomes that low-level classes are correctly marked noexcept. In that, it
is like constexpr.
2. In accordance with the rules governing noexcept specifications for the
standard library itself, the operator/-family of functions are not marked
as noexcept, since they have preconditions and thus a narrow contract.
Narrow-contract functions should not be noexcept. All other functions
have wide contracts (ie. no preconditions).
Change-Id: I2cb1f951a92dcb25eac4d9afc5b7780311e39492
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This is mostly straight-forward, but some things are worth noting:
1. Yes, this is necessary. The noexcept operator looks for noexcept tagging,
not at the contents of the function to determine whether to return true.
The more conditionally-noexcept functions are used, the more important it
becomes that low-level classes are correctly marked noexcept. In that, it
is like constexpr.
2. In accordance with the rules governing noexcept specifications for the
standard library itself, the get*()-family of functions are not marked
as noexcept, since they have preconditions and thus a narrow contract.
Narrow-contract functions should not be noexcept. All other functions
have wide contracts (ie. no preconditions).
Change-Id: I82e5d34a0293d73ddc98ee231e17e26463ab6686
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
%{threadid} should have been %{qthreadptr} but we forgot to make the
change for Qt 5.4. So do it now.
[ChangeLog][QtCore][Logging framework] %{threadid} now prints the real
thread ID. On Linux, OS X, iOS, FreeBSD and Windows, the value is unique
system-wide. On other systems, it will print something that may be
process-specific (the value of pthread_self(3)). To print the pointer
to QThread::current(), use %{qthreadptr}.
Change-Id: Ie383ff864a11966cf5d095b966a30ace65d34ee6
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
...because transposed() is inline (and transpose() is not).
This is such a simple transformation (basically, a register rename)
that it should be inlined, even a the expense of another assignment.
(the expense being in the source, not the executable code, of course).
Change-Id: I4e5a574e899a84444de8042d305f34f5a6045a3e
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
...because transposed() is inline (and transpose() is not),
and because it makes the code more readable and compact.
Change-Id: I5661ee6251be638fb40c5c748aa50a89de6f7735
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This is mostly straight-forward, but some things are worth noting:
1. Yes, this is necessary. The noexcept operator looks for noexcept tagging,
not at the contents of the function to determine whether to return true.
The more conditionally-noexcept functions are used, the more important it
becomes that low-level classes are correctly marked noexcept. In that, it
is like constexpr.
2. In accordance with the rules governing noexcept specifications for the
standard library itself, the operator/-family of functions are not marked
as noexcept, since they have preconditions and thus a narrow contract.
Narrow-contract functions should not be noexcept. All other functions
have wide contracts (ie. no preconditions).
Change-Id: I9fc94218a2728c272483f9c2826c265f5b11c9b4
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The methods where introduced with commit 01fb843af8, but removed before
the next release in a1898f4466.
Also add a comment that we should get rid of the special Q_CC_MSVC
handling in Qt 6.
Change-Id: I8bb992a59f31a0de7e3f14f34d1d4f604ebfe8f3
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
This should be completely source-compatible, aside from the indirect
header order change.
Change-Id: I4cf8800ea1bfeb3023c7319991ab8ae281c925e8
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
... which is the module-wide include, bringing in the entire QtCore.
Change-Id: I5cd872efa4562917fc4e3850809cb7595710c43a
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Since some of the algorithms use other ones, we should not warn about
those. The warnings are supposed to happen only in user code.
Warnings obtained with GCC 5. The Clang change is just to be on the safe
side.
Change-Id: If295899f6ff6534de7b19741d33efc0b5c4c912c
Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
It's been there forever, but never used. The timeout is set during the
actual call.
I moved QDBusMessage::type only for padding purposes.
Change-Id: I41dd638ac423078be642077dbf17439d15b5d405
Reviewed-by: Richard J. Moore <rich@kde.org>
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
Instead of the libdbus-1 constants. Though they're exactly the same
because they are based on the protocol wire format, so this is
technically a no-op change.
Change-Id: Ia2c638c4b508497ca693afd9c76e60ba9245f5e7
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
This has been deprecated since QDBusContext was introduced (Qt 4.3). So
it's time to remove the functionality.
[ChangeLog][Important Behavior Change] QDBusConnection::sender()
(deprecated since Qt 4.3) has changed to always return an invalid
QDBusConnection. To know what connection the incoming call was received
from, use QDBusContext.
Change-Id: I355efb82c14e54ed718c8f892d8267e727b19118
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
This makes the output slightly easier to read.
Change-Id: I590b9abcb0263ae5f0580391b42e179c47569a8a
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
Very useful to track memory leaks and other silly stuff going wrong.
Requires C++11, but since it isn't enabled by default, it's not a
problem. ALso, only works with "runtime" dbus -- for linked, use
ltrace(1) instead.
Change-Id: Iccb18516cfb729b2b1bf9ee592df4a1adefeb3b7
Reviewed-by: Alex Blasche <alexander.blasche@theqtcompany.com>
This does not try to remove support for RVCT. There has been no report
of it working or failing to work, so the status continues to be unknown.
In particular, the inline assembly code in atomic_armv[56].h remains in
place.
This commit only removes workarounds for compiler bugs or bogus
warnings, assuming that anyone using this compiler has updated since Qt
last tried to use it for Symbian in 2011. Note also how anonymous unions
are now part of the language in C++11.
Change-Id: Idc4fab092beb31239eb08b7e139bce2602adae81
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Some example code creates the backing store before the platform window.
Make this case working by calling create().
Task-number: QTBUG-43543
Change-Id: I29c260f38eddd15ea09931e814c5dbd031b65505
Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
With non-monospaced fonts the dialog constantly resized itself when hovering
with the mouse.
This patch has the side effect of fixing another annoyance. Don't present duplicated
information to the user, the color name is already shown in the HTML line edit
and it's also updated dynamically.
Task-number: QTBUG-43448
Change-Id: Ieaeda2a5b876cf15391616aed7d30ed352b463df
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
Fixes warning with MSVC:
config.cpp(973) : warning C4996: 'getenv': This function or variable may be unsafe
Change-Id: I32d2a521ff82ee9779fbcba76e80ef36a8e02094
Reviewed-by: Martin Smith <martin.smith@digia.com>
QFileSystemWatcher does not signal directoryChanged() when files are
modified in a watched directory. QTBUG-8945 was closed with the
decision that it should not signal. Updating the docs and tests to
reflect this fact.
The test code that is being changed is a partial revert of Qt4 commit
1428cc6d71a65c1ac7123c9c4cc3cfaf225cceed. It appears that Symbian
supported directoryChanged() on modification, hence why the check
was for 0 or 1.
Change-Id: I04320c68f227ca338ce65e525956ee201fd50699
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Robin Burchell <robin.burchell@viroteck.net>
This is in preparation of adding more qHash()-related tests.
Change-Id: Iae65bf8b123e1d6ac6d1eb34d74ba4eb9df8173c
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Make it compatible with eglfs. The behavior is the same: By default
mouse, keyboard and touch will all be initialized and, when having
libudev support, discovered automatically. The environment variables
QT_QPA_FB_DISABLE_INPUT and QT_QPA_FB_TSLIB can be used to used to
disable the built-in input handlers and to force tslib instead of
evdev, respectively.
This allows embedded systems and applications to easily fall back
from eglfs to linuxfb on devices that are not rendering via OpenGL.
Dynamic hiding/showing of the mouse cursor is to be done separately,
here we provide the necessary device discovery hooks only.
[ChangeLog][QtGui] The linuxfb platform plugin's input device handling
is now compatible with eglfs. The evdev keyboard, mouse and touch code
is compiled in by default.
Change-Id: I44bc661c53ae78c39b0f30486a475b4e639ab2d6
Reviewed-by: Pasi Petäjäjärvi <pasi.petajajarvi@theqtcompany.com>
Reviewed-by: Gatis Paeglis <gatis.paeglis@digia.com>
Coverity (not rightfully) complains that the code is using "iscii",
a uchar obtained by looking up into a table, as an index into the
"uni_to_iscii_pairs" array. Since the array is only 18 elements
long, there's the theoretic risk of accessing it past its end.
However, the lookup of "iscii" never returns values that may
actually go out of bounds. Coverity may be smart enough
to see the values that "iscii" can get and not raise the warning,
but since it does, make the code more robust and add an assert.
Task-number: QTBUG-43642
Change-Id: Id75ca105758b343102ca94137d0379c10e55581a
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
On a small display leftLay is left initialized to a null pointer,
therefore don't try to dereference it.
Task-number: QTBUG-43643
Change-Id: I9d22dac88a3a853ce154a6f64b35fc113abd9262
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Yes, this is necessary. The noexcept operator looks for noexcept tagging,
not at the contents of the function to determine whether to return true.
The more conditionally-noexcept functions are used, the more important it
becomes that low-level classes are correctly marked noexcept. In that, it
is like constexpr.
Change-Id: Ia1aebf9b8d73fd8164c10dfca27a710934ba79a8
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
QCursor already dealt with d == nullptr, so this is trivial.
Change-Id: Ib2c6a3f0dc8b93035ffe3059cdce925463706e10
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Under DBus it is possible to have methods and signals with the same name
or have methods which are reserved c++ keywords.
For example the logind session interface has a signal and method both
called Lock.
This patch allows generated methods to use a different method name
specified in the annotation that the original DBus name in the DBus
interface in a similar manner to how one can rename accessors.
[ChangeLog][QtDBus] Add annotation org.qtproject.QtDBus.MethodName to allow
autogenerating C++ methods with different names to the original DBus method
Change-Id: I08bbe77554fbdd348e93f82d45bab0d75d360c27
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
This makes it possible for the flags that RegisterTouchWindow takes to be
specified after the window has been created.
Task-number: QTBUG-41433
Change-Id: I166143875ef54ab6a249cffb31d017845a694a01
Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
We already let enter/return key presses to reach text edits instead
of closing the editor. Do the same for tab/backtabs.
[ChangeLog][QtWidgets][Important behavior changes] QItemDelegate will
now not close a QTextEdit/QPlainTextEdit editor when the tab key
is pressed; instead, the key will reach the editor.
Task-number: QTBUG-3305
Change-Id: Ife9e6fdc5678535c596d1068770b0963134d8d5a
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Thorbjørn Lindeijer <bjorn@lindeijer.nl>
Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com>
toString() is both a function template and a set of overloaded
functions (for const char* and const void*). So don't explicitly
specify the function template arguments (they're deduced from the
arguments anyway). This enables overloading toString() as well as
specializing the template.
[ChangeLog][QtTest][Important Behavior Changes] toString() can now be
overloaded (instead of just specialized) for custom types, and is now
reliably found through argument-dependent lookup (ADL).
Change-Id: Ic4a622d236ad7f0e4142835353f1b98bf2dc6d4c
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Change-Id: Ia624fcefe77a456424bcaa00b106ef7f69abb6b9
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
Reviewed-by: Jason McDonald <macadder1@gmail.com>
GCC said:
qtldurl.cpp:51:50: error: loop exit may only be reached after undefined behavior [-Werror=aggressive-loop-optimizations]
qtldurl.cpp:51:48: note: possible undefined statement is here
while (tldIndices[index] >= tldChunks[chunk] && chunk < tldChunkCount) {
^
That's because we check whether chunk is still valid (less than
tldChunkCount) after we've dereferenced tldChunks[chunk]. That is, we've
already read tldChunk[2].
Change-Id: I79b6a1ea9a2454813d6cce7596fc2bb6d972d097
Reviewed-by: David Faure <david.faure@kdab.com>