tlaukkanen / mobile-trail-explorer

Automatically exported from code.google.com/p/mobile-trail-explorer
2 stars 0 forks source link

audio markers don't work while recording when marker interval == 0 and streaming on. plus bonus. #186

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?

1. in Settings > Recording, set "Create marker every Nth position" to 0 and
"Stream: Save GPX Stream also as default" to On
2. start recording
3. add an audio marker (* key by default, another keypress stops recording)

What is the expected output?

a red colored "RECORDING AUDIO" with a blinking dot in fornt on the trail
canvas, and the recorded audio file track_audio_marker_YYYYMMDD_HHMMSS.wav
in the export folder

What do you see instead?

nothing: no "RECORDING AUDIO", no audio file

reason: a division by zero (the marker interval) without a catch.

fix: attached ("catch" markerInterval == 0).

patch is tested and working here (in emulators and my nokia n82). please
have a look at it and test it and let me know if i can commit it (would
like to do this myself). thanks!

bonus: i netbeans-refactored the confusing naming of variables and methods
referring to the recording and marker intervals ("recording interval in
seconds" and "Create marker every Nth position"). before, we had 10+ (sic)
different names for the same 2 things (intervalSeconds, intervalMarkerStep,
intervalStep, getRecordingMarkerInterval, setInterval,
setIntervalForMarkers, newStep, ...). now it is uniformly
[get|set]recordingInterval and [get|set]markerInterval. hope that helps.

Original issue reported on code.google.com by akollmorgen@gmail.com on 15 Jun 2009 at 6:01

Attachments:

GoogleCodeExporter commented 9 years ago
i take the zero responses for agreement and just committed a slightly modified
(removed 2 more naming inconsistencies) patch. marking FIXED.

Original comment by akollmorgen@gmail.com on 1 Jul 2009 at 2:44