Commit Graph

37263 Commits

Author SHA1 Message Date
Alessandro Portale
a959a0e206 qmake: Apply modernize-use-nullptr
Use nullptr instead of 0.

Change-Id: Ib3120b9c424a274a2d4dd4c42ec5d7cd5bdead65
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
2018-08-08 17:30:32 +00:00
Alessandro Portale
182aca8487 qmake: Apply modernize-use-override
Add overrides to functions, except for destructors.

Change-Id: I6e4640aa95a5c97d6bd6f6d8692d3290c421344e
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
2018-08-08 17:30:23 +00:00
Alessandro Portale
24115f5a9c qmake: Avoid comparison of values with different enumeration types
A switch statement using enumeration type midlErrorCheckOption as
condition had an enumeration value from type midlStructMemberAlignOption
as a case label. This had only coincidentally the intended effect, since
the intended value (midlErrorCheckOption::midlEnableCustom) and the
actually used one
(midlStructMemberAlignOption::midlStructMemberAlignOption) have both
the value 0.

Change-Id: I73b337f23e733a1a6fb80517e29365e01838238a
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
2018-08-08 17:30:12 +00:00
Mauro Persano
d25d11e6e2 Windows QPA: fix transientParentHwnd
QWindowsWindow::updateTransientParent retrieves the handle of the
topmost owner window, not that of the immediate owner window (which
corresponds to the handle of transient parent window).

Task-number: QTBUG-69620
Change-Id: I1433098e8e93832d97508ee1782f88ccc000ee3a
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
2018-08-08 17:19:17 +00:00
Gatis Paeglis
b4977a332b tests: blacklist tst_qwidget::saveRestoreGeometry on xcb
This test was un-blacklisted in 4050ee6ac7
but apparently it is still not stable.

Task-number: QTBUG-69666
Change-Id: Iaf933ee27d54ebbfa52d0a8d7b1def0ca91808e7
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
2018-08-08 10:36:21 +00:00
Qt Forward Merge Bot
577654047a Merge remote-tracking branch 'origin/5.11' into dev
Conflicts:
	src/plugins/platforms/cocoa/qcocoabackingstore.mm
	src/plugins/platforms/cocoa/qcocoascreen.mm

Change-Id: Iac965aea4867059dbf7bc401b71e8e8b5b259afb
2018-08-08 11:20:22 +02:00
Thiago Macieira
25feee4e06 Fix qmake build with glibc 2.28
We haven't yet run the configure checks to see if statx and renameat2
are present in glibc, so this fails when we redefine the structures and
functions.

linux/stat.h:56:8: error: redefinition of 'struct statx_timestamp'
bits/statx.h:25:8: note: previous definition of 'struct statx_timestamp'
qfilesystemengine_unix.cpp:110:12: error: 'int renameat2(int, const char*, int, const char*, unsigned int)' was declared 'extern' and later 'static' [-fpermissive]

Change-Id: Ia741b559c24d46c78fb2fffd1548a792d22e3368
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Reviewed-by: Jüri Valdmann <juri.valdmann@qt.io>
2018-08-08 08:23:18 +00:00
Jesus Fernandez
458b0ba8e0 Initialize variable
dstZone.offset was being used without initialization.

Coverity-Id: 178898
Change-Id: I8eabef3b4386c3ebfea5d1caffff9add6264bfce
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Jesus Fernandez <Jesus.Fernandez@qt.io>
2018-08-08 07:31:18 +00:00
Robin Lee
2adc06f940 IBus: Support the portal, needed for Flatpak environment
Following commit 35ce6247 in IBus, IBus input plugin now connects to
session bus and use IBus portal to create input context when running
in Flatpak environment or IBUS_USE_PORTAL is set.

[ChangeLog][plugins][ibus] Support IBus portal. Qt programs in Flatpak
environment can now trigger IBus input method.

Change-Id: I561f5f873d709b8abeae554d804daa058f9f6e16
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: Takao Fujiwara <takao.fujiwara1@gmail.com>
2018-08-08 06:18:13 +00:00
Joerg Bornemann
7dc930d400 qmake vcxproj generator: Fix compilation of generated C++ sources
Generated C++ source files with extensions other than .cpp would not get
compiled, because the code ignored all other C++ source extensions like
.cc and .cxx.

Fix this by respecting the value of QMAKE_EXT_CPP and QMAKE_EXT_C.

