Skip to content

Commit

Permalink
Resizeable window done, .srl support and selection block total label …
Browse files Browse the repository at this point in the history
…added
  • Loading branch information
MrJPGames committed Jul 24, 2018
1 parent 22a96f5 commit a8b8b8b
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 3 deletions.
19 changes: 17 additions & 2 deletions SRL2Hiya/Form1.Designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 6 additions & 1 deletion SRL2Hiya/Form1.cs
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ public partial class Form1 : Form {

private void RefreshPCList() {
PCDsiWareList.Items.Clear();
var ext = new List<string> { ".app", ".nds" };
var ext = new List<string> { ".app", ".nds", ".srl" };
var myFiles = Directory.GetFiles(pcDirectory, "*.*", SearchOption.AllDirectories)
.Where(s => ext.Contains(Path.GetExtension(s)));

Expand Down Expand Up @@ -272,6 +272,11 @@ public partial class Form1 : Form {
private void PCDsiWareList_SelectedIndexChanged(object sender, EventArgs e) {
if (PCDsiWareList.SelectedItems.Count > 0 && validDriveSelected) {
ToSDButton.Enabled = true;
int blockTotal = 0;
foreach (ListViewItem item in PCDsiWareList.SelectedItems) {
blockTotal += ((DSiWareTitle)item.Tag).blocks;
}
PCSelectionBlockTotalLabel.Text = "Selection block total: " + blockTotal + " blocks";
} else {
ToSDButton.Enabled = false;
}
Expand Down

0 comments on commit a8b8b8b

Please sign in to comment.