From b8196ee2be190a5c4a4b0710f9b9728c912fe767 Mon Sep 17 00:00:00 2001 From: Jared Boone Date: Fri, 22 Apr 2016 12:08:01 -0700 Subject: [PATCH] Rename capture UI record objects and functions. --- firmware/application/capture_app.cpp | 14 +++++++------- firmware/application/capture_app.hpp | 4 ++-- 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/firmware/application/capture_app.cpp b/firmware/application/capture_app.cpp index d8aae140..3bb10676 100644 --- a/firmware/application/capture_app.cpp +++ b/firmware/application/capture_app.cpp @@ -32,7 +32,7 @@ namespace ui { CaptureAppView::CaptureAppView(NavigationView& nav) { add_children({ { - &button_start_stop, + &button_record, &rssi, &channel, &field_frequency, @@ -66,8 +66,8 @@ CaptureAppView::CaptureAppView(NavigationView& nav) { this->on_vga_changed(v_db); }; - button_start_stop.on_select = [this](ImageButton&) { - this->on_start_stop(); + button_record.on_select = [this](ImageButton&) { + this->on_record(); }; receiver_model.set_baseband_configuration({ @@ -98,13 +98,13 @@ void CaptureAppView::set_parent_rect(const Rect new_parent_rect) { } void CaptureAppView::focus() { - button_start_stop.focus(); + button_record.focus(); } -void CaptureAppView::on_start_stop() { +void CaptureAppView::on_record() { if( capture_thread ) { capture_thread.reset(); - button_start_stop.set_bitmap(&bitmap_record); + button_record.set_bitmap(&bitmap_record); } else { const auto filename = next_filename_matching_pattern("BBD_????.C16"); text_record_filename.set(filename); @@ -113,7 +113,7 @@ void CaptureAppView::on_start_stop() { } capture_thread = std::make_unique(filename); - button_start_stop.set_bitmap(&bitmap_stop); + button_record.set_bitmap(&bitmap_stop); } } diff --git a/firmware/application/capture_app.hpp b/firmware/application/capture_app.hpp index 91bf8ba8..6eda1a72 100644 --- a/firmware/application/capture_app.hpp +++ b/firmware/application/capture_app.hpp @@ -57,13 +57,13 @@ private: std::unique_ptr capture_thread; - void on_start_stop(); + void on_record(); void on_tuning_frequency_changed(rf::Frequency f); void on_lna_changed(int32_t v_db); void on_vga_changed(int32_t v_db); - ImageButton button_start_stop { + ImageButton button_record { { 0 * 8, 2 * 16, 2 * 8, 1 * 16 }, &bitmap_record, Color::red(),