mirror of
https://invent.kde.org/network/falkon.git
synced 2024-12-20 10:46:35 +01:00
[Fix:] Going to history items from history back/forward menu in new tab
- fixed regression from 061e1e21543b3cfd323fa901992328e14a9f36d2
This commit is contained in:
parent
77e7ed55f0
commit
93e7c073d4
@ -48,7 +48,6 @@ BookmarksToolbar::BookmarksToolbar(QupZilla* mainClass, QWidget* parent)
|
||||
connect(m_bookmarksModel, SIGNAL(folderDeleted(QString)), this, SLOT(folderDeleted(QString)));
|
||||
connect(m_bookmarksModel, SIGNAL(folderRenamed(QString, QString)), this, SLOT(folderRenamed(QString, QString)));
|
||||
|
||||
|
||||
setMaximumWidth(p_QupZilla->width());
|
||||
|
||||
// QTimer::singleShot(0, this, SLOT(refreshBookmarks()));
|
||||
|
@ -261,9 +261,8 @@ void NavigationBar::goAtHistoryIndexInNewTab(int index)
|
||||
}
|
||||
|
||||
TabWidget* tabWidget = p_QupZilla->tabWidget();
|
||||
tabWidget->duplicateTab(tabWidget->currentIndex());
|
||||
int tabIndex = tabWidget->duplicateTab(tabWidget->currentIndex());
|
||||
|
||||
int tabIndex = tabWidget->count() - 1;
|
||||
QWebHistory* history = p_QupZilla->weView(tabIndex)->page()->history();
|
||||
|
||||
history->goToItem(history->itemAt(index));
|
||||
|
@ -419,7 +419,7 @@ void TabWidget::closeAllButCurrent(int index)
|
||||
}
|
||||
}
|
||||
|
||||
void TabWidget::duplicateTab(int index)
|
||||
int TabWidget::duplicateTab(int index)
|
||||
{
|
||||
QUrl url = weView(index)->url();
|
||||
QByteArray history;
|
||||
@ -429,6 +429,8 @@ void TabWidget::duplicateTab(int index)
|
||||
int id = addView(url, tabText(index), TabWidget::NewNotSelectedTab);
|
||||
QDataStream historyStream(history);
|
||||
historyStream >> *weView(id)->history();
|
||||
|
||||
return id;
|
||||
}
|
||||
|
||||
void TabWidget::restoreClosedTab()
|
||||
|
@ -68,14 +68,15 @@ signals:
|
||||
void pinnedTabAdded();
|
||||
|
||||
public slots:
|
||||
void closeTab(int index = -1);
|
||||
int addView(QUrl url = QUrl(), const QString &title = tr("New tab"), OpenUrlIn openIn = NewTab, bool selectLine = false, int position = -1);
|
||||
int duplicateTab(int index);
|
||||
|
||||
void closeTab(int index = -1);
|
||||
void reloadTab(int index) { weView(index)->reload(); }
|
||||
void reloadAllTabs();
|
||||
void stopTab(int index) { weView(index)->stop(); }
|
||||
void backTab(int index) { weView(index)->back(); }
|
||||
void forwardTab(int index) { weView(index)->forward(); }
|
||||
void duplicateTab(int index);
|
||||
void closeAllButCurrent(int index);
|
||||
void restoreClosedTab();
|
||||
void restoreAllClosedTabs();
|
||||
|
Loading…
Reference in New Issue
Block a user