#include "localsession.h"
#include "plugin.h"
#include "mainsession.h"
-#include "nestededls.h"
+#include "strack.h"
#include "trackcanvas.h"
#include "tracks.h"
#include "transition.h"
int Edit::silence()
{
- return asset || nested_edl ? 0 : 1;
+ return (track->data_type != TRACK_SUBTITLE ?
+ asset || nested_edl :
+ *((SEdit *)this)->get_text()) ? 0 : 1;
}
void Edit::copy_from(Edit *edit)
{
- this->nested_edl = edl->nested_edls->get_copy(edit->nested_edl);
+ this->nested_edl = edl->nested_edls.get_nested(edit->nested_edl);
this->asset = edl->assets->update(edit->asset);
this->startsource = edit->startsource;
this->startproject = edit->startproject;
return 0;
}
+void Edit::get_title(char *title)
+{
+ if( user_title[0] ) {
+ strcpy(title, user_title);
+ return;
+ }
+ Indexable *idxbl = asset ? (Indexable*)asset : (Indexable*)nested_edl;
+ if( !idxbl ) {
+ title[0] = 0;
+ return;
+ }
+ FileSystem fs;
+ fs.extract_name(title, idxbl->path);
+ if( asset || track->data_type == TRACK_AUDIO ) {
+ char number[BCSTRLEN];
+ sprintf(number, " #%d", channel + 1);
+ strcat(title, number);
+ }
+}
+