diff options
Diffstat (limited to 'qutebrowser/browser/webkit/tabhistory.py')
-rw-r--r-- | qutebrowser/browser/webkit/tabhistory.py | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/qutebrowser/browser/webkit/tabhistory.py b/qutebrowser/browser/webkit/tabhistory.py index a707030d1..183ffc7a9 100644 --- a/qutebrowser/browser/webkit/tabhistory.py +++ b/qutebrowser/browser/webkit/tabhistory.py @@ -21,7 +21,7 @@ from typing import Any, List, Mapping -from PyQt5.QtCore import QByteArray, QDataStream, QIODevice, QUrl +from qutebrowser.qt.core import QByteArray, QDataStream, QIODevice, QUrl from qutebrowser.utils import qtutils @@ -50,10 +50,10 @@ def _serialize_items(items, current_idx, stream): def _serialize_item(item): data = { - 'originalURLString': item.original_url.toString(QUrl.FullyEncoded), + 'originalURLString': item.original_url.toString(QUrl.ComponentFormattingOption.FullyEncoded), 'scrollPosition': {'x': 0, 'y': 0}, 'title': item.title, - 'urlString': item.url.toString(QUrl.FullyEncoded), + 'urlString': item.url.toString(QUrl.ComponentFormattingOption.FullyEncoded), } try: data['scrollPosition']['x'] = item.user_data['scroll-pos'].x() @@ -80,7 +80,7 @@ def serialize(items): segfault! """ data = QByteArray() - stream = QDataStream(data, QIODevice.ReadWrite) + stream = QDataStream(data, QIODevice.OpenModeFlag.ReadWrite) user_data: List[Mapping[str, Any]] = [] current_idx = None |