1 /***************************************************************************
2 movetransitioncommand.h - 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 "movetransitioncommand.h"
19 #include "customtrackview.h"
21 #include <KLocalizedString>
23 MoveTransitionCommand::MoveTransitionCommand(CustomTrackView *view, const ItemInfo &start, const ItemInfo &end, bool doIt, QUndoCommand * parent) :
30 setText(i18n("Move transition"));
32 // command has a parent, so there are several operations ongoing, do not refresh monitor
34 } else m_refresh = true;
39 void MoveTransitionCommand::undo()
41 // kDebug()<<"---- undoing action";
43 m_view->moveTransition(m_endPos, m_startPos, m_refresh);
46 void MoveTransitionCommand::redo()
48 //kDebug() << "---- redoing action";
50 m_view->moveTransition(m_startPos, m_endPos, m_refresh);