Task-number: QTBUG-69770
Change-Id: I097dfef6920e353a351c97891cdbfdc9a859815f
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
2018-08-08 05:12:44 +00:00
Thiago Macieira
634e5dd9f2 QStringLiteral: remove the wchar_t fallback for Windows
This isn't necessary anymore, since MSVC 2015 does have Unicode string
support and MinGW (GCC) has had it for a long time. More importantly, we
must remove this macro:

 #    define QT_UNICODE_LITERAL_II(str) L##str

As the updated MSVC preprocessor will no longer support it. See
"Behavior 2" in [1]

[1] https://blogs.msdn.microsoft.com/vcblog/2018/07/06/msvc-preprocessor-progress-towards-conformance/

Change-Id: Id59bdd8f1a804b809e22fffd15401099a67175d3
Reviewed-by: Samuel Gaist <samuel.gaist@idiap.ch>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2018-08-07 21:50:48 +00:00
Tor Arne Vestbø
823acb069d macOS: Don't call [NSOpenGLContext update] for every frame
Calling update has a cost, and should only be done when the drawable
object changes size or location. Instead of calling update each time
makeCurrent is called, we listen for the appropriate notifications,
limiting the number of update calls significantly.

The code has also been refactored to get rid of the m_activeWindow
member, as the active window can be tracked through the context's
drawable object property.

There is also no need to clear the drawable when a window is hidden,
so the hook into QCocoaWindow can be removed.

The QPlatformNativeInterface hook is internal and can safely be removed.

Task-number: QTBUG-63572
Change-Id: I70e3267f47882e151144bd36a50abe906164429a
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
2018-08-07 21:25:12 +00:00
Liang Qi
ee2e38490d Merge "Merge remote-tracking branch 'origin/5.11' into dev" into refs/staging/dev 2018-08-07 18:12:02 +00:00
Qt Forward Merge Bot
053e7cce79 Merge remote-tracking branch 'origin/5.11' into dev
Conflicts:
	.qmake.conf
	src/corelib/doc/src/objectmodel/signalsandslots.qdoc
	src/plugins/platforms/cocoa/qcocoamenuloader.mm
	src/plugins/platforms/xcb/qxcbconnection.cpp
	src/plugins/platforms/xcb/qxcbconnection.h
	src/plugins/platforms/xcb/qxcbconnection_xi2.cpp
	src/plugins/platforms/xcb/qxcbwindow.cpp
	tests/auto/gui/image/qimage/tst_qimage.cpp

Done-with: Gatis Paeglis <gatis.paeglis@qt.io>
Change-Id: I9bd24ee9b00d4f26c8f344ce3970aa6e93935ff5
2018-08-07 17:44:51 +02:00
Thiago Macieira
491e427bb2 QTimer: Add const to some singleShot methods
[ChangeLog][QtCore][QTimer] Fixed singleShot() methods that lacked
proper "const" qualification to QObject context receivers.

Task-number: QTBUG-69800
Change-Id: Ia741b559c24d46c78fb2fffd154865a9cb762473
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2018-08-07 14:41:08 +00:00
Andre Hartmann
59e0d72f64 Doc: Fix QByteArray::toFloat snippet
Amends dc133765ec

Change-Id: I0550e94651dcf2434a7b57b7ae845a5b40cb5cc4
Reviewed-by: Martin Smith <martin.smith@qt.io>
2018-08-07 13:14:36 +00:00
Tor Arne Vestbø
bedf50a5bb macOS: Don't blend the backingstore unless the window has a background
If there's no background, we should copy the backingstore, so that the
backingstore is not blended with the result of the previous flush.

The unified toolbar case is covered by the window having a textured
background.

Task-number: QTBUG-69773
Change-Id: I2f4eed9f44a60ebe7495ce68cf5a54d3d2424b0c
Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
Reviewed-by: Morten Johan Sørvig <morten.sorvig@qt.io>
2018-08-07 12:20:52 +00:00
Mårten Nordheim
6fe5392178 Specify to call QLocalSocket's close in dtor
Specify that we're calling QLocalSocket::close in dtor.
While it's virtual it will not call any overloads at this time.

From cppcheck.

Change-Id: I7b8030ab96e1568cbb2a378ceaf07b2ecabf054f
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2018-08-07 12:14:05 +00:00
Mårten Nordheim
e6b9d11581 NeworkAccessBackend: Remove duplicated/shadowed member
QNetworkAccessBackend has a QSharedPointer called uploadByteDevice.
QNetworkAccessDebugPipeBackend and QNetworkAccessFileBackend both
duplicated the member, by taking a copy of the raw pointer, while also
shadowing the QNetworkAccessBackend's member by reusing the name.

Change-Id: I91f4e8d43d95c5f30c5bc2571393804209b7a843
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2018-08-07 12:13:58 +00:00
Jędrzej Nowacki
9767a47173 Remove forward declaration of non existing class
QUnixEventDispatcherQPA has no private class, there is no need to
declare a fake one.

