Commit Graph

29488 Commits

Author SHA1 Message Date
Anton Kudryavtsev
1075f6c764 Use QStringRef to optimize memory allocation
Replace substring functions that return QString
with corresponding functions that return QStringRef.

Change-Id: I3c485f89352a1ee66076fba74fd486da9349c354
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2016-08-18 07:29:37 +00:00
Allan Sandfeld Jensen
748aa6b064 Do not disable subpixel rendering on compile time
This is a runtime setting, as the user's freetype version can differ from
the developer's, and freetype already safely handles it internally when
not available.

Task-number: QTBUG-55345
Change-Id: I26e73728196d60ae26e5f1919ecd0dadac393890
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
2016-08-18 06:11:02 +00:00
Gabriel de Dietrich
b13ff07f1d QCocoaInputContext: Fix wrong memory release
As per Core Foundation ownership conventions, we
should release 'source', which is a copy, and not
'langRef', which is a reference. This has shown
to lead to crashes in some occasions.

Change-Id: I2e59b8d62aac13bc60dc013c1ea621850132c719
Task-number: QTBUG-48772
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
2016-08-18 02:23:05 +00:00
Allan Sandfeld Jensen
469b139169 Register fonts with their given style name
Instead of guessing which styles we have available (always bold/italic)
register the ones we actually find.

Change-Id: I57380d0417411456a3037f8769440e7b43517e0e
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
2016-08-17 21:55:20 +00:00
Timur Pocheptsov
2e4e73d8d3 HTTP/2 - fix invalid read (auto-test)
Since headersFrame is a reference to a vector's element, clearing this
vector before accessing headersFrame.flags is not a good idea, must be
done later.

Change-Id: I80eee0761ac1cad580e979be9371ec7588a694ac
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2016-08-17 20:23:59 +00:00
Timur Pocheptsov
3c5b9977cd HTTP/2 - do not set END_HEADERS if we have CONTINUATIONs
Setting END_HEADERS flag on a HEADERS frame means we do not have
CONTINUATION frame(s). So do NOT set it too early, only if we
fit into a single frame.

Change-Id: I891a2db227cee59e4eacfe7c2f18b431cd85fe47
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
2016-08-17 20:23:34 +00:00
Dyami Caliri
ecb73a7bb3 QJsonValue: use Q_NULLPTR instead of 0 in ctor
Use Q_NULLPTR in all public headers

Task-number: QTBUG-45291
Change-Id: Ib294deb3c210a9a186448cbf9656af7a09fea2c1
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
2016-08-17 19:54:40 +00:00
Marc Mutz
d1a4c4f3c9 xcb: eradicate Q_FOREACH loops
... and mark the library with QT_NO_FOREACH.

Change-Id: I4924f1419f470b5fa92bb2f3fdefa745b65957f7
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
2016-08-17 19:52:21 +00:00
Marc Mutz
b961fca5f0 xcb: mark some types as movable/primitive
These are all held in Qt containers.

Change-Id: Ie285887b285bbcc0b70962d9f9c52d22d213d022
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
2016-08-17 19:52:15 +00:00
Friedemann Kleint
e4bb9395c2 Standardize some "We mean it" comments
Fix the occurrences where the wrong classes are mentioned.

Change-Id: Ia291af77f0f454a39cab93e7376a110c19a07771
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2016-08-17 19:51:40 +00:00
Anton Kudryavtsev
b0dba5b874 QMimeData: use QStringBuilder more
Change-Id: I5a6937545561c51add0d48a618b1921cf9201c4b
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
2016-08-17 19:44:02 +00:00
Gabriel de Dietrich
9b491616f8 Cocoa QPA Menus: Propagate enabled state downwards
NSMenu has autoenableItems set to true by default, and
we keep it this way in Qt. This means that NSMenuItem's
enabled property is basically ignored and therefore
QCocoaMenuItem::syncModalState() is wrong.

