Skip to content

Commit

Permalink
Fix display corruption inherited from transmission-remote-cli
Browse files Browse the repository at this point in the history
While in torrent details sections top area of any section of an actively
downloading torrent will be corrupted when hitting 'v' to verify torrent
Also occurs in non-compact mode

Introduced in d9a542f

Signed-off-by: Loui Chang <louipc.ist@gmail.com>
  • Loading branch information
louipc committed Nov 17, 2016
1 parent 65d0fe6 commit 14bb933
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions tremc
Original file line number Diff line number Diff line change
Expand Up @@ -1434,7 +1434,7 @@ class Interface(object):
def verify_torrent(self, c):
if self.focus > -1:
if self.torrents[self.focus]['status'] != Transmission.STATUS_CHECK \
and self.torrents[self.focus]['status'] != Transmission.STATUS_CHECK_WAIT:
and self.torrents[self.focus]['status'] != Transmission.STATUS_CHECK_WAIT:
server.verify_torrent(self.torrents[self.focus]['id'])

def reannounce_torrent(self, c):
Expand Down Expand Up @@ -1965,7 +1965,7 @@ class Interface(object):
if torrent['isIsolated']:
color = curses.color_pair(self.colors.id('title_error'))
elif torrent['status'] == Transmission.STATUS_SEED or \
torrent['status'] == Transmission.STATUS_SEED_WAIT:
torrent['status'] == Transmission.STATUS_SEED_WAIT:
color = curses.color_pair(self.colors.id('title_seed'))
elif torrent['status'] == Transmission.STATUS_STOPPED:
color = curses.color_pair(self.colors.id('title_paused'))
Expand Down Expand Up @@ -2016,7 +2016,7 @@ class Interface(object):
parts[0] = [te for te in tracker_errors if te][0]
else:
if torrent['status'] == Transmission.STATUS_CHECK:
parts[0] += " (%.2f%%)" % float(torrent['recheckProgress']) * 100
parts[0] += " (%.2f%%)" % (torrent['recheckProgress'] * 100)
elif torrent['status'] == Transmission.STATUS_DOWNLOAD:
parts[0] += " (%.2f%%)" % torrent['percentDone']
parts[0] = parts[0].ljust(20)
Expand Down

0 comments on commit 14bb933

Please sign in to comment.