iOS: Add support for QWindow::setOpacity()
Change-Id: I027154aef35d219f08915e195f2baf8595ef7343 Reviewed-by: Richard Moe Gustavsen <richard.gustavsen@digia.com>
This commit is contained in:
parent
552639c359
commit
fea21655a8
@ -73,6 +73,7 @@ public:
|
||||
void setParent(const QPlatformWindow *window);
|
||||
void handleContentOrientationChange(Qt::ScreenOrientation orientation);
|
||||
void setVisible(bool visible);
|
||||
void setOpacity(qreal level) Q_DECL_OVERRIDE;
|
||||
|
||||
bool isExposed() const Q_DECL_OVERRIDE;
|
||||
|
||||
|
@ -74,6 +74,7 @@ QIOSWindow::QIOSWindow(QWindow *window)
|
||||
screen()->availableGeometry().width(), screen()->availableGeometry().height());
|
||||
|
||||
setWindowState(window->windowState());
|
||||
setOpacity(window->opacity());
|
||||
}
|
||||
|
||||
QIOSWindow::~QIOSWindow()
|
||||
@ -135,6 +136,11 @@ void QIOSWindow::setVisible(bool visible)
|
||||
}
|
||||
}
|
||||
|
||||
void QIOSWindow::setOpacity(qreal level)
|
||||
{
|
||||
m_view.alpha = qBound(0.0, level, 1.0);
|
||||
}
|
||||
|
||||
void QIOSWindow::setGeometry(const QRect &rect)
|
||||
{
|
||||
m_normalGeometry = rect;
|
||||
|
Loading…
Reference in New Issue
Block a user