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

ouch ouch at 268f45cc-cd09-0410-ab3c-d52691b4dbfc
Sat Sep 26 08:42:41 UTC 2009


The following commit has been merged in the debian/unstable branch:
commit 07c331db8724759c57090e8549b6fb358803c15c
Author: ouch <ouch at 268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Fri May 28 15:54:26 2004 +0000

    	Added addArcToPoint and addRect path routines.
    
            Reviewed by sullivan.
    
            * khtml/ecma/kjs_html.cpp:
            (KJS::Context2DFunction::tryCall):
            * khtml/ecma/kjs_html.h:
            (KJS::Context2D::):
            * khtml/ecma/kjs_html.lut.h:
            (KJS::):
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@6720 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/WebCore/ChangeLog-2005-08-23 b/WebCore/ChangeLog-2005-08-23
index 90c349e..7136488 100644
--- a/WebCore/ChangeLog-2005-08-23
+++ b/WebCore/ChangeLog-2005-08-23
@@ -1,3 +1,16 @@
+2004-05-28  John Louch  <ouch at apple.com>
+
+	Added addArcToPoint and addRect path routines.
+
+        Reviewed by sullivan.
+
+        * khtml/ecma/kjs_html.cpp:
+        (KJS::Context2DFunction::tryCall):
+        * khtml/ecma/kjs_html.h:
+        (KJS::Context2D::):
+        * khtml/ecma/kjs_html.lut.h:
+        (KJS::):
+
 2004-05-27  Ken Kocienda  <kocienda at apple.com>
 
         Reviewed by John
diff --git a/WebCore/khtml/ecma/kjs_html.cpp b/WebCore/khtml/ecma/kjs_html.cpp
index dacf3e8..1ea605c 100644
--- a/WebCore/khtml/ecma/kjs_html.cpp
+++ b/WebCore/khtml/ecma/kjs_html.cpp
@@ -3573,6 +3573,34 @@ Value KJS::Context2DFunction::tryCall(ExecState *exec, Object &thisObj, const Li
             renderer->setNeedsImageUpdate();
             break;
         }
