mirror of
https://github.com/robweber/xbmcbackup.git
synced 2025-06-23 19:14:33 +02:00
moved when progress bar first displays so you know the addon is doing something
This commit is contained in:
12
default.py
12
default.py
@ -87,7 +87,7 @@ class XbmcBackup:
|
||||
#for the progress bar
|
||||
progressBar = None
|
||||
filesLeft = 0
|
||||
filesTotal = 0
|
||||
filesTotal = 1
|
||||
|
||||
fileManager = None
|
||||
|
||||
@ -112,6 +112,11 @@ class XbmcBackup:
|
||||
self.log('Remote Dir: ' + self.remote_path)
|
||||
|
||||
def run(self):
|
||||
#check if we should use the progress bar
|
||||
if(self.Addon.getSetting('run_silent') == 'false'):
|
||||
self.progressBar = xbmcgui.DialogProgress()
|
||||
self.progressBar.create('XBMC Backup','Gathering file list.....')
|
||||
|
||||
#check what mode were are in
|
||||
if(int(self.Addon.getSetting('addon_mode')) == 0):
|
||||
self.syncFiles()
|
||||
@ -149,11 +154,6 @@ class XbmcBackup:
|
||||
self.filesTotal = len(fileList)
|
||||
self.filesLeft = self.filesTotal
|
||||
|
||||
#check if we should use the progress bar
|
||||
if(self.Addon.getSetting('run_silent') == 'false'):
|
||||
self.progressBar = xbmcgui.DialogProgress()
|
||||
self.progressBar.create('XBMC Backup','Running......')
|
||||
|
||||
#write each file from source to destination
|
||||
for aFile in fileList:
|
||||
if(not self.checkCancel()):
|
||||
|
Reference in New Issue
Block a user