Auf dieser Seite

QPlatformSurfaceEvent Class

Die Klasse „QPlatformSurfaceEvent“ dient dazu, über native Plattform-Oberflächenereignisse zu informieren. Mehr...

Header: #include <QPlatformSurfaceEvent>
CMake: find_package(Qt6 REQUIRED COMPONENTS Gui)
target_link_libraries(mytarget PRIVATE Qt6::Gui)
qmake: QT += gui
Erbt: QEvent

Öffentliche Typen

enum SurfaceEventType { SurfaceCreated, SurfaceAboutToBeDestroyed }

Öffentliche Funktionen

QPlatformSurfaceEvent(QPlatformSurfaceEvent::SurfaceEventType surfaceEventType)
QPlatformSurfaceEvent::SurfaceEventType surfaceEventType() const

Geschützte Funktionen

QPlatformSurfaceEvent(QPlatformSurfaceEvent &&)
QPlatformSurfaceEvent &operator=(QPlatformSurfaceEvent &&)
QPlatformSurfaceEvent &operator=(const QPlatformSurfaceEvent &other)

Ausführliche Beschreibung

Plattform-Fensterereignisse werden synchron an Fenster und Offscreen-Oberflächen gesendet, wenn deren zugrunde liegende native Oberflächen erstellt werden oder kurz vor der Löschung stehen.

Anwendungen können auf diese Ereignisse reagieren, um zu erkennen, wann die zugrunde liegende Plattform-Oberfläche vorhanden ist.

Dokumentation zu den Mitgliedstypen

enum QPlatformSurfaceEvent::SurfaceEventType

Diese Enumeration beschreibt die Art des Plattformoberflächenereignisses. Die möglichen Typen sind:

KonstanteWertBeschreibung
QPlatformSurfaceEvent::SurfaceCreated0Die zugrunde liegende native Oberfläche wurde erstellt
QPlatformSurfaceEvent::SurfaceAboutToBeDestroyed1Die zugrunde liegende native Oberfläche wird unmittelbar nach diesem Ereignis zerstört

Der Ereignistyp „ SurfaceAboutToBeDestroyed “ ist nützlich, um das Rendern in ein Plattformfenster zu beenden, bevor dieses zerstört wird.

Dokumentation der Mitgliedsfunktionen

[explicit] QPlatformSurfaceEvent::QPlatformSurfaceEvent(QPlatformSurfaceEvent::SurfaceEventType surfaceEventType)

Erstellt ein Plattform-Oberflächenereignis für die angegebene „ surfaceEventType “.

[protected delete] QPlatformSurfaceEvent::QPlatformSurfaceEvent(QPlatformSurfaceEvent &&)

Erstellt eine Instanz von ` QPlatformSurfaceEvent`. Diese Funktion wurde gelöscht.

QPlatformSurfaceEvent::SurfaceEventType QPlatformSurfaceEvent::surfaceEventType() const

Gibt den spezifischen Typ des Plattformoberflächenereignisses zurück.

[protected delete] QPlatformSurfaceEvent &QPlatformSurfaceEvent::operator=(QPlatformSurfaceEvent &&)

Weist „ other “ dieser „ QPlatformSurfaceEvent “-Instanz zu. Diese Funktion wird gelöscht.

[noexcept protected default] QPlatformSurfaceEvent &QPlatformSurfaceEvent::operator=(const QPlatformSurfaceEvent &other)

other Weist dieser Instanz von „ QPlatformSurfaceEvent “ den Wert „ “ zu. “ zu dieser Instanz von „ “ zu.

© 2026 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.