Refactoring the monochrome stuff

This commit is contained in:
Michael Lazar
2017-09-11 00:30:18 -04:00
parent a208a6764a
commit 9af4b8c709
11 changed files with 110 additions and 185 deletions

View File

@@ -174,12 +174,15 @@ def main():
try:
with curses_session() as stdscr:
if config['theme']:
theme = Theme.from_name(config['theme'], config['monochrome'])
else:
theme = Theme(monochrome=config['monochrome'])
term = Terminal(stdscr, config)
if config['theme']:
theme = Theme.from_name(config['theme'])
else:
theme = None
term.set_theme(theme, monochrome=config['monochrome'])
term = Terminal(stdscr, config, theme)
with term.loader('Initializing', catch_exception=False):
reddit = praw.Reddit(user_agent=user_agent,