My buttons
unknown
csharp
a year ago
2.7 kB
2
Indexable
Never
<Grid x:Name="FirstLineRight" Grid.Column="2" ColumnDefinitions="auto, auto, auto, auto" RowDefinitions="*" IsVisible="{Binding IsOpened}"> <dxe:Chip Text="Sans prix" Margin="0" Padding="10,0" BackgroundColor="#3010E010" HeightRequest="30" SelectedBackgroundColor="#8010E010" IsCheckIconVisible="True" IsSelected="{Binding EditingProductPricing.IsPriced, Converter={StaticResource InvertedBoolConverter}}" TapCommand="{Binding ToggleIsPricedCommand}" /> <Button x:Name="ButtonAdd" Grid.Column="1" HeightRequest="30" WidthRequest="30" Command="{Binding AddProductToGroupCommand}" BackgroundColor="Transparent" Margin="5, 0,10,0" Padding="0" ImageSource="{fluent:Icon Icon=Add16}"> <Button.IsVisible> <MultiBinding ConverterParameter='And(x, y)' Converter="{StaticResource Math}"> <Binding Path="InitialProductPricing" Converter="{utils:EmptyProductConverter}" /> <Binding Path="EditingProductPricing" Converter="{utils:NotEmptyProductConverter}" /> </MultiBinding> </Button.IsVisible> </Button> <Button x:Name="ButtonEdit" Grid.Column="2" HeightRequest="30" WidthRequest="30" Command="{Binding EditProductPricingInGroupCommand}" BackgroundColor="Transparent" Margin="-10, 0,0,0" Padding="0" ImageSource="{fluent:Icon Icon=Pen16}"> <Button.IsVisible> <MultiBinding ConverterParameter='And(x, y)' Converter="{StaticResource Math}"> <Binding Path="InitialProductPricing" Converter="{StaticResource NotNullConverter}" /> <Binding Path="EditingProductPricing" Converter="{StaticResource NotNullConverter}" /> </MultiBinding> </Button.IsVisible> </Button> <Button x:Name="ButtonRemove" Grid.Column="3" HeightRequest="30" WidthRequest="30" Command="{Binding RemoveProductFromGroupCommand}" BackgroundColor="Transparent" Margin="5, 0,0,0" Padding="0" ImageSource="{fluent:Icon Icon=Subtract16}" IsEnabled="{Binding InitialProductPricing, Converter={StaticResource NotNullConverter}}"> </Button> </Grid>