Skip to content

Commit

Permalink
refactor: no files screen port
Browse files Browse the repository at this point in the history
  • Loading branch information
Otrebor671 committed Sep 20, 2024
1 parent d381f4e commit 4ff0e89
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions firmware/main/modules/file_manager/file_manager_screens.c
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,10 @@ static void update_list(file_manager_context_t* ctx) {
oled_screen_clear_buffer();
oled_screen_display_text("< Back", 0, 0, OLED_DISPLAY_NORMAL);
if (ctx->items_count == 0) {
oled_screen_display_text(" Empty folder ", 0, 3, OLED_DISPLAY_NORMAL);
oled_screen_display_text("No files to show", 0, 4, OLED_DISPLAY_NORMAL);
oled_screen_display_text(" Empty folder ", 0, MAX_ITEMS_NUM / 2 - 1,
OLED_DISPLAY_NORMAL);
oled_screen_display_text("Nothing to show", 0, MAX_ITEMS_NUM / 2,
OLED_DISPLAY_NORMAL);
} else {
for (uint8_t i = 0; i < (MIN(ctx->items_count, MAX_ITEMS_NUM - 1)); i++) {
char* str = (char*) malloc(30);
Expand Down

0 comments on commit 4ff0e89

Please sign in to comment.