Skip to content

Commit

Permalink
Fixed bug where a full flash would be allowed even if there wasn't an…
Browse files Browse the repository at this point in the history
… opened MPC file
  • Loading branch information
terraphantm committed Feb 2, 2019
1 parent d5258fe commit 47674d6
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
4 changes: 2 additions & 2 deletions MS45 Flasher/Global.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ public class Global //I know global variables are supposed to be bad, but I'm no
public static string ecuPath = ConfigurationManager.AppSettings["ecuPath"];
public static string Port = ConfigurationManager.AppSettings["Port"];
//I'd also like to add the ability to use a bluetooth interface
public static byte[] openedFlash;
public static byte[] openedMPC;
public static byte[] openedFlash = null;
public static byte[] openedMPC = null;

private static string SetTitle()
{
Expand Down
7 changes: 5 additions & 2 deletions MS45 Flasher/MainWindow.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -253,8 +253,11 @@ private void LoadFile_1()
}
}

FlashDME.IsEnabled = true;
FlashProgram.IsEnabled = true;
if (Global.openedMPC != null)
{
FlashDME.IsEnabled = true;
FlashProgram.IsEnabled = true;
}
}

}
Expand Down

0 comments on commit 47674d6

Please sign in to comment.