1
0
Fork 0
mirror of https://github.com/opentx/opentx.git synced 2025-07-19 06:15:10 +03:00

Fixed: same BMP was loaded over and over

This commit is contained in:
Damjan Adamic 2016-01-02 20:26:34 +01:00
parent 1b177ba8b8
commit 8809a64d57

View file

@ -359,9 +359,9 @@ bool menuGeneralSdManager(evt_t _event)
char * ext = getFileExtension(reusableBuffer.sdmanager.lines[index], SD_SCREEN_FILE_LENGTH+1);
if (ext && !strcasecmp(ext, BITMAPS_EXT)) {
if (lastBitmap != menuVerticalPosition) {
lastBitmap = menuVerticalPosition;
if (bmpLoad(modelBitmap, reusableBuffer.sdmanager.lines[index], MODEL_BITMAP_WIDTH, MODEL_BITMAP_HEIGHT)) {
((uint32_t *)modelBitmap)[0] = 0;
lastBitmap = menuVerticalPosition;
}
}
lcdDrawBitmap(LCD_W/2, (LCD_H-MODEL_BITMAP_HEIGHT)/2, modelBitmap);