summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/mainwindow.cpp20
-rw-r--r--src/webpage.cpp19
-rw-r--r--src/webpage.h2
-rw-r--r--src/webpluginfactory.cpp8
-rw-r--r--src/webpluginfactory.h1
5 files changed, 34 insertions, 16 deletions
diff --git a/src/mainwindow.cpp b/src/mainwindow.cpp
index 68469cdd..6a17d1b8 100644
--- a/src/mainwindow.cpp
+++ b/src/mainwindow.cpp
@@ -1009,12 +1009,19 @@ void MainWindow::openPrevious(Qt::MouseButtons btn)
QWebHistory *history = currentTab()->view()->history();
if (history->canGoBack())
{
- KUrl back = history->backItem().url();
if(btn == Qt::MidButton)
+ {
+ KUrl back = history->backItem().url();
Application::instance()->loadUrl(back, Rekonq::SettingOpenTab);
+ }
else
- Application::instance()->loadUrl(back);
+ {
+ history->goToItem(history->backItem());
+ }
+
+ updateActions();
}
+
}
@@ -1023,11 +1030,16 @@ void MainWindow::openNext(Qt::MouseButtons btn)
QWebHistory *history = currentTab()->view()->history();
if (history->canGoForward())
{
- KUrl next = history->forwardItem().url();
if(btn == Qt::MidButton)
+ {
+ KUrl next = history->forwardItem().url();
Application::instance()->loadUrl(next, Rekonq::SettingOpenTab);
+ }
else
- Application::instance()->loadUrl(next);
+ {
+ history->goToItem(history->forwardItem());
+ }
+ updateActions();
}
}
diff --git a/src/webpage.cpp b/src/webpage.cpp
index 06e733b0..71cc8be4 100644
--- a/src/webpage.cpp
+++ b/src/webpage.cpp
@@ -271,9 +271,22 @@ void WebPage::handleUnsupportedContent(QNetworkReply *reply)
}
}
// case KParts::BrowserRun::Embed
- KUrl::List list;
- list.append(url);
- KRun::run(*offer,url,0);
+ QString html;
+ html += "<html>";
+ html += "<head>";
+ html += "<title>";
+ html += url.pathOrUrl();
+ html += "</title>";
+ html += "<style type=\"text/css\">";
+ html += "* { border: 0; padding: 0; margin: 0; }";
+ html += "</style>";
+ html += "</head>";
+ html += "<body>";
+ html += "<embed src=\"" + url.pathOrUrl() + "\" width=\"100%\" height=\"100%\" />";
+ html += "</body>";
+ html += "</html>";
+
+ mainFrame()->setHtml(html, url);
}
}
diff --git a/src/webpage.h b/src/webpage.h
index a3e58dc1..abc9833c 100644
--- a/src/webpage.h
+++ b/src/webpage.h
@@ -80,7 +80,7 @@ private slots:
private:
QString errorPage(QNetworkReply *);
-
+
ProtocolHandler _protHandler;
WebSslInfo _sslInfo;
};
diff --git a/src/webpluginfactory.cpp b/src/webpluginfactory.cpp
index 9e4b8ba3..79a36aa0 100644
--- a/src/webpluginfactory.cpp
+++ b/src/webpluginfactory.cpp
@@ -47,12 +47,6 @@ WebPluginFactory::WebPluginFactory(QObject *parent)
}
-WebPluginFactory::~WebPluginFactory()
-{
-}
-
-
-
void WebPluginFactory::setLoadClickToFlash(bool load)
{
_loadClickToFlash = load;
@@ -69,7 +63,7 @@ QObject *WebPluginFactory::create(const QString &mimeType,
switch( ReKonfig::pluginsEnabled() )
{
case 0:
- kDebug() << "No plugins found for" << mimeType << ". Falling back to QtWebKit ones...";
+ kDebug() << "No plugins found for" << mimeType << ". Falling back to KDEWebKit ones...";
return KWebPluginFactory::create(mimeType, url, argumentNames, argumentValues);
case 1:
diff --git a/src/webpluginfactory.h b/src/webpluginfactory.h
index 9e5028b2..85122d56 100644
--- a/src/webpluginfactory.h
+++ b/src/webpluginfactory.h
@@ -46,7 +46,6 @@ Q_OBJECT
public:
WebPluginFactory(QObject *parent);
- ~WebPluginFactory();
virtual QObject *create(const QString &mimeType,
const QUrl &url,