|
482 | 482 | Padding="4,0"
|
483 | 483 | Background="Transparent"
|
484 | 484 | BorderThickness="0"
|
485 |
| - SelectedIndex="{Binding SearchCommitFilterType, Mode=TwoWay}"> |
| 485 | + SelectedIndex="{Binding SearchCommitFilterType, Mode=TwoWay}"> |
486 | 486 | <ComboBox.Items>
|
487 |
| - <TextBlock Text="{DynamicResource Text.Repository.Search.BySHA}" FontSize="12"/> |
488 |
| - <TextBlock Text="{DynamicResource Text.Repository.Search.ByAuthor}" FontSize="12"/> |
489 |
| - <TextBlock Text="{DynamicResource Text.Repository.Search.ByCommitter}" FontSize="12"/> |
490 |
| - <TextBlock Text="{DynamicResource Text.Repository.Search.ByMessage}" FontSize="12"/> |
491 |
| - <TextBlock Text="{DynamicResource Text.Repository.Search.ByFile}" FontSize="12"/> |
| 487 | + <TextBlock Text="{DynamicResource Text.Repository.Search.BySHA}"/> |
| 488 | + <TextBlock Text="{DynamicResource Text.Repository.Search.ByAuthor}"/> |
| 489 | + <TextBlock Text="{DynamicResource Text.Repository.Search.ByCommitter}"/> |
| 490 | + <TextBlock Text="{DynamicResource Text.Repository.Search.ByMessage}"/> |
| 491 | + <TextBlock Text="{DynamicResource Text.Repository.Search.ByFile}"/> |
492 | 492 | </ComboBox.Items>
|
493 | 493 | </ComboBox>
|
494 | 494 |
|
495 | 495 | <CheckBox Height="24"
|
496 | 496 | Margin="4,0,0,0"
|
497 | 497 | IsChecked="{Binding OnlySearchCommitsInCurrentBranch, Mode=TwoWay}"
|
498 | 498 | IsVisible="{Binding SearchCommitFilterType, Converter={x:Static c:IntConverters.IsGreaterThanZero}}">
|
499 |
| - <TextBlock Text="{DynamicResource Text.Repository.Search.InCurrentBranch}" FontSize="12"/> |
| 499 | + <TextBlock Text="{DynamicResource Text.Repository.Search.InCurrentBranch}"/> |
500 | 500 | </CheckBox>
|
501 | 501 | </StackPanel>
|
502 | 502 |
|
503 | 503 | <ListBox Grid.Row="2"
|
504 | 504 | Margin="0,8,0,0"
|
| 505 | + Padding="4" |
505 | 506 | ItemsSource="{Binding SearchedCommits}"
|
506 | 507 | SelectionMode="Single"
|
507 | 508 | SelectedItem="{Binding SelectedSearchedCommit, Mode=TwoWay}"
|
|
510 | 511 | Background="{DynamicResource Brush.Contents}"
|
511 | 512 | CornerRadius="4"
|
512 | 513 | ScrollViewer.HorizontalScrollBarVisibility="Disabled"
|
513 |
| - ScrollViewer.VerticalScrollBarVisibility="Auto"> |
| 514 | + ScrollViewer.VerticalScrollBarVisibility="Auto" |
| 515 | + Grid.IsSharedSizeScope="True"> |
514 | 516 | <ListBox.Styles>
|
515 | 517 | <Style Selector="ListBoxItem">
|
516 | 518 | <Setter Property="Margin" Value="0"/>
|
517 | 519 | <Setter Property="Padding" Value="0"/>
|
518 |
| - <Setter Property="Height" Value="50"/> |
| 520 | + <Setter Property="Height" Value="28"/> |
| 521 | + <Setter Property="CornerRadius" Value="4"/> |
519 | 522 | </Style>
|
520 | 523 | </ListBox.Styles>
|
521 | 524 |
|
|
527 | 530 |
|
528 | 531 | <ListBox.ItemTemplate>
|
529 | 532 | <DataTemplate DataType="m:Commit">
|
530 |
| - <Border BorderBrush="{DynamicResource Brush.Border2}" BorderThickness="0,0,0,1" Padding="4" Background="Transparent"> |
531 |
| - <Grid RowDefinitions="Auto,*"> |
532 |
| - <Grid Grid.Row="0" ColumnDefinitions="Auto,*,Auto,Auto"> |
533 |
| - <v:Avatar Grid.Column="0" Width="16" Height="16" VerticalAlignment="Center" IsHitTestVisible="False" User="{Binding Author}"/> |
534 |
| - <TextBlock Grid.Column="1" Classes="primary" Text="{Binding Author.Name}" Margin="8,0,0,0" ClipToBounds="True"/> |
535 |
| - <TextBlock Grid.Column="2" Classes="primary" Text="{Binding SHA, Converter={x:Static c:StringConverters.ToShortSHA}}" Foreground="DarkOrange" Margin="8,0,0,0"/> |
536 |
| - <TextBlock Grid.Column="3" Classes="primary" Text="{Binding AuthorTimeShortStr}" Foreground="{DynamicResource Brush.FG2}" Margin="8,0,0,0"/> |
537 |
| - </Grid> |
538 |
| - |
539 |
| - <TextBlock Grid.Row="1" Classes="primary" Text="{Binding Subject}" VerticalAlignment="Bottom"/> |
540 |
| - </Grid> |
541 |
| - </Border> |
| 533 | + <Grid> |
| 534 | + <Grid.ColumnDefinitions> |
| 535 | + <ColumnDefinition Width="24"/> |
| 536 | + <ColumnDefinition Width="*"/> |
| 537 | + <ColumnDefinition Width="Auto" SharedSizeGroup="SearchCommitTimeColumn"/> |
| 538 | + </Grid.ColumnDefinitions> |
| 539 | + <v:Avatar Grid.Column="0" Width="16" Height="16" HorizontalAlignment="Center" VerticalAlignment="Center" IsHitTestVisible="False" User="{Binding Author}"/> |
| 540 | + <TextBlock Grid.Column="1" Classes="primary" Text="{Binding Subject}" Margin="2,0,0,0" VerticalAlignment="Center" TextTrimming="CharacterEllipsis"/> |
| 541 | + <TextBlock Grid.Column="2" |
| 542 | + Classes="primary" |
| 543 | + Margin="4,0" |
| 544 | + Foreground="{DynamicResource Brush.FG2}" |
| 545 | + Text="{Binding CommitterTimeShortStr}" |
| 546 | + HorizontalAlignment="Right" VerticalAlignment="Center" |
| 547 | + TextTrimming="CharacterEllipsis"/> |
| 548 | + </Grid> |
542 | 549 | </DataTemplate>
|
543 | 550 | </ListBox.ItemTemplate>
|
544 | 551 | </ListBox>
|
|
0 commit comments