diff options
| author | ghost <andreas.monzner@multimedia-labs.de> | 2010-08-17 10:18:13 +0200 |
|---|---|---|
| committer | ghost <andreas.monzner@multimedia-labs.de> | 2010-08-17 10:20:41 +0200 |
| commit | a648830a100839cb95548cffe2a6cd291f8da19c (patch) | |
| tree | d7259b808f87985b05af99cba2c75c48332776ad /lib/gui | |
| parent | 65ce4a9bd27e342545b88faf9420426113d32702 (diff) | |
| download | enigma2-a648830a100839cb95548cffe2a6cd291f8da19c.tar.gz enigma2-a648830a100839cb95548cffe2a6cd291f8da19c.zip | |
Playback/Skipping fixes / cleanup by A. Holst
* Jumping between marks in the movie, with "<" and ">", doesn't work
well when there are cut marks in the movie. Especially jumping
backwards will fail if there is a mark in a cut out region that is
to be jumped over. (InfoBarGenerics.py, chunks 3 and 4)
* Now when rewind works at all platforms also at low speeds, the
rewind speeds x2 and x4 should be added again to the
default. (UsageConfig.py, chunk 1)
* Cleanup some obsolete code: SeekBackHack and non-smooth
winding. None of these can be used anymore, but remnants were left
in the code and in the configuration alternatives. It is high time
to clean these out. (setup.xml, UsageConfig.py chunk 2,
InfoBarGenerics.py chunks 1 and 2, DVDPlayer)
* In the position gauge of the movie player, marks in the movie are
shown as red dots. Long time ago the last position was also shown as
a red dot, which was bad because it was confused with the marks, so
it was removed. However, jumping between marks in the movie with "<"
and ">" also stops at the last position, which is useful e.g. if you
don't automatically start playing from the last position. The code
below adds the last position back to the position gauge as a green dot,
to distinguish it from the red ones. (epositiongauge.cpp)
refs bug #570
Diffstat (limited to 'lib/gui')
| -rw-r--r-- | lib/gui/epositiongauge.cpp | 22 |
1 files changed, 14 insertions, 8 deletions
diff --git a/lib/gui/epositiongauge.cpp b/lib/gui/epositiongauge.cpp index ff98c080..e45d4a6c 100644 --- a/lib/gui/epositiongauge.cpp +++ b/lib/gui/epositiongauge.cpp @@ -112,6 +112,7 @@ int ePositionGauge::event(int event, void *data, void *data2) // painter.fill(eRect(0, 10, s.width(), s.height()-20)); pts_t in = 0, out = 0; + int xm, xm_last = -1; std::multiset<cueEntry>::iterator i(m_cue_entries.begin()); @@ -126,17 +127,22 @@ int ePositionGauge::event(int event, void *data, void *data2) continue; } else if (i->what == 1) /* out */ out = i++->where; - else if (i->what == 2) /* mark */ + else /* mark or last */ { - int xm = scale(i->where); - painter.setForegroundColor(gRGB(0xFF8080)); - painter.fill(eRect(xm - 2, 0, 4, s.height())); + xm = scale(i->where); + if (i->what == 2) { + painter.setForegroundColor(gRGB(0xFF8080)); + if (xm - 2 < xm_last) /* Make sure last is not overdrawn */ + painter.fill(eRect(xm_last, 0, 2 + xm - xm_last, s.height())); + else + painter.fill(eRect(xm - 2, 0, 4, s.height())); + } else if (i->what == 3) { + painter.setForegroundColor(gRGB(0x80FF80)); + painter.fill(eRect(xm - 1, 0, 3, s.height())); + xm_last = xm + 2; + } i++; continue; - } else /* other marker, like last position */ - { - ++i; - continue; } } |
