Aborted QDrag object has never been removed, moreover there was no way
to know a previous drag-and-drop operation status
Task-number: QTBUG-53990
Change-Id: I2b6a7aad86d94b9d5083f9799fe54752c251660b
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
When you change tab it will loose or gain native window decos
depending on if the current dock widget has them or not.
Change-Id: I1171f43fa5ee897ce7d695fc447255dcb0d1d5a1
Task-Id: QTBUG-56866
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Don't block the event that Qt depends on to close popups.
This is the same fix as 5b65698248,
but for touch this time.
Task-number: QTBUG-57292
Change-Id: I47bc19883c2e2b5dc9615c12dc6c198193c055cf
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@qt.io>
Some formatting characters are replaced by ASCII in the output
from toPlainText(). Since this is a bit inconsistent, we should
document it.
Task-number: QTBUG-57552
Change-Id: I46033588d37517056a8d4668d1d16d48c72ee1b5
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Since Qt for Android now supports running as a service, we shouldn't
use the activity context unconditionally, but instead query the current
context from QtAndroidPrivate::context().
Change-Id: Ib793ba890fdbfc0cfe7b20115e41ff64cc73477a
Reviewed-by: Andy Shaw <andy.shaw@qt.io>
Reviewed-by: BogDan Vatra <bogdan@kdab.com>
We might run out of memory or malloc() or realloc() might fail for any
other reason. We want to crash cleanly with a clear message in that
case, rather than returning a null pointer.
Change-Id: If09c1b9e905fc60a5d9d45e598a418df433cf83b
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
We need to add Q_[ENUM|FLAG]_NS to global qt-cpp-defines doc conf otherwise
qdoc ignores them and it will not produce any documentation or links to
these enums/flags
Task-number: QTBUG-57616
Change-Id: I744317346feb41db02787677f8698c4de15db226
Reviewed-by: Martin Smith <martin.smith@qt.io>
It prints libraries necessary for linking against the MySQL static
library. When linking against dynamic libraries, we end up with too many
parameters. We don't want to explicitly link our plugin to OpenSSL and
this is especially important on macOS since Sierra no longer comes with
OpenSSL development files.
On my Linux:
-L/usr/lib64 -lmysqlclient -lpthread -lz -lm -lssl -lcrypto -ldl
On my macOS:
-L/usr/local/Cellar/mysql/5.7.16/lib -lmysqlclient -lssl -lcrypto
Instead, keep only -L options (that haven't been removed by the function
$$filterLibraryPath above) and the actual client library.
Change-Id: I3e3f0326f7234a26acf5fffd148fa985d0fd9c93
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Use qmake operator *= to prevent adding it multiple times resulting
in warnings on Linux/Desktop:
Makefile:114: warning: overriding recipe for target 'sub-eglfs_kms_support-qmake_all'
Makefile:64: warning: ignoring old recipe for target 'sub-eglfs_kms_support-qmake_all'
Makefile:118: warning: overriding recipe for target 'sub-eglfs_kms_support'
...
Change-Id: I18a926c9faeb8f9eafea5223d32c526c06c43724
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
Q_UNREACHABLE() isn't enough for some compilers, especially if it
expands to nothing.
warning #1011: missing return statement at end of non-void function "fetchPixel<bpp>(const uchar={unsigned char} *, int) [with bpp=QPixelLayout::BPPNone]"
Change-Id: I3e3f0326f7234a26acf5fffd148fecf0b72ea7e0
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
we pull this feat off by booting configure with a dummy spec. the proper
spec gets loaded subsequently.
note that it was necessary to move the cache loading after processing
the early checks (from which the spec handling is triggered). this is
just fine, as the cache is needed only by tests, which are forbidden at
this stage by definition.
Change-Id: I5120e25a8bf05fb8cc5485fd93cf6387301089aa
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
this moves us another step towards the "outer" configure doing just
minimal bootstrapping of qmake.
a challenge here was that so far, qmake itself needed qconfig.cpp. this
was replaced by usage of a qt.conf file instead of compiled-in values.
however, to make the executable still self-contained, that qt.conf is
embedded into it (by simple appending of a fixed signature and the text
file).
the qmake with the embedded qt.conf is not used for the qt build itself,
which instead relies on the qt.conf in bin/ as before. however, due to
the missing built-in values, this file now needs to contain more
information than before. but except for a minimal version that is needed
to start up qmake/configure at all, that file is now also generated with
qmake. as some of the newly set up properties are subsequently used by
configure itself, qmake gains a (deliberately undocumented) function to
reload the qt.conf after it's fully populated.
unlike the old implementations, this one doesn't emit redundant qt.conf
entries which match the hard-coded fallbacks. omitting them leads to
leaner files which are more comprehensible.
Started-by: Paolo Angelelli <paolo.angelelli@qt.io>
Change-Id: I4526ef64b3c89d9851e10f83965fe479ed7f39f6
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
in its current form, it was introduced only in 5.7, mostly as a side
effect of -external-hostbindir (which is now handled differently).
it only ever worked for the macOS and MinGW specs, as a side effect of
them supporting -sdk and -device-option (for good reasons), and was
supported only by the unix configure. it's not believed to be really
useful and complicates matters somewhat, so get rid of it again.
should it ever become actually relevant, it can be re-introduced
properly, probably along with a -host-sdk option for macOS.
Change-Id: Ib078469ea39deb821c7b6a8c67fda9e1a95fedf5
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
instead of letting the specs validate themselves on each call, let them
only define a callback for use by the verifyspec configure test. this
is somewhat faster, and allows them to be loaded before qdevice.pri is
populated.
Change-Id: I2b60d006b33bbf42c28949f10ad429520ed32f46
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
its only consumer is qt_tool.prf, which is an internal api.
Change-Id: Iae90b079c5af60efad2ded70d6ea481212e5353a
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
... where it actually belongs, as it should work in each repo in a
modular build.
Change-Id: I5463f0bcacb239900bed0b0f7be9cf32a3eab04e
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
the qmake bootstrap uses some of the options, so the configures still
read config.opt for their own purposes, but the general handling is
entirely in the new system now.
Change-Id: I2c6c657d4da01c8d520ac74795454747bb224bdd
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
otherwise, infinite loops can result, as amply demonstrated by the new
configure (which duly replicated the old configures' behavior ...).
QMakeEvaluator::evaluateBuiltinExpand() now returns a VisitReturn like
all other evaluate*() functions. the string list return value is now an
out parameter; i used a reference instead of a pointer to avoid
adjusting 56 usages of it.
Task-number: QTBUG-13964
Change-Id: I51ca7df8d694c6ffe9d9899cba414b1b46f5ce95
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Horizontal scrollbars scroll in the wrong direction when the app
has a stylesheet and the LayoutDirection is RightToLeft.
Change-Id: I860cb733709e8d59a7b844f2b6ed1ee63410956e
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Err: Undocumented parameter 'enable' in QNetworkProxyFactory::setUseSystemConfiguration()
Err: no such parameter 'editable' in QComboBox::setCompleter()
Change-Id: Ib27b93cf74e97efd656eda1265003f33c6802005
Reviewed-by: Venugopal Shivashankar <Venugopal.Shivashankar@qt.io>
Reinterpret_cast()ing a pointer to a suitably sized integer is not guaranteed
to always give the same result for the same pointer (!). Therefore the
resulting integers are not comparable in a meaningful way. std::less is
supposed to be used to compare arbitrary pointers, so use it.
(Hopefully and reasonably, under the hood std::less does exactly what we
were doing, so this isn't BiC.)
Change-Id: I9960b3d6e35657fe7a25b842054f5d338280e850
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Q_UNUSED(cursor) was failing to compile when configured with
-no-pch.
Change-Id: I1da3c95c1636ca06f38a97052ee4360232520a8b
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Private Use Area characters are quite valid input characters when used
in combination with a custom font. Joiners also serve an important language
purpose in semitic writing systems.
Note that there is a hack where we disregard any character produced
using CTRL or CTRL+SHIFT specifically because of German keyboards. I have chosen to
keep the hack in this patch to limit the change (though I have made an exception
for ZWJ and ZWNJ since both are produced using Ctrl+Shift on Windows), but it
will probably have to be reverted.
[ChangeLog][QtWidgets][Input] Accept characters in Private Use Area, as well as
zero-width joiners and zero-width non-joiners in input in QLineEdit and QTextEdit.
Task-number: QTBUG-42074
Task-number: QTBUG-57003
Change-Id: I73f3b7d587a8670de24e902dc52a51f7721dba5a
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Add a bool *ok out parameter to qt_normalizePathSegments() and return false
when ".." are left over for an absolute path, indicating an attempt to
change above root.
Factor out static helper qt_cleanPath() to be able to pass the return value
to QDir::cd() and return on failure from there.
Amends change 63f634322b, which did
not handle UNC paths.
Task-number: QTBUG-53712
Change-Id: I3e63a5dd0259306a0b99145348d815899582f78e
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Calling QDir::cleanPath() on "//server/path/.." resulted in "/".
Factor out a function to determine the root path part of an absolute
path for later use, and handle some special cases:
- Consider server name of "//server/path/.." as part of the prefix.
- Check on the root path for WinRT.
Task-number: QTBUG-53712
Change-Id: Ibddacf06212b6fc86fa74a5e4078df6cfd5b66f5
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
The C++ standard says in [support.initlist.access]/1:
constexpr const E* begin() const noexcept;
Returns: A pointer to the beginning of the array. If size() == 0 the
values of begin() and end() are unspecified but they shall be
identical.
So we can't assume it's non-null. I didn't want to remove the Q_ASSERT,
so passing a non-null pointer to append() remains required. This patch
simply won't call append() if the initializer list is empty.
This was already tested, but the failure is with a compiler that is not
part of the Qt CI.
Task-number: QTBUG-57277
Change-Id: Iaeecaffe26af4535b416fffd1489806872b412ee
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Previously, we would activate the application during
QCocoaIntegration construction, which means at QApplication
creation time. This now seems to interfere with application
startup on macOS Sierra, where the application window
ends up in an unfocused state.
Move application activation to applicationDidFinishLaunching,
at which point the Cocoa runtime should be completely
initialized. Do this for 10.12+ only to avoid regressions/
test failures on previous versions.
Change-Id: Ic5f150d53f06a302b53a3ba86a4a9b18bb2a1783
Task-number: QTBUG-57044
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
Commit 2bc7a40048 taught the CoreText font database to populate the
families lazily, and in the process added a guard to ensure that we
didn't populate internal fonts (prefixed with a '.'), as these fonts
would then show up in font selection dialogs.
Commit 909d3f5c7 then added support for private fonts, by making it
possible to filter out any private fonts from font selection daialogs.
But the guard was not removed, so we were still not populating these
fonts. This guard has been removed, and the filtering function has
been updated to include the conditions of the guard.
Next, commit e5e93345c5 used [UIFont fontNamesForFamilyName:] to verify
that each family that we registered with the font database would also
have matching fonts when finally populated. This is not the right approach,
as [UIFont fontNamesForFamilyName:] does not handle internal fonts.
Instead we trust what CTFontDescriptorCreateMatchingFontDescriptors()
gives us, but make sure to register the resulting font descriptors
with the original/originating font family, instead of the one we pull
out of the font descriptor.
Finally, as of iOS 10, we can use CTFontManagerCopyAvailableFontFamilyNames
instead of [UIFont familyNames], which gives us all of the internal font
families like on macOS, instead of just the user-visible families. For
earlier iOS versions we manually add '.PhoneFallback', as we know it
will be available even if not listed in [UIFont familyNames].
The end result is that we register and populate families like '.PhoneFallback',
which is critical to supporting more esoteric writing systems.
The check in tst_QFont that styles for a given family is not empty has
been removed, as we can't guarantee that on all platforms, which is
also documented for QFontDatabase::styles().
Task-number: QTBUG-45746
Task-number: QTBUG-50624
Change-Id: I04674dcb2bb36b4cdf5646d540c35727ff3daaad
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
Window managers typically grab the pointer after receiving
the _NET_WM_MOVERESIZE event. But they fail to do it for
touch sequences which have a receiver. So we should reject
the touch sequence before sending _NET_WM_MOVERESIZE event.
QSizeGrip calls startSystemResize() on MouseButtonPress event
which is synthesized by Qt on TouchBegin. We can find the id
of the touch point by comparing coordinates of the synthesized
MouseButtonPress event with coordinates of all TouchBegin events.
Then we use this id to reject the touch sequence (it's possible
only after receiving XI_TouchUpdate).
Change-Id: I26519840cd221e28b0be7854e4617c9aba4b0817
Task-number: QTBUG-51385
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
The prolog and epilog did not force RGB32 to be converted to RGB64 with
alpha fully defined like the middle optimized part.
Change-Id: If7c4829f2239f9a3c524f78b9ce269e2b0b5b150
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
this also removes the need for passing pre-processed options via
configure.cfg, so get rid of that.
a somewhat unfortunate side effect is that the android-style-assets
feature had to move back to the top level, as the licensing options
depend on it.
Started-by: Lars Knoll <lars.knoll@qt.io>
Change-Id: Id4d1e0ba18b3e3104400293b8f0c7f2f65e68dea
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
The function was incorrectly handling green and blue color channels
causing them to be dropped. This affects drawing non 32-bit images onto
10-bit per color channels formats such as RGB30.
Change-Id: I9211e253b1a9da0dada5c418d592a8f531265989
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
Adds platform and CPU features to the reported build type,
matching the format of the old configure.
Started-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Change-Id: I6d93ec7416b38684da51af5238a5cf537810b21d
Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Changes it to follow standard SIMD patterns so it can use
ALIGNMENT_PROLOGUE_16BYTES and SIMD_EPILOGUE helpers.
Should also improve performance by using aligned memory access.
Change-Id: I14a48b82e3f3de83bd7572aa82bed07f28ad944c
Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>