mirror of
https://github.com/crskycode/GARbro.git
synced 2026-07-08 01:30:18 +08:00
Merge remote-tracking branch 'upstream/master'
This commit is contained in:
@@ -46,6 +46,11 @@ IN THE SOFTWARE.
|
||||
<scm:SortDescription PropertyName="Tag" Direction="Ascending"/>
|
||||
</CollectionViewSource.SortDescriptions>
|
||||
</CollectionViewSource>
|
||||
<CollectionViewSource x:Key="AudioFormatsSource" Source="{Binding Source={x:Static gr:FormatCatalog.Instance}, Path=AudioFormats, Mode=OneWay}">
|
||||
<CollectionViewSource.SortDescriptions>
|
||||
<scm:SortDescription PropertyName="Tag" Direction="Ascending"/>
|
||||
</CollectionViewSource.SortDescriptions>
|
||||
</CollectionViewSource>
|
||||
<Style x:Key="HiddenHeaderStyle" TargetType="{x:Type GridViewColumnHeader}">
|
||||
<Setter Property="Visibility" Value="Collapsed" />
|
||||
</Style>
|
||||
@@ -126,7 +131,7 @@ IN THE SOFTWARE.
|
||||
<TabItem Header="{x:Static s:guiStrings.TextAboutAudio}">
|
||||
<Border BorderThickness="1" BorderBrush="Black" VerticalAlignment="Stretch" Margin="0" SnapsToDevicePixels="True">
|
||||
<ScrollViewer VerticalAlignment="Stretch" VerticalScrollBarVisibility="Auto" HorizontalScrollBarVisibility="Disabled" Margin="0" Background="{DynamicResource {x:Static SystemColors.ControlLightLightBrushKey}}">
|
||||
<ItemsControl Name="AudioFormats" ItemsSource="{Binding Source={x:Static gr:FormatCatalog.Instance}, Path=AudioFormats, Mode=OneWay}">
|
||||
<ItemsControl Name="AudioFormats" ItemsSource="{Binding Source={StaticResource AudioFormatsSource}}">
|
||||
<ItemsControl.ItemTemplate>
|
||||
<DataTemplate>
|
||||
<StackPanel Orientation="Horizontal">
|
||||
|
||||
@@ -79,9 +79,9 @@ namespace GARbro.GUI
|
||||
public string Name { get; set; }
|
||||
public Entry Entry { get; set; }
|
||||
|
||||
public bool IsEqual (IEnumerable<string> path, string name)
|
||||
public bool IsEqual (IEnumerable<string> path, Entry entry)
|
||||
{
|
||||
return Path != null && path.SequenceEqual (Path) && name.Equals (Name);
|
||||
return Path != null && path.SequenceEqual (Path) && Entry == entry;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -139,7 +139,7 @@ namespace GARbro.GUI
|
||||
/// </summary>
|
||||
private void PreviewEntry (Entry entry)
|
||||
{
|
||||
if (m_current_preview.IsEqual (ViewModel.Path, entry.Name))
|
||||
if (m_current_preview.IsEqual (ViewModel.Path, entry))
|
||||
return;
|
||||
UpdatePreviewPane (entry);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user