You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
To improve the developer experience for customizing non-client regions, WebView2 is working to support using DOM elements as non-client regions. We currently have limited support for title bar aka
4
-
draggable regions and are working on building out support for caption controls and resize regions.
3
+
To improve the developer experience for customizing non-client regions, WebView2 is working to support using DOM elements as non-client regions. We currently have
4
+
limited support for title bar aka draggable regions and are working on building out support for caption controls and resize regions.
5
5
6
-
For security and flexibility, we want developers to be able to enable or disable all custom non-client functionality per WebView. Non-client functionality will affect that app window’s size and position so
7
-
it’s important that developers can definitively toggle access. This can be achieved in a limited way using a feature flag, but feature flags are applied per WebView2 environment, thus, an API on the
8
-
WebView2 to enable/disable non-client support via a setting is the better solution.
6
+
For security and flexibility, we want developers to be able to enable or disable all custom non-client functionality per WebView. Non-client functionality will affect
7
+
that app window’s size and position so it’s important that developers can definitively toggle access. This can be achieved in a limited way using a feature flag, but
8
+
feature flags are applied per WebView2 environment, thus, an API on the WebView2 to enable/disable non-client support via a setting is the better solution.
9
9
10
10
# Description
11
-
`IsNonClientRegionSupportEnabled` defaults to `FALSE`. Disabling/Enabling `IsNonClientRegionSupportEnabled` takes effect after the next navigation. Currently, draggable regions is the only non-client
12
-
experience we have implemented. Eventually, this setting will expand to enable other non-client functionality, such as resize and caption controls.
11
+
`IsNonClientRegionSupportEnabled` defaults to `FALSE`. Disabling/Enabling `IsNonClientRegionSupportEnabled` takes effect after the next navigation. Currently,
12
+
draggable regions is the only non-client experience we have implemented. Eventually, this setting will expand to enable other non-client functionality, such as resize
13
+
and caption controls.
13
14
14
15
When the setting is set to `TRUE`, then the following non-client region support for the top level document will be enabled:
15
16
@@ -22,35 +23,75 @@ When set to `FALSE`, then all non-client region support will be disabled.
22
23
* Web pages will not be able to use the `app-region` CSS style.
If the feature flag for enabling the app-region CSS style is used to enable draggable regions in additional browser arguments, draggable region support will remain enabled even if the
53
-
`IsNonClientRegionSupportEnabled` setting is `FALSE`.
92
+
If the feature flag is used to enable draggable regions in additional browser arguments, draggable
93
+
region support will remain enabled even if the `IsNonClientRegionSupportEnabled` setting is `FALSE`.
94
+
* Note: The feature flag is experimental and should not be used in production.
54
95
55
96
# API Notes
56
97
See [API Details](#api-details) section below for API reference.
We considered implementing the APIs in the ControllerOptions class, which would establish whether non-client regions would be supported for the life of the webview at creation. To provide greater
93
-
flexibility of use, we decided to implement it as a setting.
131
+
We considered implementing the APIs in the ControllerOptions class, which would establish whether non-client regions would be supported for the life of the webview at
132
+
creation. To provide greater flexibility of use, we decided to implement it as a setting.
0 commit comments