mirror of
https://github.com/portapack-mayhem/mayhem-firmware.git
synced 2026-09-16 19:43:01 +00:00
Remove unused _previous_frequency member from BigFrequency and remove paint() guard
Co-authored-by: gullradriel <3157857+gullradriel@users.noreply.github.com>
This commit is contained in:
committed by
GitHub
parent
824b53f7d4
commit
1fcd87756e
@@ -564,12 +564,8 @@ void LiveDateTime::set_seconds_enabled(bool new_value) {
|
||||
|
||||
/* BigFrequency **********************************************************/
|
||||
|
||||
BigFrequency::BigFrequency(
|
||||
Rect parent_rect,
|
||||
rf::Frequency frequency)
|
||||
: Widget{parent_rect},
|
||||
_frequency{frequency} {
|
||||
}
|
||||
BigFrequency::BigFrequency(Rect parent_rect, rf::Frequency frequency)
|
||||
: Widget{parent_rect}, _frequency{frequency} {}
|
||||
|
||||
void BigFrequency::set(const rf::Frequency frequency) {
|
||||
_frequency = frequency;
|
||||
@@ -583,9 +579,6 @@ void BigFrequency::paint(Painter& painter) {
|
||||
Point digit_pos;
|
||||
ui::Color segment_color;
|
||||
|
||||
if (_frequency != _previous_frequency) {
|
||||
_previous_frequency = _frequency;
|
||||
|
||||
rf::Frequency frequency{_frequency};
|
||||
const auto rect = screen_rect(); // why not use screen_rect() directly for width, ...? it may be too small, but ...
|
||||
|
||||
@@ -642,7 +635,6 @@ void BigFrequency::paint(Painter& painter) {
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* ProgressBar ***********************************************************/
|
||||
|
||||
|
||||
@@ -297,7 +297,6 @@ class BigFrequency : public Widget {
|
||||
|
||||
private:
|
||||
rf::Frequency _frequency;
|
||||
rf::Frequency _previous_frequency{~0LL};
|
||||
|
||||
static constexpr Dim digit_width = 32;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user