What is also wrong, is syncModalState()'s name in both
QCocoaMenuItem and QCocoaMenu. Indeed, this function's
role should be to ensure that the enabled state is
properly propagated down the menu hierarchy, whether
the reason is being in the context of a modal dialog
or the parent menu having been disabled by the app.
Notice that the latter case is specially needed when
a menubar menu is explicitly disabled.

Therefore, we introduce a separate flag for the parent
enabled state in order to avoid polluting the app-set
enabled state flag. This is done in both QCocoaMenu
and QCocoaMenuItem.

In the case of QCocoaMenuItem, these two flags define
whether an NSMenuItem is enabled state conjointly, and
set from -[QCocoaMenuDelegate validateMenuItem:]. The
rest of the logic remains as before. Similar logic is
used in QCocoaMenu::isEnabled().

In addition, the presence of the second flag allows us
to show disabled submenus in the same fashion native
Cocoa applications do. This means, the submenu item
itself remains enabled, allowing to show the submenu
popup where all its menu items will appear disabled.

Bonus change: merged all the bool flags into a bitfield
and made the compiler happy about the ivar reordering
in QCocoaMenu and QCocoaMenuItem's constructor.

Task-number: QTBUG-54698
Task-number: QTBUG-55121
Change-Id: Ie156cb3aa57a519103908ad4605f7b43c57e5aef
Reviewed-by: Timur Pocheptsov <timur.pocheptsov@theqtcompany.com>
2016-08-17 18:21:53 +00:00
André Klitzing
810363945f Update PCRE to 8.39
Change-Id: I619ef88ea05a6bcfb6908dc18d9de7daa9113392
Reviewed-by: Giuseppe D'Angelo <giuseppe.dangelo@kdab.com>
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2016-08-17 17:33:21 +00:00
J-P Nurmi
9aeaa363e5 Auto tests: use Qt::AA_DontUseNativeDialogs where appropriate
These auto tests were trying to not create native dialogs, but setting
the QFileDialog::DontUseNativeDialog option is too late to control the
creation of the platform helper. It is already created at construction
time, unless Qt::AA_DontUseNativeDialogs is set.

Task-number: QTBUG-55276
Task-number: QTBUG-55281
Change-Id: Icf474e97059ac03a5fa01bd3a17f07203da5770a
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
2016-08-17 15:46:27 +00:00
J-P Nurmi
007f92c6ee Dialogs: don't create platform helpers unconditionally
No matter if Qt::AA_DontUseNativeDialogs was set, both QFileDialog and
QColorDialog were always unconditionally creating the platform helper
at construction time:

    QFooDialog()
    -> QFooDialogPrivate::init()
    -> QFooDialogPrivate::platformFooHelper()
    -> QDialogPrivate::platformHelper()

Only QFontDialog had the platformHelper() calls guarded with
canBeNativeDialog(). => Move the canBeNativeDialog() check inside
QDialogPrivate::platformHelper() where the platform helper
instance is created.

Task-number: QTBUG-55276
Change-Id: I84b595fbd009c70a3a1976ddbb32a835270c5203
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
2016-08-17 15:46:21 +00:00
J-P Nurmi
31127d390e Fix QGtk3ColorDialogHelper::currentColorChanged() emission
Even though GtkColorChooser provides a "color-activated" signal, it
does not get emitted whenever the selection in the dialog changes, but
only when a color is activated in a sense that the dialog is accepted.
Switch to the "notify::rgba" signal to get proper live notifications
of the selection changes.

Task-number: QTBUG-55298
Change-Id: I39ab798764c8b42a998d75c56605948eaf154dcd
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Reviewed-by: Dmitry Shachnev <mitya57@gmail.com>
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
2016-08-17 15:46:03 +00:00
J-P Nurmi
b57c878dfc QGtk3FontDialogHelper: provide proper currentFontChanged()
A workaround for the missing currentFontChanged() signal was added in
130f43c. Now we can remove the improper emission on accept, because by
using the "notify::font" signal gives proper notifications whenever the
current font selection in the dialog changes.

