13
0

Merge branch 'ardour'

This commit is contained in:
Robin Gareus 2024-05-13 21:55:50 +02:00
commit df65989cae
Signed by: rgareus
GPG Key ID: A090BCE02CF57F04
4 changed files with 16 additions and 5 deletions

View File

@ -778,7 +778,11 @@ INPUT = ../libs/ardour \
../libs/widgets \
../libs/zita-convolver \
../libs/zita-resampler \
../libs/zita-resampler \
../gtk2_ardour \
../libs/tk/ytkmm/ytkmm/gtkmm \
../libs/tk/ydkmm/ydkmm/gdkmm \
../libs/tk/ydk/ydk/gdk \
mainpage.txt
## audiographer assumes it's documented separately (has it's own @mainpage)

View File

@ -1499,6 +1499,10 @@ ARDOUR_UI::format_disk_space_label (float remain_sec)
std::string label = string_compose (X_("<span weight=\"ultralight\">%1</span>: "), _("Rec"));
if (_session && FLAC == _session->config.get_native_file_header_format () && remain_sec <= 86400) {
label += u8"\u2265"; // Greater-Than or Equal To
}
if (remain_sec > 86400) {
disk_space_label.set_markup (label + _(">24h"));
} else if (remain_sec > 32400 /* 9 hours */) {

View File

@ -340,20 +340,23 @@ RemainInfoBox::render (Cairo::RefPtr<Cairo::Context> const& cr, cairo_rectangle_
float remain_sec = samples / (float)sample_rate;
char buf[32];
bool at_least = FLAC == _session->config.get_native_file_header_format ();
const char* prefix = at_least ? u8"\u2265" : ""; // Greater-Than or Equal To
if (remain_sec > 86400) {
_layout_value->set_text (_(">24h"));
} else if (remain_sec > 32400 /* 9 hours */) {
snprintf (buf, sizeof (buf), "%.0f", remain_sec / 3600.f);
snprintf (buf, sizeof (buf), "%s%.0f", prefix, remain_sec / 3600.f);
_layout_value->set_text (std::string (buf) + S_("hours|h"));
} else if (remain_sec > 5940 /* 99 mins */) {
snprintf (buf, sizeof (buf), "%.1f", remain_sec / 3600.f);
snprintf (buf, sizeof (buf), "%s%.1f", prefix, remain_sec / 3600.f);
_layout_value->set_text (std::string (buf) + S_("hours|h"));
} else if (remain_sec > 60*3 /* 3 mins */) {
snprintf (buf, sizeof (buf), "%.0f", remain_sec / 60.f);
snprintf (buf, sizeof (buf), "%s%.0f", prefix, remain_sec / 60.f);
_layout_value->set_text (std::string (buf) + S_("minutes|m"));
} else {
Gtkmm2ext::set_source_rgb_a (cr, UIConfiguration::instance ().color ("alert:red"), .7);
snprintf (buf, sizeof (buf), "%.0f", remain_sec / 60.f);
snprintf (buf, sizeof (buf), "%s%.0f", prefix, remain_sec / 60.f);
_layout_value->set_text (std::string (buf) + S_("minutes|m"));
}
}

View File

@ -2142,7 +2142,7 @@ private:
std::vector<space_and_path> session_dirs;
std::vector<space_and_path>::iterator last_rr_session_dir;
uint32_t _total_free_4k_blocks;
uint64_t _total_free_4k_blocks;
/** If this is true, _total_free_4k_blocks is not definite,
as one or more of the session directories' filesystems
could not report free space.