Prepare for display orientation part 1 (#2661)

This commit is contained in:
Totoo
2025-05-22 17:24:53 +02:00
committed by GitHub
parent 6f6d863a14
commit a1d7cf2b86
85 changed files with 405 additions and 334 deletions
@@ -244,12 +244,12 @@ std::vector<uint8_t> SpectrumInputImageView::get_line(uint16_t y) {
void SpectrumInputImageView::paint(Painter& painter) {
painter.fill_rectangle(
{{0, 40}, {240, 204}},
{{0, 40}, {screen_width, 204}},
style().background);
if (!painted) {
// This is very slow for big pictures. Do only once.
this->drawBMP_scaled({{0, 40}, {240, 160}}, this->file);
this->drawBMP_scaled({{0, 40}, {screen_width, 160}}, this->file);
painted = true;
}
}