sailfishos-applications / filecase

File manager for SailfishOS
Other
8 stars 4 forks source link

use home folder of current user #46

Closed simonschmeisser closed 8 months ago

simonschmeisser commented 8 months ago

closes #15

This should return the current users home directory instead of hard coding it.

https://doc.qt.io/qt-5/qstandardpaths.html

`QDir::homePath would be another alternative

(not actually tested)

Olf0 commented 8 months ago

@simonschmeisser, thank you very much.

This should return the current users home directory instead of hard coding it.

Originally I thought it would be nice, if users can set the Phone memory path to anything they like: which is already the case, but not yet via a UI dialogue.

But yesterday, when reading the criticism at FSO, I already considered to automatically set it to the user's homedir. As you have come to this conclusion independently and provided a PR implementing this, this will be the way to go. Probably this is the best solution, because one line of thinking (which should not be followed too strictly) is, that a configuration option is just a programmers easy way out, when unsure which default value to set.

P.S.: I will try to remember to make another RC release next weekend, because I am away for the upcoming week. If I forget or miss to carry out this plan, feel free to remind me.

simonschmeisser commented 8 months ago

Maybe the best solution would be to use the home dir as default and let users change it if desired. I say maybe because I haven't actually used this app just thought this should be easy to fix and went for it