Skip to content

Commit

Permalink
Tweaks to status boosting in curses app
Browse files Browse the repository at this point in the history
  • Loading branch information
ihabunek committed Feb 14, 2019
1 parent c6bc4a6 commit d7cc97d
Showing 1 changed file with 10 additions and 5 deletions.
15 changes: 10 additions & 5 deletions toot/ui/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@ def footer_lines(self, status):
yield "Boosted by @{}".format(acct), Color.GREEN

if status['reblogged']:
yield "↷", Color.CYAN
yield "↷ Boosted", Color.CYAN

def draw(self, status):
self.window.erase()
Expand Down Expand Up @@ -293,7 +293,7 @@ def get_content(self):
" j or ↓ - move down",
" k or ↑ - move up",
" v - view current toot in browser",
" b - toggle boost/reblog status",
" b - toggle boost status",
" q - quit application",
" s - show sensitive content"
"",
Expand Down Expand Up @@ -391,12 +391,17 @@ def toggle_reblog(self):
return
status_id = status['id']
if status['reblogged']:
action = 'unreblogged'
status['reblogged'] = False
self.footer.draw_message("Unboosting status...", Color.YELLOW)
api.unreblog(app, user, status_id)
self.footer.draw_message("✓ Status unboosted", Color.GREEN)
else:
action = 'reblogged'
status['reblogged'] = True
self.footer.draw_message("Boosting status...", Color.YELLOW)
api.reblog(app, user, status_id)
self.footer.draw_message("Status {}".format(action), Color.GREEN)
self.footer.draw_message("✓ Status boosted", Color.GREEN)

self.right.draw(status)

def select_previous(self):
"""Move to the previous status in the timeline."""
Expand Down

0 comments on commit d7cc97d

Please sign in to comment.