[SCM] WebKit Debian packaging branch, debian/unstable, updated. debian/1.1.15-1-40151-g37bb677

hyatt hyatt at 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Sat Sep 26 08:13:50 UTC 2009


The following commit has been merged in the debian/unstable branch:
commit db12f8c769df602d7c0a14648e1e6446f475dbff
Author: hyatt <hyatt at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Tue Nov 18 22:12:18 2003 +0000

    	Fix for 3488244, marquee-increments with percentage values not handled correctly.  Also added a tweak to ensure
    	that 1% of a small value ends up being at least an increment of 1.  Also added an optimization to not even
    	bother kicking off the marquee timer if the increment's initial value is 0 (matches WinIE).
    
            * khtml/rendering/render_layer.cpp:
            (Marquee::start):
            (Marquee::timerEvent):
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@5582 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebCore/ChangeLog-2005-08-23 b/WebCore/ChangeLog-2005-08-23
index 0dd5469..34785d0 100644
--- a/WebCore/ChangeLog-2005-08-23
+++ b/WebCore/ChangeLog-2005-08-23
@@ -1,3 +1,13 @@
+2003-11-18  David Hyatt  <hyatt at apple.com>
+
+	Fix for 3488244, marquee-increments with percentage values not handled correctly.  Also added a tweak to ensure
+	that 1% of a small value ends up being at least an increment of 1.  Also added an optimization to not even
+	bother kicking off the marquee timer if the increment's initial value is 0 (matches WinIE).
+
+        * khtml/rendering/render_layer.cpp:
+        (Marquee::start):
+        (Marquee::timerEvent):
+
 2003-11-18  Richard Williamson   <rjw at apple.com>
 
 	More live connect stuff.  We're getting close.
diff --git a/WebCore/khtml/rendering/render_layer.cpp b/WebCore/khtml/rendering/render_layer.cpp
index 27204aa..d54a10b 100644
--- a/WebCore/khtml/rendering/render_layer.cpp
+++ b/WebCore/khtml/rendering/render_layer.cpp
@@ -1324,7 +1324,7 @@ int Marquee::computePosition(EMarqueeDirection dir, bool stopAtContentEdge)
 
 void Marquee::start()
 {
-    if (m_timerId)
+    if (m_timerId || m_layer->renderer()->style()->marqueeIncrement().value == 0)
         return;
     
     if (!m_suspended) {
@@ -1464,10 +1464,11 @@ void Marquee::timerEvent(QTimerEvent* evt)
                 addIncrement = !addIncrement;
         }
         bool positive = range > 0;
-        int clientSize = (isHorizontal() ? m_layer->renderer()->clientWidth() : m_layer->renderer()->clientHeight());
-        int increment = abs(m_layer->renderer()->style()->marqueeIncrement().width(clientSize));
+        int clientSize = isUnfurlMarquee() ? abs(range) :
+            (isHorizontal() ? m_layer->renderer()->clientWidth() : m_layer->renderer()->clientHeight());
+        int increment = kMax(1, abs(m_layer->renderer()->style()->marqueeIncrement().width(clientSize)));
         int currentPos = isUnfurlMarquee() ? m_unfurlPos : 
-                                             (isHorizontal() ? m_layer->scrollXOffset() : m_layer->scrollYOffset());
+            (isHorizontal() ? m_layer->scrollXOffset() : m_layer->scrollYOffset());
         newPos =  currentPos + (addIncrement ? increment : -increment);
         if (positive)
             newPos = kMin(newPos, endPoint);

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list