Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Fix timing of progress dialog.

  • Loading branch information...
commit 1663967cc64874eba18e49b2cd76f49014df8b22 1 parent c659130
@Giftie authored
View
2  addon.xml
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<addon id="script.cdartmanager"
name="cdART Manager"
- version="2.5.6"
+ version="2.5.7"
provider-name="Giftie">
<requires>
<import addon="xbmc.python" version="2.0"/>
View
3  changelog.txt
@@ -1,3 +1,6 @@
+2.5.7
+- fixed timing of Progress Dialog, fixed hang with XBMC using 12.1
+
2.5.6
- fixed script requiring the back up folder to be set(unless actually when trying to back up) - Thanks Martijn
- fixed progress dialog 'flash' - Thanks Martijn
View
4 default.py
@@ -20,8 +20,8 @@
__author__ = __addon__.getAddonInfo('author')
__version__ = __addon__.getAddonInfo('version')
__credits__ = "Ppic, Reaven, Imaginos, redje, Jair, "
-__credits2__ = "Chaos_666, Magnatism, Kode"
-__date__ = "4-30-12"
+__credits2__ = "Chaos_666, Magnatism, Kode, Martijn"
+__date__ = "5-6-12"
__dbversion__ = "1.5.3"
__dbversionold__ = "1.3.2"
__dbversionancient__ = "1.1.8"
View
12 resources/lib/download.py
@@ -98,6 +98,11 @@ def download_art( url_cdart, album, type, mode, size ):
xbmc.log( "[script.cdartmanager] - Downloading artwork... ", xbmc.LOGDEBUG )
download_success = False
percent = 1
+ try:
+ pDialog.update( percent )
+ except:
+ pDialog.create( _(32047) )
+ #Onscreen Dialog - "Downloading...."
file_name = get_filename( type, url_cdart, mode )
if file_name == "unknown":
xbmc.log( "[script.cdartmanager] - Unknown Type ", xbmc.LOGDEBUG )
@@ -115,19 +120,12 @@ def download_art( url_cdart, album, type, mode, size ):
destination = os.path.join( addon_work_folder , file_name).replace( "\\\\","\\" ) # download to work folder first
final_destination = os.path.join( path, file_name ).replace( "\\\\","\\" )
try:
- pDialog.update( percent )
- except:
- pDialog.create( _(32047) )
- #Onscreen Dialog - "Downloading...."
- try:
#this give the ability to use the progress bar by retrieving the downloading information
#and calculating the percentage
def _report_hook( count, blocksize, totalsize ):
percent = int( float( count * blocksize * 100 ) / totalsize )
if percent < 0:
precent = 1
- if percent > 100:
- percent = 100
strProgressBar = str( percent )
if type == "fanart" or type == "clearlogo":
pDialog.update( percent, "%s%s" % ( _(32038) , get_unicode( album["artist"] ) ) )
Please sign in to comment.
Something went wrong with that request. Please try again.