mirror of https://github.com/icsharpcode/ILSpy.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
156 lines
7.6 KiB
156 lines
7.6 KiB
<?xml version="1.0" encoding="utf-8"?> |
|
<Window |
|
x:Class="ICSharpCode.ILSpy.MainWindow" |
|
x:ClassModifier="public" |
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" xmlns:tv="clr-namespace:ICSharpCode.TreeView;assembly=ICSharpCode.TreeView" |
|
xmlns:local="clr-namespace:ICSharpCode.ILSpy" |
|
xmlns:avalondock="http://schemas.xceed.com/wpf/xaml/avalondock" |
|
xmlns:controls="clr-namespace:ICSharpCode.ILSpy.Controls" |
|
xmlns:properties="clr-namespace:ICSharpCode.ILSpy.Properties" |
|
Title="ILSpy" |
|
MinWidth="250" |
|
MinHeight="200" |
|
UseLayoutRounding="True" |
|
TextOptions.TextFormattingMode="Display" |
|
FocusManager.FocusedElement="{Binding ElementName=treeView}" |
|
xmlns:d="http://schemas.microsoft.com/expression/blend/2008" d:DesignHeight="500" d:DesignWidth="500" |
|
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" mc:Ignorable="d" |
|
> |
|
<Window.Resources> |
|
<BooleanToVisibilityConverter x:Key="BooleanToVisibilityConverter" /> |
|
</Window.Resources> |
|
<Window.CommandBindings> |
|
<CommandBinding |
|
Command="Open" |
|
Executed="OpenCommandExecuted" /> |
|
<CommandBinding |
|
Command="Refresh" |
|
Executed="RefreshCommandExecuted" /> |
|
<CommandBinding |
|
Command="Save" |
|
CanExecute="SaveCommandCanExecute" |
|
Executed="SaveCommandExecuted" /> |
|
<CommandBinding |
|
Command="BrowseBack" |
|
CanExecute="BackCommandCanExecute" |
|
Executed="BackCommandExecuted" /> |
|
<CommandBinding |
|
Command="BrowseForward" |
|
CanExecute="ForwardCommandCanExecute" |
|
Executed="ForwardCommandExecuted" /> |
|
<CommandBinding |
|
Command="Search" |
|
Executed="SearchCommandExecuted" /> |
|
</Window.CommandBindings> |
|
<Window.InputBindings> |
|
<KeyBinding Key="R" Modifiers="Control" Command="{x:Static local:ILSpyCommands.Analyze}" /> |
|
</Window.InputBindings> |
|
<Window.TaskbarItemInfo> |
|
<TaskbarItemInfo /> |
|
</Window.TaskbarItemInfo> |
|
<DockPanel> |
|
<!-- Main menu --> |
|
<Menu DockPanel.Dock="Top" Name="mainMenu" Height="23" KeyboardNavigation.TabNavigation="None"> |
|
<MenuItem Header="{x:Static properties:Resources._File}" /> |
|
<!-- contents of file menu are added using MEF --> |
|
<MenuItem Header="{x:Static properties:Resources._View}"> |
|
<MenuItem Header="{x:Static properties:Resources.Show_publiconlyTypesMembers}" IsCheckable="True" IsChecked="{Binding FilterSettings.ApiVisPublicOnly}" /> |
|
<MenuItem Header="{x:Static properties:Resources.Show_internalTypesMembers}" IsCheckable="True" IsChecked="{Binding FilterSettings.ApiVisPublicAndInternal}" /> |
|
<MenuItem Header="{x:Static properties:Resources.Show_allTypesAndMembers}" IsCheckable="True" IsChecked="{Binding FilterSettings.ApiVisAll}" /> |
|
</MenuItem> |
|
</Menu> |
|
<!-- ToolBar --> |
|
<ToolBar |
|
Name="toolBar" |
|
DockPanel.Dock="Top" ToolBarTray.IsLocked="True" KeyboardNavigation.TabNavigation="None"> |
|
<ToolBar.Resources> |
|
<!-- Make images transparent if menu command is disabled --> |
|
<Style TargetType="{x:Type Image}"> |
|
<Style.Triggers> |
|
<DataTrigger |
|
Binding="{Binding RelativeSource={RelativeSource AncestorType={x:Type ButtonBase}, AncestorLevel=1}, Path=IsEnabled}" |
|
Value="False"> |
|
<Setter Property="Opacity" Value="0.30" /> |
|
</DataTrigger> |
|
</Style.Triggers> |
|
</Style> |
|
</ToolBar.Resources> |
|
<!-- 'Navigation' toolbar category is inserted here --> |
|
<Separator /> |
|
<!-- 'Open' toolbar category is inserted here --> |
|
<Separator /> |
|
<CheckBox IsChecked="{Binding FilterSettings.ApiVisPublicOnly}" ToolTip="{x:Static properties:Resources.ShowPublicOnlyTypesMembers}"> |
|
<Image Width="16" Height="16" Source="{controls:XamlResource Images/ShowPublicOnly}" /> |
|
</CheckBox> |
|
<CheckBox IsChecked="{Binding FilterSettings.ApiVisPublicAndInternal}" ToolTip="{x:Static properties:Resources.ShowInternalTypesMembers}"> |
|
<Image Width="16" Height="16" Source="{controls:XamlResource Images/ShowPrivateInternal}" /> |
|
</CheckBox> |
|
<CheckBox IsChecked="{Binding FilterSettings.ApiVisAll}" ToolTip="{x:Static properties:Resources.ShowAllTypesAndMembers}"> |
|
<Image Width="16" Height="16" Source="{controls:XamlResource Images/ShowAll}" /> |
|
</CheckBox> |
|
<Separator /> |
|
<ComboBox Name="languageComboBox" DisplayMemberPath="Name" Width="100" MaxDropDownHeight="Auto" |
|
ItemsSource="{x:Static local:Languages.AllLanguages}" ToolTip="{x:Static properties:Resources.SelectLanguageDropdownTooltip}" |
|
SelectedItem="{Binding FilterSettings.Language}"/> |
|
<ComboBox Name="languageVersionComboBox" DisplayMemberPath="DisplayName" Width="120" MaxDropDownHeight="Auto" ToolTip="{x:Static properties:Resources.SelectVersionDropdownTooltip}" |
|
Visibility="{Binding SelectedItem.HasLanguageVersions, ElementName=languageComboBox, Converter={StaticResource BooleanToVisibilityConverter}}" |
|
ItemsSource="{Binding SelectedItem.LanguageVersions, ElementName=languageComboBox, UpdateSourceTrigger=PropertyChanged}" |
|
SelectedItem="{Binding FilterSettings.LanguageVersion, UpdateSourceTrigger=PropertyChanged}"/> |
|
</ToolBar> |
|
<Border DockPanel.Dock="Top" BorderBrush="Black" BorderThickness="1" Name="updatePanel" Visibility="Collapsed"> |
|
<DockPanel KeyboardNavigation.TabNavigation="Contained"> |
|
<Button DockPanel.Dock="Right" Click="updatePanelCloseButtonClick" MinWidth="0">X</Button> |
|
<StackPanel Orientation="Horizontal"> |
|
<TextBlock Name="updatePanelMessage" Margin="4,0" VerticalAlignment="Center" Text="{x:Static properties:Resources.ILSpyVersionAvailable}" /> |
|
<Button Name="downloadOrCheckUpdateButton" Click="downloadOrCheckUpdateButtonClick" Content="{x:Static properties:Resources.Download}"/> |
|
</StackPanel> |
|
</DockPanel> |
|
</Border> |
|
<!-- Status bar --> |
|
<StatusBar x:Name="statusBar" DockPanel.Dock="Bottom" Height="26" Visibility="Collapsed"> |
|
<StatusBarItem DockPanel.Dock="Right"> |
|
<TextBlock VerticalAlignment="Center" |
|
HorizontalAlignment="Right" |
|
x:Name="StatusLabel" |
|
ToolTip="{x:Static properties:Resources.Status}" |
|
Text="{x:Static properties:Resources.StandBy}"/> |
|
</StatusBarItem> |
|
</StatusBar> |
|
<!-- Main grid separating left pane (treeView) from main pane (textEditor) --> |
|
|
|
<avalondock:DockingManager x:Name="DockManager" |
|
AllowMixedOrientation="True" Grid.ColumnSpan="2"> |
|
|
|
<avalondock:LayoutRoot x:Name="LayoutRoot" > |
|
<avalondock:LayoutPanel Orientation="Vertical"> |
|
<avalondock:LayoutPanel Orientation="Horizontal"> |
|
<avalondock:LayoutAnchorablePaneGroup DockWidth="200" Orientation="Vertical"> |
|
<avalondock:LayoutAnchorablePane DockHeight="*"> |
|
<avalondock:LayoutAnchorable x:Name="Tree" Title="Project Explorer" CanHide="False" CanClose="False"> |
|
<!-- Left pane: Tree View of assemblies and classes --> |
|
<tv:SharpTreeView |
|
Name="treeView" |
|
AutomationProperties.Name="Assemblies and Classes" |
|
SelectionChanged="TreeView_SelectionChanged" |
|
ShowRoot="False" |
|
AllowDropOrder="True" |
|
AllowDrop="True" |
|
BorderThickness="0,1,1,1" Visibility="Visible" /> |
|
</avalondock:LayoutAnchorable> |
|
</avalondock:LayoutAnchorablePane> |
|
</avalondock:LayoutAnchorablePaneGroup> |
|
|
|
<avalondock:LayoutDocumentPaneGroup DockWidth="*"> |
|
<avalondock:LayoutDocumentPane x:Name="adDocumentPane"> |
|
<avalondock:LayoutDocument Title="MAIN" CanClose="False"> |
|
<!-- decompilerTextView is into the mainPane by code --> |
|
<ContentPresenter Name="mainPane" /> |
|
</avalondock:LayoutDocument> |
|
</avalondock:LayoutDocumentPane> |
|
</avalondock:LayoutDocumentPaneGroup> |
|
</avalondock:LayoutPanel> |
|
</avalondock:LayoutPanel> |
|
</avalondock:LayoutRoot> |
|
</avalondock:DockingManager> |
|
</DockPanel> |
|
</Window>
|
|
|