summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorCarl Hetherington <cth@carlh.net>2012-12-15 23:16:13 +0000
committerCarl Hetherington <cth@carlh.net>2012-12-15 23:16:13 +0000
commit6375f7268d0acd53c6dc7968e17a15471fba3a45 (patch)
tree7108a6bdf89faaeedaae108bbd88712a1cc51155 /src
parentb53091684dce1af743aa66b5e1ea819fa078adc2 (diff)
Tiny cleanup.
Diffstat (limited to 'src')
-rw-r--r--src/wx/ffmpeg_player.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/wx/ffmpeg_player.cc b/src/wx/ffmpeg_player.cc
index 6f3a4cf4c..a8e580617 100644
--- a/src/wx/ffmpeg_player.cc
+++ b/src/wx/ffmpeg_player.cc
@@ -103,8 +103,8 @@ FFmpegPlayer::timer (wxTimerEvent& ev)
decode_frame ();
convert_frame ();
- double const video_length_in_seconds = static_cast<double>(_format_context->duration) / AV_TIME_BASE;
if (_last_frame_in_seconds) {
+ double const video_length_in_seconds = static_cast<double>(_format_context->duration) / AV_TIME_BASE;
int const new_slider_position = 4096 * _last_frame_in_seconds / video_length_in_seconds;
if (new_slider_position != _slider->GetValue()) {
_slider->SetValue (new_slider_position);