<!--
// /***************************************************************************
// Aaru Data Preservation Suite
// ‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐
//
// Filename       : MediaInfo.xaml
// Author(s)      : Natalia Portillo <claunia@claunia.com>
//
// Component      : GUI panel.
//
// ‐‐[ Description ] ‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐
//
//     Media information panel.
//
// ‐‐[ License ] ‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐
//
//     This program 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.
//
//     This program 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 this program.  If not, see <http://www.gnu.org/licenses/>.
//
// ‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐‐
// Copyright © 2011-2025 Natalia Portillo
// ****************************************************************************/
-->
<UserControl xmlns="https://github.com/avaloniaui"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006"
             xmlns:panels="clr-namespace:Aaru.Gui.ViewModels.Panels"
             xmlns:localization="clr-namespace:Aaru.Localization;assembly=Aaru.Localization"
             mc:Ignorable="d"
             d:DesignWidth="800"
             d:DesignHeight="450"
             x:Class="Aaru.Gui.Views.Panels.MediaInfo">
    <Design.DataContext>
        <panels:MediaInfoViewModel />
    </Design.DataContext>
    <StackPanel Orientation="Vertical">
        <TextBlock HorizontalAlignment="Center"
                   Text="{x:Static localization:UI.Title_Media_information}" />
        <Image Width="128"
               Height="128"
               HorizontalAlignment="Center"
               Source="{Binding MediaLogo}" />
        <TabControl>
            <TabItem IsVisible="{Binding GeneralVisible}">
                <TabItem.Header>
                    <TextBlock Text="{x:Static localization:UI.Title_General}" />
                </TabItem.Header>
                <StackPanel Orientation="Vertical">
                    <StackPanel Orientation="Horizontal">
                        <TextBlock Text="{x:Static localization:UI.Title_Media_type}" />
                        <TextBox Text="{Binding MediaType}"
                                 IsReadOnly="True" />
                    </StackPanel>
                    <TextBlock IsVisible="{Binding !!MediaSize}"
                               Text="{Binding MediaSize}" />
                    <StackPanel Orientation="Horizontal"
                                IsVisible="{Binding !!MediaSerial}">
                        <TextBlock Text="{x:Static localization:UI.Title_Media_serial_number}" />
                        <TextBox Text="{Binding MediaSerial}"
                                 IsReadOnly="True" />
                    </StackPanel>
                    <Button IsVisible="{Binding SaveReadMediaSerialVisible}"
                            Command="{Binding SaveReadMediaSerialCommand}">
                        <TextBlock Text="{x:Static localization:UI.ButtonLabel_Save_READ_MEDIA_SERIAL_NUMBER_response}" />
                    </Button>
                    <Button IsVisible="{Binding SaveReadCapacityVisible}"
                            Command="{Binding SaveReadCapacityCommand}">
                        <TextBlock Text="{x:Static localization:UI.ButtonLabel_Save_READ_CAPACITY_response}" />
                    </Button>
                    <Button IsVisible="{Binding SaveReadCapacity16Visible}"
                            Command="{Binding SaveReadCapacity16Command}">
                        <TextBlock Text="{x:Static localization:UI.ButtonLabel_Save_READ_CAPACITY_16_response}" />
                    </Button>
                </StackPanel>
            </TabItem>
            <TabItem IsVisible="{Binding MmcVisible}">
                <TabItem.Header>
                    <TextBlock Text="{x:Static localization:Core.Title_MMC}" />
                </TabItem.Header>
                <StackPanel Orientation="Vertical">
                    <Button IsVisible="{Binding SaveGetConfigurationVisible}"
                            Command="{Binding SaveGetConfigurationCommand}">
                        <TextBlock Text="{x:Static localization:UI.ButtonLabel_Save_GET_CONFIGURATION_response}" />
                    </Button>
                    <Button IsVisible="{Binding SaveRecognizedFormatLayersVisible}"
                            Command="{Binding SaveRecognizedFormatLayersCommand}">
                        <TextBlock Text="{x:Static localization:UI.ButtonLabel_Save_RECOGNIZED_FORMAT_LAYERS_response}" />
                    </Button>
                    <Button IsVisible="{Binding SaveWriteProtectionStatusVisible}"
                            Command="{Binding SaveWriteProtectionStatusCommand}">
                        <TextBlock Text="{x:Static localization:UI.ButtonLabel_Save_WRITE_PROTECTION_STATUS_response}" />
                    </Button>
                </StackPanel>
            </TabItem>
            <TabItem IsVisible="{Binding SscVisible}">
                <TabItem.Header>
                    <TextBlock Text="{x:Static localization:Core.Title_SSC}" />
                </TabItem.Header>
                <StackPanel Orientation="Vertical">
                    <TextBlock IsVisible="{Binding !!DensitySupport}"
                               Text="{x:Static localization:UI.Densities_supported_by_currently_inserted_media}" />
                    <TextBox IsVisible="{Binding !!DensitySupport}"
                             Text="{Binding DensitySupport}"
                             IsReadOnly="True" />
                    <TextBlock IsVisible="{Binding !!MediumSupport}"
                               Text="{x:Static localization:UI.Medium_types_currently_inserted_in_device}" />
                    <TextBox Text="{Binding MediumSupport}"
                             IsReadOnly="True" />
                    <Button IsVisible="{Binding SaveDensitySupportVisible}"
                            Command="{Binding SaveDensitySupportCommand}">
                        <TextBlock
                            Text="{x:Static localization:UI.ButtonLabel_Save_REPORT_DENSITY_SUPPORT_MEDIA_response}" />
                    </Button>
                    <Button IsVisible="{Binding SaveMediumSupportVisible}"
                            Command="{Binding SaveMediumSupportCommand}">
                        <TextBlock
                            Text="{x:Static localization:UI.ButtonLabel_Save_REPORT_DENSITY_SUPPORT_MEDIUM_MEDIA_response}" />
                    </Button>
                </StackPanel>
            </TabItem>
            <TabItem IsVisible="{Binding !!CompactDiscInfo}">
                <TabItem.Header>
                    <TextBlock Text="{x:Static localization:Core.Title_CompactDisc}" />
                </TabItem.Header>
                <ContentControl Content="{Binding CompactDiscInfo}" />
            </TabItem>
            <TabItem IsVisible="{Binding !!DvdInfo}">
                <TabItem.Header>
                    <TextBlock Text="{x:Static localization:Core.Title_DVD}" />
                </TabItem.Header>
                <ContentControl Content="{Binding DvdInfo}" />
            </TabItem>
            <TabItem IsVisible="{Binding !!DvdWritableInfo}">
                <TabItem.Header>
                    <TextBlock Text="{x:Static localization:Core.Title_DVD_Plus_Dash_R_W}" />
                </TabItem.Header>
                <ContentControl Content="{Binding DvdWritableInfo}" />
            </TabItem>
            <TabItem IsVisible="{Binding !!XboxInfo}">
                <TabItem.Header>
                    <TextBlock Text="{x:Static localization:Core.Title_Xbox}" />
                </TabItem.Header>
                <ContentControl Content="{Binding XboxInfo}" />
            </TabItem>
            <TabItem IsVisible="{Binding !!BlurayInfo}">
                <TabItem.Header>
                    <TextBlock Text="{x:Static localization:Core.Title_Blu_ray}" />
                </TabItem.Header>
                <ContentControl Content="{Binding BlurayInfo}" />
            </TabItem>
        </TabControl>
        <Button Command="{Binding DumpCommand}">
            <TextBlock Text="{x:Static localization:UI.ButtonLabel_Dump_media_to_image}" />
        </Button>
        <Button Command="{Binding ScanCommand}">
            <TextBlock Text="{x:Static localization:UI.ButtonLabel_Scan_media_surface}" />
        </Button>
    </StackPanel>
</UserControl>