summaryrefslogtreecommitdiffstats
path: root/src/core/web_contents_adapter_client.h
diff options
context:
space:
mode:
authorKirill Burtsev <kirill.burtsev@qt.io>2021-06-24 20:57:21 +0200
committerKirill Burtsev <kirill.burtsev@qt.io>2021-07-21 14:22:41 +0200
commit13254e7950a032ebbeb11b1cf54b850c8326fb30 (patch)
tree72e311bd6e27982be6727cc70e2b182174938a84 /src/core/web_contents_adapter_client.h
parentabd050e9806123cbc6288e7d33ed01ceb2921766 (diff)
WebEngineNavigationRequest: add accept/reject and deprecate setAction
Match naming with others and use accept/reject methods to handle request. Also, allow to use request object after call scope in QML. [ChangeLog][QWebEngineQuick][WebEngineNavigationRequest] setAction(action) is deprecated in favor of new accept/reject methods Pick-to: 6.2 Change-Id: I83252370e2e83017008f6951f98b7ecad119e232 Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Diffstat (limited to 'src/core/web_contents_adapter_client.h')
-rw-r--r--src/core/web_contents_adapter_client.h8
1 files changed, 1 insertions, 7 deletions
diff --git a/src/core/web_contents_adapter_client.h b/src/core/web_contents_adapter_client.h
index 2e81f21e8..ddc371fa3 100644
--- a/src/core/web_contents_adapter_client.h
+++ b/src/core/web_contents_adapter_client.h
@@ -120,12 +120,6 @@ public:
InternalAuthorizationDialog = 0x10,
};
- enum NavigationRequestAction {
- AcceptRequest,
- // Make room in the valid range of the enum for extra actions exposed in Experimental.
- IgnoreRequest = 0xFF
- };
-
enum NavigationType {
LinkNavigation,
TypedNavigation,
@@ -206,7 +200,7 @@ public:
virtual void close() = 0;
virtual void windowCloseRejected() = 0;
virtual void contextMenuRequested(QWebEngineContextMenuRequest *request) = 0;
- virtual void navigationRequested(int navigationType, const QUrl &url, int &navigationRequestAction, bool isMainFrame) = 0;
+ virtual void navigationRequested(int navigationType, const QUrl &url, bool &accepted, bool isMainFrame) = 0;
virtual void requestFullScreenMode(const QUrl &origin, bool fullscreen) = 0;
virtual bool isFullScreenMode() const = 0;
virtual void javascriptDialog(QSharedPointer<JavaScriptDialogController>) = 0;