blizzard4591 / openMittsu

An open source implementation and desktop client of the Threema Messenger App.
Other
175 stars 23 forks source link

Use proper paths for storing user data/config #49

Closed rugk closed 5 years ago

rugk commented 5 years ago

Ref https://threema-forum.de/thread-2024-post-43299.html#pid43299

In short:

blizzard4591 commented 5 years ago

What files are currently the problem? For the log files, I use QStandardPaths::StandardLocation const location = QStandardPaths::AppLocalDataLocation;

to build the proper path. I hope this works. If not, an error message should be displayed through std::cerr. For the settings, I use the default constructor for QSettings() (https://doc.qt.io/qt-5/qsettings.html) and that seems to imply the NativeFormat, which on Windows is the registry. On my machine, my options are saved under HKEY_CURRENT_USER\Software\openMittsu\OpenMittsu\options. This should not require admin rights.

I will look into this more, but if you have a pointer or ideas what the problem might be, that would be nice.

Also: Is Native/registry not a good choice? Sure, for portable maybe not, but storing them locally next to the binary is even worse for UAC.

rugk commented 5 years ago

Okay, so actually looks good. Just wonder why the forum user had issues then. So probably better discuss/debug this in the forum thread.