Commit 219da3e0 authored by Hugo Beauzée-Luyssen's avatar Hugo Beauzée-Luyssen

Relocating TrackType to Types.h, in the Workflow namespace.

parent ac5e3396
...@@ -45,7 +45,7 @@ void Commands::trigger( Commands::Generic* command ) ...@@ -45,7 +45,7 @@ void Commands::trigger( Commands::Generic* command )
Commands::MainWorkflow::AddClip::AddClip( ClipHelper* ch, Commands::MainWorkflow::AddClip::AddClip( ClipHelper* ch,
unsigned int trackNumber, qint64 pos, unsigned int trackNumber, qint64 pos,
::MainWorkflow::TrackType trackType, Workflow::TrackType trackType,
bool undoRedoAction /*= false*/ ) : bool undoRedoAction /*= false*/ ) :
m_trackNumber( trackNumber ), m_trackNumber( trackNumber ),
m_pos( pos ), m_pos( pos ),
...@@ -73,7 +73,7 @@ void Commands::MainWorkflow::AddClip::undo() ...@@ -73,7 +73,7 @@ void Commands::MainWorkflow::AddClip::undo()
Commands::MainWorkflow::MoveClip::MoveClip( ::MainWorkflow* workflow, const QUuid& uuid, Commands::MainWorkflow::MoveClip::MoveClip( ::MainWorkflow* workflow, const QUuid& uuid,
unsigned int oldTrack, unsigned int newTrack, qint64 newPos, unsigned int oldTrack, unsigned int newTrack, qint64 newPos,
::MainWorkflow::TrackType trackType ) : Workflow::TrackType trackType ) :
m_workflow( workflow ), m_uuid( uuid ), m_oldTrack( oldTrack ), m_workflow( workflow ), m_uuid( uuid ), m_oldTrack( oldTrack ),
m_newTrack( newTrack ), m_pos( newPos ), m_trackType( trackType ) m_newTrack( newTrack ), m_pos( newPos ), m_trackType( trackType )
{ {
...@@ -101,7 +101,7 @@ void Commands::MainWorkflow::MoveClip::undo() ...@@ -101,7 +101,7 @@ void Commands::MainWorkflow::MoveClip::undo()
} }
Commands::MainWorkflow::RemoveClip::RemoveClip( ClipHelper* ch, quint32 trackNumber, Commands::MainWorkflow::RemoveClip::RemoveClip( ClipHelper* ch, quint32 trackNumber,
qint64 pos, ::MainWorkflow::TrackType trackType ) : qint64 pos, Workflow::TrackType trackType ) :
m_clipHelper( ch ), m_trackNumber( trackNumber ), m_clipHelper( ch ), m_trackNumber( trackNumber ),
m_pos( pos ), m_trackType( trackType ) m_pos( pos ), m_trackType( trackType )
{ {
...@@ -122,7 +122,7 @@ Commands::MainWorkflow::ResizeClip::ResizeClip( ClipHelper* clipHelper, ...@@ -122,7 +122,7 @@ Commands::MainWorkflow::ResizeClip::ResizeClip( ClipHelper* clipHelper,
qint64 oldBegin, qint64 oldEnd, qint64 oldBegin, qint64 oldEnd,
qint64 newPos, qint64 oldPos, qint64 newPos, qint64 oldPos,
quint32 trackId, quint32 trackId,
::MainWorkflow::TrackType trackType ) : Workflow::TrackType trackType ) :
m_newBegin( newBegin ), m_newBegin( newBegin ),
m_newEnd( newEnd ), m_newEnd( newEnd ),
m_oldBegin( oldBegin ), m_oldBegin( oldBegin ),
...@@ -160,7 +160,7 @@ void Commands::MainWorkflow::ResizeClip::undo() ...@@ -160,7 +160,7 @@ void Commands::MainWorkflow::ResizeClip::undo()
} }
Commands::MainWorkflow::SplitClip::SplitClip( ClipHelper* toSplit, quint32 trackId, Commands::MainWorkflow::SplitClip::SplitClip( ClipHelper* toSplit, quint32 trackId,
qint64 newClipPos, qint64 newClipBegin, ::MainWorkflow::TrackType trackType ) : qint64 newClipPos, qint64 newClipBegin, Workflow::TrackType trackType ) :
m_toSplit( toSplit ), m_toSplit( toSplit ),
m_newClip( NULL ), m_newClip( NULL ),
m_trackId( trackId ), m_trackId( trackId ),
......
...@@ -31,6 +31,7 @@ ...@@ -31,6 +31,7 @@
#include <QObject> #include <QObject>
#include <QVector> #include <QVector>
#include "MainWorkflow.h" #include "MainWorkflow.h"
#include "Types.h"
class Clip; class Clip;
class ClipHelper; class ClipHelper;
...@@ -63,14 +64,14 @@ namespace Commands ...@@ -63,14 +64,14 @@ namespace Commands
{ {
public: public:
AddClip( ClipHelper* ch, unsigned int trackNumber, qint64 pos, AddClip( ClipHelper* ch, unsigned int trackNumber, qint64 pos,
::MainWorkflow::TrackType trackType, bool undoRedoAction = false ); Workflow::TrackType trackType, bool undoRedoAction = false );
virtual ~AddClip(); virtual ~AddClip();
virtual void redo(); virtual void redo();
virtual void undo(); virtual void undo();
private: private:
unsigned int m_trackNumber; unsigned int m_trackNumber;
qint64 m_pos; qint64 m_pos;
::MainWorkflow::TrackType m_trackType; Workflow::TrackType m_trackType;
ClipHelper *m_clipHelper; ClipHelper *m_clipHelper;
bool m_undoRedoAction; bool m_undoRedoAction;
}; };
...@@ -80,7 +81,7 @@ namespace Commands ...@@ -80,7 +81,7 @@ namespace Commands
public: public:
MoveClip( ::MainWorkflow* workflow, const QUuid& uuid, MoveClip( ::MainWorkflow* workflow, const QUuid& uuid,
unsigned int oldTrack, unsigned int newTrack, unsigned int oldTrack, unsigned int newTrack,
qint64 newPos, ::MainWorkflow::TrackType trackType ); qint64 newPos, Workflow::TrackType trackType );
virtual void redo(); virtual void redo();
virtual void undo(); virtual void undo();
...@@ -92,14 +93,14 @@ namespace Commands ...@@ -92,14 +93,14 @@ namespace Commands
qint64 m_pos; qint64 m_pos;
qint64 m_oldPos; qint64 m_oldPos;
bool m_undoRedoAction; bool m_undoRedoAction;
::MainWorkflow::TrackType m_trackType; Workflow::TrackType m_trackType;
}; };
NEW_COMMAND( RemoveClip ) NEW_COMMAND( RemoveClip )
{ {
public: public:
RemoveClip( ClipHelper* clip, unsigned int trackNumber, RemoveClip( ClipHelper* clip, unsigned int trackNumber,
qint64 pos, ::MainWorkflow::TrackType trackType ); qint64 pos, Workflow::TrackType trackType );
virtual void redo(); virtual void redo();
virtual void undo(); virtual void undo();
...@@ -107,7 +108,7 @@ namespace Commands ...@@ -107,7 +108,7 @@ namespace Commands
ClipHelper* m_clipHelper; ClipHelper* m_clipHelper;
unsigned int m_trackNumber; unsigned int m_trackNumber;
qint64 m_pos; qint64 m_pos;
::MainWorkflow::TrackType m_trackType; Workflow::TrackType m_trackType;
}; };
/** /**
...@@ -127,7 +128,7 @@ namespace Commands ...@@ -127,7 +128,7 @@ namespace Commands
ResizeClip( ClipHelper* clipHelper, ResizeClip( ClipHelper* clipHelper,
qint64 newBegin, qint64 newEnd, qint64 oldBegin, qint64 newBegin, qint64 newEnd, qint64 oldBegin,
qint64 oldEnd, qint64 newPos, qint64 oldPos, qint64 oldEnd, qint64 newPos, qint64 oldPos,
quint32 trackId, ::MainWorkflow::TrackType trackType ); quint32 trackId, Workflow::TrackType trackType );
virtual void redo(); virtual void redo();
virtual void undo(); virtual void undo();
private: private:
...@@ -139,7 +140,7 @@ namespace Commands ...@@ -139,7 +140,7 @@ namespace Commands
qint64 m_oldPos; qint64 m_oldPos;
quint32 m_trackId; quint32 m_trackId;
ClipHelper* m_clipHelper; ClipHelper* m_clipHelper;
::MainWorkflow::TrackType m_trackType; Workflow::TrackType m_trackType;
bool m_undoRedoAction; bool m_undoRedoAction;
}; };
...@@ -147,7 +148,7 @@ namespace Commands ...@@ -147,7 +148,7 @@ namespace Commands
{ {
public: public:
SplitClip( ClipHelper* toSplit, quint32 trackId, qint64 newClipPos, SplitClip( ClipHelper* toSplit, quint32 trackId, qint64 newClipPos,
qint64 newClipBegin, ::MainWorkflow::TrackType trackType ); qint64 newClipBegin, Workflow::TrackType trackType );
~SplitClip(); ~SplitClip();
virtual void redo(); virtual void redo();
virtual void undo(); virtual void undo();
...@@ -157,7 +158,7 @@ namespace Commands ...@@ -157,7 +158,7 @@ namespace Commands
quint32 m_trackId; quint32 m_trackId;
qint64 m_newClipPos; qint64 m_newClipPos;
qint64 m_newClipBegin; qint64 m_newClipBegin;
::MainWorkflow::TrackType m_trackType; Workflow::TrackType m_trackType;
}; };
} }
} }
......
...@@ -72,7 +72,7 @@ MainWindow::MainWindow( QWidget *parent ) : ...@@ -72,7 +72,7 @@ MainWindow::MainWindow( QWidget *parent ) :
{ {
m_ui.setupUi( this ); m_ui.setupUi( this );
qRegisterMetaType<MainWorkflow::TrackType>( "MainWorkflow::TrackType" ); qRegisterMetaType<Workflow::TrackType>( "Workflow::TrackType" );
qRegisterMetaType<MainWorkflow::FrameChangedReason>( "MainWorkflow::FrameChangedReason" ); qRegisterMetaType<MainWorkflow::FrameChangedReason>( "MainWorkflow::FrameChangedReason" );
qRegisterMetaType<QVariant>( "QVariant" ); qRegisterMetaType<QVariant>( "QVariant" );
......
...@@ -76,7 +76,7 @@ public: ...@@ -76,7 +76,7 @@ public:
TracksScene* scene(); TracksScene* scene();
/// Return the type of the media /// Return the type of the media
virtual MainWorkflow::TrackType mediaType() const = 0; virtual Workflow::TrackType mediaType() const = 0;
/// Group two items together /// Group two items together
void group( AbstractGraphicsMediaItem* item ); void group( AbstractGraphicsMediaItem* item );
......
...@@ -66,9 +66,9 @@ GraphicsAudioItem::~GraphicsAudioItem() ...@@ -66,9 +66,9 @@ GraphicsAudioItem::~GraphicsAudioItem()
{ {
} }
MainWorkflow::TrackType GraphicsAudioItem::mediaType() const Workflow::TrackType GraphicsAudioItem::mediaType() const
{ {
return MainWorkflow::AudioTrack; return Workflow::AudioTrack;
} }
void GraphicsAudioItem::paint( QPainter* painter, const QStyleOptionGraphicsItem* option, QWidget* ) void GraphicsAudioItem::paint( QPainter* painter, const QStyleOptionGraphicsItem* option, QWidget* )
......
...@@ -51,7 +51,7 @@ public: ...@@ -51,7 +51,7 @@ public:
virtual int type() const { return Type; } virtual int type() const { return Type; }
virtual bool expandable() const { return false; } virtual bool expandable() const { return false; }
virtual bool moveable() const { return true; } virtual bool moveable() const { return true; }
virtual MainWorkflow::TrackType mediaType() const; virtual Workflow::TrackType mediaType() const;
virtual void paint( QPainter* painter, const QStyleOptionGraphicsItem* option, QWidget* widget = 0 ); virtual void paint( QPainter* painter, const QStyleOptionGraphicsItem* option, QWidget* widget = 0 );
protected: protected:
......
...@@ -66,9 +66,9 @@ GraphicsMovieItem::~GraphicsMovieItem() ...@@ -66,9 +66,9 @@ GraphicsMovieItem::~GraphicsMovieItem()
{ {
} }
MainWorkflow::TrackType GraphicsMovieItem::mediaType() const Workflow::TrackType GraphicsMovieItem::mediaType() const
{ {
return MainWorkflow::VideoTrack; return Workflow::VideoTrack;
} }
void GraphicsMovieItem::paint( QPainter* painter, const QStyleOptionGraphicsItem* option, QWidget* ) void GraphicsMovieItem::paint( QPainter* painter, const QStyleOptionGraphicsItem* option, QWidget* )
......
...@@ -52,7 +52,7 @@ public: ...@@ -52,7 +52,7 @@ public:
virtual int type() const { return Type; } virtual int type() const { return Type; }
virtual bool expandable() const { return false; } virtual bool expandable() const { return false; }
virtual bool moveable() const { return true; } virtual bool moveable() const { return true; }
virtual MainWorkflow::TrackType mediaType() const; virtual Workflow::TrackType mediaType() const;
virtual void paint( QPainter* painter, const QStyleOptionGraphicsItem* option, QWidget* widget = 0 ); virtual void paint( QPainter* painter, const QStyleOptionGraphicsItem* option, QWidget* widget = 0 );
protected: protected:
......
...@@ -24,7 +24,7 @@ ...@@ -24,7 +24,7 @@
#include "TracksView.h" #include "TracksView.h"
#include "GraphicsTrack.h" #include "GraphicsTrack.h"
GraphicsTrack::GraphicsTrack( MainWorkflow::TrackType type, quint32 trackNumber, GraphicsTrack::GraphicsTrack( Workflow::TrackType type, quint32 trackNumber,
QGraphicsItem *parent ) : QGraphicsWidget( parent ) QGraphicsItem *parent ) : QGraphicsWidget( parent )
{ {
m_type = type; m_type = type;
...@@ -75,7 +75,7 @@ GraphicsTrack::trackNumber() ...@@ -75,7 +75,7 @@ GraphicsTrack::trackNumber()
return m_trackNumber; return m_trackNumber;
} }
MainWorkflow::TrackType Workflow::TrackType
GraphicsTrack::mediaType() GraphicsTrack::mediaType()
{ {
return m_type; return m_type;
......
...@@ -36,7 +36,7 @@ class GraphicsTrack : public QGraphicsWidget ...@@ -36,7 +36,7 @@ class GraphicsTrack : public QGraphicsWidget
public: public:
enum { Type = UserType + 2 }; enum { Type = UserType + 2 };
GraphicsTrack( MainWorkflow::TrackType type, quint32 trackNumber, GraphicsTrack( Workflow::TrackType type, quint32 trackNumber,
QGraphicsItem *parent = 0 ); QGraphicsItem *parent = 0 );
void setHeight( int height ); void setHeight( int height );
...@@ -44,13 +44,13 @@ public: ...@@ -44,13 +44,13 @@ public:
void setTrackEnabled( bool enabled ); void setTrackEnabled( bool enabled );
bool isEnabled(); bool isEnabled();
quint32 trackNumber(); quint32 trackNumber();
MainWorkflow::TrackType mediaType(); Workflow::TrackType mediaType();
virtual int type() const { return Type; } virtual int type() const { return Type; }
QList<AbstractGraphicsMediaItem*> childs(); QList<AbstractGraphicsMediaItem*> childs();
private: private:
MainWorkflow::TrackType m_type; Workflow::TrackType m_type;
quint32 m_trackNumber; quint32 m_trackNumber;
bool m_enabled; bool m_enabled;
}; };
......
...@@ -85,12 +85,12 @@ Timeline::Timeline( WorkflowRenderer* renderer, QWidget *parent ) : ...@@ -85,12 +85,12 @@ Timeline::Timeline( WorkflowRenderer* renderer, QWidget *parent ) :
connect( m_tracksView, SIGNAL( durationChanged(int) ), this, SLOT( setDuration(int) ) ); connect( m_tracksView, SIGNAL( durationChanged(int) ), this, SLOT( setDuration(int) ) );
// Clip actions // Clip actions
connect( m_mainWorkflow, SIGNAL( clipAdded(ClipHelper*,uint,qint64,MainWorkflow::TrackType ) ), connect( m_mainWorkflow, SIGNAL( clipAdded( ClipHelper*, uint, qint64, Workflow::TrackType ) ),
this, SLOT( actionAddClip(ClipHelper*,uint,qint64,MainWorkflow::TrackType ) ) ); this, SLOT( actionAddClip(ClipHelper*, uint, qint64, Workflow::TrackType ) ) );
connect( m_mainWorkflow, SIGNAL( clipMoved(QUuid, uint, qint64,MainWorkflow::TrackType ) ), connect( m_mainWorkflow, SIGNAL( clipMoved( QUuid, uint, qint64, Workflow::TrackType ) ),
this, SLOT( actionMoveClip(QUuid,uint,qint64,MainWorkflow::TrackType ) ) ); this, SLOT( actionMoveClip(QUuid, uint, qint64, Workflow::TrackType ) ) );
connect( m_mainWorkflow, SIGNAL( clipRemoved(const QUuid&,uint,MainWorkflow::TrackType ) ), connect( m_mainWorkflow, SIGNAL( clipRemoved( const QUuid&, uint, Workflow::TrackType ) ),
this, SLOT( actionRemoveClip(const QUuid&,uint,MainWorkflow::TrackType )) ); this, SLOT( actionRemoveClip( const QUuid&, uint, Workflow::TrackType )) );
// Clear / reset // Clear / reset
connect( m_mainWorkflow, SIGNAL( cleared() ), m_tracksControls, SLOT( clear() ) ); connect( m_mainWorkflow, SIGNAL( cleared() ), m_tracksControls, SLOT( clear() ) );
...@@ -163,12 +163,12 @@ void Timeline::setTool( ToolButtons button ) ...@@ -163,12 +163,12 @@ void Timeline::setTool( ToolButtons button )
tracksView()->setTool( button ); tracksView()->setTool( button );
} }
void Timeline::actionAddClip( ClipHelper* clipHelper, unsigned int track, qint64 start, MainWorkflow::TrackType trackType ) void Timeline::actionAddClip( ClipHelper* clipHelper, unsigned int track, qint64 start, Workflow::TrackType trackType )
{ {
tracksView()->addMediaItem( clipHelper, track, trackType, start ); tracksView()->addMediaItem( clipHelper, track, trackType, start );
} }
void Timeline::actionMoveClip( const QUuid& uuid, unsigned int track, qint64 time, MainWorkflow::TrackType ) void Timeline::actionMoveClip( const QUuid& uuid, unsigned int track, qint64 time, Workflow::TrackType )
{ {
tracksView()->moveMediaItem( uuid, track, time ); tracksView()->moveMediaItem( uuid, track, time );
Q_ASSERT( tracksView()->setItemOldTrack( uuid, track ) == true ); Q_ASSERT( tracksView()->setItemOldTrack( uuid, track ) == true );
...@@ -176,7 +176,7 @@ void Timeline::actionMoveClip( const QUuid& uuid, unsigned int track, qint64 tim ...@@ -176,7 +176,7 @@ void Timeline::actionMoveClip( const QUuid& uuid, unsigned int track, qint64 tim
tracksRuler()->update(); tracksRuler()->update();
} }
void Timeline::actionRemoveClip( const QUuid &uuid, unsigned int track, MainWorkflow::TrackType trackType ) void Timeline::actionRemoveClip( const QUuid &uuid, unsigned int track, Workflow::TrackType trackType )
{ {
tracksView()->removeMediaItem( uuid, track, trackType ); tracksView()->removeMediaItem( uuid, track, trackType );
} }
......
...@@ -85,20 +85,20 @@ public slots: ...@@ -85,20 +85,20 @@ public slots:
* \param start The position in frames. * \param start The position in frames.
* \param * \param
*/ */
void actionAddClip( ClipHelper* clip, unsigned int track, qint64 start, MainWorkflow::TrackType trackType ); void actionAddClip( ClipHelper* clip, unsigned int track, qint64 start, Workflow::TrackType trackType );
/** /**
* \brief Move an item in the timeline. * \brief Move an item in the timeline.
* \param uuid The Universally Unique Identifier of the item. * \param uuid The Universally Unique Identifier of the item.
* \param track The new track of the item. * \param track The new track of the item.
* \param time The new position (in frames) of the item. * \param time The new position (in frames) of the item.
*/ */
void actionMoveClip( const QUuid& uuid, unsigned int track, qint64 time, MainWorkflow::TrackType ); void actionMoveClip( const QUuid& uuid, unsigned int track, qint64 time, Workflow::TrackType );
/** /**
* \brief Remove an item from the timeline. * \brief Remove an item from the timeline.
* \param uuid The Universally Unique Identifier of the item. * \param uuid The Universally Unique Identifier of the item.
* \param track The current track of the item. * \param track The current track of the item.
*/ */
void actionRemoveClip( const QUuid& uuid, unsigned int track, MainWorkflow::TrackType trackType ); void actionRemoveClip( const QUuid& uuid, unsigned int track, Workflow::TrackType trackType );
void dragEnterEvent( QDragEnterEvent *event ); void dragEnterEvent( QDragEnterEvent *event );
void dropEvent( QDropEvent *event ); void dropEvent( QDropEvent *event );
......
...@@ -113,7 +113,7 @@ TracksView::createLayout() ...@@ -113,7 +113,7 @@ TracksView::createLayout()
void void
TracksView::addVideoTrack() TracksView::addVideoTrack()
{ {
GraphicsTrack *track = new GraphicsTrack( MainWorkflow::VideoTrack, m_numVideoTrack ); GraphicsTrack *track = new GraphicsTrack( Workflow::VideoTrack, m_numVideoTrack );
track->setHeight( m_tracksHeight ); track->setHeight( m_tracksHeight );
m_layout->insertItem( 0, track ); m_layout->insertItem( 0, track );
m_layout->activate(); m_layout->activate();
...@@ -126,7 +126,7 @@ TracksView::addVideoTrack() ...@@ -126,7 +126,7 @@ TracksView::addVideoTrack()
void void
TracksView::addAudioTrack() TracksView::addAudioTrack()
{ {
GraphicsTrack *track = new GraphicsTrack( MainWorkflow::AudioTrack, m_numAudioTrack ); GraphicsTrack *track = new GraphicsTrack( Workflow::AudioTrack, m_numAudioTrack );
track->setHeight( m_tracksHeight ); track->setHeight( m_tracksHeight );
m_layout->insertItem( 1000, track ); m_layout->insertItem( 1000, track );
m_layout->activate(); m_layout->activate();
...@@ -204,7 +204,7 @@ TracksView::removeClip( const QUuid& uuid ) ...@@ -204,7 +204,7 @@ TracksView::removeClip( const QUuid& uuid )
// Saving its values // Saving its values
QUuid itemUuid = item->uuid(); QUuid itemUuid = item->uuid();
quint32 itemTn = item->trackNumber(); quint32 itemTn = item->trackNumber();
MainWorkflow::TrackType itemTt = item->mediaType(); Workflow::TrackType itemTt = item->mediaType();
// Remove the item from the timeline // Remove the item from the timeline
removeMediaItem( itemUuid, itemTn, itemTt ); removeMediaItem( itemUuid, itemTn, itemTt );
...@@ -218,13 +218,13 @@ TracksView::removeClip( const QUuid& uuid ) ...@@ -218,13 +218,13 @@ TracksView::removeClip( const QUuid& uuid )
} }
void void
TracksView::addMediaItem( ClipHelper *ch, unsigned int track, MainWorkflow::TrackType trackType, qint64 start ) TracksView::addMediaItem( ClipHelper *ch, unsigned int track, Workflow::TrackType trackType, qint64 start )
{ {
Q_ASSERT( ch ); Q_ASSERT( ch );
// If there is not enough tracks to insert // If there is not enough tracks to insert
// the clip do it now. // the clip do it now.
if ( trackType == MainWorkflow::VideoTrack ) if ( trackType == Workflow::VideoTrack )
{ {
if ( track + 1 >= m_numVideoTrack ) if ( track + 1 >= m_numVideoTrack )
{ {
...@@ -233,7 +233,7 @@ TracksView::addMediaItem( ClipHelper *ch, unsigned int track, MainWorkflow::Trac ...@@ -233,7 +233,7 @@ TracksView::addMediaItem( ClipHelper *ch, unsigned int track, MainWorkflow::Trac
addVideoTrack(); addVideoTrack();
} }
} }
else if ( trackType == MainWorkflow::AudioTrack ) else if ( trackType == Workflow::AudioTrack )
{ {
if ( track + 1 >= m_numAudioTrack ) if ( track + 1 >= m_numAudioTrack )
{ {
...@@ -244,13 +244,13 @@ TracksView::addMediaItem( ClipHelper *ch, unsigned int track, MainWorkflow::Trac ...@@ -244,13 +244,13 @@ TracksView::addMediaItem( ClipHelper *ch, unsigned int track, MainWorkflow::Trac
} }
AbstractGraphicsMediaItem *item = 0; AbstractGraphicsMediaItem *item = 0;
if ( trackType == MainWorkflow::VideoTrack ) if ( trackType == Workflow::VideoTrack )
{ {
item = new GraphicsMovieItem( ch ); item = new GraphicsMovieItem( ch );
connect( item, SIGNAL( split(AbstractGraphicsMediaItem*,qint64) ), connect( item, SIGNAL( split(AbstractGraphicsMediaItem*,qint64) ),
this, SLOT( split(AbstractGraphicsMediaItem*,qint64) ) ); this, SLOT( split(AbstractGraphicsMediaItem*,qint64) ) );
} }
else if ( trackType == MainWorkflow::AudioTrack ) else if ( trackType == Workflow::AudioTrack )
{ {
item = new GraphicsAudioItem( ch ); item = new GraphicsAudioItem( ch );
connect( item, SIGNAL( split(AbstractGraphicsMediaItem*,qint64) ), connect( item, SIGNAL( split(AbstractGraphicsMediaItem*,qint64) ),
...@@ -360,7 +360,7 @@ TracksView::moveMediaItem( AbstractGraphicsMediaItem *item, QPoint position ) ...@@ -360,7 +360,7 @@ TracksView::moveMediaItem( AbstractGraphicsMediaItem *item, QPoint position )
GraphicsTrack *track = NULL; GraphicsTrack *track = NULL;
if ( !m_lastKnownTrack ) if ( !m_lastKnownTrack )
m_lastKnownTrack = getTrack( MainWorkflow::VideoTrack, 0 ); m_lastKnownTrack = getTrack( Workflow::VideoTrack, 0 );
QList<QGraphicsItem*> list = items( 0, position.y() ); QList<QGraphicsItem*> list = items( 0, position.y() );
for ( int i = 0; i < list.size(); ++i ) for ( int i = 0; i < list.size(); ++i )
...@@ -389,12 +389,12 @@ void ...@@ -389,12 +389,12 @@ void
TracksView::moveMediaItem( AbstractGraphicsMediaItem *item, quint32 track, qint64 time ) TracksView::moveMediaItem( AbstractGraphicsMediaItem *item, quint32 track, qint64 time )
{ {
// Add missing tracks // Add missing tracks
if ( item->mediaType() == MainWorkflow::AudioTrack ) if ( item->mediaType() == Workflow::AudioTrack )
{ {
while ( track >= m_numAudioTrack ) while ( track >= m_numAudioTrack )
addAudioTrack(); addAudioTrack();
} }
else if ( item->mediaType() == MainWorkflow::VideoTrack ) else if ( item->mediaType() == Workflow::VideoTrack )
{ {
while ( track >= m_numVideoTrack ) while ( track >= m_numVideoTrack )
addVideoTrack(); addVideoTrack();
...@@ -407,12 +407,12 @@ TracksView::moveMediaItem( AbstractGraphicsMediaItem *item, quint32 track, qint6 ...@@ -407,12 +407,12 @@ TracksView::moveMediaItem( AbstractGraphicsMediaItem *item, quint32 track, qint6
bool validPosFound = false; bool validPosFound = false;
// Add missing tracks for the target // Add missing tracks for the target
if ( item->groupItem()->mediaType() == MainWorkflow::AudioTrack ) if ( item->groupItem()->mediaType() == Workflow::AudioTrack )
{ {
while ( p.track() >= m_numAudioTrack ) while ( p.track() >= m_numAudioTrack )
addAudioTrack(); addAudioTrack();
} }
else if ( item->groupItem()->mediaType() == MainWorkflow::VideoTrack ) else if ( item->groupItem()->mediaType() == Workflow::VideoTrack )
{ {
while ( p