REPRODUCIBILITY (% or how often): 100%
BUILD ID = OS VERSION (Settings > About product): 4.3.0.12
HARDWARE (XA2, X10, X10 II, …): Volla phone GS290
UI LANGUAGE: en_US, de_DE
REGRESSION: (compared to previous public release: Yes, No, ?): yes
DESCRIPTION:
I maintain/develope scribble. It utilizes a filepicker to obtain a path to save to:
Component {
id: savePickerPage
ImagePickerPage {
onSelectedContentPropertiesChanged: {
savePath = selectedContentProperties.filePath
}
}
}
which is used from a js function:
onClicked: {
toolSaveVisible = false;
pageStack.push(savePickerPage)
idImage.grabToImage(function(image) {
image.saveToFile( savePath + fileName + ".png" )
})
}
This worked in 3.4. It no longer works. I’m in the process of getting this sailjail conforming.
PRECONDITIONS:
Create a ImagePickerPage to obtain a path.
Attempt to save to that path.
STEPS TO REPRODUCE:
- Open scribble app
- Scribble
- Save the image
- Open gallery
- See that the image is ‘Oops, cannot display image’
EXPECTED RESULT:
Image saves. Gallery displays.
ACTUAL RESULT:
The file IS saved, but to /home/defaultuser (even after applying sailjail config). Push it from ~ to Pictures and the image can be displayed.
ADDITIONAL INFORMATION:
I’m guessing this has something to do with Standardpaths and Sailjail.
When debugging (with QML live feedback), if I initially set savepath like so:
property var savePath : StandardPaths.home + '/Pictures/'
then
pageStack.push(savePickerPage)
if (debug) console.debug(savePath)
idImage.grabToImage(function(image) {
image.saveToFile( savePath + fileName + ".png" )
})
yields:
onClicked:885 - /home/defaultuser/Pictures/
onSelectedContentPropertiesChanged:82 - /home/defaultuser/Pictures/
And the picture saves to gallery (after the filepicker shows me the directory)
For now, I’ve just disabled the picker and save to ~/Pictures.