[longomatch] Draw position triangle correctly in the timerule



commit f3caf66b569b9bd66536035c0441aa2514dc339f
Author: Andoni Morales Alastruey <ylatuya gmail com>
Date:   Tue May 20 21:20:52 2014 +0200

    Draw position triangle correctly in the timerule

 LongoMatch.Drawing/Widgets/Timerule.cs |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/LongoMatch.Drawing/Widgets/Timerule.cs b/LongoMatch.Drawing/Widgets/Timerule.cs
index 1f3e583..aa3c8ae 100644
--- a/LongoMatch.Drawing/Widgets/Timerule.cs
+++ b/LongoMatch.Drawing/Widgets/Timerule.cs
@@ -70,7 +70,7 @@ namespace LongoMatch.Drawing.Widgets
                        tk.StrokeColor = Common.TIMELINE_LINE_COLOR;
                        tk.LineWidth = Common.TIMELINE_LINE_WIDTH;
                        tk.DrawLine (new Point (0, height), new Point (width, height));
-                       
+               
                        /* Draw big lines each 10 * secondsPerPixel */
                        for(int i=0; i <= Duration.Seconds / SecondsPerPixel; i += TIME_SPACING) {
                                double pos = i - Scroll;
@@ -94,6 +94,7 @@ namespace LongoMatch.Drawing.Widgets
                        
                        /* Draw position triangle */
                        tpos = Common.TimeToPos (CurrentTime, SecondsPerPixel);
+                       tpos -= Scroll;
                        tk.FillColor = Common.TIMELINE_LINE_COLOR;
                        tk.DrawTriangle (new Point (tpos, widget.Height), 8,
                                         BIG_LINE_HEIGHT, SelectionPosition.Bottom);


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]