+void KdenliveSettingsDialog::slotReloadBlackMagic()
+{
+ Render::getBlackMagicDeviceList(m_configCapture.kcfg_decklink_capturedevice, true);
+ if (!Render::getBlackMagicOutputDeviceList(m_configSdl.kcfg_blackmagic_output_device), true) {
+ // No blackmagic card found
+ m_configSdl.kcfg_external_display->setEnabled(false);
+ }
+ m_configSdl.kcfg_external_display->setEnabled(KdenliveSettings::decklink_device_found());
+}
+
+void KdenliveSettingsDialog::slotReloadShuttleDevices()
+{
+#ifdef USE_JOGSHUTTLE
+ QString devDirStr = "/dev/input/by-id";
+ QDir devDir(devDirStr);
+ if (!devDir.exists()) {
+ devDirStr = "/dev/input";
+ }
+
+ DeviceMap devMap = JogShuttle::enumerateDevices(devDirStr);
+ if (!devMap.isEmpty()) {
+ m_configShuttle.shuttledevicelist->clear();
+ }
+
+ QStringList devNamesList;
+ QStringList devPathList;
+ DeviceMapIter iter = devMap.begin();
+ if (iter == devMap.end()) {
+ KdenliveSettings::shuttledevicenames().clear();
+ KdenliveSettings::shuttledevicepaths().clear();
+ m_configShuttle.shuttledevicelist->clear();
+ }
+ while (iter != devMap.end()) {
+ kDebug() << iter.key() << ": " << iter.value();
+ m_configShuttle.shuttledevicelist->addItem(iter.key(), iter.value());
+ devNamesList << iter.key();
+ devPathList << iter.value();
+ ++iter;
+ }
+
+ KdenliveSettings::setShuttledevicenames(devNamesList);
+ KdenliveSettings::setShuttledevicepaths(devPathList);
+ QTimer::singleShot(200, this, SLOT(slotUpdateShuttleDevice()));
+
+ kDebug() << "Devices reloaded";
+
+#endif //USE_JOGSHUTTLE
+}
+