+        case Context2D::AddArcToPoint: {
+            if (args.size() != 5) {
+                Object err = Error::create(exec,SyntaxError);
+                exec->setException(err);
+                return err;
+            }
+            float x1 = (float)args[0].toNumber(exec);
+            float y1 = (float)args[1].toNumber(exec);
+            float x2 = (float)args[2].toNumber(exec);
+            float y2 = (float)args[3].toNumber(exec);
+            float r = (float)args[4].toNumber(exec);
+            CGContextAddArcToPoint (drawingContext, x1, y1, x2, y2, r);
+            // ouch: messing with the pass should not cause an update
+            break;
+        }
+        case Context2D::AddRect: {
+            if (args.size() != 4) {
+                Object err = Error::create(exec,SyntaxError);
+                exec->setException(err);
+                return err;
+            }
+            float x = (float)args[0].toNumber(exec);
+            float y = (float)args[1].toNumber(exec);
+            float w = (float)args[2].toNumber(exec);
+            float h = (float)args[3].toNumber(exec);
+            CGContextAddRect (drawingContext, CGRectMake(x,y,w,h));
+            break;
+        }
         case Context2D::ClearRect: {
             if (args.size() != 4) {
                 Object err = Error::create(exec,SyntaxError);
@@ -3722,7 +3750,7 @@ Value KJS::Context2DFunction::tryCall(ExecState *exec, Object &thisObj, const Li
 const ClassInfo KJS::Context2D::info = { "Context2D", 0, &Context2DTable, 0 };
 
 /* Source for Context2DTable. Use "make hashtables" to regenerate.
- at begin Context2DTable 28
+ at begin Context2DTable 30
   save                     Context2D::Save                        DontDelete|Function 0
   restore                  Context2D::Restore                     DontDelete|Function 0
   scale                    Context2D::Scale                       DontDelete|Function 2
@@ -3742,6 +3770,8 @@ const ClassInfo KJS::Context2D::info = { "Context2D", 0, &Context2DTable, 0 };
   addLineToPoint           Context2D::AddLineToPoint              DontDelete|Function 2
   addQuadraticCurveToPoint Context2D::AddQuadraticCurveToPoint    DontDelete|Function 4
   addBezierCurveToPoint    Context2D::AddBezierCurveToPoint       DontDelete|Function 6
+  addArcToPoint            Context2D::AddArcToPoint               DontDelete|Function 5
+  addRect                  Context2D::AddRect                     DontDelete|Function 4
   clearRect                Context2D::ClearRect                   DontDelete|Function 4
   fillRect                 Context2D::FillRect                    DontDelete|Function 4
   strokeRect               Context2D::StrokeRect                  DontDelete|Function 4
diff --git a/WebCore/khtml/ecma/kjs_html.h b/WebCore/khtml/ecma/kjs_html.h
index f1ed3be..fefc2b9 100644
--- a/WebCore/khtml/ecma/kjs_html.h
+++ b/WebCore/khtml/ecma/kjs_html.h
@@ -257,7 +257,7 @@ namespace KJS {
         BeginPath, ClosePath, 
         SetStrokeColor, SetFillColor, SetLineWidth, SetLineCap, SetLineJoin, SetMiterLimit, 
         FillPath, StrokePath, 
-        MoveToPoint, AddLineToPoint, AddQuadraticCurveToPoint, AddBezierCurveToPoint,
+        MoveToPoint, AddLineToPoint, AddQuadraticCurveToPoint, AddBezierCurveToPoint, AddArcToPoint, AddRect,
         ClearRect, FillRect, StrokeRect,
         DrawImage, DrawImageFromRect,
         SetShadow, SetShadowWithColor, ClearShadow,
diff --git a/WebCore/khtml/ecma/kjs_html.lut.h b/WebCore/khtml/ecma/kjs_html.lut.h
index c7f00c5..5fb4e8e 100644
--- a/WebCore/khtml/ecma/kjs_html.lut.h
+++ b/WebCore/khtml/ecma/kjs_html.lut.h
@@ -1038,45 +1038,48 @@ namespace KJS {
 
 const struct HashEntry Context2DTableEntries[] = {
    { 0, 0, 0, 0, 0 },
+   { "closePath", Context2D::ClosePath, DontDelete|Function, 0, 0 },
+   { "addArcToPoint", Context2D::AddArcToPoint, DontDelete|Function, 5, 0 },
    { 0, 0, 0, 0, 0 },
    { "setFillColor", Context2D::SetFillColor, DontDelete|Function, 1, 0 },
+   { "setStrokeColor", Context2D::SetStrokeColor, DontDelete|Function, 1, &Context2DTableEntries[37] },
+   { "setLineWidth", Context2D::SetLineWidth, DontDelete|Function, 1, &Context2DTableEntries[33] },
    { 0, 0, 0, 0, 0 },
-   { "setLineWidth", Context2D::SetLineWidth, DontDelete|Function, 1, &Context2DTableEntries[30] },
-   { 0, 0, 0, 0, 0 },
-   { "addLineToPoint", Context2D::AddLineToPoint, DontDelete|Function, 2, &Context2DTableEntries[37] },
-   { "closePath", Context2D::ClosePath, DontDelete|Function, 0, &Context2DTableEntries[34] },
-   { "fillPath", Context2D::FillPath, DontDelete|Function, 0, &Context2DTableEntries[31] },
-   { "fillRect", Context2D::FillRect, DontDelete|Function, 4, 0 },
+   { "setAlpha", Context2D::SetAlpha, DontDelete|Function, 1, 0 },
+   { "setShadowWithColor", Context2D::SetShadowWithColor, DontDelete|Function, 4, 0 },
+   { "scale", Context2D::Scale, DontDelete|Function, 2, &Context2DTableEntries[31] },
+   { "save", Context2D::Save, DontDelete|Function, 0, &Context2DTableEntries[35] },
+   { "strokeRect", Context2D::StrokeRect, DontDelete|Function, 4, 0 },
+   { "drawImage", Context2D::DrawImage, DontDelete|Function, 6, 0 },
+   { "translate", Context2D::Translate, DontDelete|Function, 1, &Context2DTableEntries[30] },
    { 0, 0, 0, 0, 0 },
-   { "save", Context2D::Save, DontDelete|Function, 0, &Context2DTableEntries[29] },
-   { "setMiterLimit", Context2D::SetMiterLimit, DontDelete|Function, 1, &Context2DTableEntries[32] },
-   { "clearShadow", Context2D::ClearShadow, DontDelete|Function, 0, 0 },
+   { "moveToPoint", Context2D::MoveToPoint, DontDelete|Function, 2, &Context2DTableEntries[40] },
+   { "clearRect", Context2D::ClearRect, DontDelete|Function, 4, 0 },
    { 0, 0, 0, 0, 0 },
    { 0, 0, 0, 0, 0 },
-   { "restore", Context2D::Restore, DontDelete|Function, 0, &Context2DTableEntries[28] },
-   { "drawImage", Context2D::DrawImage, DontDelete|Function, 6, 0 },
-   { "beginPath", Context2D::BeginPath, DontDelete|Function, 0, 0 },
-   { "setStrokeColor", Context2D::SetStrokeColor, DontDelete|Function, 1, 0 },
-   { "setLineCap", Context2D::SetLineCap, DontDelete|Function, 1, 0 },
-   { "addQuadraticCurveToPoint", Context2D::AddQuadraticCurveToPoint, DontDelete|Function, 4, &Context2DTableEntries[33] },
-   { "translate", Context2D::Translate, DontDelete|Function, 1, &Context2DTableEntries[35] },
    { 0, 0, 0, 0, 0 },
    { 0, 0, 0, 0, 0 },
-   { "strokePath", Context2D::StrokePath, DontDelete|Function, 0, 0 },
-   { "strokeRect", Context2D::StrokeRect, DontDelete|Function, 4, 0 },
+   { "restore", Context2D::Restore, DontDelete|Function, 0, 0 },
+   { "clearShadow", Context2D::ClearShadow, DontDelete|Function, 0, 0 },
    { 0, 0, 0, 0, 0 },
-   { "scale", Context2D::Scale, DontDelete|Function, 2, 0 },
    { "rotate", Context2D::Rotate, DontDelete|Function, 2, 0 },
+   { "addLineToPoint", Context2D::AddLineToPoint, DontDelete|Function, 2, 0 },
+   { "addQuadraticCurveToPoint", Context2D::AddQuadraticCurveToPoint, DontDelete|Function, 4, 0 },
+   { 0, 0, 0, 0, 0 },
+   { 0, 0, 0, 0, 0 },
+   { "beginPath", Context2D::BeginPath, DontDelete|Function, 0, &Context2DTableEntries[32] },
+   { "setLineCap", Context2D::SetLineCap, DontDelete|Function, 1, &Context2DTableEntries[34] },
    { "setLineJoin", Context2D::SetLineJoin, DontDelete|Function, 1, 0 },
-   { "moveToPoint", Context2D::MoveToPoint, DontDelete|Function, 2, 0 },
+   { "setMiterLimit", Context2D::SetMiterLimit, DontDelete|Function, 1, 0 },
+   { "fillPath", Context2D::FillPath, DontDelete|Function, 0, &Context2DTableEntries[36] },
+   { "strokePath", Context2D::StrokePath, DontDelete|Function, 0, &Context2DTableEntries[38] },
    { "addBezierCurveToPoint", Context2D::AddBezierCurveToPoint, DontDelete|Function, 6, 0 },
-   { "clearRect", Context2D::ClearRect, DontDelete|Function, 4, &Context2DTableEntries[36] },
+   { "addRect", Context2D::AddRect, DontDelete|Function, 4, &Context2DTableEntries[39] },
+   { "fillRect", Context2D::FillRect, DontDelete|Function, 4, 0 },
    { "drawImageFromRect", Context2D::DrawImageFromRect, DontDelete|Function, 10, 0 },
-   { "setShadow", Context2D::SetShadow, DontDelete|Function, 3, 0 },
-   { "setShadowWithColor", Context2D::SetShadowWithColor, DontDelete|Function, 4, 0 },
-   { "setAlpha", Context2D::SetAlpha, DontDelete|Function, 1, 0 }
+   { "setShadow", Context2D::SetShadow, DontDelete|Function, 3, 0 }
 };
 
-const struct HashTable Context2DTable = { 2, 38, Context2DTableEntries, 28 };
+const struct HashTable Context2DTable = { 2, 41, Context2DTableEntries, 30 };
 
 } // namespace

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list