containments/desktop: fix back button

FolderView is supposed to show a back button if you navigate to a different folder in List mode. But it doesn't actually work. The problem is that the button is only shown if the history is not empty, and the history is stored in a JS array. This doesn't cause property bindings to re-evaluate, so the code contains an updateHistory function that tries to get it to do so by self-assignment. This may have worked in the past, but it no longer does.

Instead, we use the standard way of telling qml that a property changed: emitting the property's changed signal. That way we get a nice back button, and the meaning is so clear that we don't even need to wrap it in a helper function to understand what it does.

before after
folderview_back_before folderview_back_after

Merge request reports

Loading