diff options
Diffstat (limited to 'src/application.cpp')
-rw-r--r-- | src/application.cpp | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/src/application.cpp b/src/application.cpp index 98b8d870..3817098d 100644 --- a/src/application.cpp +++ b/src/application.cpp @@ -298,7 +298,7 @@ void Application::loadUrl(const KUrl& url, const Rekonq::OpenType& type) { loadingUrl = data.uri().url(); } - + if ( !KProtocolInfo::isKnownProtocol( loadingUrl ) ) { KMessageBox::error(0, i18n("Protocol not supported\n%1", url.protocol())); @@ -306,25 +306,29 @@ void Application::loadUrl(const KUrl& url, const Rekonq::OpenType& type) } WebView *webView; - + switch(type) { case Rekonq::SettingOpenTab: webView = m_mainWindow->mainView()->newTab(!ReKonfig::openTabsBack()); + if (!ReKonfig::openTabsBack()) + { + m_mainWindow->mainView()->currentUrlBar()->setUrl(loadingUrl.prettyUrl()); + } break; case Rekonq::NewCurrentTab: webView = m_mainWindow->mainView()->newTab(true); + m_mainWindow->mainView()->currentUrlBar()->setUrl(loadingUrl.prettyUrl()); break; case Rekonq::NewBackTab: webView = m_mainWindow->mainView()->newTab(false); break; case Rekonq::CurrentTab: webView = m_mainWindow->mainView()->currentWebView(); + m_mainWindow->mainView()->currentUrlBar()->setUrl(loadingUrl.prettyUrl()); break; }; - m_mainWindow->mainView()->currentUrlBar()->setUrl(loadingUrl.prettyUrl()); - if (webView) { webView->setFocus(); |