Skip to content

Commit

Permalink
Fixed subtitle burn in
Browse files Browse the repository at this point in the history
  • Loading branch information
ripose-jp committed Apr 18, 2021
1 parent 90bcf0f commit cb32572
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/gui/widgets/subtitlewidget.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,9 @@ void SubtitleWidget::postitionChanged(const double value)
{
if (value < m_startTime - DOUBLE_DELTA || value > m_endTime + DOUBLE_DELTA)
{
setSubtitle("", 0, std::numeric_limits<double>::infinity(), 0);
m_rawText = "";
clear();
hide();
Q_EMIT GlobalMediator::getGlobalMediator()->subtitleExpired();
}
}
Expand Down Expand Up @@ -445,6 +447,7 @@ void SubtitleWidget::showEvent(QShowEvent *event)
{
Q_EMIT GlobalMediator::getGlobalMediator()->requestSetSubtitleVisibility(false);
}
QTextEdit::showEvent(event);
}

void SubtitleWidget::hideEvent(QHideEvent *event)
Expand All @@ -453,4 +456,5 @@ void SubtitleWidget::hideEvent(QHideEvent *event)
{
Q_EMIT GlobalMediator::getGlobalMediator()->requestSetSubtitleVisibility(true);
}
QTextEdit::hideEvent(event);
}

0 comments on commit cb32572

Please sign in to comment.