mirror of
https://github.com/ElvishArtisan/rivendell.git
synced 2026-01-12 07:35:55 +01:00
2016-07-20 Fred Gleason <fredg@paravelsystems.com>
* Added a 'settrans' command to rdclilogedit(1) in 'utils/rdclilogedit/rdclilogedit.cpp' and 'utils/rdclilogedit/rdclilogedit.h'.
This commit is contained in:
@@ -15326,3 +15326,7 @@
|
|||||||
* Added a 'remove' command to rdclilogedit(1) in
|
* Added a 'remove' command to rdclilogedit(1) in
|
||||||
'utils/rdclilogedit/rdclilogedit.cpp' and
|
'utils/rdclilogedit/rdclilogedit.cpp' and
|
||||||
'utils/rdclilogedit/rdclilogedit.h'.
|
'utils/rdclilogedit/rdclilogedit.h'.
|
||||||
|
2016-07-20 Fred Gleason <fredg@paravelsystems.com>
|
||||||
|
* Added a 'settrans' command to rdclilogedit(1) in
|
||||||
|
'utils/rdclilogedit/rdclilogedit.cpp' and
|
||||||
|
'utils/rdclilogedit/rdclilogedit.h'.
|
||||||
|
|||||||
@@ -108,6 +108,14 @@ void MainObject::Help(const QStringList &cmds) const
|
|||||||
printf("\n");
|
printf("\n");
|
||||||
processed=true;
|
processed=true;
|
||||||
}
|
}
|
||||||
|
if(verb=="settrans") {
|
||||||
|
printf("\n");
|
||||||
|
printf(" settrans <line> play|segue|stop\n");
|
||||||
|
printf("\n");
|
||||||
|
printf("Set the transition type of the event at line <line>.\n");
|
||||||
|
printf("\n");
|
||||||
|
processed=true;
|
||||||
|
}
|
||||||
if(verb=="unload") {
|
if(verb=="unload") {
|
||||||
printf("\n");
|
printf("\n");
|
||||||
printf(" unload\n");
|
printf(" unload\n");
|
||||||
|
|||||||
@@ -305,6 +305,13 @@ void MainObject::Setcart(int line,unsigned cartnum)
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void MainObject::Settrans(int line,RDLogLine::TransType type)
|
||||||
|
{
|
||||||
|
edit_log_event->logLine(line)->setTransType(type);
|
||||||
|
edit_log_event->refresh(line);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
void MainObject::Unload()
|
void MainObject::Unload()
|
||||||
{
|
{
|
||||||
if(edit_log!=NULL) {
|
if(edit_log!=NULL) {
|
||||||
@@ -433,6 +440,37 @@ void MainObject::DispatchCommand(const QString &cmd)
|
|||||||
processed=true;
|
processed=true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if(verb=="settrans") {
|
||||||
|
if(cmds.size()==3) {
|
||||||
|
line=cmds[1].toInt(&ok);
|
||||||
|
if(ok&&(line>=0)&&(line<edit_log_event->size())) {
|
||||||
|
RDLogLine::TransType trans=RDLogLine::NoTrans;
|
||||||
|
if(cmds[2].lower()=="play") {
|
||||||
|
trans=RDLogLine::Play;
|
||||||
|
}
|
||||||
|
if(cmds[2].lower()=="segue") {
|
||||||
|
trans=RDLogLine::Segue;
|
||||||
|
}
|
||||||
|
if(cmds[2].lower()=="stop") {
|
||||||
|
trans=RDLogLine::Stop;
|
||||||
|
}
|
||||||
|
if(trans!=RDLogLine::NoTrans) {
|
||||||
|
Settrans(line,trans);
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
fprintf(stderr,"settrans: invalid transition type\n");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
fprintf(stderr,"settrans: invalid line number\n");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
fprintf(stderr,"settrans: invalid command arguments\n");
|
||||||
|
}
|
||||||
|
processed=true;
|
||||||
|
}
|
||||||
|
|
||||||
if(verb=="unload") {
|
if(verb=="unload") {
|
||||||
Unload();
|
Unload();
|
||||||
processed=true;
|
processed=true;
|
||||||
|
|||||||
@@ -55,6 +55,7 @@ class MainObject : public QObject
|
|||||||
void Save();
|
void Save();
|
||||||
void Saveas(const QString &logname);
|
void Saveas(const QString &logname);
|
||||||
void Setcart(int line,unsigned cartnum);
|
void Setcart(int line,unsigned cartnum);
|
||||||
|
void Settrans(int line,RDLogLine::TransType type);
|
||||||
void Unload();
|
void Unload();
|
||||||
void DispatchCommand(const QString &cmd);
|
void DispatchCommand(const QString &cmd);
|
||||||
QString ListLine(RDLogEvent *evt,int line) const;
|
QString ListLine(RDLogEvent *evt,int line) const;
|
||||||
|
|||||||
Reference in New Issue
Block a user