From 64443a3eed021babc18041b85395e0b82ec2980d Mon Sep 17 00:00:00 2001 From: Florian Bruhin Date: Wed, 11 Oct 2017 14:38:24 +0200 Subject: [PATCH] Fix docstrings --- qutebrowser/app.py | 9 +++++---- qutebrowser/mainwindow/mainwindow.py | 1 + 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/qutebrowser/app.py b/qutebrowser/app.py index 65a052660..9b5de8e2e 100644 --- a/qutebrowser/app.py +++ b/qutebrowser/app.py @@ -301,12 +301,12 @@ def process_pos_args(args, via_ipc=False, cwd=None, target_arg=None): def open_url(url, target=None, no_raise=False, via_ipc=True): - """Open an URL in new window/tab + """Open an URL in new window/tab. Args: - url: An URL to open - target: same as new_instance_open_target (used as a default) - no_raise: suppress target window raising + url: An URL to open. + target: same as new_instance_open_target (used as a default). + no_raise: suppress target window raising. via_ipc: Whether the arguments were transmitted over IPC. Return: @@ -828,6 +828,7 @@ class Application(QApplication): self._last_focus_object = output def event(self, e): + """Handle macOS FileOpen events.""" if e.type() == QEvent.FileOpen: open_url(e.url(), no_raise=True) else: diff --git a/qutebrowser/mainwindow/mainwindow.py b/qutebrowser/mainwindow/mainwindow.py index 4918d29d6..57e540a53 100644 --- a/qutebrowser/mainwindow/mainwindow.py +++ b/qutebrowser/mainwindow/mainwindow.py @@ -95,6 +95,7 @@ def get_window(via_ipc, force_window=False, force_tab=False, def raise_window(window): + """Raise the given MainWindow object.""" window.setWindowState(window.windowState() & ~Qt.WindowMinimized) window.setWindowState(window.windowState() | Qt.WindowActive) window.raise_()