From 969eb157c5343eae7efefb7e48a843c4ec2180b8 Mon Sep 17 00:00:00 2001 From: Andrea Diamantini Date: Fri, 17 Apr 2009 14:24:35 +0200 Subject: set (Untitled) to untitled pages.. --- src/mainview.cpp | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) (limited to 'src/mainview.cpp') diff --git a/src/mainview.cpp b/src/mainview.cpp index 185d0a41..49fa237b 100644 --- a/src/mainview.cpp +++ b/src/mainview.cpp @@ -560,15 +560,22 @@ void MainView::webViewIconChanged() void MainView::webViewTitleChanged(const QString &title) { + QString tabTitle = title; + if(title.isEmpty()) + { + tabTitle = i18n("(Untitled)"); + } WebView *webView = qobject_cast(sender()); int index = webViewIndex(webView); if (-1 != index) { - setTabText(index, title); + setTabText(index, tabTitle); } if (currentIndex() == index) - emit setCurrentTitle(title); - Application::historyManager()->updateHistoryItem(webView->url(), title); + { + emit setCurrentTitle(tabTitle); + } + Application::historyManager()->updateHistoryItem(webView->url(), tabTitle); } -- cgit v1.2.1