1 /***************************************************************************
2 effecstackview.cpp - description
5 copyright : (C) 2008 by Marco Gittler
6 email : g.marco@freenet.de
7 ***************************************************************************/
9 /***************************************************************************
11 * This program is free software; you can redistribute it and/or modify *
12 * it under the terms of the GNU General Public License as published by *
13 * the Free Software Foundation; either version 2 of the License, or *
14 * (at your option) any later version. *
16 ***************************************************************************/
18 #include "effectstackedit.h"
19 #include "ui_listval_ui.h"
20 #include "ui_boolval_ui.h"
21 #include "ui_wipeval_ui.h"
22 #include "ui_urlval_ui.h"
23 #include "complexparameter.h"
24 #include "geometryval.h"
25 #include "positionedit.h"
26 #include "projectlist.h"
27 #include "effectslist.h"
28 #include "kdenlivesettings.h"
29 #include "profilesdialog.h"
30 #include "kis_curve_widget.h"
31 #include "kis_cubic_curve.h"
32 #include "choosecolorwidget.h"
33 #include "geometrywidget.h"
34 #include "colortools.h"
35 #include "doubleparameterwidget.h"
39 #include <KFileDialog>
41 #include <QVBoxLayout>
43 #include <QPushButton>
45 #include <QScrollArea>
48 class Boolval: public QWidget, public Ui::Boolval_UI
52 class Listval: public QWidget, public Ui::Listval_UI
56 class Wipeval: public QWidget, public Ui::Wipeval_UI
60 class Urlval: public QWidget, public Ui::Urlval_UI
64 QMap<QString, QImage> EffectStackEdit::iconCache;
66 EffectStackEdit::EffectStackEdit(Monitor *monitor, QWidget *parent) :
70 m_frameSize(QPoint()),
71 m_keyframeEditor(NULL),
74 m_baseWidget = new QWidget(this);
75 setHorizontalScrollBarPolicy(Qt::ScrollBarAlwaysOff);
76 setVerticalScrollBarPolicy(Qt::ScrollBarAsNeeded);
77 setFrameStyle(QFrame::NoFrame);
78 setSizePolicy(QSizePolicy(QSizePolicy::Expanding, QSizePolicy::MinimumExpanding));
80 setWidget(m_baseWidget);
81 setWidgetResizable(true);
82 m_vbox = new QVBoxLayout(m_baseWidget);
83 m_vbox->setContentsMargins(0, 0, 0, 0);
84 m_vbox->setSpacing(0);
88 EffectStackEdit::~EffectStackEdit()
94 void EffectStackEdit::setFrameSize(QPoint p)
97 QDomNodeList namenode = m_params.elementsByTagName("parameter");
98 for (int i = 0; i < namenode.count() ; i++) {
99 QDomNode pa = namenode.item(i);
100 QDomNode na = pa.firstChildElement("name");
101 QString type = pa.attributes().namedItem("type").nodeValue();
102 QString paramName = i18n(na.toElement().text().toUtf8().data());
104 if (type == "geometry" && !KdenliveSettings::on_monitor_effects()) {
105 Geometryval *geom = ((Geometryval*)m_valueItems[paramName+"geometry"]);
106 geom->setFrameSize(m_frameSize);
112 void EffectStackEdit::updateTimecodeFormat()
114 if (m_keyframeEditor)
115 m_keyframeEditor->updateTimecodeFormat();
117 QDomNodeList namenode = m_params.elementsByTagName("parameter");
118 for (int i = 0; i < namenode.count() ; i++) {
119 QDomNode pa = namenode.item(i);
120 QDomNode na = pa.firstChildElement("name");
121 QString type = pa.attributes().namedItem("type").nodeValue();
122 QString paramName = i18n(na.toElement().text().toUtf8().data());
124 if (type == "geometry") {
125 if (KdenliveSettings::on_monitor_effects()) {
126 GeometryWidget *geom = (GeometryWidget*)m_valueItems[paramName+"geometry"];
127 geom->updateTimecodeFormat();
129 Geometryval *geom = ((Geometryval*)m_valueItems[paramName+"geometry"]);
130 geom->updateTimecodeFormat();
134 if (type == "position") {
135 PositionEdit *posi = ((PositionEdit*)m_valueItems[paramName+"position"]);
136 posi->updateTimecodeFormat();
142 void EffectStackEdit::meetDependency(const QString& name, QString type, QString value)
144 if (type == "curve") {
145 KisCurveWidget *curve = (KisCurveWidget*)m_valueItems[name];
147 int color = value.toInt();
148 curve->setPixmap(QPixmap::fromImage(ColorTools::rgbCurvePlane(curve->size(), (ColorTools::ColorsRGB)color)));
153 void EffectStackEdit::updateProjectFormat(MltVideoProfile profile, Timecode t)
159 void EffectStackEdit::updateParameter(const QString &name, const QString &value)
161 m_params.setAttribute(name, value);
164 void EffectStackEdit::transferParamDesc(const QDomElement d, int pos, int in, int out, bool isEffect)
167 if (m_keyframeEditor) delete m_keyframeEditor;
168 m_keyframeEditor = NULL;
172 if (m_params.isNull()) {
173 kDebug() << "// EMPTY EFFECT STACK";
177 QDomNodeList namenode = m_params.elementsByTagName("parameter");
178 QDomElement e = m_params.toElement();
179 const int minFrame = e.attribute("start").toInt();
180 const int maxFrame = e.attribute("end").toInt();
183 for (int i = 0; i < namenode.count() ; i++) {
184 QDomElement pa = namenode.item(i).toElement();
185 QDomNode na = pa.firstChildElement("name");
186 QString type = pa.attribute("type");
187 QString paramName = i18n(na.toElement().text().toUtf8().data());
188 QWidget * toFillin = new QWidget(m_baseWidget);
189 QString value = pa.attribute("value").isNull() ?
190 pa.attribute("default") : pa.attribute("value");
192 /** Currently supported parameter types are:
193 * constant (=double): a slider with an integer value (use the "factor" attribute to divide the value so that you can get a double
194 * list: a combobox containing a list of values to choose
196 * complex: designed for keyframe parameters, but old and not finished, do not use
197 * geometry: a rectangle that can be moved & resized, with possible keyframes, used in composite transition
198 * keyframe: a list widget with a list of entries (position and value)
199 * color: a color chooser button
200 * position: a slider representing the position of a frame in the current clip
201 * curve: a single curve representing multiple points
202 * wipe: a widget designed for the wipe transition, allowing to choose a position (left, right, top,...)
205 if (type == "double" || type == "constant") {
208 if (pa.attribute("min").startsWith('%'))
209 min = (int) ProfilesDialog::getStringEval(m_profile, pa.attribute("min"));
211 min = pa.attribute("min").toInt();
212 if (pa.attribute("max").startsWith('%'))
213 max = (int) ProfilesDialog::getStringEval(m_profile, pa.attribute("max"));
215 max = pa.attribute("max").toInt();
217 DoubleParameterWidget *doubleparam = new DoubleParameterWidget(paramName, (int)(value.toDouble() + 0.5), min, max,
218 pa.attribute("default").toInt(), pa.attribute("suffix"), this);
219 m_vbox->addWidget(doubleparam);
220 m_valueItems[paramName] = doubleparam;
221 connect(doubleparam, SIGNAL(valueChanged(int)), this, SLOT(collectAllParameters()));
222 } else if (type == "list") {
223 Listval *lsval = new Listval;
224 lsval->setupUi(toFillin);
225 QStringList listitems = pa.attribute("paramlist").split(',');
226 QStringList listitemsdisplay = pa.attribute("paramlistdisplay").split(',');
227 if (listitemsdisplay.count() != listitems.count()) listitemsdisplay = listitems;
228 //lsval->list->addItems(listitems);
229 lsval->list->setIconSize(QSize(30, 30));
230 for (int i = 0; i < listitems.count(); i++) {
231 lsval->list->addItem(listitemsdisplay.at(i), listitems.at(i));
232 QString entry = listitems.at(i);
233 if (!entry.isEmpty() && (entry.endsWith(".png") || entry.endsWith(".pgm"))) {
234 if (!EffectStackEdit::iconCache.contains(entry)) {
236 EffectStackEdit::iconCache[entry] = pix.scaled(30, 30);
238 lsval->list->setItemIcon(i, QPixmap::fromImage(iconCache[entry]));
241 if (!value.isEmpty()) lsval->list->setCurrentIndex(listitems.indexOf(value));
242 lsval->title->setTitle(paramName);
243 m_valueItems[paramName] = lsval;
244 connect(lsval->list, SIGNAL(currentIndexChanged(int)) , this, SLOT(collectAllParameters()));
245 m_uiItems.append(lsval);
246 } else if (type == "bool") {
247 Boolval *bval = new Boolval;
248 bval->setupUi(toFillin);
249 bval->checkBox->setCheckState(value == "0" ? Qt::Unchecked : Qt::Checked);
250 bval->checkBox->setText(paramName);
251 m_valueItems[paramName] = bval;
252 connect(bval->checkBox, SIGNAL(stateChanged(int)) , this, SLOT(collectAllParameters()));
253 m_uiItems.append(bval);
254 } else if (type == "complex") {
255 ComplexParameter *pl = new ComplexParameter;
256 pl->setupParam(d, pa.attribute("name"), 0, 100);
257 m_vbox->addWidget(pl);
258 m_valueItems[paramName+"complex"] = pl;
259 connect(pl, SIGNAL(parameterChanged()), this, SLOT(collectAllParameters()));
260 } else if (type == "geometry") {
261 if (KdenliveSettings::on_monitor_effects()) {
262 GeometryWidget *geometry = new GeometryWidget(m_monitor, m_timecode, pos, isEffect, this);
263 if (minFrame == maxFrame)
264 geometry->setupParam(pa, m_in, m_out);
266 geometry->setupParam(pa, minFrame, maxFrame);
267 m_vbox->addWidget(geometry);
268 m_valueItems[paramName+"geometry"] = geometry;
269 connect(geometry, SIGNAL(parameterChanged()), this, SLOT(collectAllParameters()));
270 connect(geometry, SIGNAL(checkMonitorPosition(int)), this, SIGNAL(checkMonitorPosition(int)));
271 connect(geometry, SIGNAL(seekToPos(int)), this, SIGNAL(seekTimeline(int)));
272 connect(this, SIGNAL(syncEffectsPos(int)), geometry, SLOT(slotSyncPosition(int)));
274 Geometryval *geo = new Geometryval(m_profile, m_timecode, m_frameSize, pos);
275 if (minFrame == maxFrame)
276 geo->setupParam(pa, m_in, m_out);
278 geo->setupParam(pa, minFrame, maxFrame);
279 m_vbox->addWidget(geo);
280 m_valueItems[paramName+"geometry"] = geo;
281 connect(geo, SIGNAL(parameterChanged()), this, SLOT(collectAllParameters()));
282 connect(geo, SIGNAL(seekToPos(int)), this, SIGNAL(seekTimeline(int)));
283 connect(this, SIGNAL(syncEffectsPos(int)), geo, SLOT(slotSyncPosition(int)));
285 } else if (type == "keyframe" || type == "simplekeyframe") {
286 //Â keyframe editor widget
287 kDebug() << "min: " << m_in << ", MAX: " << m_out;
288 if (m_keyframeEditor == NULL) {
289 KeyframeEdit *geo = new KeyframeEdit(pa, m_in, m_in + m_out, pa.attribute("min").toInt(), pa.attribute("max").toInt(), m_timecode, e.attribute("active_keyframe", "-1").toInt());
290 m_vbox->addWidget(geo);
291 m_valueItems[paramName+"keyframe"] = geo;
292 m_keyframeEditor = geo;
293 connect(geo, SIGNAL(parameterChanged()), this, SLOT(collectAllParameters()));
294 connect(geo, SIGNAL(seekToPos(int)), this, SIGNAL(seekTimeline(int)));
296 // we already have a keyframe editor, so just add another column for the new param
297 m_keyframeEditor->addParameter(pa);
299 } else if (type == "color") {
300 if (value.startsWith('#'))
301 value = value.replace('#', "0x");
303 ChooseColorWidget *choosecolor = new ChooseColorWidget(paramName, QColor(value.toUInt(&ok, 16)), this);
304 m_vbox->addWidget(choosecolor);
305 m_valueItems[paramName] = choosecolor;
306 connect(choosecolor, SIGNAL(displayMessage(const QString&, int)), this, SIGNAL(displayMessage(const QString&, int)));
307 connect(choosecolor, SIGNAL(modified()) , this, SLOT(collectAllParameters()));
308 } else if (type == "position") {
309 int pos = value.toInt();
310 if (d.attribute("id") == "fadein" || d.attribute("id") == "fade_from_black") {
312 } else if (d.attribute("id") == "fadeout" || d.attribute("id") == "fade_to_black") {
313 // fadeout position starts from clip end
314 pos = m_out - (pos - m_in);
316 PositionEdit *posedit = new PositionEdit(paramName, pos, 1, m_out, m_timecode);
317 m_vbox->addWidget(posedit);
318 m_valueItems[paramName+"position"] = posedit;
319 connect(posedit, SIGNAL(parameterChanged()), this, SLOT(collectAllParameters()));
320 } else if (type == "curve") {
321 KisCurveWidget *curve = new KisCurveWidget(this);
322 curve->setMaxPoints(pa.attribute("max").toInt());
323 QList<QPointF> points;
324 int number = EffectsList::parameter(e, pa.attribute("number")).toInt();
325 QString inName = pa.attribute("inpoints");
326 QString outName = pa.attribute("outpoints");
327 int start = pa.attribute("min").toInt();
328 for (int j = start; j <= number; j++) {
330 in.replace("%i", QString::number(j));
331 QString out = outName;
332 out.replace("%i", QString::number(j));
333 points << QPointF(EffectsList::parameter(e, in).toDouble(), EffectsList::parameter(e, out).toDouble());
335 if (!points.isEmpty())
336 curve->setCurve(KisCubicCurve(points));
337 QSpinBox *spinin = new QSpinBox();
338 spinin->setRange(0, 1000);
339 QSpinBox *spinout = new QSpinBox();
340 spinout->setRange(0, 1000);
341 curve->setupInOutControls(spinin, spinout, 0, 1000);
342 m_vbox->addWidget(curve);
343 m_vbox->addWidget(spinin);
344 m_vbox->addWidget(spinout);
346 connect(curve, SIGNAL(modified()), this, SLOT(collectAllParameters()));
347 m_valueItems[paramName] = curve;
349 QString depends = pa.attribute("depends");
350 if (!depends.isEmpty())
351 meetDependency(paramName, type, EffectsList::parameter(e, depends));
352 } else if (type == "wipe") {
353 Wipeval *wpval = new Wipeval;
354 wpval->setupUi(toFillin);
355 wipeInfo w = getWipeInfo(value);
358 wpval->start_up->setChecked(true);
361 wpval->start_down->setChecked(true);
364 wpval->start_right->setChecked(true);
367 wpval->start_left->setChecked(true);
370 wpval->start_center->setChecked(true);
375 wpval->end_up->setChecked(true);
378 wpval->end_down->setChecked(true);
381 wpval->end_right->setChecked(true);
384 wpval->end_left->setChecked(true);
387 wpval->end_center->setChecked(true);
390 wpval->start_transp->setValue(w.startTransparency);
391 wpval->end_transp->setValue(w.endTransparency);
392 m_valueItems[paramName] = wpval;
393 connect(wpval->end_up, SIGNAL(clicked()), this, SLOT(collectAllParameters()));
394 connect(wpval->end_down, SIGNAL(clicked()), this, SLOT(collectAllParameters()));
395 connect(wpval->end_left, SIGNAL(clicked()), this, SLOT(collectAllParameters()));
396 connect(wpval->end_right, SIGNAL(clicked()), this, SLOT(collectAllParameters()));
397 connect(wpval->end_center, SIGNAL(clicked()), this, SLOT(collectAllParameters()));
398 connect(wpval->start_up, SIGNAL(clicked()), this, SLOT(collectAllParameters()));
399 connect(wpval->start_down, SIGNAL(clicked()), this, SLOT(collectAllParameters()));
400 connect(wpval->start_left, SIGNAL(clicked()), this, SLOT(collectAllParameters()));
401 connect(wpval->start_right, SIGNAL(clicked()), this, SLOT(collectAllParameters()));
402 connect(wpval->start_center, SIGNAL(clicked()), this, SLOT(collectAllParameters()));
403 connect(wpval->start_transp, SIGNAL(valueChanged(int)), this, SLOT(collectAllParameters()));
404 connect(wpval->end_transp, SIGNAL(valueChanged(int)), this, SLOT(collectAllParameters()));
405 //wpval->title->setTitle(na.toElement().text());
406 m_uiItems.append(wpval);
407 } else if (type == "url") {
408 Urlval *cval = new Urlval;
409 cval->setupUi(toFillin);
410 cval->label->setText(paramName);
411 cval->urlwidget->fileDialog()->setFilter(ProjectList::getExtensions());
412 m_valueItems[paramName] = cval;
413 cval->urlwidget->setUrl(KUrl(value));
414 connect(cval->urlwidget, SIGNAL(returnPressed()) , this, SLOT(collectAllParameters()));
415 connect(cval->urlwidget, SIGNAL(urlSelected(const KUrl&)) , this, SLOT(collectAllParameters()));
416 m_uiItems.append(cval);
423 m_vbox->addWidget(toFillin);
425 m_vbox->addStretch();
428 wipeInfo EffectStackEdit::getWipeInfo(QString value)
431 QString start = value.section(';', 0, 0);
432 QString end = value.section(';', 1, 1).section('=', 1, 1);
434 if (start.startsWith("-100%,0"))
436 else if (start.startsWith("100%,0"))
438 else if (start.startsWith("0%,100%"))
440 else if (start.startsWith("0%,-100%"))
445 if (start.count(':') == 2)
446 info.startTransparency = start.section(':', -1).toInt();
448 info.startTransparency = 100;
450 if (end.startsWith("-100%,0"))
452 else if (end.startsWith("100%,0"))
454 else if (end.startsWith("0%,100%"))
456 else if (end.startsWith("0%,-100%"))
461 if (end.count(':') == 2)
462 info.endTransparency = end.section(':', -1).toInt();
464 info.endTransparency = 100;
469 QString EffectStackEdit::getWipeString(wipeInfo info)
474 switch (info.start) {
476 start = "-100%,0%:100%x100%";
479 start = "100%,0%:100%x100%";
482 start = "0%,100%:100%x100%";
485 start = "0%,-100%:100%x100%";
488 start = "0%,0%:100%x100%";
491 start.append(':' + QString::number(info.startTransparency));
495 end = "-100%,0%:100%x100%";
498 end = "100%,0%:100%x100%";
501 end = "0%,100%:100%x100%";
504 end = "0%,-100%:100%x100%";
507 end = "0%,0%:100%x100%";
510 end.append(':' + QString::number(info.endTransparency));
511 return QString(start + ";-1=" + end);
514 void EffectStackEdit::collectAllParameters()
516 if (m_valueItems.isEmpty() || m_params.isNull()) return;
517 const QDomElement oldparam = m_params.cloneNode().toElement();
518 QDomElement newparam = oldparam.cloneNode().toElement();
519 QDomNodeList namenode = newparam.elementsByTagName("parameter");
521 for (int i = 0; i < namenode.count() ; i++) {
522 QDomNode pa = namenode.item(i);
523 QDomNode na = pa.firstChildElement("name");
524 QString type = pa.attributes().namedItem("type").nodeValue();
525 QString paramName = i18n(na.toElement().text().toUtf8().data());
526 if (type == "complex")
527 paramName.append("complex");
528 else if (type == "position")
529 paramName.append("position");
530 else if (type == "geometry")
531 paramName.append("geometry");
532 else if (type == "keyframe")
533 paramName.append("keyframe");
534 if (type != "simplekeyframe" && !m_valueItems.contains(paramName)) {
535 kDebug() << "// Param: " << paramName << " NOT FOUND";
540 if (type == "double" || type == "constant") {
541 DoubleParameterWidget *doubleparam = (DoubleParameterWidget*)m_valueItems.value(paramName);
542 setValue = QString::number(doubleparam->getValue());
543 } else if (type == "list") {
544 KComboBox *box = ((Listval*)m_valueItems.value(paramName))->list;
545 setValue = box->itemData(box->currentIndex()).toString();
546 } else if (type == "bool") {
547 QCheckBox *box = ((Boolval*)m_valueItems.value(paramName))->checkBox;
548 setValue = box->checkState() == Qt::Checked ? "1" : "0" ;
549 } else if (type == "color") {
550 ChooseColorWidget *choosecolor = ((ChooseColorWidget*)m_valueItems.value(paramName));
551 setValue = choosecolor->getColor().name();
552 } else if (type == "complex") {
553 ComplexParameter *complex = ((ComplexParameter*)m_valueItems.value(paramName));
554 namenode.item(i) = complex->getParamDesc();
555 } else if (type == "geometry") {
556 if (KdenliveSettings::on_monitor_effects()) {
557 GeometryWidget *geometry = ((GeometryWidget*)m_valueItems.value(paramName));
558 namenode.item(i).toElement().setAttribute("value", geometry->getValue());
560 Geometryval *geom = ((Geometryval*)m_valueItems.value(paramName));
561 namenode.item(i).toElement().setAttribute("value", geom->getValue());
563 } else if (type == "position") {
564 PositionEdit *pedit = ((PositionEdit*)m_valueItems.value(paramName));
565 int pos = pedit->getPosition();
566 setValue = QString::number(pos);
567 if (newparam.attribute("id") == "fadein" || newparam.attribute("id") == "fade_from_black") {
568 // Make sure duration is not longer than clip
571 pedit->setPosition(pos);
573 EffectsList::setParameter(newparam, "in", QString::number(m_in));
574 EffectsList::setParameter(newparam, "out", QString::number(m_in + pos));
576 } else if (newparam.attribute("id") == "fadeout" || newparam.attribute("id") == "fade_to_black") {
577 // Make sure duration is not longer than clip
580 pedit->setPosition(pos);
582 EffectsList::setParameter(newparam, "in", QString::number(m_out + m_in - pos));
583 EffectsList::setParameter(newparam, "out", QString::number(m_out + m_in));
586 } else if (type == "curve") {
587 KisCurveWidget *curve = ((KisCurveWidget*)m_valueItems.value(paramName));
588 QList<QPointF> points = curve->curve().points();
589 QString number = pa.attributes().namedItem("number").nodeValue();
590 QString inName = pa.attributes().namedItem("inpoints").nodeValue();
591 QString outName = pa.attributes().namedItem("outpoints").nodeValue();
592 int off = pa.attributes().namedItem("min").nodeValue().toInt();
593 int end = pa.attributes().namedItem("max").nodeValue().toInt();
594 EffectsList::setParameter(newparam, number, QString::number(points.count()));
595 for (int j = 0; (j < points.count() && j + off <= end); j++) {
597 in.replace("%i", QString::number(j + off));
598 QString out = outName;
599 out.replace("%i", QString::number(j + off));
600 EffectsList::setParameter(newparam, in, QString::number(points.at(j).x()));
601 EffectsList::setParameter(newparam, out, QString::number(points.at(j).y()));
603 QString depends = pa.attributes().namedItem("depends").nodeValue();
604 if (!depends.isEmpty())
605 meetDependency(paramName, type, EffectsList::parameter(newparam, depends));
606 } else if (type == "wipe") {
607 Wipeval *wp = (Wipeval*)m_valueItems.value(paramName);
609 if (wp->start_left->isChecked())
611 else if (wp->start_right->isChecked())
613 else if (wp->start_up->isChecked())
615 else if (wp->start_down->isChecked())
617 else if (wp->start_center->isChecked())
621 info.startTransparency = wp->start_transp->value();
623 if (wp->end_left->isChecked())
625 else if (wp->end_right->isChecked())
627 else if (wp->end_up->isChecked())
629 else if (wp->end_down->isChecked())
631 else if (wp->end_center->isChecked())
635 info.endTransparency = wp->end_transp->value();
637 setValue = getWipeString(info);
638 } else if ((type == "simplekeyframe" || type == "keyframe") && m_keyframeEditor) {
639 QString realName = i18n(na.toElement().text().toUtf8().data());
640 QString val = m_keyframeEditor->getValue(realName);
641 kDebug() << "SET VALUE: " << val;
642 namenode.item(i).toElement().setAttribute("keyframes", val);
643 } else if (type == "url") {
644 KUrlRequester *req = ((Urlval*)m_valueItems.value(paramName))->urlwidget;
645 setValue = req->url().path();
648 if (!setValue.isNull())
649 pa.attributes().namedItem("value").setNodeValue(setValue);
652 emit parameterChanged(oldparam, newparam);
655 void EffectStackEdit::clearAllItems()
658 m_valueItems.clear();
660 /*while (!m_items.isEmpty()) {
661 QWidget *die = m_items.takeFirst();
665 //qDeleteAll(m_uiItems);
667 while ((child = m_vbox->takeAt(0)) != 0) {
668 QWidget *wid = child->widget();
672 m_keyframeEditor = NULL;
676 void EffectStackEdit::slotSyncEffectsPos(int pos)
678 emit syncEffectsPos(pos);