Commit 8a266762 authored by Sashmita Raghav's avatar Sashmita Raghav
Browse files

Connect Subtitle Model signals with respective slots

parent 73930cd8
......@@ -84,6 +84,8 @@ KdenliveDoc::KdenliveDoc(const QUrl &url, QString projectFolder, QUndoGroup *und
m_guideModel.reset(new MarkerListModel(m_commandStack, this));
connect(m_guideModel.get(), &MarkerListModel::modelChanged, this, &KdenliveDoc::guidesChanged);
m_subtitleModel.reset(new SubtitleModel (m_commandStack, this));
connect(m_subtitleModel.get(), &SubtitleModel::modelChanged, this, &KdenliveDoc::subtitlesChanged);
connect(this, SIGNAL(updateCompositionMode(int)), parent, SLOT(slotUpdateCompositeAction(int)));
bool success = false;
connect(m_commandStack.get(), &QUndoStack::indexChanged, this, &KdenliveDoc::slotModified);
......@@ -1289,6 +1291,7 @@ void KdenliveDoc::loadDocumentProperties()
if (pl.isNull()) {
QMetaObject::invokeMethod(m_subtitleModel.get(), "parseSubtitle", Qt::QueuedConnection);
QDomNodeList props = pl.elementsByTagName(QStringLiteral("property"));
QString name;
QDomElement e;
......@@ -1771,4 +1774,10 @@ int KdenliveDoc::audioChannels() const
std::shared_ptr<SubtitleModel> KdenliveDoc::getSubtitleModel() const
return m_subtitleModel;
void KdenliveDoc::subtitlesChanged()
\ No newline at end of file
......@@ -236,6 +236,7 @@ private slots:
void checkPreviewStack(int ix);
/** @brief Guides were changed, save to MLT. */
void guidesChanged();
void subtitlesChanged();
void resetProjectList();
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment