summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAndrea Diamantini <adjam7@gmail.com>2009-03-24 17:43:34 +0100
committerAndrea Diamantini <adjam7@gmail.com>2009-03-24 17:43:34 +0100
commit1132e1a3b95726f0e2da5c361524eff6c59df1ee (patch)
tree731dfe0b96dbfd77c85ce139d99d448f9ad148d7 /src
parentSome fixes on font dim. Updating data still doesn't work.. (diff)
downloadrekonq-1132e1a3b95726f0e2da5c361524eff6c59df1ee.tar.xz
Fixed notFound.html page
Diffstat (limited to 'src')
-rw-r--r--src/main.cpp4
-rw-r--r--src/webview.cpp15
2 files changed, 8 insertions, 11 deletions
diff --git a/src/main.cpp b/src/main.cpp
index 110188e4..71f5792d 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -18,18 +18,20 @@
* ============================================================ */
-
#include "application.h"
#include <KAboutData>
#include <KCmdLineArgs>
#include <KDebug>
+
static const char description[] =
I18N_NOOP("KDE Browser Webkit Based");
+
static const char version[] = "0.0.5";
+
int main(int argc, char **argv)
{
KAboutData about( "rekonq",
diff --git a/src/webview.cpp b/src/webview.cpp
index 0b981633..da286ee8 100644
--- a/src/webview.cpp
+++ b/src/webview.cpp
@@ -160,22 +160,17 @@ void WebPage::handleUnsupportedContent(QNetworkReply *reply)
QFile file( myfilestr );
bool isOpened = file.open(QIODevice::ReadOnly);
Q_ASSERT(isOpened);
+
QString title = i18n("Error loading page: ") + reply->url().toString();
+
+ QString imagePath = KIconLoader::global()->iconPath( "rekonq", KIconLoader::NoGroup, false);
+
QString html = QString(QLatin1String(file.readAll()))
.arg(title)
+ .arg("file://" + imagePath)
.arg(reply->errorString())
.arg(reply->url().toString());
- QBuffer imageBuffer;
- imageBuffer.open(QBuffer::ReadWrite);
- QIcon icon = view()->style()->standardIcon(QStyle::SP_MessageBoxWarning, 0, view());
- QPixmap pixmap = icon.pixmap(QSize(32,32));
- if (pixmap.save(&imageBuffer, "PNG"))
- {
- html.replace(QLatin1String("IMAGE_BINARY_DATA_HERE"),
- QString(QLatin1String(imageBuffer.buffer().toBase64())));
- }
-
QList<QWebFrame*> frames;
frames.append(mainFrame());
while (!frames.isEmpty())