Implement media-info command in GUI.

This commit is contained in:
2018-09-09 01:00:54 +01:00
parent 629846777f
commit 285f83d232
5 changed files with 1195 additions and 16 deletions

View File

@@ -1,8 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<project version="4"> <project version="4">
<component name="ContentModelStore"> <component name="ContentModelStore">
<e p="/7b7d2f51" t="IncludeRecursive" />
<e p="/app" t="IncludeRecursive" />
<e p="$APPLICATION_CONFIG_DIR$/consoles/db" t="IncludeRecursive" /> <e p="$APPLICATION_CONFIG_DIR$/consoles/db" t="IncludeRecursive" />
<e p="$APPLICATION_CONFIG_DIR$/extensions" t="IncludeRecursive" /> <e p="$APPLICATION_CONFIG_DIR$/extensions" t="IncludeRecursive" />
<e p="$USER_HOME$/.Rider2018.2/system/extResources" t="IncludeRecursive" /> <e p="$USER_HOME$/.Rider2018.2/system/extResources" t="IncludeRecursive" />
@@ -1328,6 +1326,8 @@
</e> </e>
<e p="pnlDeviceInfo.xeto" t="Include" /> <e p="pnlDeviceInfo.xeto" t="Include" />
<e p="pnlDeviceInfo.xeto.cs" t="Include" /> <e p="pnlDeviceInfo.xeto.cs" t="Include" />
<e p="pnlScsiInfo.xeto" t="Include" />
<e p="pnlScsiInfo.xeto.cs" t="Include" />
</e> </e>
<e p="DiscImageChef.Gui.XamMac" t="IncludeRecursive"> <e p="DiscImageChef.Gui.XamMac" t="IncludeRecursive">
<e p="DiscImageChef.Gui.XamMac.csproj" t="IncludeRecursive" /> <e p="DiscImageChef.Gui.XamMac.csproj" t="IncludeRecursive" />

View File

@@ -1,11 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?> <?xml version="1.0" encoding="UTF-8"?>
<module type="RIDER_MODULE" version="4"> <module type="RIDER_MODULE" version="4">
<component name="NewModuleRootManager"> <component name="NewModuleRootManager">
<content url="file:///7b7d2f51" />
<content url="file:///app" />
<content url="file://$APPLICATION_CONFIG_DIR$/consoles/db" />
<content url="file://$APPLICATION_CONFIG_DIR$/extensions" />
<content url="file://$USER_HOME$/.Rider2018.2/system/extResources" />
<content url="file://$USER_HOME$/.nuget/packages/sqlitepclraw.lib.e_sqlite3.linux/1.1.11/runtimes/linux-x64/native/libe_sqlite3.so" /> <content url="file://$USER_HOME$/.nuget/packages/sqlitepclraw.lib.e_sqlite3.linux/1.1.11/runtimes/linux-x64/native/libe_sqlite3.so" />
<content url="file://$MODULE_DIR$/../.." /> <content url="file://$MODULE_DIR$/../.." />
<orderEntry type="sourceFolder" forTests="false" /> <orderEntry type="sourceFolder" forTests="false" />

View File

@@ -34,6 +34,7 @@ using System;
using System.ComponentModel; using System.ComponentModel;
using System.Linq; using System.Linq;
using DiscImageChef.Console; using DiscImageChef.Console;
using DiscImageChef.Core.Media.Info;
using DiscImageChef.Devices; using DiscImageChef.Devices;
using Eto.Forms; using Eto.Forms;
using Eto.Serialization.Xaml; using Eto.Serialization.Xaml;
@@ -182,6 +183,12 @@ namespace DiscImageChef.Gui
splMain.Panel2 = null; splMain.Panel2 = null;
if(selectedItem.Values.Length >= 3 && selectedItem.Values[2] is Panel infoPanel)
{
splMain.Panel2 = infoPanel;
return;
}
if(selectedItem.Parent != devicesRoot) return; if(selectedItem.Parent != devicesRoot) return;
switch(selectedItem.Values[2]) switch(selectedItem.Values[2])
@@ -216,9 +223,6 @@ namespace DiscImageChef.Gui
lblError.Text = devErrorMessage; lblError.Text = devErrorMessage;
splMain.Panel2 = lblError; splMain.Panel2 = lblError;
break; break;
case Panel devInfoPanel:
splMain.Panel2 = devInfoPanel;
break;
} }
} }
@@ -264,13 +268,22 @@ namespace DiscImageChef.Gui
} }
}); });
else else
deviceItem.Children.Add(new TreeGridItem {
{ // TODO: Removable non-SCSI?
Values = new object[] ScsiInfo scsiInfo = new ScsiInfo(dev);
if(!scsiInfo.MediaInserted)
deviceItem.Children.Add(new TreeGridItem {Values = new object[] {"No media inserted"}});
else
deviceItem.Children.Add(new TreeGridItem
{ {
"Removable device commands not yet implemented" Values = new[]
} {
}); scsiInfo.MediaType, deviceItem.Values[1],
new pnlScsiInfo(scsiInfo)
}
});
}
dev.Close(); dev.Close();
} }

View File

