Fix empty drive not showing T??

This commit is contained in:
michaelangel007 2023-04-25 22:58:15 -07:00
parent fdd93d0b43
commit 789ff5336f
2 changed files with 5 additions and 3 deletions

View File

@ -135,7 +135,7 @@ public:
DWORD m_spinning;
DWORD m_writelight;
FloppyDisk m_disk;
BYTE m_LastReadTrackSector[2];
int m_LastReadTrackSector[2];
};
class Disk2InterfaceCard : public Card

View File

@ -609,7 +609,9 @@ void Win32Frame::FrameDrawDiskStatus()
void Win32Frame::GetTrackSector(UINT slot, int& drive1Track, int& drive2Track, int& activeFloppy)
{
drive1Track = drive2Track = activeFloppy = 0;
drive1Track = -1;
drive2Track = -1;
activeFloppy = 0;
g_nSector[slot][0] = -1;
g_nSector[slot][1] = -1;
@ -625,7 +627,7 @@ void Win32Frame::GetTrackSector(UINT slot, int& drive1Track, int& drive2Track, i
void Win32Frame::CreateTrackSectorStrings(int track, int sector, std::string& strTrack, std::string& strSector)
{
strTrack = StrFormat("%2d", track);
strTrack = (track < 0) ? "??" : StrFormat("%2d", track );
strSector = (sector < 0) ? "??" : StrFormat("%2d", sector);
}