Change defaultSaveLocation to use QUrl
Summary:
There were two issues with the default save lcoation. First the url passed to
QFileDialog was missing the "file://" prefix and the file dialog would open in
the working directory of the application (usually /). The second issue hidden
by this was that the last part of the path (~/Pictures) was removed because it
was returned through functions which expect file paths and trim them to get a
path to a folder. To avoid this a slash is added to the path.
BUG: 406058
Test Plan:
Open Spectacle with a fresh user or delete lines related to save paths from
your spectaclerc. Clicking on "Save as..." should open the dialog in
~/Pictures.
Reviewers: Spectacle, ngraham
Reviewed By: Spectacle, ngraham
Subscribers: ngraham, broulik
Tags: Spectacle
Differential Revision: https://phabricator.kde.org/D21556