@@ -0,0 +1,370 @@
<?xml version="1.0" encoding="UTF-8"?><!--
// /***************************************************************************
// The Disc Image Chef
// ============================================================================
//
// Filename : pnlScsiInfo.xeto
// Author(s) : Natalia Portillo <claunia@claunia.com>
//
// Component : SCSI media information panel.
//
// ==[ Description ] ==========================================================
//
// Defines the structure for the SCSI 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-2018 Natalia Portillo
// ****************************************************************************/
-->
<Panel xmlns="http://schema.picoe.ca/eto.forms" xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml">
<StackLayout Orientation="Vertical">
<StackLayoutItem HorizontalAlignment="Center">
<Label ID="lblMediaInfo" Text="Media information"/>
</StackLayoutItem>
<StackLayoutItem HorizontalAlignment="Stretch" Expand="True" VerticalAlignment="Stretch">
<TabControl ID="tabInfos">
<TabPage ID="tabGeneral" Text="General" Visible="False">
<StackLayout Orientation="Vertical">
<StackLayoutItem HorizontalAlignment="Stretch">
<StackLayout Orientation="Horizontal">
<Label ID="lblType" Text="Media type"/>
<TextBox ID="txtType" ReadOnly="True"/>
</StackLayout>
</StackLayoutItem>
<StackLayoutItem HorizontalAlignment="Left">
<Label ID="lblMediaSize" Visible="False"
Text="Media has {0} blocks of {1} bytes/each. (for a total of {2} bytes)"/>
</StackLayoutItem>
<StackLayoutItem HorizontalAlignment="Stretch">
<StackLayout Orientation="Horizontal" ID="stkMediaSerial" Visible="False">
<Label ID="lblMediaSerial" Text="Media serial number"/>
<TextBox ID="txtMediaSerial" ReadOnly="True"/>
</StackLayout>
</StackLayoutItem>
<Button ID="btnSaveReadMediaSerial" Text="Save READ MEDIA SERIAL NUMBER response"
Click="OnBtnSaveReadMediaSerialClick" Visible="False"/>
<Button ID="btnSaveReadCapacity" Text="Save READ CAPACITY response"
Click="OnBtnSaveReadCapacityClick" Visible="False"/>
<Button ID="btnSaveReadCapacity16" Text="Save READ CAPACITY (16) response"
Click="OnBtnSaveReadCapacity16Click" Visible="False"/>
</StackLayout>
</TabPage>
<TabPage ID="tabMmc" Text="MMC" Visible="False">
<StackLayout Orientation="Vertical">
<Button Click="OnBtnSaveGetConfigurationClick" ID="btnSaveGetConfiguration"
Text="Save GET CONFIGURATION response" Visible="False"/>
<Button Click="OnBtnSaveRecognizedFormatLayersClick" ID="btnSaveRecognizedFormatLayers"
Text="Save RECOGNIZED FORMAT LAYERS response" Visible="False"/>
<Button Click="OnBtnSaveWriteProtectionStatusClick" ID="btnSaveWriteProtectionStatus"
Text="Save WRITE PROTECTION STATUS response" Visible="False"/>
</StackLayout>
</TabPage>
<TabPage ID="tabSsc" Text="SSC" Visible="False">
<StackLayout Orientation="Vertical">
<StackLayoutItem HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
<GroupBox ID="grpDensitySupport" Text="Densities supported by currently inserted media"
Visible="False">
<TextArea ID="txtDensitySupport" ReadOnly="True"/>
</GroupBox>
</StackLayoutItem>
<StackLayoutItem HorizontalAlignment="Stretch" VerticalAlignment="Stretch">
<GroupBox ID="grpMediumSupport" Text="Medium types currently inserted in device"
Visible="False">
<TextArea ID="txtMediumSupport" ReadOnly="True"/>
</GroupBox>
</StackLayoutItem>
<Button Click="OnBtnSaveDensitySupportClick" ID="btnSaveDensitySupport"
Text="Save REPORT DENSITY SUPPORT (MEDIA) response" Visible="False"/>
<Button Click="OnBtnSaveMediumSupportClick" ID="btnSaveMediumSupport"
Text="Save REPORT DENSITY SUPPORT (MEDIUM &amp; MEDIA) response" Visible="False"/>
</StackLayout>
</TabPage>
<TabPage ID="tabCd" Text="CompactDisc" Visible="False">
<TabControl>
<TabPage ID="tabCdInformation" Text="Information" Visible="False">
<StackLayout Orientation="Vertical">
<StackLayoutItem Expand="True" VerticalAlignment="Stretch"
HorizontalAlignment="Stretch">
<TextArea ID="txtCdInformation" ReadOnly="True"/>
</StackLayoutItem>
<Button Click="OnBtnCdInformationClick" ID="btnCdInformation"
Text="Save READ DISC INFORMATION response"/>
</StackLayout>
</TabPage>
<TabPage ID="tabCdToc" Text="TOC" Visible="False">
<StackLayout Orientation="Vertical">
<StackLayoutItem Expand="True" VerticalAlignment="Stretch"
HorizontalAlignment="Stretch">
<TextArea ID="txtCdToc" ReadOnly="True"/>
</StackLayoutItem>
<Button Click="OnBtnCdTocClick" ID="btnCdToc" Text="Save READ TOC response"/>
</StackLayout>
</TabPage>
<TabPage ID="tabCdFullToc" Text="TOC (full)" Visible="False">
<StackLayout Orientation="Vertical">
<StackLayoutItem Expand="True" VerticalAlignment="Stretch"
HorizontalAlignment="Stretch">
<TextArea ID="txtCdFullToc" ReadOnly="True"/>
</StackLayoutItem>
<Button Click="OnBtnCdFullTocClick" ID="btnCdFullToc"
Text="Save READ RAW TOC response"/>
</StackLayout>
</TabPage>
<TabPage ID="tabCdSession" Text="Session" Visible="False">
<StackLayout Orientation="Vertical">
<StackLayoutItem Expand="True" VerticalAlignment="Stretch"
HorizontalAlignment="Stretch">
<TextArea ID="txtCdSession" ReadOnly="True"/>
</StackLayoutItem>
<Button Click="OnBtnCdSessionClick" ID="btnCdSession"
Text="Save READ SESSION response"/>
</StackLayout>
</TabPage>
<TabPage ID="tabCdText" Text="CD-TEXT" Visible="False">
<StackLayout Orientation="Vertical">
<StackLayoutItem Expand="True" VerticalAlignment="Stretch"
HorizontalAlignment="Stretch">
<TextArea ID="txtCdText" ReadOnly="True"/>
</StackLayoutItem>
<Button Click="OnBtnCdTextClick" ID="btnCdText" Text="Save Lead-In CD-TEXT"/>
</StackLayout>
</TabPage>
<TabPage ID="tabCdAtip" Text="ATIP" Visible="False">
<StackLayout Orientation="Vertical">
<StackLayoutItem Expand="True" VerticalAlignment="Stretch"
HorizontalAlignment="Stretch">
<TextArea ID="txtCdAtip" ReadOnly="True"/>
</StackLayoutItem>
<Button Click="OnBtnCdAtipClick" ID="btnCdAtip" Text="Save READ ATIP response"/>
</StackLayout>
</TabPage>
<TabPage ID="tabCdMisc" Text="Miscellaneous" Visible="False">
<StackLayout Orientation="Vertical">
<StackLayoutItem HorizontalAlignment="Stretch">
<StackLayout Orientation="Horizontal" ID="stkMcn" Visible="False">
<Label ID="lblMcn" Text="Media catalog number"/>
<TextBox ID="txtMcn" ReadOnly="True"/>
</StackLayout>
</StackLayoutItem>
<StackLayoutItem HorizontalAlignment="Stretch" VerticalAlignment="Stretch"
Expand="True">
<GroupBox ID="grpIsrcs" Text="ISRCs" Visible="False">
<TreeGridView ID="grdIsrcs"/>
</GroupBox>
</StackLayoutItem>
<Button Click="OnBtnCdPmaClick" ID="btnCdPma" Text="Save READ PMA response"
Visible="False"/>
</StackLayout>
</TabPage>
</TabControl>
</TabPage>
<TabPage ID="tabDvd" Text="DVD" Visible="False">
<StackLayout Orientation="Vertical">
<StackLayoutItem HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Expand="True">
<GroupBox ID="grpDvdPfi" Text="Physical Format Information" Visible="False">
<TextArea ID="txtDvdPfi" ReadOnly="True"/>
</GroupBox>
</StackLayoutItem>
<StackLayoutItem HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Expand="True">
<GroupBox ID="grpDvdCmi" Text="Copyright Management Information" Visible="False">
<TextArea ID="txtDvdCmi" ReadOnly="True"/>
</GroupBox>
</StackLayoutItem>
<Button Click="OnBtnSaveDvdPfiClick" ID="btnSaveDvdPfi" Text="Save Physical Format Information"
Visible="False"/>
<Button Click="OnBtnSaveDvdDmiClick" ID="btnSaveDvdDmi"
Text="Save Disc Manufacturer Information" Visible="False"/>
<Button Click="OnBtnSaveDvdCmiClick" ID="btnSaveDvdCmi"
Text="Save Copyright Management Information" Visible="False"/>
<Button Click="OnBtnSaveHdDvdCmiClick" ID="btnSaveHdDvdCmi"
Text="Save Copyright Management Information" Visible="False"/>
<Button Click="OnBtnSaveDvdBcaClick" ID="btnSaveDvdBca" Text="Save Burst Cutting Area"
Visible="False"/>
<Button Click="OnBtnSaveDvdAacsClick" ID="btnSaveDvdAacs" Text="Save AACS Information"
Visible="False"/>
</StackLayout>
</TabPage>
<TabPage ID="tabXbox" Text="Xbox" Visible="False">
<StackLayout Orientation="Vertical">
<StackLayout Orientation="Vertical" ID="stkXboxInformation" Visible="False">
<StackLayoutItem HorizontalAlignment="Stretch">
<StackLayout Orientation="Horizontal">
<Label ID="lblXboxL0Video" Text="Video layer 0 size"/>
<TextBox ID="txtXboxL0Video" ReadOnly="True"/>
</StackLayout>
</StackLayoutItem>
<StackLayoutItem HorizontalAlignment="Stretch">
<StackLayout Orientation="Horizontal">
<Label ID="lblXboxL1Video" Text="Video layer 1 size"/>
<TextBox ID="txtXboxL1Video" ReadOnly="True"/>
</StackLayout>
</StackLayoutItem>
<StackLayoutItem HorizontalAlignment="Stretch">
<StackLayout Orientation="Horizontal">
<Label ID="lblXboxMiddleZone" Text="Middle zone size"/>
<TextBox ID="txtXboxMiddleZone" ReadOnly="True"/>
</StackLayout>
</StackLayoutItem>
<StackLayoutItem HorizontalAlignment="Stretch">
<StackLayout Orientation="Horizontal">
<Label ID="lblXboxGameSize" Text="Game data size"/>
<TextBox ID="txtXboxGameSize" ReadOnly="True"/>
</StackLayout>
</StackLayoutItem>
<StackLayoutItem HorizontalAlignment="Stretch">
<StackLayout Orientation="Horizontal">
<Label ID="lblXboxTotalSize" Text="Total size"/>
<TextBox ID="txtXboxTotalSize" ReadOnly="True"/>
</StackLayout>
</StackLayoutItem>
<StackLayoutItem HorizontalAlignment="Stretch">
<StackLayout Orientation="Horizontal">
<Label ID="lblXboxRealBreak" Text="Real layer break"/>
<TextBox ID="txtXboxRealBreak" ReadOnly="True"/>
</StackLayout>
</StackLayoutItem>
</StackLayout>
<StackLayoutItem HorizontalAlignment="Stretch" Expand="True" VerticalAlignment="Stretch">
<GroupBox ID="grpXboxDmi" Text="Disc Manufacturing Information" Visible="False">
<TextArea ID="txtXboxDmi" ReadOnly="True"/>
</GroupBox>
</StackLayoutItem>
<StackLayoutItem HorizontalAlignment="Stretch" Expand="True" VerticalAlignment="Stretch">
<GroupBox ID="grpXboxSs" Text="Security Sector" Visible="False">
<TextArea ID="txtXboxSs" ReadOnly="True"/>
</GroupBox>
</StackLayoutItem>
<Button ID="btnSaveXboxSs" Click="OnBtnSaveXboxSsClick" Text="Save Xbox Security Sector"
Visible="False"/>
</StackLayout>
</TabPage>
<TabPage ID="tabDvdr" Text="DVD-R(W)" Visible="False">
<StackLayout Orientation="Vertical">
<StackLayoutItem HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Expand="True">
<GroupBox ID="grpDvdRamDds" Text="Disc Definition Structure" Visible="False">
<TextArea ID="txtDvdRamDds" ReadOnly="True"/>
</GroupBox>
</StackLayoutItem>
<StackLayoutItem HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Expand="True">
<GroupBox ID="grpDvdRamCartridgeStatus" Text="Cartridge Status" Visible="False">
<TextArea ID="txtDvdRamCartridgeStatus" ReadOnly="True"/>
</GroupBox>
</StackLayoutItem>
<StackLayoutItem HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Expand="True">
<GroupBox ID="grpDvdRamSpareAreaInformation" Text="Spare Area Information" Visible="False">
<TextArea ID="txtDvdRamSpareAreaInformation" ReadOnly="True"/>
</GroupBox>
</StackLayoutItem>
<Button Click="OnBtnSaveDvdRamDdsClick" ID="btnSaveDvdRamDds"
Text="Save Disc Definition Structure" Visible="False"/>
<Button Click="OnBtnSaveDvdRamCartridgeStatusClick" ID="btnSaveDvdRamCartridgeStatus"
Text="Save Cartridge Status" Visible="False"/>
<Button Click="OnBtnSaveDvdRamSpareAreaInformationClick" ID="btnSaveDvdRamSpareAreaInformation"
Text="Save Spare Area Information" Visible="False"/>
<Button Click="OnBtnSaveLastBorderOutRmdClick" ID="btnSaveLastBorderOutRmd"
Text="Save Last Border-Out RMD" Visible="False"/>
<Button Click="OnBtnSaveDvdPreRecordedInfoClick" ID="btnSaveDvdPreRecordedInfo"
Text="Save Pre-Recorded Physical Information" Visible="False"/>
<Button Click="OnBtnSaveDvdrMediaIdentifierClick" ID="btnSaveDvdrMediaIdentifier"
Text="Save Media Identifier" Visible="False"/>
<Button Click="OnBtnSaveDvdrPhysicalInformationClick" ID="btnSaveDvdrPhysicalInformation"
Text="Save Recordable Physical Information" Visible="False"/>
<Button Click="OnBtnSaveHddvdrMediumStatusClick" ID="btnSaveHddvdrMediumStatus"
Text="Save Medium Status" Visible="False"/>
<Button Click="OnBtnSaveHddvdrLastRmdClick" ID="btnSaveHddvdrLastRmd"
Text="Save Last Border-Out RMD" Visible="False"/>
<Button Click="OnBtnSaveDvdrLayerCapacityClick" ID="btnSaveDvdrLayerCapacity"
Text="Save Layer Capacity" Visible="False"/>
<Button Click="OnBtnSaveDvdrDlMiddleZoneStartClick" ID="btnSaveDvdrDlMiddleZoneStart"
Text="Save Middle Zone Start" Visible="False"/>
<Button Click="OnBtnSaveDvdrDlJumpIntervalSizeClick" ID="btnSaveDvdrDlJumpIntervalSize"
Text="Save Jump Interval Size" Visible="False"/>
<Button Click="OnBtnSaveDvdrDlManualLayerJumpStartLbaClick"
ID="btnSaveDvdrDlManualLayerJumpStartLba" Text="Save Manual Layer Jump Start LBA"
Visible="False"/>
<Button Click="OnBtnSaveDvdrDlRemapAnchorPointClick" ID="btnSaveDvdrDlRemapAnchorPoint"
Text="Save Remap Anchor Point" Visible="False"/>
<Button Click="OnBtnSaveDvdPlusAdipClick" ID="btnSaveDvdPlusAdip" Text="Save ADIP"
Visible="False"/>
<Button Click="OnBtnSaveDvdPlusDcbClick" ID="btnSaveDvdPlusDcb" Text="Save Disc Control Blocks"
Visible="False"/>
</StackLayout>
</TabPage>
<TabPage ID="tabBluray" Text="Blu-ray" Visible="False">
<StackLayout Orientation="Vertical">
<StackLayoutItem HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Expand="True">
<GroupBox ID="grpBlurayDiscInformation" Text="Disc information" Visible="False">
<TextArea ID="txtBlurayDiscInformation" ReadOnly="True"/>
</GroupBox>
</StackLayoutItem>
<StackLayoutItem HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Expand="True">
<GroupBox ID="grpBlurayBurstCuttingArea" Text="Burst Cutting Area" Visible="False">
<TextArea ID="txtBlurayBurstCuttingArea" ReadOnly="True"/>
</GroupBox>
</StackLayoutItem>
<StackLayoutItem HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Expand="True">
<GroupBox ID="grpBlurayDds" Text="Disc Definition Structure" Visible="False">
<TextArea ID="txtBlurayDds" ReadOnly="True"/>
</GroupBox>
</StackLayoutItem>
<StackLayoutItem HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Expand="True">
<GroupBox ID="grpBlurayCartridgeStatus" Text="Cartridge Status" Visible="False">
<TextArea ID="txtBlurayCartridgeStatus" ReadOnly="True"/>
</GroupBox>
</StackLayoutItem>
<StackLayoutItem HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Expand="True">
<GroupBox ID="grpBluraySpareAreaInformation" Text="Spare Area Information" Visible="False">
<TextArea ID="txtBluraySpareAreaInformation" ReadOnly="True"/>
</GroupBox>
</StackLayoutItem>
<StackLayoutItem HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Expand="True">
<GroupBox ID="grpBlurayPowResources" Text="Pseudo-OverWrite Resources" Visible="False">
<TextArea ID="txtBlurayPowResources" ReadOnly="True"/>
</GroupBox>
</StackLayoutItem>
<StackLayoutItem HorizontalAlignment="Stretch" VerticalAlignment="Stretch" Expand="True">
<GroupBox ID="grpBlurayTrackResources" Text="Track Resources" Visible="False">
<TextArea ID="txtBlurayTrackResources" ReadOnly="True"/>
</GroupBox>
</StackLayoutItem>
<Button Click="OnBtnSaveBlurayDiscInformationClick" ID="btnSaveBlurayDiscInformation"
Text="Save Disc Information" Visible="False"/>
<Button Click="OnBtnSaveBlurayBurstCuttingAreaClick" ID="btnSaveBlurayBurstCuttingArea"
Text="Save Burst Cutting Area" Visible="False"/>
<Button Click="OnBtnSaveBlurayDdsClick" ID="btnSaveBlurayDds"
Text="Save Disc Definition Structure" Visible="False"/>
<Button Click="OnBtnSaveBlurayCartridgeStatusClick" ID="btnSaveBlurayCartridgeStatus"
Text="Save Cartridge Status" Visible="False"/>
<Button Click="OnBtnSaveBluraySpareAreaInformationClick" ID="btnSaveBluraySpareAreaInformation"
Text="Save Spare Area Information" Visible="False"/>
<Button Click="OnBtnSaveBlurayPowResourcesClick" ID="btnSaveBlurayPowResources"
Text="Save Pseudo-OverWrite Resources" Visible="False"/>
<Button Click="OnBtnSaveBlurayTrackResourcesClick" ID="btnSaveBlurayTrackResources"
Text="Save Track Resources" Visible="False"/>
<Button Click="OnBtnSaveBlurayRawDflClick" ID="btnSaveBlurayRawDfl" Text="Save raw DFL"
Visible="False"/>
<Button Click="OnBtnSaveBlurayPacClick" ID="btnSaveBlurayPac" Text="Save PAC" Visible="False"/>
</StackLayout>
</TabPage>
</TabControl>
</StackLayoutItem>
<StackLayoutItem HorizontalAlignment="Left" VerticalAlignment="Bottom">
<Button Click="OnBtnDumpClick" ID="btnDump" Text="Dump media to image" Enabled="False"/>
</StackLayoutItem>
</StackLayout>
</Panel>

