def restore(self):
# clear out caches prior to restore
# this prevents hanging cache data
self.playlistCache.reset()
self.cache.reset()
self.timer.reset()
# restore the channels saved from the last backup
tempTable=tables.table(_datadir+'backup/')
channels=tempTable.loadValue('backup')
# refresh all channel data for channels
for channel in channels:
# grab each channels metadata and store it
self.grabChannelMetadata(channel)
# save all channels into the cache
self.cache.saveValue(channel,list())
# refresh the view and load the popup
xbmc.executebuiltin('container.Update('+_url+',replace)')
popup('YoutubeTV','Restore of backup Complete!')
################################################################################
评论列表
文章目录