-<ui version="4.0" >
+<?xml version="1.0" encoding="UTF-8"?>
+<ui version="4.0">
<class>WizardCheck_UI</class>
- <widget class="QWidget" name="WizardCheck_UI" >
- <property name="geometry" >
+ <widget class="QWidget" name="WizardCheck_UI">
+ <property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<height>236</height>
</rect>
</property>
- <layout class="QGridLayout" name="gridLayout" >
- <item row="0" column="0" >
- <widget class="QTreeWidget" name="programList" />
+ <layout class="QGridLayout" name="gridLayout">
+ <item row="0" column="0">
+ <widget class="QTreeWidget" name="programList">
+ <property name="alternatingRowColors">
+ <bool>true</bool>
+ </property>
+ <property name="rootIsDecorated">
+ <bool>false</bool>
+ </property>
+ <property name="columnCount">
+ <number>2</number>
+ </property>
+ <attribute name="headerVisible">
+ <bool>false</bool>
+ </attribute>
+ <attribute name="headerVisible">
+ <bool>false</bool>
+ </attribute>
+ <column>
+ <property name="text">
+ <string notr="true">1</string>
+ </property>
+ </column>
+ <column>
+ <property name="text">
+ <string notr="true">2</string>
+ </property>
+ </column>
+ </widget>
</item>
</layout>
</widget>
-<ui version="4.0" >
+<?xml version="1.0" encoding="UTF-8"?>
+<ui version="4.0">
<class>WizardMltCheck_UI</class>
- <widget class="QWidget" name="WizardMltCheck_UI" >
- <property name="geometry" >
+ <widget class="QWidget" name="WizardMltCheck_UI">
+ <property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<height>284</height>
</rect>
</property>
- <layout class="QGridLayout" name="gridLayout_3" >
- <item row="0" column="0" >
- <widget class="QTabWidget" name="tabWidget" >
- <property name="currentIndex" >
+ <layout class="QGridLayout" name="gridLayout_3">
+ <item row="0" column="0">
+ <widget class="QTabWidget" name="tabWidget">
+ <property name="currentIndex">
<number>0</number>
</property>
- <widget class="QWidget" name="tab" >
- <attribute name="title" >
+ <widget class="QWidget" name="tab">
+ <attribute name="title">
<string>Installed modules</string>
</attribute>
- <layout class="QGridLayout" name="gridLayout_2" >
- <item row="0" column="0" >
- <widget class="QTreeWidget" name="programList" >
- <property name="sizePolicy" >
- <sizepolicy vsizetype="Expanding" hsizetype="MinimumExpanding" >
+ <layout class="QGridLayout" name="gridLayout_2">
+ <item row="0" column="0">
+ <widget class="QTreeWidget" name="programList">
+ <property name="sizePolicy">
+ <sizepolicy hsizetype="MinimumExpanding" vsizetype="Expanding">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
+ <property name="alternatingRowColors">
+ <bool>true</bool>
+ </property>
+ <property name="rootIsDecorated">
+ <bool>false</bool>
+ </property>
+ <property name="columnCount">
+ <number>2</number>
+ </property>
+ <attribute name="headerVisible">
+ <bool>false</bool>
+ </attribute>
+ <attribute name="headerVisible">
+ <bool>false</bool>
+ </attribute>
<column>
- <property name="text" >
+ <property name="text">
<string>1</string>
</property>
</column>
+ <column>
+ <property name="text">
+ <string notr="true">2</string>
+ </property>
+ </column>
</widget>
</item>
</layout>
</widget>
- <widget class="QWidget" name="tab_2" >
- <attribute name="title" >
+ <widget class="QWidget" name="tab_2">
+ <attribute name="title">
<string>Available Codecs (avformat)</string>
</attribute>
- <layout class="QGridLayout" name="gridLayout" >
- <item row="0" column="0" >
- <widget class="QLabel" name="label" >
- <property name="text" >
- <string>Audio Codecs</string>
+ <layout class="QGridLayout" name="gridLayout">
+ <item row="1" column="0">
+ <widget class="QListWidget" name="acodecs_list">
+ <property name="alternatingRowColors">
+ <bool>true</bool>
</property>
</widget>
</item>
- <item row="0" column="1" >
- <widget class="QLabel" name="label_2" >
- <property name="text" >
- <string>Video Codecs</string>
+ <item row="1" column="1">
+ <widget class="QListWidget" name="vcodecs_list">
+ <property name="alternatingRowColors">
+ <bool>true</bool>
</property>
</widget>
</item>
- <item row="0" column="2" >
- <widget class="QLabel" name="label_3" >
- <property name="text" >
- <string>Formats</string>
+ <item row="1" column="2">
+ <widget class="QListWidget" name="formats_list">
+ <property name="alternatingRowColors">
+ <bool>true</bool>
</property>
</widget>
</item>
- <item row="1" column="0" >
- <widget class="QListWidget" name="acodecs_list" />
+ <item row="0" column="2">
+ <widget class="QLabel" name="label_3">
+ <property name="text">
+ <string>Formats</string>
+ </property>
+ </widget>
</item>
- <item row="1" column="1" >
- <widget class="QListWidget" name="vcodecs_list" />
+ <item row="0" column="1">
+ <widget class="QLabel" name="label_2">
+ <property name="text">
+ <string>Video Codecs</string>
+ </property>
+ </widget>
</item>
- <item row="1" column="2" >
- <widget class="QListWidget" name="formats_list" />
+ <item row="0" column="0">
+ <widget class="QLabel" name="label">
+ <property name="text">
+ <string>Audio Codecs</string>
+ </property>
+ </widget>
</item>
</layout>
<zorder>acodecs_list</zorder>
#include <KProcess>
#include <kmimetype.h>
#include <KRun>
+#include <KService>
+#include <KMimeTypeTrader>
#include <QLabel>
#include <QFile>
void Wizard::checkMltComponents()
{
- m_mltCheck.programList->setColumnCount(2);
- m_mltCheck.programList->setRootIsDecorated(false);
- m_mltCheck.programList->setHeaderHidden(true);
QSize itemSize(20, fontMetrics().height() * 2.5);
m_mltCheck.programList->setColumnWidth(0, 30);
m_mltCheck.programList->setIconSize(QSize(24, 24));
void Wizard::slotCheckPrograms()
{
- m_check.programList->setColumnCount(2);
- m_check.programList->setRootIsDecorated(false);
- m_check.programList->setHeaderHidden(true);
QSize itemSize(20, fontMetrics().height() * 2.5);
m_check.programList->setColumnWidth(0, 30);
m_check.programList->setIconSize(QSize(24, 24));
if (KStandardDirs::findExe("mkisofs").isEmpty()) item->setIcon(0, m_badIcon);
else item->setIcon(0, m_okIcon);
+ // set up some default applications
+ QString program;
+ if (KdenliveSettings::defaultimageapp().isEmpty()) {
+ program = KStandardDirs::findExe("gimp");
+ if (program.isEmpty()) program = KStandardDirs::findExe("krita");
+ if (!program.isEmpty()) KdenliveSettings::setDefaultimageapp(program);
+ }
+ if (KdenliveSettings::defaultaudioapp().isEmpty()) {
+ program = KStandardDirs::findExe("audacity");
+ if (program.isEmpty()) program = KStandardDirs::findExe("traverso");
+ if (!program.isEmpty()) KdenliveSettings::setDefaultaudioapp(program);
+ }
+ if (KdenliveSettings::defaultvideoapp().isEmpty()) {
+ KService::Ptr offer = KMimeTypeTrader::self()->preferredService("video/mpeg");
+ if (offer)
+ KdenliveSettings::setDefaultvideoapp(KRun::binaryName(offer->exec(), true));
+ }
}
void Wizard::installExtraMimes(QString baseName, QStringList globs)
return m_systemCheckIsOk;
}
-bool Wizard::slotShowWebInfos()
+void Wizard::slotShowWebInfos()
{
KRun::runUrl(KUrl("http://kdenlive.org/discover/" + QString(version).section(' ', 0, 0)), "text/html", this);
}