Show filename during print fixed, sorting files on Sd card in farm mode fixed
This commit is contained in:
parent
a9cbd91321
commit
33168bedbd
|
|
@ -4186,7 +4186,8 @@ void lcd_sdcard_menu()
|
||||||
{
|
{
|
||||||
if (_menuItemNr == _lineNr)
|
if (_menuItemNr == _lineNr)
|
||||||
{
|
{
|
||||||
const uint16_t nr = (sdSort == SD_SORT_NONE) ? (fileCnt - 1 - i) : i;
|
const uint16_t nr = ((sdSort == SD_SORT_NONE) || farm_mode) ? (fileCnt - 1 - i) : i;
|
||||||
|
|
||||||
/* #ifdef SDCARD_RATHERRECENTFIRST
|
/* #ifdef SDCARD_RATHERRECENTFIRST
|
||||||
#ifndef SDCARD_SORT_ALPHA
|
#ifndef SDCARD_SORT_ALPHA
|
||||||
fileCnt - 1 -
|
fileCnt - 1 -
|
||||||
|
|
|
||||||
|
|
@ -830,21 +830,20 @@ static void lcd_implementation_status_screen()
|
||||||
// If heating in progress, set flag
|
// If heating in progress, set flag
|
||||||
if (heating_status != 0) { custom_message = true; }
|
if (heating_status != 0) { custom_message = true; }
|
||||||
|
|
||||||
|
if (IS_SD_PRINTING) {
|
||||||
|
if (strcmp(longFilenameOLD, card.longFilename) != 0)
|
||||||
|
{
|
||||||
|
memset(longFilenameOLD, '\0', strlen(longFilenameOLD));
|
||||||
|
sprintf_P(longFilenameOLD, PSTR("%s"), card.longFilename);
|
||||||
|
scrollstuff = 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
// If printing from SD, show what we are printing
|
// If printing from SD, show what we are printing
|
||||||
if (IS_SD_PRINTING)
|
if (IS_SD_PRINTING && !custom_message)
|
||||||
{
|
{
|
||||||
|
|
||||||
if(strcmp(longFilenameOLD, card.longFilename) != 0)
|
|
||||||
{
|
|
||||||
memset(longFilenameOLD,'\0',strlen(longFilenameOLD));
|
|
||||||
sprintf_P(longFilenameOLD, PSTR("%s"), card.longFilename);
|
|
||||||
scrollstuff = 0;
|
|
||||||
}
|
|
||||||
if (!custom_message) {
|
|
||||||
|
|
||||||
if (strlen(card.longFilename) > LCD_WIDTH)
|
if (strlen(card.longFilename) > LCD_WIDTH)
|
||||||
{
|
{
|
||||||
|
|
||||||
int inters = 0;
|
int inters = 0;
|
||||||
int gh = scrollstuff;
|
int gh = scrollstuff;
|
||||||
while (((gh - scrollstuff) < LCD_WIDTH) && (inters == 0))
|
while (((gh - scrollstuff) < LCD_WIDTH) && (inters == 0))
|
||||||
|
|
@ -873,9 +872,6 @@ static void lcd_implementation_status_screen()
|
||||||
{
|
{
|
||||||
lcd.print(longFilenameOLD);
|
lcd.print(longFilenameOLD);
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
// If not, check for other special events
|
// If not, check for other special events
|
||||||
else
|
else
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue