From 8946eecd22b4810dea452dafa4e0e2f8e55c573c Mon Sep 17 00:00:00 2001 From: Andrea Diamantini Date: Mon, 21 Mar 2011 22:26:48 +0100 Subject: Workaround the troubles with the tabbar highlight feature. Another fantastic patch by Johannes Trosher. Thanks :) CCBUG:267234 --- src/mainview.cpp | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'src/mainview.cpp') diff --git a/src/mainview.cpp b/src/mainview.cpp index bf99010e..a0f05ccd 100644 --- a/src/mainview.cpp +++ b/src/mainview.cpp @@ -56,6 +56,8 @@ #include #include +//Hack: +QString temporaryUglyHackString = ""; MainView::MainView(MainWindow *parent) : KTabWidget(parent) @@ -310,11 +312,13 @@ WebTab *MainView::newWebTab(bool focused) if (ReKonfig::openTabsNearCurrent()) { insertTab(currentIndex() + 1, tab, i18n("(Untitled)")); + temporaryUglyHackString = tabText(currentIndex() + 1); m_widgetBar->insertWidget(currentIndex() + 1, tab->urlBar()); } else { addTab(tab, i18n("(Untitled)")); + temporaryUglyHackString = tabText(count() - 1); m_widgetBar->addWidget(tab->urlBar()); } updateTabBar(); @@ -589,7 +593,8 @@ void MainView::webViewTitleChanged(const QString &title) } else { - tabBar()->setTabHighlighted(index); + if (tabTitle != temporaryUglyHackString) + tabBar()->setTabHighlighted(index); } rApp->historyManager()->updateHistoryEntry(tab->url(), tabTitle); if (ReKonfig::hoveringTabOption() == 1) -- cgit v1.2.1