Changeset 128374 in webkit
- Timestamp:
- Sep 12, 2012 3:43:54 PM (12 years ago)
- Location:
- trunk
- Files:
-
- 3 added
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r128370 r128374 1 2012-09-12 Adam Barth <abarth@webkit.org> 2 3 [v8] document.getCSSCanvasContext doesn't need to be custom 4 https://bugs.webkit.org/show_bug.cgi?id=96560 5 6 Reviewed by Eric Seidel. 7 8 Test that document.getCSSCanvasContext returns null for a bogus canvas type. 9 10 * fast/canvas/canvas-css-crazy-expected.txt: Added. 11 * fast/canvas/canvas-css-crazy.html: Added. 12 1 13 2012-09-12 Joshua Bell <jsbell@chromium.org> 2 14 -
trunk/Source/WebCore/ChangeLog
r128373 r128374 1 2012-09-12 Adam Barth <abarth@webkit.org> 2 3 [v8] document.getCSSCanvasContext doesn't need to be custom 4 https://bugs.webkit.org/show_bug.cgi?id=96560 5 6 Reviewed by Eric Seidel. 7 8 Instead of having a special case for toV8(CanvasRenderingContext*) 9 inlined into this custom function, we should just make the toV8 10 function itself custom. 11 12 Test: fast/canvas/canvas-css-crazy.html 13 14 * UseV8.cmake: 15 * WebCore.gypi: 16 * bindings/v8/custom/V8DocumentCustom.cpp: 17 * dom/Document.idl: 18 * html/canvas/CanvasRenderingContext.idl: 19 1 20 2012-09-12 Eric Seidel <eric@webkit.org> 2 21 -
trunk/Source/WebCore/UseV8.cmake
r128261 r128374 83 83 bindings/v8/custom/V8CSSValueCustom.cpp 84 84 bindings/v8/custom/V8CanvasRenderingContext2DCustom.cpp 85 bindings/v8/custom/V8CanvasRenderingContextCustom.cpp 85 86 bindings/v8/custom/V8ClipboardCustom.cpp 86 87 bindings/v8/custom/V8ConsoleCustom.cpp -
trunk/Source/WebCore/WebCore.gypi
r128223 r128374 2352 2352 'bindings/v8/custom/V8CSSValueCustom.cpp', 2353 2353 'bindings/v8/custom/V8CanvasRenderingContext2DCustom.cpp', 2354 'bindings/v8/custom/V8CanvasRenderingContextCustom.cpp', 2354 2355 'bindings/v8/custom/V8ClipboardCustom.cpp', 2355 2356 'bindings/v8/custom/V8ConsoleCustom.cpp', -
trunk/Source/WebCore/bindings/v8/custom/V8DocumentCustom.cpp
r128159 r128374 96 96 } 97 97 98 v8::Handle<v8::Value> V8Document::getCSSCanvasContextCallback(const v8::Arguments& args)99 {100 INC_STATS("DOM.Document.getCSSCanvasContext");101 v8::Handle<v8::Object> holder = args.Holder();102 Document* imp = V8Document::toNative(holder);103 String contextId = toWebCoreString(args[0]);104 String name = toWebCoreString(args[1]);105 int width = toInt32(args[2]);106 int height = toInt32(args[3]);107 CanvasRenderingContext* result = imp->getCSSCanvasContext(contextId, name, width, height);108 if (!result)109 return v8::Undefined();110 if (result->is2d())111 return toV8(static_cast<CanvasRenderingContext2D*>(result), args.Holder(), args.GetIsolate());112 #if ENABLE(WEBGL)113 else if (result->is3d())114 return toV8(static_cast<WebGLRenderingContext*>(result), args.Holder(), args.GetIsolate());115 #endif // ENABLE(WEBGL)116 ASSERT_NOT_REACHED();117 return v8::Undefined();118 }119 120 98 v8::Handle<v8::Value> toV8(Document* impl, v8::Handle<v8::Object> creationContext, v8::Isolate* isolate, bool forceNewObject) 121 99 { -
trunk/Source/WebCore/dom/Document.idl
r126627 r128374 238 238 #if !defined(LANGUAGE_CPP) || !LANGUAGE_CPP 239 239 #if !defined(LANGUAGE_OBJECTIVE_C) || !LANGUAGE_OBJECTIVE_C 240 [V8Custom] DOMObject getCSSCanvasContext(in DOMString contextId, in DOMString name, in long width, in long height);240 CanvasRenderingContext getCSSCanvasContext(in DOMString contextId, in DOMString name, in long width, in long height); 241 241 #endif 242 242 #endif -
trunk/Source/WebCore/html/canvas/CanvasRenderingContext.idl
r107553 r128374 29 29 JSCustomMarkFunction, 30 30 JSGenerateIsReachable, 31 JSCustomToJSObject31 CustomToJSObject 32 32 ] CanvasRenderingContext { 33 34 33 readonly attribute HTMLCanvasElement canvas; 35 34 }; 36 35 37 36 } 38
Note: See TracChangeset
for help on using the changeset viewer.