95 lines
5.8 KiB
Plaintext
95 lines
5.8 KiB
Plaintext
![]() |
<!--
|
||
|
Copyright (C) 2014-2019 de4dot@gmail.com
|
||
|
|
||
|
This file is part of dnSpy
|
||
|
|
||
|
dnSpy is free software: you can redistribute it and/or modify
|
||
|
it under the terms of the GNU General Public License as published by
|
||
|
the Free Software Foundation, either version 3 of the License, or
|
||
|
(at your option) any later version.
|
||
|
|
||
|
dnSpy is distributed in the hope that it will be useful,
|
||
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||
|
GNU General Public License for more details.
|
||
|
|
||
|
You should have received a copy of the GNU General Public License
|
||
|
along with dnSpy. If not, see <http://www.gnu.org/licenses/>.
|
||
|
-->
|
||
|
<UserControl x:Class="dnSpy.AsmEditor.DnlibDialogs.GenericParamControl"
|
||
|
x:ClassModifier="internal"
|
||
|
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
|
||
|
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
|
||
|
xmlns:dnlibdlgs="clr-namespace:dnSpy.AsmEditor.DnlibDialogs"
|
||
|
xmlns:p="clr-namespace:dnSpy.AsmEditor.Properties">
|
||
|
<TabControl>
|
||
|
<TabItem Header="{x:Static p:dnSpy_AsmEditor_Resources.MainTab}" FocusManager.FocusedElement="{Binding ElementName=nameTextBox}">
|
||
|
<ScrollViewer VerticalScrollBarVisibility="Auto">
|
||
|
<Grid Margin="5">
|
||
|
<Grid.RowDefinitions>
|
||
|
<RowDefinition Height="Auto" />
|
||
|
<RowDefinition Height="Auto" />
|
||
|
<RowDefinition Height="Auto" />
|
||
|
</Grid.RowDefinitions>
|
||
|
|
||
|
<Grid Grid.Row="0">
|
||
|
<Grid.ColumnDefinitions>
|
||
|
<ColumnDefinition Width="Auto" />
|
||
|
<ColumnDefinition Width="*" />
|
||
|
<ColumnDefinition Width="Auto" />
|
||
|
<ColumnDefinition Width="*" />
|
||
|
</Grid.ColumnDefinitions>
|
||
|
<Grid.RowDefinitions>
|
||
|
<RowDefinition />
|
||
|
<RowDefinition />
|
||
|
</Grid.RowDefinitions>
|
||
|
|
||
|
<Label Grid.Row="0" Grid.Column="0" Margin="0 0 0 0" Target="{Binding ElementName=nameTextBox}" Content="{x:Static p:dnSpy_AsmEditor_Resources.GP_Name}" />
|
||
|
<TextBox Grid.Row="0" Grid.Column="1" Margin="5 0 0 0" Name="nameTextBox" Text="{Binding Name, ValidatesOnDataErrors=True, ValidatesOnExceptions=True, UpdateSourceTrigger=PropertyChanged}" />
|
||
|
<Label Grid.Row="0" Grid.Column="2" Margin="5 0 0 0" Target="{Binding ElementName=seqTextBox}" Content="{x:Static p:dnSpy_AsmEditor_Resources.GP_Number}" />
|
||
|
<TextBox Grid.Row="0" Grid.Column="3" Margin="5 0 0 0" Name="seqTextBox" Text="{Binding Number.StringValue, ValidatesOnDataErrors=True, ValidatesOnExceptions=True, UpdateSourceTrigger=PropertyChanged}" />
|
||
|
</Grid>
|
||
|
|
||
|
<GroupBox Grid.Row="1" Header="{x:Static p:dnSpy_AsmEditor_Resources.GP_GenericParamConstraints}">
|
||
|
<Grid>
|
||
|
<Grid.ColumnDefinitions>
|
||
|
<ColumnDefinition />
|
||
|
<ColumnDefinition />
|
||
|
<ColumnDefinition />
|
||
|
</Grid.ColumnDefinitions>
|
||
|
<CheckBox Grid.Row="0" Grid.Column="0" Margin="0 5 0 0" IsChecked="{Binding ReferenceTypeConstraint}" Content="{x:Static p:dnSpy_AsmEditor_Resources.GP_Class}" />
|
||
|
<CheckBox Grid.Row="0" Grid.Column="1" Margin="5 5 0 0" IsChecked="{Binding NotNullableValueTypeConstraint}" Content="{x:Static p:dnSpy_AsmEditor_Resources.GP_Struct}" />
|
||
|
<CheckBox Grid.Row="0" Grid.Column="2" Margin="5 5 0 0" IsChecked="{Binding DefaultConstructorConstraint}" Content="{x:Static p:dnSpy_AsmEditor_Resources.GP_DefaultConstructor}" />
|
||
|
</Grid>
|
||
|
</GroupBox>
|
||
|
|
||
|
<Grid Grid.Row="2">
|
||
|
<Grid.ColumnDefinitions>
|
||
|
<ColumnDefinition Width="Auto" />
|
||
|
<ColumnDefinition Width="*" />
|
||
|
<ColumnDefinition Width="Auto" />
|
||
|
<ColumnDefinition Width="*" />
|
||
|
</Grid.ColumnDefinitions>
|
||
|
<Grid.RowDefinitions>
|
||
|
<RowDefinition />
|
||
|
<RowDefinition />
|
||
|
</Grid.RowDefinitions>
|
||
|
|
||
|
<Label Grid.Row="0" Grid.Column="0" Margin="0 5 0 0" Content="{x:Static p:dnSpy_AsmEditor_Resources.GP_Variance}" Target="{Binding ElementName=varianceComboBox}" />
|
||
|
<ComboBox Grid.Row="0" Grid.Column="1" Margin="5 5 0 0" HorizontalAlignment="Stretch" Name="varianceComboBox" DisplayMemberPath="Name" ItemsSource="{Binding GPVarianceVM.Items}" SelectedIndex="{Binding GPVarianceVM.SelectedIndex}" VerticalContentAlignment="Center" />
|
||
|
</Grid>
|
||
|
</Grid>
|
||
|
</ScrollViewer>
|
||
|
</TabItem>
|
||
|
<TabItem Header="{x:Static p:dnSpy_AsmEditor_Resources.GP_Constraints}">
|
||
|
<dnlibdlgs:TypeDefOrRefAndCAsControl Margin="0 5 0 0" DataContext="{Binding TypeDefOrRefAndCAsVM}" />
|
||
|
</TabItem>
|
||
|
<TabItem Header="{x:Static p:dnSpy_AsmEditor_Resources.CustomAttributesTab}">
|
||
|
<dnlibdlgs:CustomAttributesControl Margin="0 5 0 0" DataContext="{Binding CustomAttributesVM}" />
|
||
|
</TabItem>
|
||
|
<TabItem Header="{x:Static p:dnSpy_AsmEditor_Resources.GP_Kind}" ToolTip="{x:Static p:dnSpy_AsmEditor_Resources.GP_Kind_ToolTip}">
|
||
|
<dnlibdlgs:TypeSigCreatorControl Grid.Row="0" DataContext="{Binding TypeSigCreator}" />
|
||
|
</TabItem>
|
||
|
</TabControl>
|
||
|
</UserControl>
|