From eb52521b43669aab1c38ab9872a53386b776662d Mon Sep 17 00:00:00 2001 From: Andrea Diamantini Date: Tue, 13 Apr 2010 03:01:42 +0200 Subject: This commit is (quite) last in the urlbar encodings fix series. It fixes: BUG: 233159 BUG: 234168 Moreover it "cleans" road to fix (not yet, but we are near..) another bug CCBUG: 230771 at least from the rekonq side. Changes in there - cleaning and fixing filterurljob class (responsible for the encodings) - using urls instead of strings in the resolver class (work with right data..) - letting first box appearance without item selection and adding one signal to use the filterurljob class directly. --- src/urlbar/urlbar.cpp | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) (limited to 'src/urlbar/urlbar.cpp') diff --git a/src/urlbar/urlbar.cpp b/src/urlbar/urlbar.cpp index 3b79b06b..5423e5d0 100644 --- a/src/urlbar/urlbar.cpp +++ b/src/urlbar/urlbar.cpp @@ -74,6 +74,7 @@ UrlBar::UrlBar(QWidget *parent) // suggestions installEventFilter(_box); connect(_box, SIGNAL(chosenUrl(const KUrl &, Rekonq::OpenType)), SLOT(activated(const KUrl &, Rekonq::OpenType))); + connect(_box, SIGNAL(loadTypedUrl()), this, SLOT(activated())); } @@ -108,8 +109,16 @@ void UrlBar::activated(const KUrl& url, Rekonq::OpenType type) disconnect(this, SIGNAL(textChanged(const QString &)), this, SLOT(suggestUrls(const QString &))); clearFocus(); - setUrl(url); - Application::instance()->loadUrl(url, type); + KUrl loadingUrl; + + if(url.isEmpty()) + loadingUrl = KUrl(text()); + else + loadingUrl = url; + + setUrl(loadingUrl); + + Application::instance()->loadUrl(loadingUrl, type); } -- cgit v1.2.1