-
Notifications
You must be signed in to change notification settings - Fork 5.7k
User preferences are not restored between sessions. #445
Description
Describe the bug
Looking at Calculator source code, it looks like we meant save a user's last selected category and units, and restore them when a calculator starts up. In other words, Calculator meant to support saving & restoring user preferences between sessions.
However, calculator is failing to restore saved units. It does restore saved category.
Steps To Reproduce
- Launch Calculator.
- Pick a category (ex> Area) and units (ex> Hectares to Acres )
- Close & re-launch Calculator.
Expected behavior
A user's last selected category and units should be restored when a calculator starts up (i.e. if you chose category Area and unit Hectares to Acres, and restarts Calculator, then Calculator should show category Area and unit Hectares to Acres ).
However, Calculator reverts back to the default units ( it does seem to restore category though ).
Screenshots
Please refer to this video.
For quick reference, refer to the below

Device and Application Information (please complete the following information):
- OS Build: 10.0.17763.0
- Architecture: X64
- Application Version: 10.1812.10048.0
Additional context
UnitConverter::RestoreUserPreferences()is working correctly.UnitConverter::SaveUserPreferences()is working correctly.- However, after restoring saved values on Calculator startup, Something is overriding the restored value to the default value.
Note: I would like to tackle this one and make a PR 🙂 if this issue gets accepted.