From 3a5b99104288d292dc3ab2935617268f335cd455 Mon Sep 17 00:00:00 2001 From: Karol Kosek Date: Mon, 11 Jan 2021 19:08:48 +0100 Subject: Replace history on redirect --- src/tabbrowsinghistory.cpp | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/tabbrowsinghistory.cpp') diff --git a/src/tabbrowsinghistory.cpp b/src/tabbrowsinghistory.cpp index 5f2cba4..5cb03ae 100644 --- a/src/tabbrowsinghistory.cpp +++ b/src/tabbrowsinghistory.cpp @@ -30,6 +30,11 @@ QModelIndex TabBrowsingHistory::pushUrl(QModelIndex const & position, const QUrl return this->createIndex(this->history.size() - 1, 0); } +void TabBrowsingHistory::replaceUrl(size_t const position, QUrl const & url) +{ + this->history.replace(position, url); +} + QUrl TabBrowsingHistory::get(const QModelIndex &index) const { if(not index.isValid()) -- cgit v1.2.3