Skip to content

Commit

Permalink
improved support for odyssey
Browse files Browse the repository at this point in the history
improved credit calculation
  • Loading branch information
mhwlng committed May 20, 2021
1 parent d4c1509 commit 4486bef
Show file tree
Hide file tree
Showing 21 changed files with 691 additions and 175 deletions.
3 changes: 1 addition & 2 deletions EDEngineer/EDEngineer/Resources/Data/entryData.json
Original file line number Diff line number Diff line change
Expand Up @@ -1187,8 +1187,7 @@
"OriginDetails": [
"Surface prospecting"
],
"Group": "Category3",
"MaximumCapacity": 100
"Group": "Category3"
},
{
"Name": "Salvaged Alloys",
Expand Down
12 changes: 12 additions & 0 deletions Elite/App.xaml.cs
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ public partial class App : Application
public static JournalWatcher journalWatcher;
public static CargoWatcher cargoWatcher;
public static NavRouteWatcher navRouteWatcher;
public static BackPackWatcher backPackWatcher;

private static StatusWatcher _statusWatcher;

Expand Down Expand Up @@ -578,6 +579,13 @@ protected override void OnStartup(StartupEventArgs evtArgs)

navRouteWatcher.StartWatching();

splashScreen.Dispatcher.Invoke(() => splashScreen.ProgressText.Text = "Starting Elite BackPack Watcher...");
backPackWatcher = new BackPackWatcher(path);

backPackWatcher.BackPackUpdated += Data.HandleBackPackEvent;

backPackWatcher.StartWatching();

splashScreen.Dispatcher.Invoke(() => splashScreen.ProgressText.Text = "Initializing FIP...");
if (!FipHandler.Initialize())
{
Expand Down Expand Up @@ -692,6 +700,10 @@ protected override void OnExit(ExitEventArgs e)

navRouteWatcher.StopWatching();

backPackWatcher.BackPackUpdated -= Data.HandleBackPackEvent;

backPackWatcher.StopWatching();

FipHandler.Close();

_notifyIcon.Dispose(); //the icon would clean up automatically, but this is cleaner
Expand Down
Loading

0 comments on commit 4486bef

Please sign in to comment.