Skip to content

Commit

Permalink
离线下载失败红色标识
Browse files Browse the repository at this point in the history
  • Loading branch information
chliny committed Sep 27, 2013
1 parent 3a728c2 commit 6a1f6a3
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion xfdown.py
Original file line number Diff line number Diff line change
Expand Up @@ -203,6 +203,7 @@ def getfilename_url(self,url):
else:
filename=url.split("/")[-1]
return filename.split("?")[0]

def __getlogin(self):
self.__request(url ="http://lixian.qq.com/handler/lixian/check_tc.php",data={},savecookie=True)
urlv = 'http://lixian.qq.com/handler/lixian/do_lixian_login.php'
Expand Down Expand Up @@ -258,8 +259,10 @@ def __getlist(self):
break
size="%.1f%s"%(size,_dw)
out="%d\t%s\t%s%%\t%s"%(num+1,size,percent,_(self.filename[num]))
if index["dl_status"] == 7:
out=u"\033[41m%s 下载失败!\033[m"%out
if num % 2==0 and os.name=='posix':
out="\033[47m%s\033[m"%out
out=u"\033[47m%s\033[m"%out

_print (out)
_print ("=======================END=========================\n")
Expand Down

0 comments on commit 6a1f6a3

Please # to comment.