Change-Id: I615304709fbbea83f6747bb6202dbfd2cc03256d
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
2018-08-07 11:54:07 +00:00
Tor Arne Vestbø
b122e0e323 Guard QGL2PaintEngineEx/QGLPaintDevice against using unset context
QGL2PaintEngineEx::end() calls endPaint() on the device, which may end up
calling QGLContext::swapBuffers() on the context, a call which we have
documented to require makeCurrent() for any further GL commands:

  Call this to finish a frame of OpenGL rendering, and make sure to
  call makeCurrent() again before issuing any further OpenGL commands,
  for example as part of a new frame.

QOpenGLContext also documents that:

  To be able to support certain platforms, QOpenGLContext requires that
  you call makeCurrent() again before starting rendering a new frame,
  after calling swapBuffers().

As a consequence, we need to guard the GL usage in QGLPaintDevice::endPaint(),
as well as the GL reset in QGL2PaintEngineEx::end().

Change-Id: Ib66e91cce12fbaea32ed3c30141150fa15907187
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2018-08-07 11:20:17 +00:00
Simon Hausmann
70b7b2bffc Fix ASAN error about new-delete-size-mismatch in QVariant
We allocate the variant's PrivateShared for custom types with space for
the actual custom type right after that, using operator new to allocate
the memory and a new calls for the constructors. However to free the
memory we merely call delete on the private shared, which upsets ASAN
because the size passed to operator delete is the size of the private
shared, which is not the same as the size that was provided for the
returned address.

This is easily fixable by calling the destructor explicitly and calling
operator delete with just the pointer.

Change-Id: I50afbe0e8afc875c0876e85e02689dcbdc152633
Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
Reviewed-by: Jędrzej Nowacki <jedrzej.nowacki@qt.io>
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2018-08-07 11:14:58 +00:00
Erik Verbruggen
4ec155053a Fix possible heap-buffer-overflow in qt_string_normalize
When starting further into the string than index 0, do correct the
length too. This shows up in tst_qurl and tst_qurlinternal.

Kindly pointed out by ASAN:

==5513==ERROR: AddressSanitizer: heap-buffer-overflow on address 0x60600002bf27 at pc 0x000100654de3 bp 0x7ffeefbfad10 sp 0x7ffeefbfad08
READ of size 16 at 0x60600002bf27 thread T0
    #0 0x100654de2 in QtNS::simdTestMask(char const*&, char const*, unsigned int) qstring.cpp:395
    #1 0x1005f9777 in QtNS::isAscii(QtNS::QChar const*&, QtNS::QChar const*) qstring.cpp:491
    #2 0x100638642 in QtNS::qt_string_normalize(QtNS::QString*, QtNS::QString::NormalizationForm, QtNS::QChar::UnicodeVersion, int) qstring.cpp:7999

Change-Id: I44ad65b47eb98c6085c77b56dc2da50ef5659d25
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2018-08-07 10:31:08 +00:00
Tor Arne Vestbø
5c1c403edb Add logging for QPlatformBackingStore::composeAndFlush
Change-Id: I96778296480d2aaad5e01ed15353106bc90d4d2b
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
2018-08-07 10:19:50 +00:00
Tor Arne Vestbø
fbce032226 macOS: Add missing braces in QCocoaIntegration::updateScreens()
Change-Id: I0f5009c8ba8f2f1853a968d9853dc45e8cbc2b5f
Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2018-08-07 10:19:48 +00:00
Mitch Curtis
ca14151a0c tst_qspinbox: include actual emission count in failure message
It's useful to know how many times the signal was emitted, because it
gives us insight into why the test may have failed, especially when
it's difficult to reproduce.

Task-number: QTBUG-69492
Change-Id: I94796ed880512b060e0a724c87edde8c3b91bb7c
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
2018-08-07 10:12:29 +00:00
Mitch Curtis
2bb454ee67 tst_qdatetimeedit: call setCalendarPopup(false) when cleaning up
Tests could change this property, and since the majority of the tests
share testWidget instead of creating local instances, we should be
thorough when cleaning up.

Change-Id: I6039fb6857f4f788f809b1d1fd491b4ef34923ca
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
2018-08-07 10:12:12 +00:00
Mitch Curtis
58e3e32adf tst_qdatetimeedit: hide testWidget when creating widgets on the stack
The majority of the test reuses testWidget. While this may be faster
than creating a QDateTimeEdit instance on the stack for each test,
it introduces issues when certain properties aren't unset when cleaning
up. This happens easily when new tests are introduced which rely on
certain properties, for example.

