MicrosoftEdge / MicrosoftEdge/WebView2Feedback
WPF - Tabcontrol - focus problem (activeElement)
@champnic is already working on this.
Since Jan 28, 2022.
- Dominant language
- PowerShell
- Stars
- 526
- Forks
- 67
- PR merge metrics
- No merged PRs in 30d
Description
Hello,
I'm using multiple webviews2 inside a WPF tabcontrol, one webview per tabitem
When you switch tab, the focus inside the webview is lost.
The webview still have keyboardfocus but the activeElement is not the same.
SDK: 1.0.1133-prerelease
Runtime: edge 97.0.1072.69
Framework: WPF
OS: WIN 10
You can reproduce this in the webview2 sample, WebView2WpfBrowser project for example.
Simply replace the single webview by a tabcontrol with 2 webview :
<TabControl Name="tabControl">
<TabItem Header="webview1">
<wv2:WebView2 x:Name="webView" CreationProperties="{StaticResource EvergreenWebView2CreationProperties}" Source="https://www.bing.com/"/>
</TabItem>
<TabItem Header="webview2">
<wv2:WebView2 x:Name="webView2" CreationProperties="{StaticResource EvergreenWebView2CreationProperties}" Source="https://www.bing.com/"/>
</TabItem>
</TabControl>
Focus the bing searchbar, switch to tab2, switch back to tab1; focus is not inside the searchbar anymore.
Regards
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.