Fix WebKitElement._move_text_cursor with old PyQt

This commit is contained in:
Florian Bruhin 2017-03-01 20:19:40 +01:00
parent 1f12b4c1c1
commit f4490fb90c

View File

@ -291,6 +291,9 @@ class WebKitElement(webelem.AbstractWebElement):
elem = elem._parent() # pylint: disable=protected-access
def _move_text_cursor(self):
if self is None:
# old PyQt versions call the slot after the element is deleted.
return
if self.is_text_input() and self.is_editable():
self._tab.caret.move_to_end_of_document()