Hi all,
I had some minor issues with pytrainer (and fixed them):
1) ./glade/trigger_manual.png should be ./glade/trigger_Manual.png at
least on non-Windows systems or the reference in the code should be fixed.
2) Run/Rest times are not calculated for acitivities with only one lap.
3) When updating the record view, the value of lap['intensity'] was
'Active' and not 'active' so the look-up in the color-mapping did not
succeed.
The patch attached fixed 2) and 3).
To fix issue 1) please decide to rename the file or change the code.
cheers,
friso
--
viele Grüße,
Jan-Friso Evers-Senne
Dr.-Ing. Jan-Friso Evers-Senne
Bonndorfer Str. 22
79853 Lenzkirch
07653-9648053
0179-1499217
fr...@evers-senne.de
Index: pytrainer/gui/windowmain.py
===================================================================
--- pytrainer/gui/windowmain.py (Revision 809)
+++ pytrainer/gui/windowmain.py (Arbeitskopie)
@@ -457,10 +457,11 @@
color = {
'active' : '#000000',
'rest' : '#808080',
+ 'Active' : '#000000',
+ 'Rest' : '#808080',
}
pic = gtk.gdk.pixbuf_new_from_file(self.data_path+"glade/trigger_%s.png" % lap['trigger'])
-
iter = store.append()
store.set(iter,
0, lap['lap_number']+1,
@@ -516,9 +517,11 @@
i += 1
self.frame_laps.show()
else:
- self.frame_laps.hide()
- runTime = activity.time
-
+ self.frame_laps.hide()
+ if len(activity.laps)==1:
+ runTime = float(activity.laps[0]['elapsed_time'])
+ else:
+ runTime = activity.time
else:
self.recordview.set_current_page(0)
self.recordview.set_sensitive(0)
------------------------------------------------------------------------------
AppSumo Presents a FREE Video for the SourceForge Community by Eric
Ries, the creator of the Lean Startup Methodology on "Lean Startup
Secrets Revealed." This video shows you how to validate your ideas,
optimize your ideas and identify your business strategy.
http://p.sf.net/sfu/appsumosfdev2dev
_______________________________________________
Pytrainer-devel mailing list
Pytrainer-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/pytrainer-devel