Rather than making the newly introduced step-modifier-related tests
use testWidget, this patch goes with the simpler option of hiding
testWidget, just like other tests currently do.

Eventually we should probably switch to using local instances
everywhere.

Task-number: QTBUG-69492
Change-Id: I4d5625be0b7c72db793346f43fe3a7e7c1241f13
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
2018-08-07 10:12:05 +00:00
Volker Krause
86bea797dc Look for dependency XML files in all prefix paths
src/tools/androiddeployqt/main.cpp was moved from qttools into
qtbase in 5.11. So re-apply 07bc7c02 in qttools here.

Change-Id: I13a77a0c8567d07c4aa6369ed76bdb894b88f86f
Reviewed-by: Volker Krause <volker.krause@kdab.com>
2018-08-07 10:11:08 +00:00
Volker Krause
413ca86c29 Add support for additional prefix paths
That is, paths that are searched for dependencies too, next to the Qt
install prefix.

So far this only covers library dependencies, dependency meta data or
QML imports are subject to subsequent patches.

src/tools/androiddeployqt/main.cpp was moved from qttools into
qtbase in 5.11. So re-apply 14013829 in qttools here.

Change-Id: I5649e518cfa3deeac429b4142e6292cb514ef104
Reviewed-by: Volker Krause <volker.krause@kdab.com>
2018-08-07 10:11:05 +00:00
BogDan Vatra
e2f4193112 Fix apkPath for gradle 4.0+
This change keeps the compatibility with old gradle.
It is needed for projects that must use the old gradle version.

src/tools/androiddeployqt/main.cpp was moved from qttools into
qtbase in 5.11. So re-apply c03f5673 in qttools here.

Change-Id: Iaa669c6bf12277cb0cde422228a5c653b6bcf433
Reviewed-by: Volker Krause <volker.krause@kdab.com>
2018-08-07 10:11:02 +00:00
Tor Arne Vestbø
3068b185c5 macOS: Update window geometries after screen properties change
Task-number: QTBUG-69794
Task-number: QTBUG-68140
Change-Id: I4d33bc2136478d779cc4ae8170c3421d9a7557cc
Reviewed-by: Erik Verbruggen <erik.verbruggen@qt.io>
2018-08-07 09:19:26 +00:00
Martin Smith
ed7f86cb07 qdoc: Fix \fn commands for QCborxxx member functions
Severa qdoc function comments had incorrect signatures. This update corrects
them to match the declarations in the header file. A \keyword command was also
added for linking to the generic algorithms header file page.

Change-Id: I997f7f2c7e4d0c3fcd269ee2c89a2836fecd4927
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2018-08-07 05:43:59 +00:00
Timur Pocheptsov
ca5d53abc2 SecureTransport - fix verifyPeerTrust for the renegotiation case
Also remove unneeded and now wrong check (was marked with TODO)
which was a copy and paste from OpenSSL counterpart. There, testing
if peerCertificateChain.isEmpty() makes sense, since there we
potentially call storePeerCertificates() twice during the handshake.

Change-Id: I946e6876adb3f9504e93c06ac90ff36dd44aca4c
Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2018-08-07 03:08:45 +00:00
Tor Arne Vestbø
e7063e6cc6 Add QPlatformScreen::windows() helper to return all windows on screen
Change-Id: Ib55b37b64ed0890ca777dfea8c4d702e267c34bf
Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
2018-08-06 20:14:55 +00:00
Tor Arne Vestbø
be35539123 Use consistent naming of QPA screen change callbacks in QGuiApplication
Change-Id: I76be8a993e5d71e472faf9a5770b4c1128e8a4c6
Reviewed-by: Gatis Paeglis <gatis.paeglis@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
2018-08-06 20:14:55 +00:00
Andre de la Rocha
f271dd8f96 Windows QPA: Fix UIA-to-MSAA accessibility bridge
According to MS sample code, MSAA requests should be replied with
UI Automation providers to enable the use the UIA-to-MSAA bridge, in
order to support MSAA-only clients. Also changing the mapping of
QAccessible::Client from UIA_CustomControlTypeId to UIA_GroupControlTypeId,
as it seems more appropriate and avoids an incorrect mapping to a push button
type in the UIA-to-MSAA conversion.

Change-Id: I5149d250da2d1bd7b14b44ca46e856a81c9be045
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
2018-08-06 19:34:23 +00:00
Mårten Nordheim
a420d02538 Make qcoreapplication_win compile in mingw g++ 8.2
"type qualifiers ignored on cast result type [-Werror=ignored-qualifiers]"

