mirror of
https://github.com/cefsharp/CefSharp.git
synced 2026-12-06 12:09:40 +00:00
Add WPF SimpleMainWindow - bare minimum example
This commit is contained in:
@@ -104,6 +104,9 @@
|
||||
<Compile Include="Handlers\MenuHandler.cs" />
|
||||
<Compile Include="Handlers\LifespanHandler.cs" />
|
||||
<Compile Include="Handlers\PluginHandler.cs" />
|
||||
<Compile Include="SimpleMainWindow.xaml.cs">
|
||||
<DependentUpon>SimpleMainWindow.xaml</DependentUpon>
|
||||
</Compile>
|
||||
<Compile Include="SpawnBrowsersWindow.xaml.cs">
|
||||
<DependentUpon>SpawnBrowsersWindow.xaml</DependentUpon>
|
||||
</Compile>
|
||||
@@ -123,6 +126,10 @@
|
||||
<DependentUpon>MainWindow.xaml</DependentUpon>
|
||||
<SubType>Code</SubType>
|
||||
</Compile>
|
||||
<Page Include="SimpleMainWindow.xaml">
|
||||
<SubType>Designer</SubType>
|
||||
<Generator>MSBuild:Compile</Generator>
|
||||
</Page>
|
||||
<Page Include="SpawnBrowsersWindow.xaml">
|
||||
<Generator>MSBuild:Compile</Generator>
|
||||
<SubType>Designer</SubType>
|
||||
|
||||
@@ -0,0 +1,25 @@
|
||||
<Window x:Class="CefSharp.Wpf.Example.SimpleMainWindow"
|
||||
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||||
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||||
xmlns:wpf="clr-namespace:CefSharp.Wpf;assembly=CefSharp.Wpf"
|
||||
Title="SimpleMainWindow" WindowState="Maximized">
|
||||
<Grid>
|
||||
<Grid.RowDefinitions>
|
||||
<RowDefinition />
|
||||
<RowDefinition Height="Auto" />
|
||||
</Grid.RowDefinitions>
|
||||
<wpf:ChromiumWebBrowser Grid.Row="0"
|
||||
x:Name="Browser"
|
||||
Address="http://www.google.com" />
|
||||
<StatusBar Grid.Row="1">
|
||||
<ProgressBar HorizontalAlignment="Right"
|
||||
IsIndeterminate="{Binding WebBrowser.IsLoading}"
|
||||
Width="100"
|
||||
Height="16"
|
||||
Margin="3" />
|
||||
<Separator />
|
||||
<!-- TODO: Could show hover link URL here -->
|
||||
<TextBlock />
|
||||
</StatusBar>
|
||||
</Grid>
|
||||
</Window>
|
||||
@@ -0,0 +1,15 @@
|
||||
using System.Windows;
|
||||
|
||||
namespace CefSharp.Wpf.Example
|
||||
{
|
||||
/// <summary>
|
||||
/// Interaction logic for SimpleMainWindow.xaml
|
||||
/// </summary>
|
||||
public partial class SimpleMainWindow : Window
|
||||
{
|
||||
public SimpleMainWindow()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user