<UserControl x:Class="LabInOnePC.View.UcSampleBankView"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
xmlns:cef="clr-namespace:CefSharp.Wpf;assembly=CefSharp.Wpf"
mc:Ignorable="d" Height="900" Width="1100">
<Grid Background="White">
<Grid.RowDefinitions>
<RowDefinition Height="48"></RowDefinition>
<RowDefinition></RowDefinition>
</Grid.RowDefinitions>
<Button Cursor="Hand" Width="42" Height="42" BorderThickness="0" VerticalAlignment="Top"
HorizontalAlignment="Right" x:Name="btnClose">
<Button.Background>
<ImageBrush ImageSource="/Images/PC/Close1.png"/>
</Button.Background>
</Button>
<cef:ChromiumWebBrowser x:Name="webBrowser" Grid.Row="1"/>
<Grid VerticalAlignment="Center" HorizontalAlignment="Center" x:Name="gdLoad" Grid.Row="1">
<StackPanel>
<Image Source="/Images/PC/LoadingData.png" Width="{StaticResource LoadingImageWidth}" Height="{StaticResource LoadingImageHeight}"></Image>
<TextBlock Margin="0,14,0,0" Text="加载中…" Foreground="#666666" FontSize="{StaticResource FontSize12}"
wpf vue cef 交互
于 2021-03-23 09:34:42 首次发布
本文介绍如何在WPF用户控件中使用CefSharp加载网页,并实现实时通信。通过CefSharp的JavascriptObjectRepository注册对象,实现与Vue组件的交互,包括错误处理和关闭操作。

最低0.47元/天 解锁文章
3278

被折叠的 条评论
为什么被折叠?



