This commit is contained in:
cuu 2019-08-07 15:29:39 +08:00
parent a8b3a7084c
commit 3dd659860e

View File

@ -84,7 +84,7 @@ class DownloadProcessPage(Page):
def OnExitCb(self,event):
print("DownloadProcessPage OnExitCb")
#print("DownloadProcessPage OnExitCb")
if self._Downloader == None:
return
try:
@ -97,7 +97,7 @@ class DownloadProcessPage(Page):
if self._Screen.CurPage() == self:
if self._Downloader.isFinished():
if self._Downloader.isSuccessful():
print("Success!")
print("Download Success!")
# Do something with obj.get_dest()
filename = os.path.basename(self._Downloader.get_dest())
cur_dir = os.getcwd()
@ -116,6 +116,7 @@ class DownloadProcessPage(Page):
os.system( "rm -rf " + filename)
os.chdir(cur_dir)
self.DownloadPostJob()
self.ReturnToUpLevelPage()
self._Screen.Draw()
self._Screen.SwapAndShow()
@ -162,7 +163,7 @@ class DownloadProcessPage(Page):
if len(arr) > 1:
downloaded_filename = arr[1]
try:
os.chdir(os.path.join(cur_dir,"patches",downloaded_filename)
os.chdir(os.path.join(cur_dir,"patches",downloaded_filename))
os.system("/bin/sh Run.sh")
except:
pass