]> git.sesse.net Git - kdenlive/commitdiff
Fix bugs in loading of dvd project (background image/video widget & profile problems)
authorJean-Baptiste Mardelle <jb@kdenlive.org>
Mon, 3 Dec 2012 14:09:07 +0000 (15:09 +0100)
committerJean-Baptiste Mardelle <jb@kdenlive.org>
Mon, 3 Dec 2012 14:09:07 +0000 (15:09 +0100)
src/dvdwizard.cpp
src/dvdwizardmenu.cpp
src/dvdwizardmenu.h

index 741d5e6f67e1dafbd79e1b3904cc7c1384cda5be..4fe1b2962bdae49e200b979f518dc1b029b3ccee 100644 (file)
@@ -985,5 +985,5 @@ void DvdWizard::slotLoad()
         QDomElement e = vobs.at(i).toElement();
         m_pageVob->slotAddVobFile(KUrl(e.attribute("file")), e.attribute("chapters"));
     }
-    m_pageMenu->loadXml(dvdproject.firstChildElement("menu"));
+    m_pageMenu->loadXml(m_pageVob->dvdFormat(), dvdproject.firstChildElement("menu"));
 }
index b922bf9c4e374c02bee6880da8ceb4983a9b2b15..bd0b940338fc9adabc659c8e0850bd11a8bed0d7 100644 (file)
@@ -122,7 +122,7 @@ DvdWizardMenu::DvdWizardMenu(DVDFORMAT format, QWidget *parent) :
     connect(m_view.background_image, SIGNAL(textChanged(const QString &)), this, SLOT(buildImage()));
     connect(m_view.background_color, SIGNAL(changed(const QColor &)), this, SLOT(buildColor()));
 
-    connect(m_view.background_list, SIGNAL(activated(int)), this, SLOT(checkBackgroundType(int)));
+    connect(m_view.background_list, SIGNAL(currentIndexChanged(int)), this, SLOT(checkBackgroundType(int)));
 
     connect(m_view.target_list, SIGNAL(activated(int)), this, SLOT(setButtonTarget(int)));
     connect(m_view.back_to_menu, SIGNAL(toggled(bool)), this, SLOT(setBackToMenu(bool)));
@@ -810,11 +810,12 @@ QDomElement DvdWizardMenu::toXml() const
 }
 
 
-void DvdWizardMenu::loadXml(QDomElement xml)
+void DvdWizardMenu::loadXml(DVDFORMAT format, QDomElement xml)
 {
     kDebug() << "// LOADING MENU";
     if (xml.isNull()) return;
     kDebug() << "// LOADING MENU 1";
+    changeProfile(format);
     m_view.create_menu->setChecked(xml.attribute("enabled").toInt());
     if (xml.hasAttribute("background_color")) {
         m_view.background_list->setCurrentIndex(0);
index 3854d8b950c8d713587a4484fb8ab60b55b31aec..5c5794f09a9c07487f5845ad6dcffc0104f932d3 100644 (file)
@@ -144,7 +144,7 @@ public:
     int menuMovieLength() const;
     void changeProfile(DVDFORMAT format);
     QDomElement toXml() const;
-    void loadXml(QDomElement xml);
+    void loadXml(DVDFORMAT format, QDomElement xml);
     void prepareUnderLines();
     void resetUnderLines();