summaryrefslogtreecommitdiff
path: root/gtk2_ardour/editor_region_list.cc
diff options
context:
space:
mode:
Diffstat (limited to 'gtk2_ardour/editor_region_list.cc')
-rw-r--r--gtk2_ardour/editor_region_list.cc14
1 files changed, 12 insertions, 2 deletions
diff --git a/gtk2_ardour/editor_region_list.cc b/gtk2_ardour/editor_region_list.cc
index 56196623ed..df23ac503c 100644
--- a/gtk2_ardour/editor_region_list.cc
+++ b/gtk2_ardour/editor_region_list.cc
@@ -21,6 +21,7 @@
#include <cmath>
#include <algorithm>
#include <string>
+#include <sstream>
#include <pbd/basename.h>
@@ -138,12 +139,13 @@ Editor::add_audio_region_to_region_display (boost::shared_ptr<AudioRegion> regio
if (region->source()->name()[0] == '/') { // external file
if (region->whole_file()) {
- str = ".../";
boost::shared_ptr<AudioFileSource> afs = boost::dynamic_pointer_cast<AudioFileSource>(region->source());
+ str = ".../";
+
if (afs) {
- str += region_name_from_path (afs->path(), region->n_channels() > 1);
+ str = region_name_from_path (afs->path(), region->n_channels() > 1);
} else {
str += region->source()->name();
}
@@ -158,6 +160,14 @@ Editor::add_audio_region_to_region_display (boost::shared_ptr<AudioRegion> regio
}
+ if (region->n_channels() > 1) {
+ std::stringstream foo;
+ foo << region->n_channels ();
+ str += " [";
+ str += foo.str();
+ str += ']';
+ }
+
if (missing_source) {
str += _(" (MISSING)");
}