Skip to content

Commit

Permalink
Add ability to trim and untrim XCI files from the application context…
Browse files Browse the repository at this point in the history
… menu AND in Bulk (#105)
  • Loading branch information
amurgshere authored Nov 6, 2024
1 parent 47b8145 commit 4831965
Show file tree
Hide file tree
Showing 23 changed files with 2,095 additions and 3 deletions.
1 change: 1 addition & 0 deletions src/Ryujinx.Common/Logging/LogClass.cs
Original file line number Diff line number Diff line change
Expand Up @@ -72,5 +72,6 @@ public enum LogClass
TamperMachine,
UI,
Vic,
XCIFileTrimmer
}
}
30 changes: 30 additions & 0 deletions src/Ryujinx.Common/Logging/XCIFileTrimmerLog.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
using Ryujinx.Common.Utilities;

namespace Ryujinx.Common.Logging
{
public class XCIFileTrimmerLog : XCIFileTrimmer.ILog
{
public virtual void Progress(long current, long total, string text, bool complete)
{
}

public void Write(XCIFileTrimmer.LogType logType, string text)
{
switch (logType)
{
case XCIFileTrimmer.LogType.Info:
Logger.Notice.Print(LogClass.XCIFileTrimmer, text);
break;
case XCIFileTrimmer.LogType.Warn:
Logger.Warning?.Print(LogClass.XCIFileTrimmer, text);
break;
case XCIFileTrimmer.LogType.Error:
Logger.Error?.Print(LogClass.XCIFileTrimmer, text);
break;
case XCIFileTrimmer.LogType.Progress:
Logger.Info?.Print(LogClass.XCIFileTrimmer, text);
break;
}
}
}
}
Loading

0 comments on commit 4831965

Please sign in to comment.