mirror of
https://github.com/GoldenCheetah/GoldenCheetah.git
synced 2026-02-14 00:28:42 +00:00
Remove reading of .notes from LTMPopup
Last vestiges of references to the old .notes file which is now deprecated fully and replaced with a metadata tag "Notes". If a .notes file exists it will be read in and used to initialize the Notes metadata tag -- this is pre-existing functionality and not changed with this patch, which is just related to LTM Popup. There are no other know references to the old .notes file left in the active code. Fixes #179.
This commit is contained in:
@@ -235,21 +235,7 @@ LTMPopup::rideSelected()
|
||||
// update summary
|
||||
metrics->setText(selected[index].toString(summary, useMetricUnits));
|
||||
|
||||
// read notes
|
||||
QString filename = main->home.absolutePath() + "/" +
|
||||
QFileInfo(selected[index].getFileName()).baseName() +
|
||||
".notes";
|
||||
|
||||
QFile notesFile(filename);
|
||||
|
||||
// read it in if it exists
|
||||
if (notesFile.exists() && notesFile.open(QFile::ReadOnly | QFile::Text)) {
|
||||
QTextStream in(¬esFile);
|
||||
notes->setText(in.readAll());
|
||||
notesFile.close();
|
||||
} else {
|
||||
notes->setText("No notes recorded.");
|
||||
}
|
||||
notes->setText(selected[index].getText("Notes", ""));
|
||||
}
|
||||
resizeEvent(NULL);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user