Task-number: QTBUG-55298
Change-Id: Id9a4f32a92f0be8f466a0a0587bb2acd4c9056f7
Reviewed-by: Dmitry Shachnev <mitya57@gmail.com>
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
2016-08-17 15:45:57 +00:00
J-P Nurmi
0295984786 Fix missing plugins.qmltypes in static builds
plugins.qmltypes should never be built into resources, but always
deployed on the file system so Qt Creator can read it.

Task-number: QTBUG-52297
Task-number: QTBUG-52299
Task-number: QTBUG-52940
Change-Id: Ieadb82bcb71dd4fb769fa0b7d15ec74e12ce7b42
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2016-08-17 15:45:51 +00:00
Friedemann Kleint
60a695ab5e Fix qdoc warnings
qtbase/src/network/socket/qsctpsocket.cpp:506: warning: Undocumented parameter 'datagram' in QSctpSocket::writeDatagram()
qtbase/src/network/ssl/qssldiffiehellmanparameters.cpp:129: warning: Undocumented parameter 'encoding' in QSslDiffieHellmanParameters::QSslDiffieHellmanParameters()
qtbase/src/gui/opengl/qopengltextureblitter.cpp:540: warning: Undocumented parameter 'opacity' in QOpenGLTextureBlitter::setOpacity()
qtbase/src/gui/opengl/qopengltextureblitter.cpp:522: warning: Undocumented parameter 'swizzle' in QOpenGLTextureBlitter::setRedBlueSwizzle()
qtbase/src/testlib/qtestcase.qdoc:1124: warning: Cannot find 'createTouchDevice(...)' in '\fn' QTest::createTouchDevice()

Change-Id: Ie8799aa5f63a4ea6c9fe309e2a627fbe3a13b685
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
Reviewed-by: Topi Reiniö <topi.reinio@theqtcompany.com>
2016-08-17 13:18:26 +00:00
Eskil Abrahamsen Blomfeldt
ec7fee968f Support stretch when using DirectWrite font engine
The DirectWrite font we get when converting the GDI font
does not respect the stretch we have set, as this is an attribute
of the text layout in DirectWrite and not the font description.

To compensate for this, we scale advances and glyphs in the
engine if the stretch is different from 100%.

[ChangeLog][QtGui][Windows] Fixed stretch when combined with either
no or vertical hinting preference or a device pixel ratio different
from 1.

Task-number: QTBUG-54494
Change-Id: Icc06d1457191782d1a281c99da2da3081a82c542
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
2016-08-17 13:15:26 +00:00
Allan Sandfeld Jensen
0d99452339 Protect QImage::convertToFormat against null QImage
QImage may have a null d-pointer, and convertToFormat_helper was the
only method not protected against it.

Change-Id: Ibfe5b139e3922f2a0c8284c6ae1932c2150efc66
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
2016-08-17 12:54:05 +00:00
Andy Nichols
2b0e52757c Disable switchable widget compositing when using XCB in Parallels VM
The Parallels 3D hardware acceleration does not seem to play nice with
Qt Creator when switching between tabs that have OpenGL Qt Quick Content
and those that have just raster widget content.  QWidgetBackingstore has
the ability to switch how content is flushed depending on if the
SwitchableWidgetComposition capability is available.  Previously for XCB
it was always enabled, but should be disabled when using the GLX
integration for the Parallels VM.

Change-Id: I42e41456e0873f6780f5d0333dbfaaf8fcce4a5e
Task-number: QTCREATORBUG-16742
Reviewed-by: Laszlo Agocs <laszlo.agocs@qt.io>
2016-08-17 12:22:57 +00:00
Venugopal Shivashankar
faadf0d8f4 Doc: Remove references to Windows CE in Qt Gui
The platform is not supported since Qt 5.7

Task-number: QTBUG-55331
Change-Id: I3a6027661c2d597158999fe9665e76b1db18a9de
Reviewed-by: Martin Smith <martin.smith@theqtcompany.com>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
2016-08-17 11:20:17 +00:00
Marc Mutz
253d2e5135 QLinkedList: restore move special member functions for iterators
They were masked by the pointless user-defined copy special member
functions, which we cannot remove because it would change the way
the iterators are passed by value into functions, on some platforms.

Add a reminder for Qt 6 to fix the issue for good.

Change-Id: I039093894db4a4e5e4bbf94fb346fd90311316c0
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2016-08-17 08:59:06 +00:00
Marc Mutz
e6f5a7d6c0 tst_QString: clean up
- add Q_DECLARE_TYPEINFO for types held in Qt containers (incl. QVariant)
- port Q_FOREACH to C++11 range-for
- port uses of inefficient QLists to QVector

Fixes errors pointed out by my tree's static checks.

Change-Id: I7176b4b12ed47ed23166857bd127c459ea2a48d5
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2016-08-17 08:58:58 +00:00
Marc Mutz
af5ccb7f8c tst_QStyleSheetStyle: Extract Method sample_widgets()
The only difference between the sample widget sets was:

  -    widgets << new QLabel("TESTING TESTING");
  +    widgets << new QLabel("<b>TESTING TESTING</b>");

I chose the latter, because it's the more complex example
and neither the hoverColors nor focusColors tests suggest
the boldness of the text matters.

Part of port away from Q_FOREACH.

Change-Id: I9a928de4e781b96ad00a8c9515977c35ebfa6c24
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2016-08-17 08:58:50 +00:00
Marc Mutz
3d39c66369 QColor: remove unused qt_get_rgb_val()
Defined out-of-line, not exported, not used anywhere in QtGui,
so it can be removed.

Change-Id: Ib049bad7d02e5412c063965cd81c8d95e1c1c183
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2016-08-17 08:58:42 +00:00
Maurice Kalinowski
35f17de487 ANGLE: Fix initialization of zero-sized window
The clientRect might be empty when creating a window of zero size. The
side effect of a division by zero is that matrix transformation fails
and hence the swapchain gets into an invalid state.

Change-Id: Idbaed72deadb7b87052ac27e194a40d1810e6f7a
Reviewed-by: Andrew Knight <andrew.knight@intopalo.com>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
2016-08-17 07:42:13 +00:00
Friedemann Kleint
02a03e52f7 QCocoaFileIconEngine: Add icon size 256
Change-Id: Ib36025f802404f74f6ce5494f3858dfe0e283004
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
2016-08-17 04:44:15 +00:00
Jake Petroules
5264ddf1e0 xcodebuild.mk: forward INSTALL_ROOT from make to xcodebuild
This allows overriding the INSTALL_ROOT with the Xcode generator.

Change-Id: Ifb894bdbf9764918f76428fb32d9af68914853f6
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
2016-08-16 21:22:20 +00:00
Jake Petroules
f1f767da92 Don't build the tests which require helpers on UIKit platforms
These tests use helpers, which are not supported on UIKit platforms.

Change-Id: I51447754dba2cd2547be05c3767e4ff3b6b5a671
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2016-08-16 21:22:15 +00:00
Jake Petroules
e708d63e18 Don't build the complexpingpong example on UIKit platforms
This example uses QProcess which is not available on UIKit platforms.

Change-Id: I126d20369ccf307579a60956de7769e92e17548a
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2016-08-16 21:22:10 +00:00
Jake Petroules
dee35b5a78 xcodebuild.mk: explicitly specify the Xcode project to build
This fixes the examples build on UIKit platforms in
examples/dbus/pingpong where there are two Xcode projects and the build
therefore cannot disambiguate between the two.

