Disable timeouts with 0 values
This commit is contained in:
parent
4442f02561
commit
1a97781e8c
5 changed files with 15 additions and 9 deletions
|
@ -15,7 +15,10 @@
|
|||
Ffmpeg::Ffmpeg() {
|
||||
m_ffmpegPath = Preferences::instance()->getFfmpegPath();
|
||||
m_ffmpegTimeout = Preferences::instance()->getFfmpegTimeout();
|
||||
if (m_ffmpegTimeout > 0) m_ffmpegTimeout * 1000;
|
||||
if (m_ffmpegTimeout > 0)
|
||||
m_ffmpegTimeout * 1000;
|
||||
else
|
||||
m_ffmpegTimeout = -1;
|
||||
std::string strPath = m_ffmpegPath.toStdString();
|
||||
m_intermediateFormat = "png";
|
||||
}
|
||||
|
|
|
@ -46,7 +46,7 @@ public:
|
|||
private:
|
||||
QString m_intermediateFormat, m_ffmpegPath, m_audioPath, m_audioFormat;
|
||||
int m_frameCount = 0, m_lx, m_ly, m_bpp, m_bitsPerSample, m_channelCount,
|
||||
m_ffmpegTimeout = 30000, m_frameNumberOffset = -1;
|
||||
m_ffmpegTimeout = -1, m_frameNumberOffset = -1;
|
||||
double m_frameRate = 24.0;
|
||||
bool m_ffmpegExists = false, m_ffprobeExists = false, m_hasSoundTrack = false;
|
||||
TFilePath m_path;
|
||||
|
|
|
@ -835,7 +835,10 @@ void LipSyncPopup::onApplyButton() {
|
|||
}
|
||||
runRhubarb();
|
||||
int rhubarbTimeout = Preferences::instance()->getRhubarbTimeout();
|
||||
if (rhubarbTimeout > 0) rhubarbTimeout * 1000;
|
||||
if (rhubarbTimeout > 0)
|
||||
rhubarbTimeout * 1000;
|
||||
else
|
||||
rhubarbTimeout = -1;
|
||||
m_rhubarb->waitForFinished(rhubarbTimeout);
|
||||
m_progressDialog->hide();
|
||||
QString results = m_rhubarb->readAllStandardError();
|
||||
|
|
|
@ -1043,10 +1043,10 @@ QString PreferencesPopup::getUIString(PreferencesItemId id) {
|
|||
|
||||
// Import / Export
|
||||
{ffmpegPath, tr("Executable Directory:")},
|
||||
{ffmpegTimeout, tr("Import/Export Timeout (sec; -1 = no timeout):")},
|
||||
{ffmpegTimeout, tr("Import/Export Timeout (seconds):")},
|
||||
{fastRenderPath, tr("Fast Render Output Directory:")},
|
||||
{rhubarbPath, tr("Executable Directory:")},
|
||||
{rhubarbTimeout, tr("Analyze Audio Timeout (sec; -1 = no timeout):") },
|
||||
{rhubarbTimeout, tr("Analyze Audio Timeout (seconds):")},
|
||||
|
||||
// Drawing
|
||||
{scanLevelType, tr("Scan File Format:")},
|
||||
|
|
|
@ -446,12 +446,12 @@ void Preferences::definePreferenceItems() {
|
|||
|
||||
// Import / Export
|
||||
define(ffmpegPath, "ffmpegPath", QMetaType::QString, "");
|
||||
define(ffmpegTimeout, "ffmpegTimeout", QMetaType::Int, -1, -1,
|
||||
define(ffmpegTimeout, "ffmpegTimeout", QMetaType::Int, 0, 0,
|
||||
std::numeric_limits<int>::max());
|
||||
define(fastRenderPath, "fastRenderPath", QMetaType::QString, "desktop");
|
||||
define(rhubarbPath, "rhubarbPath", QMetaType::QString, "");
|
||||
define(rhubarbTimeout, "rhubarbTimeout", QMetaType::Int, -1, -1,
|
||||
std::numeric_limits<int>::max());
|
||||
define(rhubarbTimeout, "rhubarbTimeout", QMetaType::Int, 0, 0,
|
||||
std::numeric_limits<int>::max());
|
||||
|
||||
// Drawing
|
||||
define(scanLevelType, "scanLevelType", QMetaType::QString, "tif");
|
||||
|
|
Loading…
Reference in a new issue