]> git.sesse.net Git - kdenlive/blobdiff - src/kdenlivedoc.cpp
kdenlivedoc.cpp: Use QPointer [krazy 35/37] by Mikko Rapeli
[kdenlive] / src / kdenlivedoc.cpp
index bd8335deec768e02471b026fe490132759818830..b210a5bcfc0e382393c7ca34223a0c6e11a43a54 100644 (file)
@@ -798,7 +798,7 @@ void KdenliveDoc::setProjectFolder(KUrl url)
     KStandardDirs::makeDir(url.path());
     KStandardDirs::makeDir(url.path(KUrl::AddTrailingSlash) + "titles/");
     KStandardDirs::makeDir(url.path(KUrl::AddTrailingSlash) + "thumbs/");
-    if (KMessageBox::questionYesNo(kapp->activeWindow(), i18n("You have changed the project folder. Do you want to copy the cached data from %1 to the new folder %2?").arg(m_projectFolder.path(), url.path())) == KMessageBox::Yes) moveProjectData(url);
+    if (KMessageBox::questionYesNo(kapp->activeWindow(), i18n("You have changed the project folder. Do you want to copy the cached data from %1 to the new folder %2?"m_projectFolder.path(), url.path())) == KMessageBox::Yes) moveProjectData(url);
     m_projectFolder = url;
 
     updateProjectFolderPlacesEntry();
@@ -1266,7 +1266,7 @@ void KdenliveDoc::slotCreateTextClip(QString group, const QString &groupId, cons
 {
     QString titlesFolder = projectFolder().path(KUrl::AddTrailingSlash) + "titles/";
     KStandardDirs::makeDir(titlesFolder);
-    TitleWidget *dia_ui = new TitleWidget(templatePath, m_timecode, titlesFolder, m_render, kapp->activeWindow());
+    QPointer<TitleWidget> dia_ui = new TitleWidget(templatePath, m_timecode, titlesFolder, m_render, kapp->activeWindow());
     if (dia_ui->exec() == QDialog::Accepted) {
         m_clipManager->slotAddTextClipFile(i18n("Title clip"), dia_ui->outPoint(), dia_ui->xml().toString(), group, groupId);
         setModified(true);