Change-Id: Ic8b808c1ddf3565bb9861a487eab6854ec177184
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
Reviewed-by: Gabriel de Dietrich <gabriel.dedietrich@qt.io>
Reviewed-by: Jake Petroules <jake.petroules@qt.io>
2016-08-16 21:22:05 +00:00
Anton Kudryavtsev
8617ce5c88 Use QStringRef() more, exploiting its new ::chop()
Change-Id: Id2201639be604b9a32b2dc5d21e675a961bee477
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2016-08-16 20:08:31 +00:00
J-P Nurmi
ed4cd363b1 Fix missing qmlplugindump_wrapper.sh (debug_and_release)
qtPrepareTool() must be called outside a build pass, as it protects
against concurrent wrapper creation by omitting it during build passes.

Change-Id: I7cf080cf78d1099e4893a204ea40d8c6bc63af58
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2016-08-16 18:18:01 +00:00
Marc Mutz
1e4ba2b4e5 Don't hold MakefileGenerator::Compiler in QList
MakefileGenerater::Compiler is larger than a void*, so holding
it in QList is horribly inefficient.

Fix by using QVector instead.

Change-Id: I9ea173271caf9b4995d311c3864c6967da049380
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2016-08-16 17:09:12 +00:00
Marc Mutz
839bab1355 qmake: don't hold VCFilter in QList
Change-Id: Ib10539187e0c8e4ffa2000dcad75715a7b931701
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2016-08-16 17:09:07 +00:00
Marc Mutz
e7b6cc2700 qmake: remove pointless ~VCProjectSingleConfig()
It's empty, but non-trivial, thus preventing move special member
functions from being generated by the compiler (now that qmake
is compiled as C++11, too).

The default ctor was also empty - removed, too.

Change-Id: I714db524f681f1fc250d21926245757e97351e87
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2016-08-16 17:09:03 +00:00
Marc Mutz
aa11287a27 qmake: mark VCProjectSingleConfig as movable
Has a few too many fields for defining a member-swap
(which would be required to mark it shared).

Change-Id: Iecbeec9e60a9884cb4a984c58cb192918cef799d
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2016-08-16 17:08:59 +00:00
Friedemann Kleint
ff00b2efbd Add " We mean it" comment to qdeadlinetimer_p.h
Fix warning:
QtCore: WARNING: qtbase/src/corelib/kernel/qdeadlinetimer_p.h does not have the "We mean it." warning

Amends change 12eacc3bab

Change-Id: Ibb8fd25cee0249380996ae271200055e131d359b
Reviewed-by: Lars Knoll <lars.knoll@qt.io>
2016-08-16 15:46:20 +00:00
Friedemann Kleint
c0ccea7efe Manual dialog test: Add option -n to set Qt::AA_DontUseNativeDialogs
Change-Id: I413f378487bea2c975b1dd722b8a4a4c289a2997
Reviewed-by: J-P Nurmi <jpnurmi@qt.io>
2016-08-16 13:51:43 +00:00
Friedemann Kleint
cb08543c18 ~QGraphicsProxyWidget: Remove event filter on widget before deleting it
Prevent events being received on the widget during its destruction
phase.

Task-number: QTBUG-55112
Change-Id: I0d990fc69eee06b7e5af3845aa3f7627e3e3d5b9
Reviewed-by: Marc Mutz <marc.mutz@kdab.com>
2016-08-16 13:51:24 +00:00
Friedemann Kleint
ff68be114e Fix documentation of the Windows parts of QSettings::setPath()
Explain in terms of CSIDL_ values and update the sample locations.

Task-number: QTBUG-55065
Change-Id: I15ddf32555d43cffae66d98c6ac12d62a98d5e6d
Reviewed-by: Maurice Kalinowski <maurice.kalinowski@qt.io>
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Reviewed-by: Topi Reiniö <topi.reinio@theqtcompany.com>
2016-08-16 13:51:16 +00:00
Marc Mutz
6d95497931 QLinkedList: compile with -Wzero-as-null-pointer-constant
The existing header check unfortunately doesn't detect uses of
'0' as nullptr in template code.

