Add LZSS/BLZ decompression by dropping on ToolsUI

Tools UI now has the same functionality as GARCTool.
This commit is contained in:
Kurt
2015-11-08 21:57:05 -08:00
parent e14451cd11
commit 6ee56c8306
2 changed files with 7 additions and 2 deletions

View File

@@ -57,9 +57,9 @@ private void InitializeComponent()
this.L_DARCMini.AutoSize = true;
this.L_DARCMini.Location = new System.Drawing.Point(9, 9);
this.L_DARCMini.Name = "L_DARCMini";
this.L_DARCMini.Size = new System.Drawing.Size(145, 13);
this.L_DARCMini.Size = new System.Drawing.Size(294, 13);
this.L_DARCMini.TabIndex = 1;
this.L_DARCMini.Text = "GARC, DARC && Mini Unpack";
this.L_DARCMini.Text = "GARC, DARC && Mini Unpack (CTRL to Skip Decompression)";
//
// CHK_PNG
//

View File

@@ -41,6 +41,11 @@ private void tabMain_DragDrop(object sender, DragEventArgs e)
openIMG(path);
else if (sender == PB_Repack)
saveARC(path);
else try {
CTR.LZSS.Decompress(path, Path.Combine(Path.GetDirectoryName(path), "dec_" + Path.GetFileName(path)));
} catch { try {
new Thread(() => { threads++; new CTR.BLZCoder(new[] { "-d", path }, pBar1); threads--; Util.Alert("Decompressed!"); }).Start();
} catch { Util.Error("Unable to process file."); } }
}
private void dropHover(object sender, EventArgs e)
{