QPlatformSurfaceEvent Class
The QPlatformSurfaceEvent class is used to notify about native platform surface events. 更多...
头文件: | #include <QPlatformSurfaceEvent> |
qmake: | QT += gui |
开始支持版本: | Qt 5.5 |
基类: | QEvent |
公有类型
enum | SurfaceEventType { SurfaceCreated, SurfaceAboutToBeDestroyed } |
公有函数
QPlatformSurfaceEvent(SurfaceEventType surfaceEventType) | |
SurfaceEventType | surfaceEventType() const |
- 6 个公有函数继承自 QEvent
其他继承的成员
详细描述
The QPlatformSurfaceEvent class is used to notify about native platform surface events.
Platform window events are synchronously sent to windows and offscreen surfaces when their underlying native surfaces are created or are about to be destroyed.
Applications can respond to these events to know when the underlying platform surface exists.
成员类型
enum QPlatformSurfaceEvent::SurfaceEventType
This enum describes the type of platform surface event. The possible types are:
Constant | Value | Description |
---|---|---|
QPlatformSurfaceEvent::SurfaceCreated | 0 | The underlying native surface has been created |
QPlatformSurfaceEvent::SurfaceAboutToBeDestroyed | 1 | The underlying native surface will be destroyed immediately after this event |
The SurfaceAboutToBeDestroyed
event type is useful as a means of stopping rendering to a platform window before it is destroyed.
成员函数
QPlatformSurfaceEvent::QPlatformSurfaceEvent(SurfaceEventType surfaceEventType)
Constructs a platform surface event for the given surfaceEventType.
SurfaceEventType QPlatformSurfaceEvent::surfaceEventType() const
Returns the specific type of platform surface event.