Log load status changes
This commit is contained in:
parent
70214bfedf
commit
480e222d6d
@ -30,6 +30,7 @@ import qutebrowser.config.config as config
|
|||||||
import qutebrowser.keyinput.modeman as modeman
|
import qutebrowser.keyinput.modeman as modeman
|
||||||
import qutebrowser.utils.message as message
|
import qutebrowser.utils.message as message
|
||||||
import qutebrowser.utils.webelem as webelem
|
import qutebrowser.utils.webelem as webelem
|
||||||
|
import qutebrowser.utils.misc as utils
|
||||||
from qutebrowser.browser.webpage import BrowserPage
|
from qutebrowser.browser.webpage import BrowserPage
|
||||||
from qutebrowser.browser.hints import HintManager
|
from qutebrowser.browser.hints import HintManager
|
||||||
from qutebrowser.utils.usertypes import NeighborList, enum
|
from qutebrowser.utils.usertypes import NeighborList, enum
|
||||||
@ -112,6 +113,10 @@ class WebView(QWebView):
|
|||||||
lambda *args: setattr(self, '_has_ssl_errors', True))
|
lambda *args: setattr(self, '_has_ssl_errors', True))
|
||||||
# FIXME find some way to hide scrollbars without setScrollBarPolicy
|
# FIXME find some way to hide scrollbars without setScrollBarPolicy
|
||||||
|
|
||||||
|
def __repr__(self):
|
||||||
|
return "WebView(url='{}')".format(
|
||||||
|
utils.elide(urlutils.urlstring(self.url()), 50))
|
||||||
|
|
||||||
@property
|
@property
|
||||||
def load_status(self):
|
def load_status(self):
|
||||||
"""Getter for load_status."""
|
"""Getter for load_status."""
|
||||||
@ -124,6 +129,8 @@ class WebView(QWebView):
|
|||||||
Emit:
|
Emit:
|
||||||
load_status_changed
|
load_status_changed
|
||||||
"""
|
"""
|
||||||
|
logging.debug("load status for {}: {}".format(
|
||||||
|
repr(self), LoadStatus[val]))
|
||||||
self._load_status = val
|
self._load_status = val
|
||||||
self.load_status_changed.emit(LoadStatus[val])
|
self.load_status_changed.emit(LoadStatus[val])
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user