コード例 #1
0
    // Update is called once per frame
    void OnGUI()
    {
        fileUrlForDownload = GUILayout.TextField(fileUrlForDownload);
        fromDisk           = GUILayout.Toggle(fromDisk, "From Disk");
        if (GUILayout.Button("Download"))
        {
            downloader.Download(fileUrlForDownload, true, fromDisk);
        }
        GUILayout.Label("\n======================================\n");
        fileUrlForUpload = GUILayout.TextField(fileUrlForUpload);
        if (GUILayout.Button("Upload File"))
        {
            UploadFile(fileUrlForUpload);
        }

        GUILayout.Label(percentage.ToString());
    }
コード例 #2
0
 public void DownloadFromUrl()
 {
     downloader.Download(url, true, false);
     progressBar.SetActive(true);
 }
コード例 #3
0
        public JsonResult DownloadFile(string path)
        {
            UploadAndDownload.Download(path);

            return(Json(JsonRequestBehavior.AllowGet));
        }