-AddTransitionCommand::AddTransitionCommand(CustomTrackView *view, int track, QDomElement xml, GenTime pos, bool doIt) : m_view(view), m_track(track), m_xml(xml), m_pos(pos), m_doIt(doIt) {
- if (m_doIt) setText(i18n("Add transition to clip"));
- else setText(i18n("Delete transition from clip"));
+#include <KLocale>
+
+AddTransitionCommand::AddTransitionCommand(CustomTrackView *view, ItemInfo info, int transitiontrack, QDomElement params, bool remove, bool doIt, QUndoCommand * parent) :
+ QUndoCommand(parent),
+ m_view(view),
+ m_info(info),
+ m_params(params),
+ m_track(transitiontrack),
+ m_doIt(doIt),
+ m_remove(remove)
+{
+ if (m_remove) setText(i18n("Delete transition from clip"));
+ else setText(i18n("Add transition to clip"));
+ if (parent) {
+ // command has a parent, so there are several operations ongoing, do not refresh monitor
+ m_refresh = false;
+ } else m_refresh = true;