Allow repeated command entries when in "Special Menu" by not clearing "SelectedDirectory".

This commit is contained in:
Sam Hardeman 2020-10-22 18:03:26 +09:00
parent 2f686a7904
commit b1aa1a5fb9
1 changed files with 7 additions and 3 deletions

View File

@ -903,7 +903,9 @@ void AnycubicTFTClass::GetCommandFromTFT()
} }
case 8: // A8 GET SD LIST case 8: // A8 GET SD LIST
#ifdef SDSUPPORT #ifdef SDSUPPORT
if (!SpecialMenu)
SelectedDirectory[0]=0; SelectedDirectory[0]=0;
if(!IS_SD_INSERTED()) if(!IS_SD_INSERTED())
{ {
ANYCUBIC_SERIAL_PROTOCOLPGM("J02"); ANYCUBIC_SERIAL_PROTOCOLPGM("J02");
@ -985,6 +987,7 @@ void AnycubicTFTClass::GetCommandFromTFT()
} else if (TFTstrchr_pointer[4] == '<') { } else if (TFTstrchr_pointer[4] == '<') {
strcpy(SelectedDirectory, TFTstrchr_pointer+4); strcpy(SelectedDirectory, TFTstrchr_pointer+4);
} else { } else {
if (!SpecialMenu)
SelectedDirectory[0]=0; SelectedDirectory[0]=0;
if(starpos!=NULL) if(starpos!=NULL)
@ -1211,6 +1214,7 @@ void AnycubicTFTClass::GetCommandFromTFT()
} }
} }
if (!SpecialMenu)
SelectedDirectory[0]=0; SelectedDirectory[0]=0;
if(!IS_SD_INSERTED()) if(!IS_SD_INSERTED())