SportsTracker-TODO
==================

ExerciseViewer standalone mode:
- add support for viewing just a single HRM file by using the "Open with"
  option of the operating system
- use standalone mode when just one argument has been passed at app execution
- display ExerciseViewer window only, don't launch the SportsTracker application
  and don't load user data then
- use speed mode and unit system configured by the user
- document EV standalone mode usage

Reminder for Notes:
- useful for planning events or tasks (e.g. for training or maintenance)
- Add row to Note Dialog below the date and time:
  - Label "Reminder:"
  - Selection ComboBox with values:
    - No
    - Remind me at this day
    - Remind me before that day
  - For option 3 show this input next to selection:
    - Spinner with values 1 (default) to 1000
    - Label "days before"
- On SportsTracker start:
  - Check for notes with reminders where reminder day has been reached
    (also for noted in the past if the reminder has been missing)
  - If there are Notes to remind, show a reminder dialog:
    - it shows a table of all notes to remind
      (first column date, second column shortened text)
    - the user can:
      - open each displayed note directly
      - remove the reminder of each note
      - close the dialog

JavaFX Migration:
- Migration status: completed, Swing is not in use anymore
- tested on macOS, Windows and Linux (incl. printing, drag & drop)
- DatePicker validation does not work => when removing the date no error will be shown (uses previous date)
- ControlsFX bug, remove workaround when fixed:
  - Dialogs can't be displayed when they contain multiple controls with validation support
    (see https://bitbucket.org/controlsfx/controlsfx/issues/539/multiple-dialog-fields-with-validation )
  - workaround is to setup the validation after the dialog has been shown (with Platform.invokeLater(...)
    => remove after the bug has been fixed in Filter-, Exercise-, Note- and Weight Dialog
- ExerciseViewer: Done & tested
  - Bug (also with JavaFX 8u40): EV window is always placed in screen center, not placed at center of parent window
    (initially, when no previous window bounds were persisted)
- Print Views: Done for all views
  - Problem in List Views: tables can't be printed completely, the JavaFX API support only the printing
    of one single node at one single page
  - Used workaround: create a snapshot image of the current displayed table view, scale to fit on paper
    and print the image instead the view (prints only the visible rows)
  - Update ViewPrinter when JavaFX API supports the printing of the complete tables
    (the I18N properties for list printing on multiple pages are present, see st.???view.print.???)
- Spinner in Overview Dialog: remove mouse wheel workaround when added to JavaFX by default
  - I've filed a tweak request: https://javafx-jira.kenai.com/browse/RT-40269
- JavaFX bug in DatePicker: text editor entries are always ignored
  - https://bugs.openjdk.java.net/browse/JDK-8136838
  - although this bug is closed, it still exists in JDK 10
  - temporary workaround in FxWorkarounds.fixDatePickerTextEntry() => remove when fixed in JavaFX

Mac OS X integration:
- Application name is not displayed in the MenuBar, it shows STMain instead
  => Workaround: pass JVM parameter "-Xdock:name=SportsTracker" on startup
  => JDK 9/10 will provide a new API for macOS specific dock and menu integration
- SportsTracker.app and native packages work properly, the name and icons are
  set via JVM parameter there
- Use of JEP 272: Platform-Specific Desktop Features for mac-specific menu items
  (see http://openjdk.java.net/jeps/272)
  - currently for Swing apps only
  - JavaFX support might be added after Java 10: https://bugs.openjdk.java.net/browse/JDK-8091107


General TODOs:
--------------

- Use JPA for database persistence instead of XML files
  - Derby or SQLite are interesting options, SQLite links:
    - https://bitbucket.org/xerial/sqlite-jdbc/overview  (mature JDBC driver)
    - https://github.com/sqlitebrowser/sqlitebrowser  (SQLite database client)
- Import feature for devices connected via USB
  - New Tab in Options dialog with these settings:
    - Device directory/drive
    - Import directory
    - Default sport type / subtype
    - Default equipment (optional)
- Overview Dialog: new display mode for comparing 2 seasons / years:
  (https://sourceforge.net/projects/sportstracker/forums/forum/451565/topic/4435642)
  - add a new diagram option in the selection combobox called "Compare two seasons"
  - in this mode the user gets following input fields:
    - year 1 (default: current year) 
    - year 2 (default: previous year)
    - season start month (default: January) 
  - it must display all the monthly data of year 1 on the left (line graph) and
    year 2 on the right vertical axis (dashed graph)
- Exercise Dialog (and all others): use formated text fields for entering
  distance, duration etc. (will be possible with Java 8u40)
- translation updates (german, french and spanish are up to date)
- Batch import for multiple exercise files (e.g. when migrating from Windows
  Polar software): In the Import dialog the user needs to select the the sport 
  type, the subtype, the intensity and which value from distance, AVG speed or 
  duration needs to be recalculated (because these 3 values in the exercise 
  files does not fit together in most cases) first. Then all selected files 
  will be imported as exercises into SportsTracker. 
- FilterDialog should also make possible to show e.g. all bicycle
  sport subtypes, except those from "ergometer" (hint from Steffen Rehn)

Training route/lap support:
- requested by Bernd Mirbach and other users, see mail from Bernd:
- we need a dialog for editing possible routes/laps and the appropriate
  length, ascent and description
- the user can select a predefined route in the exercise dialog and
  the appropriate widgets will be pre-filled
- it should be possible to filter for specific routes for evaluation


ExerciseViewer-TODO
===================

ExerciseParsers:
- GarminTcxParser:
  - refactor big method parseExercisePath(...), split into multiple methods
  - parse speed data for Trackpoints if available instead of calculation 
    (available when there's a speed sensor, e.g. on Edge 500 export files) 
  - average speed is wrong when there are pauses in the exercise (Auto-Stop)
- PolarHsrRawParser and PolarSRawParser:
  - Refactor: Extract duplicate methods/code
- HAC4 Parser:
  - more exercise data checks for parser in unit tests
- HRM Parser: 
  - recalculate average heartrate, speed, times within ranges ... from samples,
    there are often wrong values in the appropriate HRM fields (hint from 
    Steffen Rehn) - (Polar Windows software seems to recalculate this too :-)
  - When the monitor displays heartrate and ranges in percent instead in bpm
    the heartrate limit ranges in the HRM files are also stored in percent. 
    But it's not possible yet to determine whether it's bpm (default) or 
    percent. That's why the parses always assumes bpm values.
    (Calculate the BPM values with help of max. heartrate should work ...)  
