splash fix and draw bmp fuc logic wrong (#2376)

* revert

* rename drawBMP to draw_bmp_from_bmp_hex_arr

* rename drawBMP2

* add comments

* rename BMPView class in child of nav into SplashView

* rename SplashView class in child of nav into SplashScreeView

* fix draw from wrong line

* comment

* comment

* comment
This commit is contained in:
sommermorgentraum 2024-11-20 17:35:40 +08:00 committed by GitHub
parent 131523d726
commit e88e0b5f8f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
6 changed files with 26 additions and 22 deletions

View file

@ -119,7 +119,7 @@ bool SplashViewer::on_key(const KeyEvent key) {
void SplashViewer::paint(Painter& painter) {
painter.fill_rectangle({0, 0, screen_width, screen_height}, Color::black());
if (!portapack::display.drawBMP2({0, 0}, path_)) {
if (!portapack::display.draw_bmp_from_sdcard_file({0, 0}, path_)) {
painter.draw_string({10, 160}, *Theme::getInstance()->bg_darkest, "Not a valid splash image.");
return;
}