This commit is contained in:
zhuzichu
2023-07-24 18:23:26 +08:00
parent db805ef85d
commit be7b2dcc34
4 changed files with 67 additions and 21 deletions

View File

@ -11,10 +11,6 @@ FluScrollablePage{
title:"Http"
Component.onDestruction: {
console.debug("T_Http -> onDestruction")
}
FluHttp{
id:http_get
url:"https://api.github.com/search/repositories"
@ -60,7 +56,7 @@ FluScrollablePage{
FluHttp{
id:http_download
url:"http://clips.vorwaerts-gmbh.de/big_buck_bunny.mp4"
// url:"https://www.w3school.com.cn/example/html5/mov_bbb.mp4"
// url:"https://www.w3school.com.cn/example/html5/mov_bbb.mp4"
onStart: {
btn_download.disabled = true
}
@ -119,7 +115,7 @@ FluScrollablePage{
id: file_dialog
currentFolder: StandardPaths.standardLocations(StandardPaths.DownloadLocation)[0]
onAccepted: {
var path = currentFolder.toString().replace(FluTools.isMacos() ? "file://" : "file:///","") + "/big_buck_bunny.mp4"
var path = FluTools.toLocalPath(currentFolder)+ "/big_buck_bunny.mp4"
http_download.download(path)
}
}
@ -131,7 +127,6 @@ FluScrollablePage{
height: 400
Item{
anchors.fill: parent
Flickable{
id:scrollview
width: parent.width
@ -149,7 +144,4 @@ FluScrollablePage{
}
}
}
}