- global_disk_space_estimator = new DiskSpaceEstimator(bind(&MainWindow::report_disk_space, this, _1, _2));
+ global_disk_space_estimator = new DiskSpaceEstimator(bind(&MainWindow::report_disk_space, this, _1, _2, _3));
disk_free_label = new QLabel(this);
disk_free_label->setStyleSheet("QLabel {padding-right: 5px;}");
ui->menuBar->setCornerWidget(disk_free_label);
disk_free_label = new QLabel(this);
disk_free_label->setStyleSheet("QLabel {padding-right: 5px;}");
ui->menuBar->setCornerWidget(disk_free_label);
connect(ui->me_live, &GLWidget::transition_names_updated, this, &MainWindow::set_transition_names);
qRegisterMetaType<Mixer::Output>("Mixer::Output");
connect(ui->me_live, &GLWidget::transition_names_updated, this, &MainWindow::set_transition_names);
qRegisterMetaType<Mixer::Output>("Mixer::Output");
+ connect(ui->me_live, &GLWidget::name_updated, this, &MainWindow::update_channel_name);
+ connect(ui->me_preview, &GLWidget::name_updated, this, &MainWindow::update_channel_name);
+
// Hook up the prev/next buttons on the audio views.
connect(ui->compact_prev_page, &QAbstractButton::clicked, this, &MainWindow::prev_page);
connect(ui->compact_next_page, &QAbstractButton::clicked, this, &MainWindow::next_page);
// Hook up the prev/next buttons on the audio views.
connect(ui->compact_prev_page, &QAbstractButton::clicked, this, &MainWindow::prev_page);
connect(ui->compact_next_page, &QAbstractButton::clicked, this, &MainWindow::next_page);
char buf[256];
snprintf(buf, sizeof(buf), "Disk free: %'.0f MB (approx. %s)", free_bytes / 1048576.0, time_str);
char buf[256];
snprintf(buf, sizeof(buf), "Disk free: %'.0f MB (approx. %s)", free_bytes / 1048576.0, time_str);
- std::string label = buf;
+ // NOTE: The default formatter does not use file_length_seconds for anything,
+ // but the theme might want to do so.
+ std::string label = global_mixer->format_status_line(buf, file_length_seconds);
post_to_main_thread([this, label]{
disk_free_label->setText(QString::fromStdString(label));
post_to_main_thread([this, label]{
disk_free_label->setText(QString::fromStdString(label));
- if (output >= Mixer::OUTPUT_INPUT0) {
+ if (output == Mixer::OUTPUT_LIVE) {
+ ui->label_live->setText(name.c_str());
+ } else if (output == Mixer::OUTPUT_PREVIEW) {
+ ui->label_preview->setText(name.c_str());
+ } else if (output >= Mixer::OUTPUT_INPUT0) {