X-Git-Url: http://git.cinelerra-gg.org/git/?a=blobdiff_plain;f=cinelerra-5.1%2Fcinelerra%2Fedit.C;h=20e8b93bff063052288fde2966e89733f5e97347;hb=0c086b3e7b552e0f6b06c8696d7682d9d4bd91db;hp=e40b8c18924c5f1d712d620582b8c08240c062fe;hpb=e23393f4ff9f772ac8f47926cf490dc87a630ed4;p=goodguy%2Fcinelerra.git diff --git a/cinelerra-5.1/cinelerra/edit.C b/cinelerra-5.1/cinelerra/edit.C index e40b8c18..20e8b93b 100644 --- a/cinelerra-5.1/cinelerra/edit.C +++ b/cinelerra-5.1/cinelerra/edit.C @@ -242,14 +242,13 @@ int Edit::silence() asset || nested_edl : *((SEdit *)this)->get_text()) ? 0 : 1; } -void Edit::mute() + +void Edit::set_selected(int v) { - if( track->data_type != TRACK_SUBTITLE ) { - asset = 0; - nested_edl = 0; - } + if( group_id ) + edl->tracks->set_group_selected(group_id, v); else - *((SEdit *)this)->get_text() = 0; + is_selected = v >= 0 ? v : !is_selected ? 1 : 0; } void Edit::copy_from(Edit *edit) @@ -389,7 +388,8 @@ int Edit::dump(FILE *fp) asset, asset ? asset->path : ""); fflush(fp); - fprintf(fp," channel %d, color %08x, group_id %d\n", channel, color, group_id); + fprintf(fp," channel %d, color %08x, group_id %d, is_selected %d\n", + channel, color, group_id, is_selected); if(transition) { fprintf(fp," TRANSITION %p\n", transition); @@ -406,7 +406,7 @@ int Edit::load_properties(FileXML *file, int64_t &startproject) length = file->tag.get_property("LENGTH", (int64_t)0); hard_left = file->tag.get_property("HARD_LEFT", (int64_t)0); hard_right = file->tag.get_property("HARD_RIGHT", (int64_t)0); - color = file->tag.get_property("COLOR", (int64_t)-1); + color = file->tag.get_property("COLOR", 0); group_id = file->tag.get_property("GROUP_ID", group_id); user_title[0] = 0; file->tag.get_property("USER_TITLE", user_title);