Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 14 additions & 4 deletions src/Common/InputSupport/DirectInput/DIDeviceMonitor.cs
Original file line number Diff line number Diff line change
Expand Up @@ -203,11 +203,19 @@ public void DIEventMonitorThreadWork()
}
}
}
catch (ThreadAbortException)
catch (ThreadAbortException exception)
{
Log.Error(exception.ToString());
Thread.ResetAbort();
}
catch (ThreadInterruptedException) {}
catch (ThreadInterruptedException exception)
{
Log.Error(exception.ToString());
}
catch (Exception exception)
{
Log.Error(exception.ToString());
}
}
}

Expand Down Expand Up @@ -368,8 +376,9 @@ protected override void Prepare()
Prepared = true;
}
}
catch
catch(Exception exception)
{
Log.Error(exception.ToString());
Prepared = false;
}
finally
Expand Down Expand Up @@ -446,8 +455,9 @@ private void GetNewJoyState()
StateChanged?.Invoke(this, new DIStateChangedEventArgs(_prevState, _state));
}
}
catch
catch(Exception exception)
{
Log.Error(exception.ToString());
Dispose();
Prepared = false;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ public InputControlEventHandler(
ISetExtFuelSwitchTransWingFirstEventHandler setExtFuelSwitchTransWingFirstEventHandler=null
)
{
falconCallbackSender = falconCallbackSender ?? new FalconCallbackSender(mfdManager);
_optionSelectButtonPressHandler = optionSelectButtonPressHandler ?? new OptionSelectButtonPressHandler(mfdManager, falconCallbackSender);
_setHsiModeTcnEventHandler = setHsiModeTcnEventHandler ?? new SetHsiModeTcnEventHandler(falconCallbackSender);
_setHsiModePlsNavEventHandler = setHsiModePlsNavEventHandler ?? new SetHsiModePlsNavEventHandler(falconCallbackSender);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ public void DrawCenterAirplaneSymbol(Graphics g, Rectangle renderRectangle)
{
if (_mapAirplaneBitmap == null)
{
_mapAirplaneBitmap = (Bitmap) Resources.F16Symbol.Clone();
_mapAirplaneBitmap = new Bitmap((System.Drawing.Image) Resources.F16Symbol.Clone());
_mapAirplaneBitmap.MakeTransparent(Color.FromArgb(255, 0, 255));
_mapAirplaneBitmap =
(Bitmap)
Expand Down
4 changes: 2 additions & 2 deletions src/F4Utils/Terrain/TileSetConfigValueReader.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@ public string TileSetConfigValue
get
{
var configLines = new List<string>();
var configFolder = Path.Combine(_bmsBaseDir, @"\Config");
var bmsConfigFile = Path.Combine(configFolder, "Falcon BMS.config");
var configFolder = Path.Combine(_bmsBaseDir, "User/Config");
var bmsConfigFile = Path.Combine(configFolder, "Falcon BMS.cfg");
using (var sr = new StreamReader(bmsConfigFile))
{
while (!sr.EndOfStream)
Expand Down