And preemptively fix Clang nagging about repeated type.

Change-Id: I2253b032d1867aa9976b4bdfc0f45023198f917c
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
2018-08-06 18:53:03 +00:00
Eirik Aavitsland
7dfc3ed663 Fix potential out of bounds read in qpkmhandler
Off-by-one bug in the validity test of the texture type field.

Change-Id: I46ded85a0ad93166aa886e71f0c391f27e79f64f
Reviewed-by: Jesus Fernandez <Jesus.Fernandez@qt.io>
2018-08-06 12:04:08 +00:00
Tor Arne Vestbø
819cad6670 Be more explicit about the effects of swapBuffers() on the current context
Change-Id: I7ab9e4e7323d49cf19774bfd0c51f8516ecb842d
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
2018-08-06 11:42:15 +00:00
Tor Arne Vestbø
09d21c1dec Add private helper class QMacScopedObserver
Change-Id: I993ce32c1f6a6eabdce8d5b2b52d8edb28ca2bfa
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
2018-08-06 11:42:13 +00:00
Joni Jantti
377bc2b2ae Blacklist tst_Gestures::graphicsItemTreeGesture
This autotest fails on the new Ubuntu 18.04 platform.

Task-number: QTBUG-69648
Change-Id: I08bd892e2b6a733f3cda32091463745e8b8feed7
Reviewed-by: Simo Fält <simo.falt@qt.io>
2018-08-06 10:59:06 +00:00
Oswald Buddenhagen
a09a28879e qmake: improve the fake project
qt creator's clang code model is a bit more picky than the old one, so
we need a project that approximately works.

while we're at it, inline qmake.pri, add some missing files, and
beautify the source lists.

Change-Id: I87ca1db2ee3e55ea08e4c23f7913e882ab44fd21
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2018-08-06 10:25:50 +00:00
Jesus Fernandez
adea4cf012 Simplify QUrlPrivate::appendHost
Coverity-Id: 191128
Change-Id: I70f2d8b2e0063783851c1520862c2845c8908321
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Robbert Proost <robbert.proost@outlook.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2018-08-06 10:04:55 +00:00
Jesus Fernandez
d9c3dbc93a Pass parameters by const-reference
Coverity-Id: 178810
Change-Id: I996955543c32907a54bf095bf52f242dbb7d5400
Reviewed-by: Eirik Aavitsland <eirik.aavitsland@qt.io>
2018-08-06 09:17:59 +00:00
Friedemann Kleint
eacd789502 Windows QPA: Fix clang-tidy-warnings about class definitions
- Use ' = default' for trivial constructors/destructors
- Remove unneeded destructors
- replace virtual by override or add override where applicable
- Add Q_DISABLE_COPY

Change-Id: Ic7a61579dbc845769beada4fc79bb5dd310e5e52
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2018-08-06 09:06:23 +00:00
Jüri Valdmann
b3574edd2f QTextureFileData: Fix build with -no-opengl
Need to include <QSize> for operator<<(QDebug, const QSize &).

Change-Id: I4857e9b43918243af66cc09ff352619595c081c9
Reviewed-by: Jesus Fernandez <Jesus.Fernandez@qt.io>
2018-08-06 08:45:51 +00:00
Friedemann Kleint
43af54c228 Windows QPA: Fix some clang-tidy-warnings
- Replace index-based loops by range-based for
- Change else if to if after return/break/continue or simplify
- Fix indentation
- Do not check for non-null before invoking delete on pointer
- Use isEmpty() instead size() to check for empty containers
- Remove C-style casts
- Use raw string literal
- Do not repeat type in return, use {} instead
- Reference local variables by const ref where applicable

Change-Id: I5cc4b4026a10bddb561ba1ba8ec137e0d4119f94
Reviewed-by: Miguel Costa <miguel.costa@qt.io>
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
2018-08-06 08:34:00 +00:00
Andre Hartmann
67b296e249 QLabel: Use nullptr
Also, change an old-style-cast while touching its line.

Change-Id: I7b4a38994fb7f52fb7fb02826a71ef4b3698aa34
Reviewed-by: Jesus Fernandez <Jesus.Fernandez@qt.io>
2018-08-06 08:30:46 +00:00
Andre Hartmann
9514229249 QByteArray: Fix documentation for toDouble() and toInt()
The character 'g' is only a valid format when converting numbers
to strings, but not other way round.

Amends dc133765ec

Change-Id: I98d1a4d4cf0665f6e4da6861243e41cd63d7d4b5
Reviewed-by: Martin Smith <martin.smith@qt.io>
2018-08-06 08:28:30 +00:00