[SCM] WebKit Debian packaging branch, webkit-1.2, updated. upstream/1.1.90-6072-g9a69373

eric at webkit.org eric at webkit.org
Thu Apr 8 00:09:01 UTC 2010


The following commit has been merged in the webkit-1.2 branch:
commit a82ec71485f574fe3f9f0ff8585e4ee9e8a1b092
Author: eric at webkit.org <eric at webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Tue Dec 1 22:05:02 2009 +0000

    2009-12-01  Daniel Bates  <dbates at webkit.org>
    
            Reviewed by Kenneth Rohde Christiansen.
    
            https://bugs.webkit.org/show_bug.cgi?id=31898
    
            Makes QtLauncher default to the http scheme for URLs.
    
            * QtLauncher/main.cpp:
            (MainWindow::MainWindow):
            (MainWindow::changeLocation):
            (main):
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@51558 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebKit/qt/ChangeLog b/WebKit/qt/ChangeLog
index 4c5a43a..a563aaa 100644
--- a/WebKit/qt/ChangeLog
+++ b/WebKit/qt/ChangeLog
@@ -1,3 +1,16 @@
+2009-12-01  Daniel Bates  <dbates at webkit.org>
+
+        Reviewed by Kenneth Rohde Christiansen.
+
+        https://bugs.webkit.org/show_bug.cgi?id=31898
+
+        Makes QtLauncher default to the http scheme for URLs.
+
+        * QtLauncher/main.cpp:
+        (MainWindow::MainWindow):
+        (MainWindow::changeLocation):
+        (main):
+
 2009-11-30  Abhinav Mithal  <abhinav.mithal at nokia.com>
 
         Reviewed by Simon Hausmann.
diff --git a/WebKit/qt/QtLauncher/main.cpp b/WebKit/qt/QtLauncher/main.cpp
index 8ff01e9..c06d474 100644
--- a/WebKit/qt/QtLauncher/main.cpp
+++ b/WebKit/qt/QtLauncher/main.cpp
@@ -187,10 +187,11 @@ public:
             url = fi.absoluteFilePath();
 
         QUrl qurl = urlFromUserInput(url);
+        if (qurl.scheme().isEmpty())
+            qurl = QUrl("http://" + url + "/");
         if (qurl.isValid()) {
             urlEdit->setText(qurl.toEncoded());
             view->load(qurl);
-
         }
 
         // the zoom values are chosen to be like in Mozilla Firefox 3
@@ -212,11 +213,13 @@ protected slots:
     void changeLocation() {
         QString string = urlEdit->text();
         QUrl url = urlFromUserInput(string);
-        if (!url.isValid())
+        if (url.scheme().isEmpty())
             url = QUrl("http://" + string + "/");
-        urlEdit->setText(url.toEncoded());
-        view->load(url);
-        view->setFocus(Qt::OtherFocusReason);
+        if (url.isValid()) {
+            urlEdit->setText(url.toEncoded());
+            view->load(url);
+            view->setFocus(Qt::OtherFocusReason);
+        }
     }
 
     void loadFinished() {
@@ -562,7 +565,7 @@ int launcherMain(const QApplication& app)
 int main(int argc, char **argv)
 {
     QApplication app(argc, argv);
-    QString url = QString("%1/%2").arg(QDir::homePath()).arg(QLatin1String("index.html"));
+    QString url = QString("file://%1/%2").arg(QDir::homePath()).arg(QLatin1String("index.html"));
 
     QWebSettings::setMaximumPagesInCache(4);
 

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list