mirror of
https://github.com/portapack-mayhem/mayhem-firmware.git
synced 2024-12-13 11:44:31 +00:00
Move UIRecordView::set_sampling_rate to .cpp.
This commit is contained in:
parent
59aa99c8ff
commit
19e5e111a9
@ -195,6 +195,19 @@ void RecordView::focus() {
|
||||
button_record.focus();
|
||||
}
|
||||
|
||||
void RecordView::set_sampling_rate(const size_t new_sampling_rate) {
|
||||
if( new_sampling_rate != sampling_rate ) {
|
||||
stop();
|
||||
sampling_rate = new_sampling_rate;
|
||||
|
||||
button_record.hidden(sampling_rate == 0);
|
||||
text_record_filename.hidden(sampling_rate == 0);
|
||||
text_record_dropped.hidden(sampling_rate == 0);
|
||||
text_time_available.hidden(sampling_rate == 0);
|
||||
rect_background.hidden(sampling_rate != 0);
|
||||
}
|
||||
}
|
||||
|
||||
bool RecordView::is_active() const {
|
||||
return (bool)capture_thread;
|
||||
}
|
||||
|
@ -55,18 +55,7 @@ public:
|
||||
|
||||
void focus() override;
|
||||
|
||||
void set_sampling_rate(const size_t new_sampling_rate) {
|
||||
if( new_sampling_rate != sampling_rate ) {
|
||||
stop();
|
||||
sampling_rate = new_sampling_rate;
|
||||
|
||||
button_record.hidden(sampling_rate == 0);
|
||||
text_record_filename.hidden(sampling_rate == 0);
|
||||
text_record_dropped.hidden(sampling_rate == 0);
|
||||
text_time_available.hidden(sampling_rate == 0);
|
||||
rect_background.hidden(sampling_rate != 0);
|
||||
}
|
||||
}
|
||||
void set_sampling_rate(const size_t new_sampling_rate);
|
||||
|
||||
void start();
|
||||
void stop();
|
||||
|
Loading…
Reference in New Issue
Block a user