Task-number: QTBUG-45291
Change-Id: Ibe701402d95deca98c5286e2cee5f7118fd7f606
Reviewed-by: Olivier Goffart (Woboq GmbH) <ogoffart@woboq.com>
2016-08-16 13:36:15 +00:00
BogDan Vatra
27a0ec9b9a Revert "Android: use gold linker"
It seems there is a configure test which should enable it.

This reverts commit 7e4f0ad961.

Change-Id: I39c594e5e779732d2f5954b42e266a1eaa1be3f0
Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>
2016-08-16 13:31:38 +00:00
Eskil Abrahamsen Blomfeldt
365a65da70 Remove special case for color fonts from Freetype font engine
When adding color font support to the Freetype engine, we added
a special case to some functions based on the assumption that
color fonts do not contain the latin alphabet. The reason for
the assumption is that color fonts are currently most popular
for emojis and the most popular ones on Linux did not contain
the latin alphabet. But there is nothing special about color
fonts making them less likely to contain latin characters
than other fonts especially made for non-latin writing systems.

If we want an additional fallback when the x character is
not available, this should be implemented for all font engines
and font types.

Change-Id: I1c4aa28d49c38ba7a416c1cae50a1d1c09cbda41
Reviewed-by: Simon Hausmann <simon.hausmann@qt.io>
Reviewed-by: jian liang <jianliang79@gmail.com>
2016-08-16 12:47:06 +00:00
Allan Sandfeld Jensen
5def42f783 Fix alpha from qfontengine_ft to fit qdrawhelper expectations
The short-cuts in qdrawhelper's qt_alphargbblit_argb32 expects the
alpha value of the A32 glyphs to be 0xff.

Since the alpha value is not otherwise used, set it to that.

The reported image format is also changed to RGB32, matching
coretext and windows fontengines, and expected by the OpenGL
paintengine.

Change-Id: I0873156d716566f7f1634249155b6c9983a3d0de
Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@qt.io>
2016-08-16 11:50:34 +00:00
Giuseppe D'Angelo
8dc45d5b7c Deprecate Q(Persistent)ModelIndex::child
Due to how invalid model indices are handled in Qt, child() is unsuitable
for general purpose usage. In particular you can never get a top level
item in the model because the root model index by definition hasn't got
a pointer to the model it belongs.

That makes child() useless for anything but tree models (and even there
you'd need to special case your code anyhow).

[ChangeLog][QtCore][QModelIndex] QModelIndex::child has
been deprecated due to its lack of generality.
Use model->index(row, column, index) instead.

[ChangeLog][QtCore][QPersistentModelIndex] QPersistentModelIndex::child has
been deprecated due to its lack of generality.
Use model->index(row, column, index) instead.

Change-Id: Ice73c17133aaf71355fa2af1eacfe64da01bd456
Reviewed-by: Thorbjørn Lund Martsum <tmartsum@gmail.com>
Reviewed-by: David Faure <david.faure@kdab.com>
2016-08-16 11:07:03 +00:00
Liang Qi
17198e03ab Merge remote-tracking branch 'origin/5.7' into dev
Conflicts:
	qmake/doc/src/qmake-manual.qdoc
	src/corelib/global/qglobal.cpp
	src/corelib/tools/qstring.cpp
	src/network/socket/qabstractsocket.cpp
	src/network/socket/qnativesocketengine_unix.cpp
	src/plugins/platforms/eglfs/api/qeglfsglobal.h

Change-Id: Id5dfdbd30fa996f9b4b66a0b030b7d3b8c0ef288
2016-08-16 07:58:32 +02:00
Friedemann Kleint
cc517d7cd9 QWindowsServices::openUrl(): Don't convert URLs with fragments/queries to local files
Pass the URL instead.

Task-number: QTBUG-55300
Change-Id: I4ce9171db5c1a9e07b17911729b165c115329664
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
2016-08-16 04:49:20 +00:00