Simplify code

The result from `self.add_os_window()` is overwritten later and not used
between the two assignments, so I removed the first assignment and moved the second
assignment to the line after the call to `self.add_os_window()`.
This commit is contained in:
Luflosi 2019-06-05 17:26:52 +02:00
parent 03003d270e
commit 7f01e758b3
No known key found for this signature in database
GPG Key ID: 14140F703B7D8362

View File

@ -135,13 +135,13 @@ def __init__(self, os_window_id, opts, args, cached_values, new_os_window_trigge
if new_os_window_trigger is not None:
self.keymap.pop(new_os_window_trigger, None)
for startup_session in startup_sessions:
os_window_id = self.add_os_window(startup_session, os_window_id=os_window_id)
self.add_os_window(startup_session, os_window_id=os_window_id)
os_window_id = None
if args.start_as != 'normal':
if args.start_as == 'fullscreen':
self.toggle_fullscreen()
else:
change_os_window_state(args.start_as)
os_window_id = None
if is_macos:
from .fast_data_types import cocoa_set_notification_activated_callback
cocoa_set_notification_activated_callback(self.notification_activated)