diff options
Diffstat (limited to 'src/webenginequick/doc/src/fullscreen_request.qdoc')
-rw-r--r-- | src/webenginequick/doc/src/fullscreen_request.qdoc | 58 |
1 files changed, 58 insertions, 0 deletions
diff --git a/src/webenginequick/doc/src/fullscreen_request.qdoc b/src/webenginequick/doc/src/fullscreen_request.qdoc new file mode 100644 index 000000000..60da2748c --- /dev/null +++ b/src/webenginequick/doc/src/fullscreen_request.qdoc @@ -0,0 +1,58 @@ +// Copyright (C) 2020 The Qt Company Ltd. +// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only + +/*! + \qmltype FullScreenRequest + \instantiates QWebEngineFullScreenRequest + \inqmlmodule QtWebEngine + \since QtWebEngine 1.1 + + \brief A utility type for the WebEngineView::fullScreenRequested() signal. + + \sa WebEngineView::fullScreenRequested() +*/ + +/*! + \qmlproperty url FullScreenRequest::origin + \readonly + The URL of the web page that issued the fullscreen request. +*/ + +/*! + \qmlproperty bool FullScreenRequest::toggleOn + \readonly + + Returns \c{true} if the application should toggle fullscreen mode on, \c{false} otherwise. + + \sa accept() +*/ + +/*! + \qmlmethod void FullScreenRequest::accept() + + Call this method to accept the fullscreen request. It sets the WebEngineView::isFullScreen + property to be equal to toggleOn. + + \qml + ApplicationWindow { + id: window + WebEngineView { + onFullScreenRequested: function(request) { + if (request.toggleOn) + window.showFullScreen() + else + window.showNormal() + request.accept() + } + } + } + \endqml + + \sa toggleOn +*/ + +/*! + \qmlmethod void FullScreenRequest::reject() + Rejects a fullscreen request. +*/ + |