Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(28)

Side by Side Diff: Source/core/html/HTMLCanvasElement.idl

Issue 1249913003: The contextId argument for HTMLCanvasElement getContext() api should not be optional (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 5 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « LayoutTests/fast/dom/script-tests/non-numeric-values-numeric-parameters.js ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2006, 2008, 2009 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2008, 2009 Apple Inc. All rights reserved.
3 * Copyright (C) 2010 Torch Mobile (Beijing) Co. Ltd. All rights reserved. 3 * Copyright (C) 2010 Torch Mobile (Beijing) Co. Ltd. All rights reserved.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 27 matching lines...) Expand all
38 // The PermissiveDictionaryConversion extended attribute is needed to allow the 38 // The PermissiveDictionaryConversion extended attribute is needed to allow the
39 // autogenerated code to match the behavior of the custom binding. Web IDL 39 // autogenerated code to match the behavior of the custom binding. Web IDL
40 // requires throwing TypeError if the incoming argument is not an object typ e 40 // requires throwing TypeError if the incoming argument is not an object typ e
41 // (and is not undefined or null). The binding must ignore this. 41 // (and is not undefined or null). The binding must ignore this.
42 // 42 //
43 // Also note: the only reason this must return type "any" is to allow the 43 // Also note: the only reason this must return type "any" is to allow the
44 // InspectorInstrumentation wrappers to be called for canvases. If that coul d be 44 // InspectorInstrumentation wrappers to be called for canvases. If that coul d be
45 // handled differently the return type could be changed to "RenderingContext ?" 45 // handled differently the return type could be changed to "RenderingContext ?"
46 // and the [CallWith=ScriptState] extended attribute removed. 46 // and the [CallWith=ScriptState] extended attribute removed.
47 // 47 //
48 // FIXME: The contextId argument should not be optional. 48 [CallWith=ScriptState] any getContext(DOMString contextId, [PermissiveDictio naryConversion] optional CanvasContextCreationAttributes attributes);
49 [CallWith=ScriptState] any getContext([Default=Undefined] optional DOMString contextId, [PermissiveDictionaryConversion] optional CanvasContextCreationAttri butes attributes);
50 49
51 // Note: The arguments argument is variadic in the spec, but not here as 50 // Note: The arguments argument is variadic in the spec, but not here as
52 // only one extra argument is actually used. 51 // only one extra argument is actually used.
53 // FIXME: type should not be nullable or have a default value. 52 // FIXME: type should not be nullable or have a default value.
54 [RaisesException] DOMString toDataURL(optional DOMString? type = null, optio nal any arguments); 53 [RaisesException] DOMString toDataURL(optional DOMString? type = null, optio nal any arguments);
55 }; 54 };
OLDNEW
« no previous file with comments | « LayoutTests/fast/dom/script-tests/non-numeric-values-numeric-parameters.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698