aboutsummaryrefslogtreecommitdiff
path: root/lib/gui
diff options
context:
space:
mode:
authorghost <andreas.monzner@multimedia-labs.de>2010-11-25 00:12:59 +0100
committerghost <andreas.monzner@multimedia-labs.de>2010-11-25 00:12:59 +0100
commitcdfd7a570b5b0813c8f62fc76deed949d7a11803 (patch)
tree1b4e1f1ada84e532fe7c37ea9aea49a4c9d32fa0 /lib/gui
parentac065de0aa482d630e41ba80ccdc5ef617e7e378 (diff)
parent16902de6f4215ccd425622b92e8ae6be1ae4a97f (diff)
downloadenigma2-cdfd7a570b5b0813c8f62fc76deed949d7a11803.tar.gz
enigma2-cdfd7a570b5b0813c8f62fc76deed949d7a11803.zip
Merge branch 'bug_570_playback_skip_fixes_and_cleanup_ml_aholst' into experimental
Diffstat (limited to 'lib/gui')
-rw-r--r--lib/gui/epositiongauge.cpp22
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;
}
}