summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrea Diamantini <adjam7@gmail.com>2009-04-09 18:46:46 +0200
committerAndrea Diamantini <adjam7@gmail.com>2009-04-09 18:46:46 +0200
commit4de5fd991b2a797e8644c581db6fe41cc4791735 (patch)
treef667dba6d1e2740b45e9cc83964528612bff9559
parentpedantic (diff)
downloadrekonq-4de5fd991b2a797e8644c581db6fe41cc4791735.tar.xz
Removed unuseful lasttabclosed signal in mainview.
This becamed unuseful because of choose to do nothing if just 1 tab opened.
-rw-r--r--src/mainview.cpp2
-rw-r--r--src/mainview.h1
-rw-r--r--src/mainwindow.cpp13
3 files changed, 8 insertions, 8 deletions
diff --git a/src/mainview.cpp b/src/mainview.cpp
index 80738cfd..604cb7cd 100644
--- a/src/mainview.cpp
+++ b/src/mainview.cpp
@@ -523,8 +523,6 @@ void MainView::closeTab(int index)
emit tabsChanged();
if (hasFocus && count() > 0)
currentWebView()->setFocus();
- if (count() == 0)
- emit lastTabClosed();
showTabBar();
}
diff --git a/src/mainview.h b/src/mainview.h
index f7e1bbb9..41543b65 100644
--- a/src/mainview.h
+++ b/src/mainview.h
@@ -60,7 +60,6 @@ signals:
// tab widget signals
void loadUrlPage(const KUrl &url);
void tabsChanged();
- void lastTabClosed();
// current tab signals
void setCurrentTitle(const QString &url);
diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp
index 249dd389..c074d667 100644
--- a/src/mainwindow.cpp
+++ b/src/mainwindow.cpp
@@ -87,21 +87,24 @@ MainWindow::MainWindow()
// setting size policies
setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
- // connect signals and slots
+ // --------- connect signals and slots
connect(m_view, SIGNAL(loadUrlPage(const KUrl &)), this, SLOT(loadUrl(const KUrl &)));
connect(m_view, SIGNAL(setCurrentTitle(const QString &)), this, SLOT(slotUpdateWindowTitle(const QString &)));
- connect(m_view, SIGNAL(showStatusBarMessage(const QString&)), statusBar(), SLOT(showMessage(const QString&)));
- connect(m_view, SIGNAL(linkHovered(const QString&)), statusBar(), SLOT(showMessage(const QString&)));
connect(m_view, SIGNAL(loadProgress(int)), this, SLOT(slotLoadProgress(int)));
connect(m_view, SIGNAL(geometryChangeRequested(const QRect &)), this, SLOT(geometryChangeRequested(const QRect &)));
connect(m_view, SIGNAL(printRequested(QWebFrame *)), this, SLOT(printRequested(QWebFrame *)));
connect(m_view, SIGNAL(menuBarVisibilityChangeRequested(bool)), menuBar(), SLOT(setVisible(bool)));
connect(m_view, SIGNAL(statusBarVisibilityChangeRequested(bool)), statusBar(), SLOT(setVisible(bool)));
- connect(m_view, SIGNAL(lastTabClosed()), m_view, SLOT(newWebView()));
+ // status bar message
+ connect(m_view, SIGNAL(showStatusBarMessage(const QString&)), statusBar(), SLOT(showMessage(const QString&)));
+ connect(m_view, SIGNAL(linkHovered(const QString&)), statusBar(), SLOT(showMessage(const QString&)));
+
+ // update toolbar actions
connect(m_view, SIGNAL(tabsChanged()), this, SLOT(slotUpdateActions()));
connect(m_view, SIGNAL(currentChanged(int)), this, SLOT(slotUpdateActions()));
-
+ // --------------------------------------
+
slotUpdateWindowTitle();
// then, setup our actions