View File

@@ -0,0 +1,801 @@
// /***************************************************************************
// The Disc Image Chef
// ----------------------------------------------------------------------------
//
// Filename : pnlScsiInfo.xeto.cs
// Author(s) : Natalia Portillo <claunia@claunia.com>
//
// Component : SCSI media information panel.
//
// --[ Description ] ----------------------------------------------------------
//
// Implements the SCSI 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-2018 Natalia Portillo
// ****************************************************************************/
using System;
using System.Collections.Generic;
using System.IO;
using System.Text;
using DiscImageChef.CommonTypes;
using DiscImageChef.Core.Media.Info;
using DiscImageChef.Decoders.Bluray;
using DiscImageChef.Decoders.CD;
using DiscImageChef.Decoders.DVD;
using DiscImageChef.Decoders.SCSI.MMC;
using DiscImageChef.Decoders.SCSI.SSC;
using DiscImageChef.Decoders.Xbox;
using Eto.Forms;
using Eto.Serialization.Xaml;
using BCA = DiscImageChef.Decoders.Bluray.BCA;
using Cartridge = DiscImageChef.Decoders.DVD.Cartridge;
using DDS = DiscImageChef.Decoders.DVD.DDS;
using DMI = DiscImageChef.Decoders.Xbox.DMI;
using Spare = DiscImageChef.Decoders.DVD.Spare;
namespace DiscImageChef.Gui
{
public class pnlScsiInfo : Panel
{
ScsiInfo scsiInfo;
public pnlScsiInfo(ScsiInfo scsiInfo)
{
XamlReader.Load(this);
this.scsiInfo = scsiInfo;
switch(this.scsiInfo.MediaType)
{
case MediaType.HDDVDROM:
case MediaType.HDDVDRAM:
case MediaType.HDDVDR:
case MediaType.HDDVDRW:
case MediaType.HDDVDRDL:
case MediaType.HDDVDRWDL:
tabDvd.Text = "HD DVD";
break;
default:
tabDvd.Text = "DVD";
break;
}
switch(this.scsiInfo.MediaType)
{
case MediaType.DVDR:
tabDvdr.Text = "DVD-R";
break;
case MediaType.DVDRW:
tabDvdr.Text = "DVD-RW";
break;
case MediaType.DVDPR:
tabDvdr.Text = "DVD+R";
break;
case MediaType.DVDPRW:
tabDvdr.Text = "DVD+RW";
break;
case MediaType.DVDPRWDL:
tabDvdr.Text = "DVD+RW DL";
break;
case MediaType.DVDRDL:
tabDvdr.Text = "DVD-R DL";
break;
case MediaType.DVDPRDL:
tabDvdr.Text = "DVD+R DL";
break;
case MediaType.DVDRAM:
tabDvdr.Text = "DVD-RAM";
break;
case MediaType.DVDRWDL:
tabDvdr.Text = "DVD-RW DL";
break;
case MediaType.HDDVDRAM:
tabDvdr.Text = "HD DVD-RAM";
break;
case MediaType.HDDVDR:
tabDvdr.Text = "HD DVD-R";
break;
case MediaType.HDDVDRW:
tabDvdr.Text = "HD DVD-RW";
break;
case MediaType.HDDVDRDL:
tabDvdr.Text = "HD DVD-R DL";
break;
case MediaType.HDDVDRWDL:
tabDvdr.Text = "HD DVD-RW DL";
break;
}
txtType.Text = scsiInfo.MediaType.ToString();
lblMediaSize.Text =
$"Media has {scsiInfo.Blocks} blocks of {scsiInfo.BlockSize} bytes/each. (for a total of {scsiInfo.Blocks * scsiInfo.BlockSize} bytes)";
lblMediaSize.Visible = scsiInfo.Blocks != 0 && scsiInfo.BlockSize != 0;
if(scsiInfo.MediaSerialNumber != null)
{
stkMediaSerial.Visible = true;
StringBuilder sbSerial = new StringBuilder();
for(int i = 4; i < scsiInfo.MediaSerialNumber.Length; i++)
sbSerial.AppendFormat("{0:X2}", scsiInfo.MediaSerialNumber[i]);
txtMediaSerial.Text = sbSerial.ToString();
}
btnSaveReadMediaSerial.Visible = this.scsiInfo.MediaSerialNumber != null;
btnSaveReadCapacity.Visible = this.scsiInfo.ReadCapacity != null;
btnSaveReadCapacity16.Visible = this.scsiInfo.ReadCapacity16 != null;
btnSaveGetConfiguration.Visible = this.scsiInfo.MmcConfiguration != null;
btnSaveRecognizedFormatLayers.Visible = this.scsiInfo.RecognizedFormatLayers != null;
btnSaveWriteProtectionStatus.Visible = this.scsiInfo.WriteProtectionStatus != null;
tabMmc.Visible = btnSaveGetConfiguration.Visible || btnSaveRecognizedFormatLayers.Visible ||
btnSaveWriteProtectionStatus.Visible;
if(this.scsiInfo.DensitySupportHeader.HasValue)
{
grpDensitySupport.Visible = true;
txtDensitySupport.Text = DensitySupport.PrettifyDensity(scsiInfo.DensitySupportHeader);
}
if(this.scsiInfo.MediaTypeSupportHeader.HasValue)
{
grpMediumSupport.Visible = true;
txtMediumSupport.Text = DensitySupport.PrettifyMediumType(scsiInfo.MediaTypeSupportHeader);
}
btnSaveDensitySupport.Visible = scsiInfo.DensitySupport != null;
btnSaveMediumSupport.Visible = scsiInfo.MediaTypeSupport != null;
tabSsc.Visible = grpDensitySupport.Visible || grpMediumSupport.Visible || btnSaveDensitySupport.Visible ||
btnSaveMediumSupport.Visible;
if(this.scsiInfo.DecodedCompactDiscInformation.HasValue)
{
tabCdInformation.Visible = true;
txtCdInformation.Text = DiscInformation.Prettify000b(scsiInfo.DecodedCompactDiscInformation);
btnCdInformation.Visible = scsiInfo.CompactDiscInformation != null;
}
if(this.scsiInfo.DecodedToc.HasValue)
{
tabCdToc.Visible = true;
txtCdToc.Text = TOC.Prettify(scsiInfo.DecodedToc);
btnCdToc.Visible = scsiInfo.Toc != null;
}
if(this.scsiInfo.FullToc.HasValue)
{
tabCdFullToc.Visible = true;
txtCdFullToc.Text = FullTOC.Prettify(scsiInfo.FullToc);
btnCdFullToc.Visible = scsiInfo.RawToc != null;
}
if(this.scsiInfo.DecodedSession.HasValue)
{
tabCdSession.Visible = true;
txtCdSession.Text = Session.Prettify(scsiInfo.DecodedSession);
btnCdSession.Visible = scsiInfo.Session != null;
}
if(this.scsiInfo.DecodedCdTextLeadIn.HasValue)
{
tabCdText.Visible = true;
txtCdText.Text = CDTextOnLeadIn.Prettify(this.scsiInfo.DecodedCdTextLeadIn);
btnCdText.Visible = scsiInfo.CdTextLeadIn != null;
}
if(this.scsiInfo.DecodedAtip.HasValue)
{
tabCdAtip.Visible = true;
txtCdAtip.Text = ATIP.Prettify(this.scsiInfo.Atip);
btnCdAtip.Visible = scsiInfo.Atip != null;
}
if(!string.IsNullOrEmpty(scsiInfo.Mcn))
{
stkMcn.Visible = true;
txtMcn.Text = scsiInfo.Mcn;
}
if(this.scsiInfo.Isrcs != null && this.scsiInfo.Isrcs.Count > 0)
{
grpIsrcs.Visible = true;
TreeGridItemCollection isrcsItems = new TreeGridItemCollection();
grdIsrcs.Columns.Add(new GridColumn {HeaderText = "ISRC", DataCell = new TextBoxCell(0)});
grdIsrcs.Columns.Add(new GridColumn {HeaderText = "Track", DataCell = new TextBoxCell(0)});
grdIsrcs.AllowMultipleSelection = false;
grdIsrcs.ShowHeader = true;
grdIsrcs.DataStore = isrcsItems;
foreach(KeyValuePair<byte, string> isrc in this.scsiInfo.Isrcs)
isrcsItems.Add(new TreeGridItem {Values = new object[] {isrc.Key.ToString(), isrc.Value}});
}
btnCdPma.Visible = this.scsiInfo.Pma != null;
tabCdMisc.Visible = stkMcn.Visible || grpIsrcs.Visible || btnCdPma.Visible;
tabCd.Visible = tabCdInformation.Visible || tabCdToc.Visible || tabCdFullToc.Visible ||
tabCdSession.Visible || tabCdText.Visible || tabCdAtip.Visible || stkMcn.Visible ||
grpIsrcs.Visible || btnCdPma.Visible;
if(this.scsiInfo.DecodedPfi.HasValue)
{
grpDvdPfi.Visible = true;
txtDvdPfi.Text = PFI.Prettify(this.scsiInfo.DecodedPfi);
}
if(this.scsiInfo.DvdCmi != null)
{
grpDvdCmi.Visible = true;
txtDvdCmi.Text = CSS_CPRM.PrettifyLeadInCopyright(this.scsiInfo.DvdCmi);
btnSaveDvdCmi.Visible = true;
}
btnSaveDvdPfi.Visible = this.scsiInfo.DvdPfi != null;
btnSaveDvdDmi.Visible = this.scsiInfo.DvdDmi != null;
btnSaveDvdCmi.Visible = this.scsiInfo.DvdCmi != null;
btnSaveHdDvdCmi.Visible = this.scsiInfo.HddvdCopyrightInformation != null;
btnSaveDvdBca.Visible = this.scsiInfo.DvdBca != null;
btnSaveDvdAacs.Visible = this.scsiInfo.DvdAacs != null;
tabDvd.Visible = grpDvdPfi.Visible || grpDvdCmi.Visible || btnSaveDvdPfi.Visible ||
btnSaveDvdDmi.Visible ||
btnSaveDvdCmi.Visible || btnSaveHdDvdCmi.Visible || btnSaveDvdBca.Visible ||
btnSaveDvdAacs.Visible;
if(this.scsiInfo.XgdInfo != null)
{
stkXboxInformation.Visible = true;
txtXboxL0Video.Text = $"{this.scsiInfo.XgdInfo.L0Video} sectors";
txtXboxL1Video.Text = $"{this.scsiInfo.XgdInfo.L1Video} sectors";
txtXboxMiddleZone.Text = $"{this.scsiInfo.XgdInfo.MiddleZone} sectors";
txtXboxGameSize.Text = $"{this.scsiInfo.XgdInfo.GameSize} sectors";
txtXboxTotalSize.Text = $"{this.scsiInfo.XgdInfo.TotalSize} sectors";
txtXboxRealBreak.Text = this.scsiInfo.XgdInfo.LayerBreak.ToString();
}
if(this.scsiInfo.DvdDmi != null)
{
if(DMI.IsXbox(scsiInfo.DvdDmi))
{
grpXboxDmi.Visible = true;
txtXboxDmi.Text = DMI.PrettifyXbox(scsiInfo.DvdDmi);
}
else if(DMI.IsXbox360(scsiInfo.DvdDmi))
{
grpXboxDmi.Visible = true;
txtXboxDmi.Text = DMI.PrettifyXbox360(scsiInfo.DvdDmi);
}
}
if(this.scsiInfo.DecodedXboxSecuritySector.HasValue)
{
grpXboxSs.Visible = true;
txtXboxSs.Text = SS.Prettify(this.scsiInfo.DecodedXboxSecuritySector);
}
btnSaveXboxSs.Visible = this.scsiInfo.XboxSecuritySector != null;
tabXbox.Visible = stkXboxInformation.Visible || grpXboxDmi.Visible || grpXboxSs.Visible ||
btnSaveXboxSs.Visible;
if(this.scsiInfo.DvdRamDds != null)
{
grpDvdRamDds.Visible = true;
btnSaveDvdRamDds.Visible = true;
txtDvdRamDds.Text = DDS.Prettify(this.scsiInfo.DvdRamDds);
}
if(this.scsiInfo.DvdRamCartridgeStatus != null)
{
grpDvdRamCartridgeStatus.Visible = true;
btnSaveDvdRamCartridgeStatus.Visible = true;
txtDvdRamCartridgeStatus.Text = Cartridge.Prettify(this.scsiInfo.DvdRamCartridgeStatus);
}
if(this.scsiInfo.DvdRamSpareArea != null)
{
grpDvdRamSpareAreaInformation.Visible = true;
btnSaveDvdRamSpareAreaInformation.Visible = true;
txtDvdRamSpareAreaInformation.Text = Spare.Prettify(this.scsiInfo.DvdRamSpareArea);
}
btnSaveDvdRamDds.Visible = this.scsiInfo.DvdRamDds != null;
btnSaveDvdRamCartridgeStatus.Visible = this.scsiInfo.DvdRamCartridgeStatus != null;
btnSaveDvdRamSpareAreaInformation.Visible = this.scsiInfo.DvdRamSpareArea != null;
btnSaveLastBorderOutRmd.Visible = this.scsiInfo.LastBorderOutRmd != null;
btnSaveDvdPreRecordedInfo.Visible = this.scsiInfo.DvdPreRecordedInfo != null;
btnSaveDvdrMediaIdentifier.Visible = this.scsiInfo.DvdrMediaIdentifier != null;
btnSaveDvdrPhysicalInformation.Visible = this.scsiInfo.DvdrPhysicalInformation != null;
btnSaveHddvdrMediumStatus.Visible = this.scsiInfo.HddvdrMediumStatus != null;
btnSaveHddvdrLastRmd.Visible = this.scsiInfo.HddvdrLastRmd != null;
btnSaveDvdrLayerCapacity.Visible = this.scsiInfo.DvdrLayerCapacity != null;
btnSaveDvdrDlMiddleZoneStart.Visible = this.scsiInfo.DvdrDlMiddleZoneStart != null;
btnSaveDvdrDlJumpIntervalSize.Visible = this.scsiInfo.DvdrDlJumpIntervalSize != null;
btnSaveDvdrDlManualLayerJumpStartLba.Visible = this.scsiInfo.DvdrDlManualLayerJumpStartLba != null;
btnSaveDvdrDlRemapAnchorPoint.Visible = this.scsiInfo.DvdrDlRemapAnchorPoint != null;
btnSaveDvdPlusAdip.Visible = this.scsiInfo.DvdPlusAdip != null;
btnSaveDvdPlusDcb.Visible = this.scsiInfo.DvdPlusDcb != null;
tabDvdr.Visible = grpDvdRamDds.Visible || grpDvdRamCartridgeStatus.Visible ||
grpDvdRamSpareAreaInformation.Visible || btnSaveDvdRamDds.Visible ||
btnSaveDvdRamCartridgeStatus.Visible || btnSaveDvdRamSpareAreaInformation.Visible ||
btnSaveLastBorderOutRmd.Visible || btnSaveDvdPreRecordedInfo.Visible ||
btnSaveDvdrMediaIdentifier.Visible || btnSaveDvdrPhysicalInformation.Visible ||
btnSaveHddvdrMediumStatus.Visible || btnSaveHddvdrLastRmd.Visible ||
btnSaveDvdrLayerCapacity.Visible || btnSaveDvdrDlMiddleZoneStart.Visible ||
btnSaveDvdrDlJumpIntervalSize.Visible || btnSaveDvdrDlManualLayerJumpStartLba.Visible ||
btnSaveDvdrDlRemapAnchorPoint.Visible || btnSaveDvdPlusAdip.Visible ||
btnSaveDvdPlusDcb.Visible;
if(this.scsiInfo.BlurayDiscInformation != null)
{
grpBlurayDiscInformation.Visible = true;
btnSaveBlurayDiscInformation.Visible = true;
txtBlurayDiscInformation.Text = DI.Prettify(this.scsiInfo.BlurayDiscInformation);
}
if(this.scsiInfo.BlurayBurstCuttingArea != null)
{
grpBlurayBurstCuttingArea.Visible = true;
btnSaveBlurayBurstCuttingArea.Visible = true;
txtBlurayBurstCuttingArea.Text = BCA.Prettify(this.scsiInfo.BlurayBurstCuttingArea);
}
if(this.scsiInfo.BlurayDds != null)
{
grpBlurayDds.Visible = true;
btnSaveBlurayDds.Visible = true;
txtBlurayDds.Text = Decoders.Bluray.DDS.Prettify(this.scsiInfo.BlurayDds);
}
if(this.scsiInfo.BlurayCartridgeStatus != null)
{
grpBlurayCartridgeStatus.Visible = true;
btnSaveBlurayCartridgeStatus.Visible = true;
txtBlurayCartridgeStatus.Text =
Decoders.Bluray.Cartridge.Prettify(this.scsiInfo.BlurayCartridgeStatus);
}
if(this.scsiInfo.BluraySpareAreaInformation != null)
{
grpBluraySpareAreaInformation.Visible = true;
btnSaveBluraySpareAreaInformation.Visible = true;
txtBluraySpareAreaInformation.Text =
Decoders.Bluray.Spare.Prettify(this.scsiInfo.BluraySpareAreaInformation);
}
if(this.scsiInfo.BlurayPowResources != null)
{
grpBlurayPowResources.Visible = true;
btnSaveBlurayPowResources.Visible = true;
txtBlurayPowResources.Text = DiscInformation.Prettify(this.scsiInfo.BlurayPowResources);
}
if(this.scsiInfo.BlurayTrackResources != null)
{
grpBlurayTrackResources.Visible = true;
btnSaveBlurayTrackResources.Visible = true;
txtBlurayTrackResources.Text = DiscInformation.Prettify(this.scsiInfo.BlurayTrackResources);
}
btnSaveBlurayRawDfl.Visible = this.scsiInfo.BlurayRawDfl != null;
btnSaveBlurayPac.Visible = this.scsiInfo.BlurayPac != null;
tabBluray.Visible = grpBlurayDiscInformation.Visible || grpBlurayBurstCuttingArea.Visible ||
grpBlurayDds.Visible || grpBlurayCartridgeStatus.Visible ||
grpBluraySpareAreaInformation.Visible || grpBlurayPowResources.Visible ||
grpBlurayTrackResources.Visible || btnSaveBlurayRawDfl.Visible ||
btnSaveBlurayPac.Visible;
}
void SaveElement(byte[] data)
{
SaveFileDialog dlgSaveBinary = new SaveFileDialog();
dlgSaveBinary.Filters.Add(new FileFilter {Extensions = new[] {"*.bin"}, Name = "Binary"});
DialogResult result = dlgSaveBinary.ShowDialog(this);
if(result != DialogResult.Ok) return;
FileStream saveFs = new FileStream(dlgSaveBinary.FileName, FileMode.Create);
saveFs.Write(data, 0, data.Length);
saveFs.Close();
}
protected void OnBtnSaveReadMediaSerialClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.MediaSerialNumber);
}
protected void OnBtnSaveReadCapacityClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.ReadCapacity);
}
protected void OnBtnSaveReadCapacity16Click(object sender, EventArgs e)
{
SaveElement(scsiInfo.ReadCapacity16);
}
protected void OnBtnSaveGetConfigurationClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.MmcConfiguration);
}
protected void OnBtnSaveRecognizedFormatLayersClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.RecognizedFormatLayers);
}
protected void OnBtnSaveWriteProtectionStatusClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.WriteProtectionStatus);
}
protected void OnBtnSaveDensitySupportClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.DensitySupport);
}
protected void OnBtnSaveMediumSupportClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.MediaTypeSupport);
}
protected void OnBtnCdInformationClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.CompactDiscInformation);
}
protected void OnBtnCdTocClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.Toc);
}
protected void OnBtnCdFullTocClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.RawToc);
}
protected void OnBtnCdSessionClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.Session);
}
protected void OnBtnCdTextClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.CdTextLeadIn);
}
protected void OnBtnCdAtipClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.Atip);
}
protected void OnBtnCdPmaClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.Pma);
}
protected void OnBtnSaveDvdPfiClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.DvdPfi);
}
protected void OnBtnSaveDvdDmiClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.DvdDmi);
}
protected void OnBtnSaveDvdCmiClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.DvdCmi);
}
protected void OnBtnSaveHdDvdCmiClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.HddvdCopyrightInformation);
}
protected void OnBtnSaveDvdBcaClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.DvdBca);
}
protected void OnBtnSaveDvdAacsClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.DvdAacs);
}
protected void OnBtnSaveXboxSsClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.XboxSecuritySector);
}
protected void OnBtnSaveDvdRamDdsClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.DvdRamDds);
}
protected void OnBtnSaveDvdRamCartridgeStatusClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.DvdRamCartridgeStatus);
}
protected void OnBtnSaveDvdRamSpareAreaInformationClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.DvdRamSpareArea);
}
protected void OnBtnSaveLastBorderOutRmdClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.LastBorderOutRmd);
}
protected void OnBtnSaveDvdPreRecordedInfoClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.DvdPreRecordedInfo);
}
protected void OnBtnSaveDvdrMediaIdentifierClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.DvdrMediaIdentifier);
}
protected void OnBtnSaveDvdrPhysicalInformationClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.DvdrPhysicalInformation);
}
protected void OnBtnSaveHddvdrMediumStatusClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.HddvdrMediumStatus);
}
protected void OnBtnSaveHddvdrLastRmdClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.HddvdrLastRmd);
}
protected void OnBtnSaveDvdrLayerCapacityClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.DvdrLayerCapacity);
}
protected void OnBtnSaveDvdrDlMiddleZoneStartClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.DvdrDlMiddleZoneStart);
}
protected void OnBtnSaveDvdrDlJumpIntervalSizeClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.DvdrDlJumpIntervalSize);
}
protected void OnBtnSaveDvdrDlManualLayerJumpStartLbaClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.DvdrDlManualLayerJumpStartLba);
}
protected void OnBtnSaveDvdrDlRemapAnchorPointClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.DvdrDlRemapAnchorPoint);
}
protected void OnBtnSaveDvdPlusAdipClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.DvdPlusAdip);
}
protected void OnBtnSaveDvdPlusDcbClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.DvdPlusDcb);
}
protected void OnBtnSaveBlurayDiscInformationClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.BlurayDiscInformation);
}
protected void OnBtnSaveBlurayBurstCuttingAreaClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.BlurayBurstCuttingArea);
}
protected void OnBtnSaveBlurayDdsClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.BlurayDds);
}
protected void OnBtnSaveBlurayCartridgeStatusClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.BlurayCartridgeStatus);
}
protected void OnBtnSaveBluraySpareAreaInformationClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.BluraySpareAreaInformation);
}
protected void OnBtnSaveBlurayPowResourcesClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.BlurayPowResources);
}
protected void OnBtnSaveBlurayTrackResourcesClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.BlurayTrackResources);
}
protected void OnBtnSaveBlurayRawDflClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.BlurayRawDfl);
}
protected void OnBtnSaveBlurayPacClick(object sender, EventArgs e)
{
SaveElement(scsiInfo.BlurayPac);
}
protected void OnBtnDumpClick(object sender, EventArgs e)
{
// Not implemented
}
#region XAML controls
#pragma warning disable 169
#pragma warning disable 649
Label lblMediaInfo;
TabControl tabInfos;
TabPage tabGeneral;
Label lblType;
TextBox txtType;
Label lblMediaSize;
StackLayout stkMediaSerial;
Label lblMediaSerial;
TextBox txtMediaSerial;
Button btnSaveReadCapacity;
Button btnSaveReadCapacity16;
Button btnSaveReadMediaSerial;
TabPage tabMmc;
Button btnSaveGetConfiguration;
Button btnSaveRecognizedFormatLayers;
Button btnSaveWriteProtectionStatus;
TabPage tabSsc;
GroupBox grpDensitySupport;
TextArea txtDensitySupport;
GroupBox grpMediumSupport;
TextArea txtMediumSupport;
Button btnSaveDensitySupport;
Button btnSaveMediumSupport;
TabPage tabCd;
TabPage tabCdInformation;
TextArea txtCdInformation;
Button btnCdInformation;
TabPage tabCdToc;
TextArea txtCdToc;
Button btnCdToc;
TabPage tabCdFullToc;
TextArea txtCdFullToc;
Button btnCdFullToc;
TabPage tabCdSession;
TextArea txtCdSession;
Button btnCdSession;
TabPage tabCdText;
TextArea txtCdText;
Button btnCdText;
TabPage tabCdAtip;
TextArea txtCdAtip;
Button btnCdAtip;
TabPage tabCdMisc;
StackLayout stkMcn;
Label lblMcn;
TextBox txtMcn;
GroupBox grpIsrcs;
TreeGridView grdIsrcs;
Button btnCdPma;
TabPage tabDvd;
GroupBox grpDvdPfi;
TextArea txtDvdPfi;
GroupBox grpDvdCmi;
TextArea txtDvdCmi;
GroupBox grpHdDvdCmi;
TextArea txtHdDvdCmi;
Button btnSaveDvdPfi;
Button btnSaveDvdDmi;
Button btnSaveDvdCmi;
Button btnSaveHdDvdCmi;
Button btnSaveDvdBca;
Button btnSaveDvdAacs;
TabPage tabXbox;
StackLayout stkXboxInformation;
Label lblXboxL0Video;
TextBox txtXboxL0Video;
Label lblXboxL1Video;
TextBox txtXboxL1Video;
Label lblXboxMiddleZone;
TextBox txtXboxMiddleZone;
Label lblXboxGameSize;
TextBox txtXboxGameSize;
Label lblXboxTotalSize;
TextBox txtXboxTotalSize;
Label lblXboxRealBreak;
TextBox txtXboxRealBreak;
GroupBox grpXboxDmi;
TextArea txtXboxDmi;
GroupBox grpXboxSs;
TextArea txtXboxSs;
Button btnSaveXboxSs;
GroupBox grpDvdRamDds;
TextArea txtDvdRamDds;
GroupBox grpDvdRamCartridgeStatus;
TextArea txtDvdRamCartridgeStatus;
GroupBox grpDvdRamSpareAreaInformation;
TextArea txtDvdRamSpareAreaInformation;
Button btnSaveDvdRamDds;
Button btnSaveDvdRamCartridgeStatus;
Button btnSaveDvdRamSpareAreaInformation;
TabPage tabDvdr;
Button btnSaveLastBorderOutRmd;
Button btnSaveDvdPreRecordedInfo;
Button btnSaveDvdrMediaIdentifier;
Button btnSaveDvdrPhysicalInformation;
Button btnSaveHddvdrMediumStatus;
Button btnSaveHddvdrLastRmd;
Button btnSaveDvdrLayerCapacity;
Button btnSaveDvdrDlMiddleZoneStart;
Button btnSaveDvdrDlJumpIntervalSize;
Button btnSaveDvdrDlManualLayerJumpStartLba;
Button btnSaveDvdrDlRemapAnchorPoint;
Button btnSaveDvdPlusAdip;
Button btnSaveDvdPlusDcb;
TabPage tabBluray;
GroupBox grpBlurayDiscInformation;
TextArea txtBlurayDiscInformation;
GroupBox grpBlurayBurstCuttingArea;
TextArea txtBlurayBurstCuttingArea;
GroupBox grpBlurayDds;
TextArea txtBlurayDds;
GroupBox grpBlurayCartridgeStatus;
TextArea txtBlurayCartridgeStatus;
GroupBox grpBluraySpareAreaInformation;
TextArea txtBluraySpareAreaInformation;
GroupBox grpBlurayPowResources;
TextArea txtBlurayPowResources;
GroupBox grpBlurayTrackResources;
TextArea txtBlurayTrackResources;
Button btnSaveBlurayDiscInformation;
Button btnSaveBlurayBurstCuttingArea;
Button btnSaveBlurayDds;
Button btnSaveBlurayCartridgeStatus;
Button btnSaveBluraySpareAreaInformation;
Button btnSaveBlurayPowResources;
Button btnSaveBlurayTrackResources;
Button btnSaveBlurayRawDfl;
Button btnSaveBlurayPac;
Button btnDump;
#pragma warning restore 169
#pragma warning restore 649
#endregion
}
}