i found a error in the Time To Destination function. Then the time is more than a hour it only shows a "-" line and not the time. Then the time is less than a hour everthing is fine.
Ouch, you're right. Thanks for catching this bug.
I found that the return value of Units.getReadableTime(duration) can be in "hr:min" format. This confuses the if (readableDuration.value > 0) loop. Commenting out the sanity checking makes the time display correctly. Please verify this solution if you can, if it doesn't introduce new bug, then I think this is an easy fix and can be pushed to unstable patch.
Did some experiments with loading the trafficDetailsPage. Calling the page was done by:
Code:
windows.push("trafficDetailsPage.qml")'
Also, need to make "TrafficEventHeader" visible by adding the following line in components/qmldir
Code:
TrafficEventHeader 1.0 TrafficEventHeader.qml
For testing, I put this into the onMenuButtonClicked() signal in guidancePage.Dashboard. The traffic detail page (tdPage) did show up, but there were no information available. Taking a deeper look at tdPage, it seemed to me that a traffic event in the trafficModel needs to be selected first in order for tdPage to load the info. Unfortunately, I didn't find anywhere in the source code for selecting the traffic event.
EDIT:
Also, the object 'TrafficViewHelper' used in tdPage doesn't have associated qml file.
So this feature will take more efforts if someone ever tries to make it work.
I found that the return value of Units.getReadableTime(duration) can be in "hr:min" format. This confuses the if (readableDuration.value > 0) loop. Commenting out the sanity checking makes the time display correctly. Please verify this solution if you can, if it doesn't introduce new bug, then I think this is an easy fix and can be pushed to unstable patch.
Hi sony123 !!!
I have updated my full patch with your latest discover in section Unstable ;-)
That came at the right time, Thursday 26 July I go holidays to the south west of France, the travel is 776 Km long ...
I have updated my full patch with your latest discover in section Unstable ;-)
A++
Hi colin.stephane
I think you got carried away with the commenting!
The unstable patch as-is doesn't work. You commented out the definition for the variable distTime at the same time as the 'sanity-check'. If that is left in there it seems to work - at least trying to navigate 700km on my sofa!
I found that the return value of Units.getReadableTime(duration) can be in "hr:min" format. This confuses the if (readableDuration.value > 0) loop. Commenting out the sanity checking makes the time display correctly.
Using duration (the raw ttd in seconds) instead of readableDuration.value works as well, and still displays "-" if there is e.g. no GPS lock, as is shows for distance (otherwise you get "-" for distance and "-1" or "0" for ttd, which looks odd).
The unstable patch as-is doesn't work. You commented out the definition for the variable distTime at the same time as the 'sanity-check'. If that is left in there it seems to work - at least trying to navigate 700km on my sofa!
WOOPS !!!
Sorry for MY mistake ...
Well this forced me to reread the thread and find also the fix for the blank map, by reverting a mbanck patch ...
Anyhow, as usual, I have modified my full patch with mbanck patch revert on post #198 and added also the fix he provided on post #226 in the Unstable patch section.
Did you install patch (it's an application)?
Did you insert the right destination to your diff file?
Put your diff file in MyDocs or any subfolder (like Documents or Downloads), but not above MyDocs.