mirror of
https://github.com/Thealexbarney/LibHac.git
synced 2024-11-14 10:49:41 +01:00
Add nacp U8Span properties for convenience
Adds U8Span properties for the fields in ApplicationControlProperty that contain strings. Makes it easier to know what these fields contain.
This commit is contained in:
parent
19dc9ebe9f
commit
d6bfecb63f
3 changed files with 8 additions and 3 deletions
|
@ -71,6 +71,11 @@ public struct ApplicationControlProperty
|
|||
public AccessibleLaunchRequiredVersionValue AccessibleLaunchRequiredVersion;
|
||||
public Array3000<byte> Reserved3448;
|
||||
|
||||
public U8Span IsbnString => new U8Span(Isbn.ItemsRo);
|
||||
public U8Span DisplayVersionString => new U8Span(DisplayVersion.ItemsRo);
|
||||
public U8Span ApplicationErrorCodeCategoryString => new U8Span(ApplicationErrorCodeCategory.ItemsRo);
|
||||
public U8Span BcatPassphraseString => new U8Span(BcatPassphrase.ItemsRo);
|
||||
|
||||
public struct ApplicationTitle
|
||||
{
|
||||
private Array512<byte> _name;
|
||||
|
|
|
@ -406,14 +406,14 @@ public class Application
|
|||
{
|
||||
Name = Patch.Name;
|
||||
Version = Patch.Version;
|
||||
DisplayVersion = Patch.Control.Value.DisplayVersion.ToString();
|
||||
DisplayVersion = Patch.Control.Value.DisplayVersionString.ToString();
|
||||
Nacp = Patch.Control;
|
||||
}
|
||||
else if (Main != null)
|
||||
{
|
||||
Name = Main.Name;
|
||||
Version = Main.Version;
|
||||
DisplayVersion = Main.Control.Value.DisplayVersion.ToString();
|
||||
DisplayVersion = Main.Control.Value.DisplayVersionString.ToString();
|
||||
Nacp = Main.Control;
|
||||
}
|
||||
else
|
||||
|
|
|
@ -245,7 +245,7 @@ internal static class ProcessSwitchFs
|
|||
title.Version?.ToString(),
|
||||
title.Metadata?.Type.Print(),
|
||||
Utilities.GetBytesReadable(title.GetSize()),
|
||||
title.Control.Value.DisplayVersion.ToString(),
|
||||
title.Control.Value.DisplayVersionString.ToString(),
|
||||
title.Name);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue