This makes the terminology consistent with Sailfish OS and the QNX QPA.
The kImePlatformDataReturnKeyType in the iOS QPA is not changed to not
break compatibility. Also, improve documentation.
Change-Id: I2780de5b1e9277185ae1d4d9bbc67e36682fbfba
Reviewed-by: J-P Nurmi <jpnurmi@theqtcompany.com>
Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@theqtcompany.com>
De-duplicates vtables and enables RTTI on this class
hierarchy.
Export QFramePrivate, as QAbstractScrollAreaPrivate
(a subclass) is exported, too.
Change-Id: I541886373435dc49c4267190a7191e2436f4c95e
Reported-by: Volker Krause <volker.krause@kdab.com>
Task-number: QTBUG-45582
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Keeping a static variable in an inline function is a bad idea because
each definition of that function will have its own version of the
variable. As qtestmouse.h can be included multiple times in the same
test (via some utility classes as with tst_qquickflickable), this
leads to confusion.
Change-Id: I80f198817c34c3a7e07bf6944189927817efb8a6
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
...but only for Qt 6. It's a source-incompatible change,
e.g. in a user hierarchy of clone()able runnables.
Change-Id: I8610308dea46da19bda5c96985d35f31c43484be
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
De-duplicates vtables and enables RTTI on this hierarchy.
This is esp. important for exception classes, as RTTI is used
to select the catch clause to handle the exception in-flight.
The issue is made a bit complicated by the fact that the
exception specification changed from C++98 to 11 and that C++98
clients require the empty throw() specification while we don't
want to introduce warnings for C++11 users.
Let's hope no compiler includes throw specs into the mangled
names.
Task-number: QTBUG-45582
Change-Id: If086c8c38fccdc2c9c7e2aa7a492192cc1f86a6c
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
It should also be possible to use QT_STRICT_ITERATORS in Qt's own code base
Change-Id: I0914db480d4d2b06e71e3a2588163efdd3ff6d27
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
- Implement init() and cleanup() to verify that
no top level widgets are leaked.
- Position widget in tst_QToolTip::task183679() and set
window title.
- Remove hardcoded wait in tst_QToolTip::whatsThis()
and use a find function within QTRY_VERIFY().
- Rearrange and clean code a bit.
Change-Id: I0b1ad88444fc9441c1071a2527f75de1f68ea9e5
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
Deprecate the qmake variable DEPLOYMENT that was used for installing
files on remote devices for Windows RT and Windows CE Visual Studio
projects. Use INSTALLS for both nmake and Visual Studio projects.
[ChangeLog][core][qmake] Deprecated the qmake variable DEPLOYMENT in
favor of INSTALLS.
Task-number: QTBUG-21854
Change-Id: Ia9d2c69feb7d87b0b9dc69ff7c0a68be35a57acd
Reviewed-by: Oliver Wolff <oliver.wolff@theqtcompany.com>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Calling QCursor::setPos() to emulate mouse move events
is a rather bad idea, as it creates round trips through
the server, leading to timing issues etc.
In addition, we should not call qapp->notify(), but rather
route the events through the proper QPA interface. This
is required to properly generate all other events such
as enter/leave etc. As this breaks existing tests,
put the new behavior behind an #ifdef for now. Like this,
we can fix tests one by one, and then turn on the define by
default for 5.6 (with a changelog message).
We emulate timestamps to avoid creating double clicks
by mistake. In addition, fix QGuiApplication::processMouseEvent
to not push events back into the QPA event queue (as this is
a bad hack and breaks the new testing system).
Change-Id: I71774cb56674d7fb66b9a7cf1e1ada1629536408
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
Corrects a few white-spaces, return statements and else statements
to fit Qt coding style.
Comment updated to indicate how far the code is getting from its
original roots.
No semantic changes.
Change-Id: Ia2288c501788a291bfc4e8b70e8eb1efb7a90128
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Use the last path from QSP to hint that we want to
load photos from the global photo library. This
should currently only make a difference on iOS.
Change-Id: I7a6217dbbbc2e247b69bf406c02001458c757211
Reviewed-by: Shawn Rutledge <shawn.rutledge@theqtcompany.com>
Now we can choose to use separate screens or virtual desktop.
With virtual desktop the geometry of all screens is taken
into account so that the input plugin do not clamp global
pointer coordinates to the first screen anymore, we also
create only one hardware cursor that can now freely move
on all the screens.
Virtual desktop is enabled by default, but the old default
behavior can be restored by setting separateScreens to true.
Change-Id: I78dbf9e8d3dd44f68d33350dc8fc3727bf8a26fe
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
When enabled, all QWindows will be backed by a NSWindow.
This is unlike the default where only top-level
QWindows get a NSWindow.
The QWindow still has (Q)NSView as the NSWindow content
view. The return value of the winId functions are
still the NSView and is not affected by this switch.
Change-Id: I131b89af04c09451a6e7515d1da3f7498f53979a
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>
Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com>
qmake win32 generators by default used values of DEFINES for RC
preprocessor defines, too. For simple defines this works. For
string literals this failed for the .vcxproj files:
DEFINES += "FOO=\"BAR BAR\"" works for CL but fails for RC.
DEFINES += "FOO=\\\"BAR BAR\\\"" works for RC but fails for CL.
This patch introduces the qmake variable RC_DEFINES. The variable
contains the preprocessor defines, that are used for RC. If the
varible is not set, the DEFINES values are used for RC.
Task-number: QTBUG-44184
Change-Id: I4202271759d29de8c1829347ae3ef117eda54b38
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
The methods are called hslHue and hslSaturation. This was leading
to dead links.
Change-Id: I0997c415958aae9a66fb037d98f8ad3d43b38231
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
- Use QTRY_COMPARE() in touchBeginWithGraphicsWidget.
- Change raw event translation tests to wait for the
window to become active to avoid WM positioning issues.
- Blacklist the raw event translation tests on Linux.
Task-number: QTBUG-46266
Change-Id: I73aae375ee279a518a2a083d0ce8919cce474cb3
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
It's not a real dependency as all we need is to store a pointer,
but better not to use the name QWidget at all.
Change-Id: I30ef1dd44ac7e42c1b9c84675f94088b8c516076
Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
Introduce support for the widgets' clipRect(). Right now render-to-texture widgets
in scroll areas placed close to each other result in broken (non-existent) clipping.
Similarly, stack-on-top widgets fail to clip when placed inside a scroll area.
This is now corrected and the qopenglwidget example is enhanced to utilize a scroll
area.
Task-number: QTBUG-45860
Change-Id: I859a63d61a50d64ba9e87244f83c5969dce12337
Reviewed-by: Jørgen Lind <jorgen.lind@theqtcompany.com>
they are self-contained, as they are the result of another project's
full resolution. consequently, recursing them just burns cycles, and
additionally introduces the risk of an endless loop if the file is
botched.
Task-number: QTBUG-12711
Change-Id: I401ee691c170092cc61fe05538cec4272ed8f922
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
we use qmake properties in the installed .prl files, so the paths
need to be converted to native separators before emission.
Task-number: QTBUG-46217
Change-Id: If3fb0a84488795478fc2a701271c931c62eba6aa
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
... by implementing a fake ln in qmake.
symlinks are supported only since vista (we officially still support
xp), and even there are permission-restricted (MS being (rightfully)
afraid of symlink attacks). so we fake the links by copying the files
instead.
the previous hack was a bit naive, simply using cp/copy instead of ln.
this didn't work with relative paths, as real symlinks are resolved
against their parent directory, not the working directory of the "ln"
command. the new fake does this correctly.
Change-Id: Ia2f5d68a39d6ffcc8a4383f9d0fc63a9da0a05c3
Reviewed-by: Joerg Bornemann <joerg.bornemann@theqtcompany.com>
Probably not performance-relevant here, but easier to read and safer,
too (consider what happens if frect becomes QRectF).
Change-Id: Ia5e4369b550b3a5b899b41ac4cbbda91229f2eb4
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
According to NETBSD manual pages, there's no statfs structure; statvfs
should be used instead, change introduces defines for the stat(v)fs
struct/function.
Task-number: QTBUG-40785
Change-Id: I98599e4635e46f90ffcc99c768f4c250f09f914f
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The Windows 10 CRT does not export __getmainargs(), so we need to move
to GetCommandLine like on WinCE and desktop Windows. As CommandLineToArgv
is not available, the command line is split according by spaces, allowing
for quotes (and quote escaping) around arguments.
Change-Id: Ibc969df94ca5423a3a71d8190bbacd201189ea19
Reviewed-by: Andrew Knight <andrew.knight@intopalo.com>
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@theqtcompany.com>
When running a modal session with NSOpenPanel (QFileDialog), our menu delegate
should not touch qApp->focusObject, since it's not what actually has focus
inside NSOpenPanel (will be some native view). Return YES instead.
Task-number: QTBUG-17291
Change-Id: I94f3281237fb25495d317b02310bf9d77b21d2ba
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
De-duplicates vtables and enables RTTI on this class
hierarchy.
Export, as QDeclarativeTranslatePrivate (QtQuick1)
inherits it.
Change-Id: I32439c59f7d4bff466ecae969bb761a42c3837f1
Reported-by: Volker Krause <volker.krause@kdab.com>
Task-number: QTBUG-45582
Reviewed-by: Lars Knoll <lars.knoll@digia.com>
Switch to using the pointer events from XI2 when touch is available (i.e.
version is >= 2.2). This allows us to select and grab the button and motion
events together with the touch ones. This prevents the issue of not getting
touch events when grabbing via the plain xcb functions.
To prevent touch sequences from being replayed after ungrabbing (for example after
dismissing a popup that caused a grab), we try to accept touches via XIAllowTouchEvents.
Unfortunately this leads to a deadlock and therefore we can only do it when we know
we have a new enough libXi. This is a configure time check which is not ideal since
the system on which apps run can have a newer libXi than the machine that did the Qt
build, but seems like the best we can do.
The environment variable QT_XCB_NO_XI2_MOUSE can be set to 1 in order to prevent
processing mouse events through XInput. This restores the old behavior with broken
grabbing.
[ChangeLog][QtGui] Pointer event delivery on X11 is now done via XInput 2.2+ when available.
Done-with: Michal Klocek <michal.klocek@theqtcompany.com>
Done-with: Alexander Volkov <a.volkov@rusbitech.ru>
Task-number: QTBUG-43525
Task-number: QTBUG-45054
Task-number: QTBUG-30417
Change-Id: I7cb2002b31bef4cd527aa427549dcf2d5467968e
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
With Qt 5.5 we are changing the license of the Qt for the WinRT &
WinCE ports to LGPLv3 / GPLv2+ / commercial.
Change-Id: I221559c5c42b1dcda172eb85e6bfa53c91976b23
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
De-duplicates vtables and enables RTTI on this class
hierarchy.
Export, as QPlainTextDocumentLayoutPrivate (QtWidgets)
inherits it.
Change-Id: I8aee43b43898a72430d8bc1247ea76c7d4e9031d
Reported-by: Volker Krause <volker.krause@kdab.com>
Task-number: QTBUG-45582
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
Change-Id: Ia825ef6d932fbd45ceaf8c54a3207f207fa40994
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
Subpixel rendered text doesn't work in the old OpenGL paint engine
because it assumes the glyphs are returned in RGB32 format, when they
may be in ARGB32. This patch changes the test of the returned format
to just check for 32bit matching the logic in the new OpenGL paint
engine.
Change-Id: Ib5b784dedba51cf22f216e2f035361518610b96b
Reviewed-by: Laszlo Agocs <laszlo.agocs@theqtcompany.com>
Pass a temporary QVector instead of a named variable. Apart from less function
calls, it also makes the code C++11-ready (enables move semantics).
Change-Id: Ia7d3bed8aeae48453f96dc3c979f7ae394a5a26d
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Simon Hausmann <simon.hausmann@theqtcompany.com>
QTextLayout::additionalFormats setters and getters using QList<FormatRange> have
been deprecated; port to the QVector versions.
Moved op== definition for FormatRange needed in tst_qsyntaxhighlighter.cpp
to a friend declaration in FormatRange itself, because MSVC 2008 doesn't find
it otherwise.
Change-Id: Ibab6589df057f02377d895079b56395859e3401e
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
To avoid a touch release outside the combobox triggering the popup,
a check was added that the combobox was hit. This fails if the combox
itself is only used for the popup and associated behavior, but does
not exist as widget. This patch changes the check so that only touch
release checks for a hit, but a generic click still behaves as in 5.4
to avoid regressions.
This fixes comboboxes no longer working in QtWebKit, since QtWebKit
renders its own comboxes in webpages, and only uses the popup of
the QComboBox.
Task-number: QTBUG-46152
Change-Id: I74fd57b2e42e77aa4a269d812ca4a6689f254889
Reviewed-by: Florian Bruhin <qt-project.org@the-compiler.org>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@theqtcompany.com>
When invoking a macro with less argument than it expect, we would
crash trying to access the vector of arguments from the invocation
as we are trying to substitute an argument.
(Note that we do not show an error in case of argument mismatch
because ithat might happen parsing valid code as moc's c++ parser
is not 100% accurate (that was QTBUG-29331))
Task-number: QTBUG-46210
Change-Id: I3f08d7f5049e593a5bdc02a594ea63cadf66e7a4
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@theqtcompany.com>
The pattern "mySet.intersect(other).isEmpty()" has been spotted in
the wild and in Qt codebase. intersects() is much cheaper because it
bails out as soon as we find one common item and doesn't do any
allocations.
[ChangeLog][QtCore][QSet] Added intersects().
Change-Id: I44a350dc4cdb9deb835a23eee99fc99d6ca24c82
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Needed for QSet::intersects() for optimization purposes. No need
to calculate the hash when we already have it.
Change-Id: I247602bb0558ca8d1fb8333de9d5f339146c576d
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
This reverts commit c9aaa3e2cd.
This fix broke fullscreen mode on Android. A better solution is
in the works, but we'll probably push that to Qt 5.5.1 instead
since it comes with a risk and we don't want to delay the release
any further.
Change-Id: I3aae6d52ebb8425089cdb6f7fc4c8ce9ad4911df
Task-number: QTBUG-38700
Task-number: QTBUG-46234
Reviewed-by: BogDan Vatra <bogdan@kde.org>
The range sampling operates the same in both directions just with
different step-sizes, so the code can be unduplicated,
Change-Id: I47805a7e925d4058f62c558ef08e79485915e937
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
The global variable is a left over from when there was an MMX assembler
implementation, and is now just making the compiler's job harder.
Change-Id: I686704b64a2f8c68ec8ca83f2ac3e465ded773e0
Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Reviewed-by: Gunnar Sletta <gunnar@sletta.org>
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>