qt5base-lts/examples
Volker Hilsheimer 44fb925f50 Phase 2 of removing QDesktopWidget
Remove QDestopWidget public header, simplify the implementation that
maintains a Qt::Desktop type QWidget for each QScreen, and turn
QWidget's initial target screen into a QScreen pointer.

QApplication::desktop() now takes an optional QScreen pointer, and
returns a QWidget pointer, so that applications and widgets can get
access to the root widget for a specific screen without having to
resort to private APIs.

QDesktopWidgetPrivate implementations to look up a screen for an index,
widget, or point are now all inline functions that thinly wrap
QGuiApplication::screens/screenAt calls. We should consider adding those
as convenience APIs to QScreen instead.

Note that QWidget::screen is assumed to return a valid pointer; there is
code that handles the case that it returns nullptr (but also code that
trusts that it never is nullptr), so this needs to be defined, verified
with tests, and asserted. We can then simplify the code further.

Change-Id: Ifc89be65a0dce265b6729feaf54121c35137cb94
Reviewed-by: Shawn Rutledge <shawn.rutledge@qt.io>
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org>
2020-06-08 20:29:49 +02:00
..
aggregate install a sane top-level examples.pro file 2012-12-11 13:37:57 +01:00
corelib Replace calls to deprecated QEvent accessor functions 2020-06-08 19:11:51 +02:00
dbus Regenerate examples 2020-02-04 18:50:39 +00:00
embedded Replace calls to deprecated QEvent accessor functions 2020-06-08 19:11:51 +02:00
gui Regenerate examples 2020-02-04 18:50:39 +00:00
network Torrent example: fix crash 2020-05-11 10:21:29 +02:00
opengl Phase 2 of removing QDesktopWidget 2020-06-08 20:29:49 +02:00
qmake Add cmdline feature to qmake 2019-02-18 07:12:14 +00:00
qpa Replace calls to deprecated QEvent accessor functions 2020-06-08 19:11:51 +02:00
qtconcurrent Replace calls to deprecated QEvent accessor functions 2020-06-08 19:11:51 +02:00
qtestlib Regenerate examples 2020-02-04 18:50:39 +00:00
sql Replace calls to deprecated QEvent accessor functions 2020-06-08 19:11:51 +02:00
vulkan Replace calls to deprecated QEvent accessor functions 2020-06-08 19:11:51 +02:00
widgets Phase 2 of removing QDesktopWidget 2020-06-08 20:29:49 +02:00
xml examples: avoid int -> QChar conversions 2020-04-29 10:10:36 +02:00
CMakeLists.txt cmake: add examples/opengl 2019-10-07 07:22:17 +00:00
examples.pro Doc: Move touch examples around so they get included in docs 2018-09-14 03:56:22 +00:00
README Remove more references to demos. 2011-07-08 15:36:26 +02:00

Qt is supplied with a number of example applications that have been
written to provide developers with examples of the Qt API in use,
highlight good programming practice, and showcase features found in each of
Qt's core technologies.


Documentation for examples can be found in the Examples section
of the Qt documentation.