Changed the QWebPage::loadProgressChange API to have an integer (percent) argument
authorhausmann <hausmann@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 18 May 2007 14:17:52 +0000 (14:17 +0000)
committerhausmann <hausmann@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 18 May 2007 14:17:52 +0000 (14:17 +0000)
instead of a double precision float.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@21567 268f45cc-cd09-0410-ab3c-d52691b4dbfc

WebKitQt/Api/qwebpage.h
WebKitQt/ChangeLog
WebKitQt/WebCoreSupport/FrameLoaderClientQt.cpp
WebKitQt/WebCoreSupport/FrameLoaderClientQt.h

index 08fca038072d38709688022c87b05e0b80342a12..fcd5622de5e25d4f51008bc5814db6db34c2bd36 100644 (file)
@@ -102,7 +102,7 @@ signals:
      * Signal is emitted when the global progress status changes.
      * It accumulates changes from all the child frames.
      */
-    void loadProgressChanged(double progress);
+    void loadProgressChanged(int progress);
     /**
      * Signal is emitted when load has been finished on one of
      * the child frames of the page. The frame on which the
index 1cbd730a936ecffbddbe340b8857f4337351f3f6..a069834766360dd1292a3505e69748dffc330628 100644 (file)
@@ -1,3 +1,14 @@
+2007-05-18  Simon Hausmann  <hausmann@kde.org>
+
+        Reviewed by Nikolas.
+
+        * Api/qwebpage.h: Changed the loadProgressChanged API to use an
+        percent integer instead of a double precision floating pointer number.
+        * WebCoreSupport/FrameLoaderClientQt.cpp:
+        (WebCore::FrameLoaderClientQt::setFrame):
+        (WebCore::FrameLoaderClientQt::postProgressEstimateChangedNotification):
+        * WebCoreSupport/FrameLoaderClientQt.h:
+
 2007-05-18  Marius Bugge Monsen  <mbm@trolltech.com>
 
         Reviewed by Zack Rusin.
index 36c58c8fc4fe4ba292a9e7ad91fb472293471470..10dd9a996440b0b518af680f44498319f9a56fca 100644 (file)
@@ -79,8 +79,8 @@ void FrameLoaderClientQt::setFrame(QWebFrame* webFrame, Frame* frame)
 
     connect(this, SIGNAL(loadStarted(QWebFrame*)),
             m_webFrame->page(), SIGNAL(loadStarted(QWebFrame *)));
-    connect(this, SIGNAL(loadProgressChanged(double)),
-            m_webFrame->page(), SIGNAL(loadProgressChanged(double)));
+    connect(this, SIGNAL(loadProgressChanged(int)),
+            m_webFrame->page(), SIGNAL(loadProgressChanged(int)));
     connect(this, SIGNAL(loadFinished(QWebFrame*)),
             m_webFrame->page(), SIGNAL(loadFinished(QWebFrame *)));
     connect(this, SIGNAL(titleChanged(const QString&)),
@@ -428,7 +428,7 @@ void FrameLoaderClientQt::postProgressStartedNotification()
 void FrameLoaderClientQt::postProgressEstimateChangedNotification()
 {
     if (m_webFrame && m_frame->page())
-        emit loadProgressChanged(m_frame->page()->progress()->estimatedProgress());
+        emit loadProgressChanged(m_frame->page()->progress()->estimatedProgress() * 100);
 }
 
 void FrameLoaderClientQt::postProgressFinishedNotification()
index 388ad6426f39d08866fc89db035015c52409aaa5..fd70f2a79c73e112fb1e19f1ed05415eacff39a1 100644 (file)
@@ -60,7 +60,7 @@ namespace WebCore {
     signals:
         void sigCallPolicyFunction(int);
         void loadStarted(QWebFrame *frame);
-        void loadProgressChanged(double d);
+        void loadProgressChanged(int d);
         void loadFinished(QWebFrame *frame);
         void titleChanged(const QString& title);