Skip to content

Commit 1b30122

Browse files
committed
Revert "uae: use existing thing instead of GetFullName()"
This reverts commit 13f49a1. fixed GetFullName() instead
1 parent 6dccb75 commit 1b30122

File tree

1 file changed

+6
-4
lines changed
  • src/BizHawk.Emulation.Cores/Computers/Amiga

1 file changed

+6
-4
lines changed

src/BizHawk.Emulation.Cores/Computers/Amiga/UAE.cs

+6-4
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
using System.Linq;
44
using System.Text;
55

6+
using BizHawk.Common.StringExtensions;
67
using BizHawk.Emulation.Common;
78
using BizHawk.Emulation.Cores.Waterbox;
89

@@ -55,6 +56,7 @@ public partial class UAE : WaterboxCore
5556
private bool _nextDrivePressed;
5657
private int _correctedWidth;
5758
private string _chipsetCompatible = "";
59+
private string GetFullName(IRomAsset rom) => Path.GetFileName(rom.RomPath.SubstringAfter('|'));
5860

5961
public override int VirtualWidth => _correctedWidth;
6062

@@ -218,7 +220,7 @@ protected override LibWaterboxCore.FrameInfo FrameAdvancePrep(IController contro
218220
}
219221
else
220222
{
221-
CoreComm.Notify($"Ejected drive FD{_currentDrive}: {Path.GetFileName(_roms[_driveSlots[_currentDrive]].RomPath)}", _messageDuration);
223+
CoreComm.Notify($"Ejected drive FD{_currentDrive}: {GetFullName(_roms[_driveSlots[_currentDrive]])}", _messageDuration);
222224
_driveSlots[_currentDrive] = _driveNullOrEmpty;
223225
}
224226
}
@@ -240,7 +242,7 @@ protected override LibWaterboxCore.FrameInfo FrameAdvancePrep(IController contro
240242
}
241243
}
242244
_driveSlots[_currentDrive] = _currentSlot;
243-
CoreComm.Notify($"Insterted drive FD{_currentDrive}: {Path.GetFileName(_roms[_driveSlots[_currentDrive]].RomPath)}", _messageDuration);
245+
CoreComm.Notify($"Insterted drive FD{_currentDrive}: {GetFullName(_roms[_driveSlots[_currentDrive]])}", _messageDuration);
244246
}
245247
}
246248

@@ -251,7 +253,7 @@ protected override LibWaterboxCore.FrameInfo FrameAdvancePrep(IController contro
251253
_currentSlot++;
252254
_currentSlot %= _roms.Count;
253255
var selectedFile = _roms[_currentSlot];
254-
CoreComm.Notify($"Selected slot {_currentSlot}: {Path.GetFileName(selectedFile.RomPath)}", _messageDuration);
256+
CoreComm.Notify($"Selected slot {_currentSlot}: {GetFullName(selectedFile)}", _messageDuration);
255257
}
256258
}
257259

@@ -268,7 +270,7 @@ protected override LibWaterboxCore.FrameInfo FrameAdvancePrep(IController contro
268270
}
269271
else
270272
{
271-
name = Path.GetFileName(_roms[_driveSlots[_currentDrive]].RomPath);
273+
name = GetFullName(_roms[_driveSlots[_currentDrive]]);
272274
}
273275
CoreComm.Notify($"Selected drive FD{_currentDrive}: {name}", _messageDuration);
274276
}

0 commit comments

Comments
 (0)