haikuwebkit/LayoutTests/js/console.html

100 lines
2.9 KiB
HTML
Raw Permalink Normal View History

Make console a namespace object (like Math/JSON), allowing functions to be called unbound https://bugs.webkit.org/show_bug.cgi?id=157286 <rdar://problem/26052830> Patch by Joseph Pecoraro <pecoraro@apple.com> on 2016-05-02 Reviewed by Timothy Hatcher. Source/JavaScriptCore: This changes `console` to be a global namespace object, like `Math` and `JSON`. It just holds a bunch of functions, that can be used on their own, unbound. For example, `[1,2,3].forEach(console.log)` and `var log = console.log; log(1)` used to throw exceptions and now do not. Previously console was an Object/Prototype pair, so functions were on ConsolePrototype (console.__proto__.log) and they needed to be called Console objects as the `this` value. Now, `console` is just a standard object with a bunch of functions. Since there is no console prototype the functions can be passed around and called as expected and they will just do the right thing. For compatability with other browsers, `console` was made enumerable on the global object. * CMakeLists.txt: * JavaScriptCore.xcodeproj/project.pbxproj: Add new files and remove old files. * runtime/CommonIdentifiers.h: Add "console". * runtime/ConsoleObject.cpp: Renamed from Source/JavaScriptCore/runtime/ConsolePrototype.cpp. (JSC::ConsoleObject::ConsoleObject): (JSC::ConsoleObject::finishCreation): (JSC::valueToStringWithUndefinedOrNullCheck): (JSC::consoleLogWithLevel): (JSC::consoleProtoFuncDebug): (JSC::consoleProtoFuncError): (JSC::consoleProtoFuncLog): (JSC::consoleProtoFuncInfo): (JSC::consoleProtoFuncWarn): (JSC::consoleProtoFuncClear): (JSC::consoleProtoFuncDir): (JSC::consoleProtoFuncDirXML): (JSC::consoleProtoFuncTable): (JSC::consoleProtoFuncTrace): (JSC::consoleProtoFuncAssert): (JSC::consoleProtoFuncCount): (JSC::consoleProtoFuncProfile): (JSC::consoleProtoFuncProfileEnd): (JSC::consoleProtoFuncTakeHeapSnapshot): (JSC::consoleProtoFuncTime): (JSC::consoleProtoFuncTimeEnd): (JSC::consoleProtoFuncTimeStamp): (JSC::consoleProtoFuncGroup): (JSC::consoleProtoFuncGroupCollapsed): (JSC::consoleProtoFuncGroupEnd): Console functions no longer need to check if the this object is a Console object. They will always just work now. * runtime/MathObject.cpp: * runtime/MathObject.h: * runtime/ConsoleObject.h: Renamed from Source/JavaScriptCore/runtime/ConsolePrototype.h. (JSC::ConsoleObject::create): (JSC::ConsoleObject::createStructure): ConsoleObject is a basic object like MathObject. * runtime/JSConsole.cpp: Removed. * runtime/JSConsole.h: Removed. * runtime/JSGlobalObject.h: * runtime/JSGlobalObject.cpp: (JSC::JSGlobalObject::init): (JSC::JSGlobalObject::visitChildren): Remove JSConsole / ConsolePrototype in favor of the single ConsoleObject. LayoutTests: * js/console-expected.txt: Added. * js/console.html: Added. Canonical link: https://commits.webkit.org/175386@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@200350 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2016-05-03 00:51:24 +00:00
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML//EN">
<html>
<head>
<script src="../resources/js-test-pre.js"></script>
</head>
<body>
<script>
shouldBeEqualToString("typeof console", "object");
Console object's @@toStringTag should be "console" instead of "Console" https://bugs.webkit.org/show_bug.cgi?id=215750 Reviewed by Ross Kirsling. LayoutTests/imported/w3c: Import ToT wpt/console tests including @@toStringTag tests. * resources/import-expectations.json: * web-platform-tests/console/META.yml: Added. * web-platform-tests/console/console-is-a-namespace.any-expected.txt: Added. * web-platform-tests/console/console-is-a-namespace.any.html: Added. * web-platform-tests/console/console-is-a-namespace.any.js: Added. (test): * web-platform-tests/console/console-is-a-namespace.any.worker-expected.txt: Added. * web-platform-tests/console/console-is-a-namespace.any.worker.html: Added. * web-platform-tests/console/console-label-conversion.any-expected.txt: Added. * web-platform-tests/console/console-label-conversion.any.html: Added. * web-platform-tests/console/console-label-conversion.any.js: Added. (const.method.of.methods.test): * web-platform-tests/console/console-label-conversion.any.worker-expected.txt: Added. * web-platform-tests/console/console-label-conversion.any.worker.html: Added. * web-platform-tests/console/console-namespace-object-class-string.any-expected.txt: Added. * web-platform-tests/console/console-namespace-object-class-string.any.html: Added. * web-platform-tests/console/console-namespace-object-class-string.any.js: Added. (test): (test.t.t.add_cleanup): * web-platform-tests/console/console-namespace-object-class-string.any.worker-expected.txt: Added. * web-platform-tests/console/console-namespace-object-class-string.any.worker.html: Added. * web-platform-tests/console/console-tests-historical.any-expected.txt: Added. * web-platform-tests/console/console-tests-historical.any.html: Added. * web-platform-tests/console/console-tests-historical.any.js: Added. (test): * web-platform-tests/console/console-tests-historical.any.worker-expected.txt: Added. * web-platform-tests/console/console-tests-historical.any.worker.html: Added. * web-platform-tests/console/idlharness.any-expected.txt: Added. * web-platform-tests/console/idlharness.any.html: Added. * web-platform-tests/console/idlharness.any.js: Added. * web-platform-tests/console/idlharness.any.worker-expected.txt: Added. * web-platform-tests/console/idlharness.any.worker.html: Added. * web-platform-tests/console/w3c-import.log: Added. Source/JavaScriptCore: Use "console" instead of "Console". Now, namespace object has @@toStringTag. https://github.com/web-platform-tests/wpt/pull/24717 * runtime/ConsoleObject.cpp: LayoutTests: * fast/dom/Window/window-lookup-precedence-expected.txt: * fast/loader/window-properties-restored-from-page-cache-expected.txt: * http/tests/security/cross-frame-access-put-expected.txt: * inspector/debugger/pause-for-internal-scripts-expected.txt: * inspector/debugger/stepping/stepping-internal-scripts-expected.txt: * js/console-expected.txt: * js/console.html: * platform/gtk/fast/dom/Window/window-lookup-precedence-expected.txt: * platform/mac-wk2/fast/dom/Window/window-lookup-precedence-expected.txt: Canonical link: https://commits.webkit.org/228507@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@266030 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2020-08-22 18:08:49 +00:00
shouldBeEqualToString("console.toString()", "[object console]");
Make console a namespace object (like Math/JSON), allowing functions to be called unbound https://bugs.webkit.org/show_bug.cgi?id=157286 <rdar://problem/26052830> Patch by Joseph Pecoraro <pecoraro@apple.com> on 2016-05-02 Reviewed by Timothy Hatcher. Source/JavaScriptCore: This changes `console` to be a global namespace object, like `Math` and `JSON`. It just holds a bunch of functions, that can be used on their own, unbound. For example, `[1,2,3].forEach(console.log)` and `var log = console.log; log(1)` used to throw exceptions and now do not. Previously console was an Object/Prototype pair, so functions were on ConsolePrototype (console.__proto__.log) and they needed to be called Console objects as the `this` value. Now, `console` is just a standard object with a bunch of functions. Since there is no console prototype the functions can be passed around and called as expected and they will just do the right thing. For compatability with other browsers, `console` was made enumerable on the global object. * CMakeLists.txt: * JavaScriptCore.xcodeproj/project.pbxproj: Add new files and remove old files. * runtime/CommonIdentifiers.h: Add "console". * runtime/ConsoleObject.cpp: Renamed from Source/JavaScriptCore/runtime/ConsolePrototype.cpp. (JSC::ConsoleObject::ConsoleObject): (JSC::ConsoleObject::finishCreation): (JSC::valueToStringWithUndefinedOrNullCheck): (JSC::consoleLogWithLevel): (JSC::consoleProtoFuncDebug): (JSC::consoleProtoFuncError): (JSC::consoleProtoFuncLog): (JSC::consoleProtoFuncInfo): (JSC::consoleProtoFuncWarn): (JSC::consoleProtoFuncClear): (JSC::consoleProtoFuncDir): (JSC::consoleProtoFuncDirXML): (JSC::consoleProtoFuncTable): (JSC::consoleProtoFuncTrace): (JSC::consoleProtoFuncAssert): (JSC::consoleProtoFuncCount): (JSC::consoleProtoFuncProfile): (JSC::consoleProtoFuncProfileEnd): (JSC::consoleProtoFuncTakeHeapSnapshot): (JSC::consoleProtoFuncTime): (JSC::consoleProtoFuncTimeEnd): (JSC::consoleProtoFuncTimeStamp): (JSC::consoleProtoFuncGroup): (JSC::consoleProtoFuncGroupCollapsed): (JSC::consoleProtoFuncGroupEnd): Console functions no longer need to check if the this object is a Console object. They will always just work now. * runtime/MathObject.cpp: * runtime/MathObject.h: * runtime/ConsoleObject.h: Renamed from Source/JavaScriptCore/runtime/ConsolePrototype.h. (JSC::ConsoleObject::create): (JSC::ConsoleObject::createStructure): ConsoleObject is a basic object like MathObject. * runtime/JSConsole.cpp: Removed. * runtime/JSConsole.h: Removed. * runtime/JSGlobalObject.h: * runtime/JSGlobalObject.cpp: (JSC::JSGlobalObject::init): (JSC::JSGlobalObject::visitChildren): Remove JSConsole / ConsolePrototype in favor of the single ConsoleObject. LayoutTests: * js/console-expected.txt: Added. * js/console.html: Added. Canonical link: https://commits.webkit.org/175386@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@200350 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2016-05-03 00:51:24 +00:00
shouldBe("console", "console");
// <https://webkit.org/b/157782> console namespace breaks putting properties on console.__proto__
shouldNotBe("Object.getPrototypeOf(console)", "Object.getPrototypeOf({})");
Make console a namespace object (like Math/JSON), allowing functions to be called unbound https://bugs.webkit.org/show_bug.cgi?id=157286 <rdar://problem/26052830> Patch by Joseph Pecoraro <pecoraro@apple.com> on 2016-05-02 Reviewed by Timothy Hatcher. Source/JavaScriptCore: This changes `console` to be a global namespace object, like `Math` and `JSON`. It just holds a bunch of functions, that can be used on their own, unbound. For example, `[1,2,3].forEach(console.log)` and `var log = console.log; log(1)` used to throw exceptions and now do not. Previously console was an Object/Prototype pair, so functions were on ConsolePrototype (console.__proto__.log) and they needed to be called Console objects as the `this` value. Now, `console` is just a standard object with a bunch of functions. Since there is no console prototype the functions can be passed around and called as expected and they will just do the right thing. For compatability with other browsers, `console` was made enumerable on the global object. * CMakeLists.txt: * JavaScriptCore.xcodeproj/project.pbxproj: Add new files and remove old files. * runtime/CommonIdentifiers.h: Add "console". * runtime/ConsoleObject.cpp: Renamed from Source/JavaScriptCore/runtime/ConsolePrototype.cpp. (JSC::ConsoleObject::ConsoleObject): (JSC::ConsoleObject::finishCreation): (JSC::valueToStringWithUndefinedOrNullCheck): (JSC::consoleLogWithLevel): (JSC::consoleProtoFuncDebug): (JSC::consoleProtoFuncError): (JSC::consoleProtoFuncLog): (JSC::consoleProtoFuncInfo): (JSC::consoleProtoFuncWarn): (JSC::consoleProtoFuncClear): (JSC::consoleProtoFuncDir): (JSC::consoleProtoFuncDirXML): (JSC::consoleProtoFuncTable): (JSC::consoleProtoFuncTrace): (JSC::consoleProtoFuncAssert): (JSC::consoleProtoFuncCount): (JSC::consoleProtoFuncProfile): (JSC::consoleProtoFuncProfileEnd): (JSC::consoleProtoFuncTakeHeapSnapshot): (JSC::consoleProtoFuncTime): (JSC::consoleProtoFuncTimeEnd): (JSC::consoleProtoFuncTimeStamp): (JSC::consoleProtoFuncGroup): (JSC::consoleProtoFuncGroupCollapsed): (JSC::consoleProtoFuncGroupEnd): Console functions no longer need to check if the this object is a Console object. They will always just work now. * runtime/MathObject.cpp: * runtime/MathObject.h: * runtime/ConsoleObject.h: Renamed from Source/JavaScriptCore/runtime/ConsolePrototype.h. (JSC::ConsoleObject::create): (JSC::ConsoleObject::createStructure): ConsoleObject is a basic object like MathObject. * runtime/JSConsole.cpp: Removed. * runtime/JSConsole.h: Removed. * runtime/JSGlobalObject.h: * runtime/JSGlobalObject.cpp: (JSC::JSGlobalObject::init): (JSC::JSGlobalObject::visitChildren): Remove JSConsole / ConsolePrototype in favor of the single ConsoleObject. LayoutTests: * js/console-expected.txt: Added. * js/console.html: Added. Canonical link: https://commits.webkit.org/175386@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@200350 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2016-05-03 00:51:24 +00:00
var consoleDescriptor = Object.getOwnPropertyDescriptor(window, "console");
shouldBeTrue('consoleDescriptor.configurable');
shouldBeTrue('consoleDescriptor.writable');
shouldBeFalse('consoleDescriptor.enumerable');
Make console a namespace object (like Math/JSON), allowing functions to be called unbound https://bugs.webkit.org/show_bug.cgi?id=157286 <rdar://problem/26052830> Patch by Joseph Pecoraro <pecoraro@apple.com> on 2016-05-02 Reviewed by Timothy Hatcher. Source/JavaScriptCore: This changes `console` to be a global namespace object, like `Math` and `JSON`. It just holds a bunch of functions, that can be used on their own, unbound. For example, `[1,2,3].forEach(console.log)` and `var log = console.log; log(1)` used to throw exceptions and now do not. Previously console was an Object/Prototype pair, so functions were on ConsolePrototype (console.__proto__.log) and they needed to be called Console objects as the `this` value. Now, `console` is just a standard object with a bunch of functions. Since there is no console prototype the functions can be passed around and called as expected and they will just do the right thing. For compatability with other browsers, `console` was made enumerable on the global object. * CMakeLists.txt: * JavaScriptCore.xcodeproj/project.pbxproj: Add new files and remove old files. * runtime/CommonIdentifiers.h: Add "console". * runtime/ConsoleObject.cpp: Renamed from Source/JavaScriptCore/runtime/ConsolePrototype.cpp. (JSC::ConsoleObject::ConsoleObject): (JSC::ConsoleObject::finishCreation): (JSC::valueToStringWithUndefinedOrNullCheck): (JSC::consoleLogWithLevel): (JSC::consoleProtoFuncDebug): (JSC::consoleProtoFuncError): (JSC::consoleProtoFuncLog): (JSC::consoleProtoFuncInfo): (JSC::consoleProtoFuncWarn): (JSC::consoleProtoFuncClear): (JSC::consoleProtoFuncDir): (JSC::consoleProtoFuncDirXML): (JSC::consoleProtoFuncTable): (JSC::consoleProtoFuncTrace): (JSC::consoleProtoFuncAssert): (JSC::consoleProtoFuncCount): (JSC::consoleProtoFuncProfile): (JSC::consoleProtoFuncProfileEnd): (JSC::consoleProtoFuncTakeHeapSnapshot): (JSC::consoleProtoFuncTime): (JSC::consoleProtoFuncTimeEnd): (JSC::consoleProtoFuncTimeStamp): (JSC::consoleProtoFuncGroup): (JSC::consoleProtoFuncGroupCollapsed): (JSC::consoleProtoFuncGroupEnd): Console functions no longer need to check if the this object is a Console object. They will always just work now. * runtime/MathObject.cpp: * runtime/MathObject.h: * runtime/ConsoleObject.h: Renamed from Source/JavaScriptCore/runtime/ConsolePrototype.h. (JSC::ConsoleObject::create): (JSC::ConsoleObject::createStructure): ConsoleObject is a basic object like MathObject. * runtime/JSConsole.cpp: Removed. * runtime/JSConsole.h: Removed. * runtime/JSGlobalObject.h: * runtime/JSGlobalObject.cpp: (JSC::JSGlobalObject::init): (JSC::JSGlobalObject::visitChildren): Remove JSConsole / ConsolePrototype in favor of the single ConsoleObject. LayoutTests: * js/console-expected.txt: Added. * js/console.html: Added. Canonical link: https://commits.webkit.org/175386@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@200350 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2016-05-03 00:51:24 +00:00
// Console methods don't care what their this object is.
console.log("log message");
console.log.call(null, "log message");
console.log.call(undefined, "log message");
console.log.call(console, "log message");
console.log.call(123, "log message");
console.log.call("ignore", "log message");
console.log.bind(console, "log message");
console.log.bind(console)("log message");
[1,2,3].forEach(console.log);
// All properties should be enumerable.
var property, descriptor;
var enumerablePropertyCount = 0;
for (property in console) {
enumerablePropertyCount++;
descriptor = Object.getOwnPropertyDescriptor(console, property);
debug("");
debug(`console.${property}`);
shouldBeEqualToString(`typeof console.${property}`, "function");
shouldBe(`console.${property}.length`, '0');
shouldBeTrue('descriptor.configurable');
shouldBeTrue('descriptor.writable');
shouldBeTrue('descriptor.enumerable');
}
debug("");
shouldBe("Object.getOwnPropertyNames(console).length", "enumerablePropertyCount");
Web Inspector: provide method for recording CanvasRenderingContext2D from JavaScript https://bugs.webkit.org/show_bug.cgi?id=175166 <rdar://problem/34040740> Reviewed by Joseph Pecoraro. Source/JavaScriptCore: * inspector/protocol/Recording.json: Add optional `name` that will be used by the frontend for uniquely identifying the Recording. * inspector/JSGlobalObjectConsoleClient.h: * inspector/JSGlobalObjectConsoleClient.cpp: (Inspector::JSGlobalObjectConsoleClient::record): (Inspector::JSGlobalObjectConsoleClient::recordEnd): * runtime/ConsoleClient.h: * runtime/ConsoleObject.cpp: (JSC::ConsoleObject::finishCreation): (JSC::consoleProtoFuncRecord): (JSC::consoleProtoFuncRecordEnd): Source/WebCore: No new tests, updated existing tests. * inspector/InspectorCanvas.h: * inspector/InspectorCanvas.cpp: (WebCore::InspectorCanvas::resetRecordingData): * inspector/InspectorCanvasAgent.h: * inspector/InspectorCanvasAgent.cpp: (WebCore::InspectorCanvasAgent::didFinishRecordingCanvasFrame): (WebCore::InspectorCanvasAgent::consoleStartRecordingCanvas): * inspector/InspectorInstrumentation.h: * inspector/InspectorInstrumentation.cpp: (WebCore::InspectorInstrumentation::consoleStartRecordingCanvas): (WebCore::InspectorInstrumentation::consoleStartRecordingCanvasImpl): * page/PageConsoleClient.h: * page/PageConsoleClient.cpp: (WebCore::PageConsoleClient::record): (WebCore::PageConsoleClient::recordEnd): * workers/WorkerConsoleClient.h: * workers/WorkerConsoleClient.cpp: (WebCore::WorkerConsoleClient::record): (WebCore::WorkerConsoleClient::recordEnd): Source/WebInspectorUI: * UserInterface/Controllers/CanvasManager.js: (WI.CanvasManager.prototype.recordingFinished): If a `name` is sent with the payload, use it as the suggested name. * UserInterface/Models/NativeFunctionParameters.js: Add `console.record` and `console.recordEnd`. * UserInterface/Views/CanvasTabContentView.js: (WI.CanvasTabContentView.prototype.showRepresentedObject): Drive-by: remove logic that toggled the collapsed state of the navigation sidebar, as this was not very controllable by the user and often was aggravating. (WI.CanvasTabContentView.prototype._recordingStopped): Only show the recording if it was not started from the console. This can determined by CanvasManager when it recieves a recording if the recording's source is not the same as the current canvas being recorded. LayoutTests: * inspector/canvas/recording-2d-expected.txt: * inspector/canvas/recording-2d.html: (performConsoleRecording): * inspector/canvas/recording-webgl-expected.txt: * inspector/canvas/recording-webgl.html: (performConsoleRecording): * inspector/canvas/resources/recording-utilities.js: (TestPage.registerInitializer): * js/console-expected.txt: * js/console.html: Canonical link: https://commits.webkit.org/196332@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@225488 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2017-12-04 21:40:55 +00:00
Web Inspector: provide a way to capture a screenshot of a node from within the page https://bugs.webkit.org/show_bug.cgi?id=194279 <rdar://problem/10731573> Reviewed by Joseph Pecoraro. Source/JavaScriptCore: Add `console.screenshot` functionality, which displays a screenshot of a given object (if able) within Web Inspector's Console tab. From there, it can be viewed and saved. Currently, `console.screenshot` will - capture an image of a `Node` (if provided) - capture an image of the viewport if nothing is provided * inspector/protocol/Console.json: Add `Image` enum value to `ConsoleMessage` type. * runtime/ConsoleTypes.h: * inspector/ConsoleMessage.h: * inspector/ConsoleMessage.cpp: (Inspector::messageTypeValue): * runtime/ConsoleClient.h: * runtime/ConsoleObject.cpp: (JSC::ConsoleObject::finishCreation): (JSC::consoleProtoFuncScreenshot): Added. * inspector/JSGlobalObjectConsoleClient.h: * inspector/JSGlobalObjectConsoleClient.cpp: (Inspector::JSGlobalObjectConsoleClient::screenshot): Added. Source/WebCore: Test: inspector/console/console-screenshot.html Add `console.screenshot` functionality, which displays a screenshot of a given object (if able) within Web Inspector's Console tab. From there, it can be viewed and saved. Currently, `console.screenshot` will - capture an image of a `Node` (if provided) - capture an image of the viewport if nothing is provided * page/PageConsoleClient.h: * page/PageConsoleClient.cpp: (WebCore::PageConsoleClient::addMessage): (WebCore::PageConsoleClient::screenshot): Added. * workers/WorkerConsoleClient.h: * workers/WorkerConsoleClient.cpp: (WebCore::WorkerConsoleClient::screenshot): Added. * worklets/WorkletConsoleClient.h: * worklets/WorkletConsoleClient.cpp: (WebCore::WorkletConsoleClient::screenshot): Added. * inspector/CommandLineAPIModuleSource.js: (CommandLineAPIImpl.prototype.screenshot): Added. * inspector/InspectorInstrumentation.h: Source/WebInspectorUI: Add `console.screenshot` functionality, which displays a screenshot of a given object (if able) within Web Inspector's Console tab. From there, it can be viewed and saved. Currently, `console.screenshot` will - capture an image of a `Node` (if provided) - capture an image of the viewport if nothing is provided * UserInterface/Models/ConsoleMessage.js: (WI.ConsoleMessage): * UserInterface/Views/ConsoleCommandView.js: (WI.ConsoleCommandView.prototype.render): * UserInterface/Views/ConsoleMessageView.js: (WI.ConsoleMessageView.prototype.render): (WI.ConsoleMessageView.prototype.toClipboardString): (WI.ConsoleMessageView.prototype._appendMessageTextAndArguments): (WI.ConsoleMessageView.prototype._appendSavedResultIndex): (WI.ConsoleMessageView.prototype._appendStackTrace): (WI.ConsoleMessageView.prototype._makeExpandable): (WI.ConsoleMessageView.prototype._handleContextMenu): Added. * UserInterface/Views/ConsoleMessageView.css: (.console-user-command.special-user-log > .console-message-body): Added. (.console-message-body): Added. (.console-message-body > span): Added. (.console-message-body > span > :matches(.console-message-enclosed, .console-message-preview, .console-message-preview-divider)): Added. (.console-message-body > .console-image): Added. (.console-message-body > .show-grid): Added. (.console-error-level .console-message-body): Added. (.console-warning-level .console-message-body): Added. (.console-log-level.console-image-container::before): Added. (.console-user-command > .console-message-body): Added. (.console-warning-level .console-message-body): Added. (.console-error-level .console-message-body): Added. (.console-user-command > .console-message-body): Added. (.console-user-command.special-user-log > .console-message-text): Deleted. (.console-message-text): Deleted. (.console-message-text > span): Deleted. (.console-message-text > span > :matches(.console-message-enclosed, .console-message-preview, .console-message-preview-divider)): Deleted. (.console-error-level .console-message-text): Deleted. (.console-warning-level .console-message-text): Deleted. (.console-user-command > .console-message-text): Deleted. (.console-warning-level .console-message-text): Deleted. (.console-error-level .console-message-text): Deleted. (.console-user-command > .console-message-text): Deleted. * UserInterface/Views/LogContentView.css: (.search-in-progress .console-item:not(.filtered-out-by-search).special-user-log .console-message-text .highlighted): Added. (.search-in-progress .console-item:not(.filtered-out-by-search).special-user-log .console-message-body .highlighted): Deleted. Renamed variables/classes to be more semantically correct when the content is an image. - `_messageTextElement` to `_messageBodyElement` (JS) - `.console-message-text` to `.console-message-body` (CSS) * UserInterface/Controllers/JavaScriptLogViewController.js: (WI.JavaScriptLogViewController.prototype.renderPendingMessages): * UserInterface/Views/Main.css: (:matches(img, canvas).show-grid): (@media (prefers-color-scheme: dark) :matches(img, canvas).show-grid): * UserInterface/Base/FileUtilities.js: (WI.FileUtilities.screenshotString): Added. * UserInterface/Models/NativeFunctionParameters.js: * UserInterface/Controllers/JavaScriptRuntimeCompletionProvider.js: * UserInterface/Images/ConsoleImage.svg: Copied from UserInterface/Images/Canvas.svg. * Localizations/en.lproj/localizedStrings.js: LayoutTests: * js/console.html: * js/console-expected.txt: * inspector/console/console-screenshot.html: Added. * inspector/console/console-screenshot-expected.txt: Added. * http/tests/inspector/dom/cross-domain-inspected-node-access-expected.txt: Canonical link: https://commits.webkit.org/210079@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@242992 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2019-03-15 08:12:21 +00:00
const fuzzingArguments = [
Web Inspector: provide method for recording CanvasRenderingContext2D from JavaScript https://bugs.webkit.org/show_bug.cgi?id=175166 <rdar://problem/34040740> Reviewed by Joseph Pecoraro. Source/JavaScriptCore: * inspector/protocol/Recording.json: Add optional `name` that will be used by the frontend for uniquely identifying the Recording. * inspector/JSGlobalObjectConsoleClient.h: * inspector/JSGlobalObjectConsoleClient.cpp: (Inspector::JSGlobalObjectConsoleClient::record): (Inspector::JSGlobalObjectConsoleClient::recordEnd): * runtime/ConsoleClient.h: * runtime/ConsoleObject.cpp: (JSC::ConsoleObject::finishCreation): (JSC::consoleProtoFuncRecord): (JSC::consoleProtoFuncRecordEnd): Source/WebCore: No new tests, updated existing tests. * inspector/InspectorCanvas.h: * inspector/InspectorCanvas.cpp: (WebCore::InspectorCanvas::resetRecordingData): * inspector/InspectorCanvasAgent.h: * inspector/InspectorCanvasAgent.cpp: (WebCore::InspectorCanvasAgent::didFinishRecordingCanvasFrame): (WebCore::InspectorCanvasAgent::consoleStartRecordingCanvas): * inspector/InspectorInstrumentation.h: * inspector/InspectorInstrumentation.cpp: (WebCore::InspectorInstrumentation::consoleStartRecordingCanvas): (WebCore::InspectorInstrumentation::consoleStartRecordingCanvasImpl): * page/PageConsoleClient.h: * page/PageConsoleClient.cpp: (WebCore::PageConsoleClient::record): (WebCore::PageConsoleClient::recordEnd): * workers/WorkerConsoleClient.h: * workers/WorkerConsoleClient.cpp: (WebCore::WorkerConsoleClient::record): (WebCore::WorkerConsoleClient::recordEnd): Source/WebInspectorUI: * UserInterface/Controllers/CanvasManager.js: (WI.CanvasManager.prototype.recordingFinished): If a `name` is sent with the payload, use it as the suggested name. * UserInterface/Models/NativeFunctionParameters.js: Add `console.record` and `console.recordEnd`. * UserInterface/Views/CanvasTabContentView.js: (WI.CanvasTabContentView.prototype.showRepresentedObject): Drive-by: remove logic that toggled the collapsed state of the navigation sidebar, as this was not very controllable by the user and often was aggravating. (WI.CanvasTabContentView.prototype._recordingStopped): Only show the recording if it was not started from the console. This can determined by CanvasManager when it recieves a recording if the recording's source is not the same as the current canvas being recorded. LayoutTests: * inspector/canvas/recording-2d-expected.txt: * inspector/canvas/recording-2d.html: (performConsoleRecording): * inspector/canvas/recording-webgl-expected.txt: * inspector/canvas/recording-webgl.html: (performConsoleRecording): * inspector/canvas/resources/recording-utilities.js: (TestPage.registerInitializer): * js/console-expected.txt: * js/console.html: Canonical link: https://commits.webkit.org/196332@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@225488 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2017-12-04 21:40:55 +00:00
`undefined`,
`null`,
`1`,
`"test"`,
`[]`,
`{}`,
`window`,
`console`,
];
debug("");
debug("fuzzing of target for console.record");
shouldNotThrow(`console.record()`);
Web Inspector: provide a way to capture a screenshot of a node from within the page https://bugs.webkit.org/show_bug.cgi?id=194279 <rdar://problem/10731573> Reviewed by Joseph Pecoraro. Source/JavaScriptCore: Add `console.screenshot` functionality, which displays a screenshot of a given object (if able) within Web Inspector's Console tab. From there, it can be viewed and saved. Currently, `console.screenshot` will - capture an image of a `Node` (if provided) - capture an image of the viewport if nothing is provided * inspector/protocol/Console.json: Add `Image` enum value to `ConsoleMessage` type. * runtime/ConsoleTypes.h: * inspector/ConsoleMessage.h: * inspector/ConsoleMessage.cpp: (Inspector::messageTypeValue): * runtime/ConsoleClient.h: * runtime/ConsoleObject.cpp: (JSC::ConsoleObject::finishCreation): (JSC::consoleProtoFuncScreenshot): Added. * inspector/JSGlobalObjectConsoleClient.h: * inspector/JSGlobalObjectConsoleClient.cpp: (Inspector::JSGlobalObjectConsoleClient::screenshot): Added. Source/WebCore: Test: inspector/console/console-screenshot.html Add `console.screenshot` functionality, which displays a screenshot of a given object (if able) within Web Inspector's Console tab. From there, it can be viewed and saved. Currently, `console.screenshot` will - capture an image of a `Node` (if provided) - capture an image of the viewport if nothing is provided * page/PageConsoleClient.h: * page/PageConsoleClient.cpp: (WebCore::PageConsoleClient::addMessage): (WebCore::PageConsoleClient::screenshot): Added. * workers/WorkerConsoleClient.h: * workers/WorkerConsoleClient.cpp: (WebCore::WorkerConsoleClient::screenshot): Added. * worklets/WorkletConsoleClient.h: * worklets/WorkletConsoleClient.cpp: (WebCore::WorkletConsoleClient::screenshot): Added. * inspector/CommandLineAPIModuleSource.js: (CommandLineAPIImpl.prototype.screenshot): Added. * inspector/InspectorInstrumentation.h: Source/WebInspectorUI: Add `console.screenshot` functionality, which displays a screenshot of a given object (if able) within Web Inspector's Console tab. From there, it can be viewed and saved. Currently, `console.screenshot` will - capture an image of a `Node` (if provided) - capture an image of the viewport if nothing is provided * UserInterface/Models/ConsoleMessage.js: (WI.ConsoleMessage): * UserInterface/Views/ConsoleCommandView.js: (WI.ConsoleCommandView.prototype.render): * UserInterface/Views/ConsoleMessageView.js: (WI.ConsoleMessageView.prototype.render): (WI.ConsoleMessageView.prototype.toClipboardString): (WI.ConsoleMessageView.prototype._appendMessageTextAndArguments): (WI.ConsoleMessageView.prototype._appendSavedResultIndex): (WI.ConsoleMessageView.prototype._appendStackTrace): (WI.ConsoleMessageView.prototype._makeExpandable): (WI.ConsoleMessageView.prototype._handleContextMenu): Added. * UserInterface/Views/ConsoleMessageView.css: (.console-user-command.special-user-log > .console-message-body): Added. (.console-message-body): Added. (.console-message-body > span): Added. (.console-message-body > span > :matches(.console-message-enclosed, .console-message-preview, .console-message-preview-divider)): Added. (.console-message-body > .console-image): Added. (.console-message-body > .show-grid): Added. (.console-error-level .console-message-body): Added. (.console-warning-level .console-message-body): Added. (.console-log-level.console-image-container::before): Added. (.console-user-command > .console-message-body): Added. (.console-warning-level .console-message-body): Added. (.console-error-level .console-message-body): Added. (.console-user-command > .console-message-body): Added. (.console-user-command.special-user-log > .console-message-text): Deleted. (.console-message-text): Deleted. (.console-message-text > span): Deleted. (.console-message-text > span > :matches(.console-message-enclosed, .console-message-preview, .console-message-preview-divider)): Deleted. (.console-error-level .console-message-text): Deleted. (.console-warning-level .console-message-text): Deleted. (.console-user-command > .console-message-text): Deleted. (.console-warning-level .console-message-text): Deleted. (.console-error-level .console-message-text): Deleted. (.console-user-command > .console-message-text): Deleted. * UserInterface/Views/LogContentView.css: (.search-in-progress .console-item:not(.filtered-out-by-search).special-user-log .console-message-text .highlighted): Added. (.search-in-progress .console-item:not(.filtered-out-by-search).special-user-log .console-message-body .highlighted): Deleted. Renamed variables/classes to be more semantically correct when the content is an image. - `_messageTextElement` to `_messageBodyElement` (JS) - `.console-message-text` to `.console-message-body` (CSS) * UserInterface/Controllers/JavaScriptLogViewController.js: (WI.JavaScriptLogViewController.prototype.renderPendingMessages): * UserInterface/Views/Main.css: (:matches(img, canvas).show-grid): (@media (prefers-color-scheme: dark) :matches(img, canvas).show-grid): * UserInterface/Base/FileUtilities.js: (WI.FileUtilities.screenshotString): Added. * UserInterface/Models/NativeFunctionParameters.js: * UserInterface/Controllers/JavaScriptRuntimeCompletionProvider.js: * UserInterface/Images/ConsoleImage.svg: Copied from UserInterface/Images/Canvas.svg. * Localizations/en.lproj/localizedStrings.js: LayoutTests: * js/console.html: * js/console-expected.txt: * inspector/console/console-screenshot.html: Added. * inspector/console/console-screenshot-expected.txt: Added. * http/tests/inspector/dom/cross-domain-inspected-node-access-expected.txt: Canonical link: https://commits.webkit.org/210079@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@242992 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2019-03-15 08:12:21 +00:00
for (let argument of fuzzingArguments)
Web Inspector: provide method for recording CanvasRenderingContext2D from JavaScript https://bugs.webkit.org/show_bug.cgi?id=175166 <rdar://problem/34040740> Reviewed by Joseph Pecoraro. Source/JavaScriptCore: * inspector/protocol/Recording.json: Add optional `name` that will be used by the frontend for uniquely identifying the Recording. * inspector/JSGlobalObjectConsoleClient.h: * inspector/JSGlobalObjectConsoleClient.cpp: (Inspector::JSGlobalObjectConsoleClient::record): (Inspector::JSGlobalObjectConsoleClient::recordEnd): * runtime/ConsoleClient.h: * runtime/ConsoleObject.cpp: (JSC::ConsoleObject::finishCreation): (JSC::consoleProtoFuncRecord): (JSC::consoleProtoFuncRecordEnd): Source/WebCore: No new tests, updated existing tests. * inspector/InspectorCanvas.h: * inspector/InspectorCanvas.cpp: (WebCore::InspectorCanvas::resetRecordingData): * inspector/InspectorCanvasAgent.h: * inspector/InspectorCanvasAgent.cpp: (WebCore::InspectorCanvasAgent::didFinishRecordingCanvasFrame): (WebCore::InspectorCanvasAgent::consoleStartRecordingCanvas): * inspector/InspectorInstrumentation.h: * inspector/InspectorInstrumentation.cpp: (WebCore::InspectorInstrumentation::consoleStartRecordingCanvas): (WebCore::InspectorInstrumentation::consoleStartRecordingCanvasImpl): * page/PageConsoleClient.h: * page/PageConsoleClient.cpp: (WebCore::PageConsoleClient::record): (WebCore::PageConsoleClient::recordEnd): * workers/WorkerConsoleClient.h: * workers/WorkerConsoleClient.cpp: (WebCore::WorkerConsoleClient::record): (WebCore::WorkerConsoleClient::recordEnd): Source/WebInspectorUI: * UserInterface/Controllers/CanvasManager.js: (WI.CanvasManager.prototype.recordingFinished): If a `name` is sent with the payload, use it as the suggested name. * UserInterface/Models/NativeFunctionParameters.js: Add `console.record` and `console.recordEnd`. * UserInterface/Views/CanvasTabContentView.js: (WI.CanvasTabContentView.prototype.showRepresentedObject): Drive-by: remove logic that toggled the collapsed state of the navigation sidebar, as this was not very controllable by the user and often was aggravating. (WI.CanvasTabContentView.prototype._recordingStopped): Only show the recording if it was not started from the console. This can determined by CanvasManager when it recieves a recording if the recording's source is not the same as the current canvas being recorded. LayoutTests: * inspector/canvas/recording-2d-expected.txt: * inspector/canvas/recording-2d.html: (performConsoleRecording): * inspector/canvas/recording-webgl-expected.txt: * inspector/canvas/recording-webgl.html: (performConsoleRecording): * inspector/canvas/resources/recording-utilities.js: (TestPage.registerInitializer): * js/console-expected.txt: * js/console.html: Canonical link: https://commits.webkit.org/196332@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@225488 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2017-12-04 21:40:55 +00:00
shouldNotThrow(`console.record(${argument})`);
debug("");
debug("fuzzing of options for console.record");
Web Inspector: provide a way to capture a screenshot of a node from within the page https://bugs.webkit.org/show_bug.cgi?id=194279 <rdar://problem/10731573> Reviewed by Joseph Pecoraro. Source/JavaScriptCore: Add `console.screenshot` functionality, which displays a screenshot of a given object (if able) within Web Inspector's Console tab. From there, it can be viewed and saved. Currently, `console.screenshot` will - capture an image of a `Node` (if provided) - capture an image of the viewport if nothing is provided * inspector/protocol/Console.json: Add `Image` enum value to `ConsoleMessage` type. * runtime/ConsoleTypes.h: * inspector/ConsoleMessage.h: * inspector/ConsoleMessage.cpp: (Inspector::messageTypeValue): * runtime/ConsoleClient.h: * runtime/ConsoleObject.cpp: (JSC::ConsoleObject::finishCreation): (JSC::consoleProtoFuncScreenshot): Added. * inspector/JSGlobalObjectConsoleClient.h: * inspector/JSGlobalObjectConsoleClient.cpp: (Inspector::JSGlobalObjectConsoleClient::screenshot): Added. Source/WebCore: Test: inspector/console/console-screenshot.html Add `console.screenshot` functionality, which displays a screenshot of a given object (if able) within Web Inspector's Console tab. From there, it can be viewed and saved. Currently, `console.screenshot` will - capture an image of a `Node` (if provided) - capture an image of the viewport if nothing is provided * page/PageConsoleClient.h: * page/PageConsoleClient.cpp: (WebCore::PageConsoleClient::addMessage): (WebCore::PageConsoleClient::screenshot): Added. * workers/WorkerConsoleClient.h: * workers/WorkerConsoleClient.cpp: (WebCore::WorkerConsoleClient::screenshot): Added. * worklets/WorkletConsoleClient.h: * worklets/WorkletConsoleClient.cpp: (WebCore::WorkletConsoleClient::screenshot): Added. * inspector/CommandLineAPIModuleSource.js: (CommandLineAPIImpl.prototype.screenshot): Added. * inspector/InspectorInstrumentation.h: Source/WebInspectorUI: Add `console.screenshot` functionality, which displays a screenshot of a given object (if able) within Web Inspector's Console tab. From there, it can be viewed and saved. Currently, `console.screenshot` will - capture an image of a `Node` (if provided) - capture an image of the viewport if nothing is provided * UserInterface/Models/ConsoleMessage.js: (WI.ConsoleMessage): * UserInterface/Views/ConsoleCommandView.js: (WI.ConsoleCommandView.prototype.render): * UserInterface/Views/ConsoleMessageView.js: (WI.ConsoleMessageView.prototype.render): (WI.ConsoleMessageView.prototype.toClipboardString): (WI.ConsoleMessageView.prototype._appendMessageTextAndArguments): (WI.ConsoleMessageView.prototype._appendSavedResultIndex): (WI.ConsoleMessageView.prototype._appendStackTrace): (WI.ConsoleMessageView.prototype._makeExpandable): (WI.ConsoleMessageView.prototype._handleContextMenu): Added. * UserInterface/Views/ConsoleMessageView.css: (.console-user-command.special-user-log > .console-message-body): Added. (.console-message-body): Added. (.console-message-body > span): Added. (.console-message-body > span > :matches(.console-message-enclosed, .console-message-preview, .console-message-preview-divider)): Added. (.console-message-body > .console-image): Added. (.console-message-body > .show-grid): Added. (.console-error-level .console-message-body): Added. (.console-warning-level .console-message-body): Added. (.console-log-level.console-image-container::before): Added. (.console-user-command > .console-message-body): Added. (.console-warning-level .console-message-body): Added. (.console-error-level .console-message-body): Added. (.console-user-command > .console-message-body): Added. (.console-user-command.special-user-log > .console-message-text): Deleted. (.console-message-text): Deleted. (.console-message-text > span): Deleted. (.console-message-text > span > :matches(.console-message-enclosed, .console-message-preview, .console-message-preview-divider)): Deleted. (.console-error-level .console-message-text): Deleted. (.console-warning-level .console-message-text): Deleted. (.console-user-command > .console-message-text): Deleted. (.console-warning-level .console-message-text): Deleted. (.console-error-level .console-message-text): Deleted. (.console-user-command > .console-message-text): Deleted. * UserInterface/Views/LogContentView.css: (.search-in-progress .console-item:not(.filtered-out-by-search).special-user-log .console-message-text .highlighted): Added. (.search-in-progress .console-item:not(.filtered-out-by-search).special-user-log .console-message-body .highlighted): Deleted. Renamed variables/classes to be more semantically correct when the content is an image. - `_messageTextElement` to `_messageBodyElement` (JS) - `.console-message-text` to `.console-message-body` (CSS) * UserInterface/Controllers/JavaScriptLogViewController.js: (WI.JavaScriptLogViewController.prototype.renderPendingMessages): * UserInterface/Views/Main.css: (:matches(img, canvas).show-grid): (@media (prefers-color-scheme: dark) :matches(img, canvas).show-grid): * UserInterface/Base/FileUtilities.js: (WI.FileUtilities.screenshotString): Added. * UserInterface/Models/NativeFunctionParameters.js: * UserInterface/Controllers/JavaScriptRuntimeCompletionProvider.js: * UserInterface/Images/ConsoleImage.svg: Copied from UserInterface/Images/Canvas.svg. * Localizations/en.lproj/localizedStrings.js: LayoutTests: * js/console.html: * js/console-expected.txt: * inspector/console/console-screenshot.html: Added. * inspector/console/console-screenshot-expected.txt: Added. * http/tests/inspector/dom/cross-domain-inspected-node-access-expected.txt: Canonical link: https://commits.webkit.org/210079@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@242992 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2019-03-15 08:12:21 +00:00
for (let argument of fuzzingArguments)
Web Inspector: provide method for recording CanvasRenderingContext2D from JavaScript https://bugs.webkit.org/show_bug.cgi?id=175166 <rdar://problem/34040740> Reviewed by Joseph Pecoraro. Source/JavaScriptCore: * inspector/protocol/Recording.json: Add optional `name` that will be used by the frontend for uniquely identifying the Recording. * inspector/JSGlobalObjectConsoleClient.h: * inspector/JSGlobalObjectConsoleClient.cpp: (Inspector::JSGlobalObjectConsoleClient::record): (Inspector::JSGlobalObjectConsoleClient::recordEnd): * runtime/ConsoleClient.h: * runtime/ConsoleObject.cpp: (JSC::ConsoleObject::finishCreation): (JSC::consoleProtoFuncRecord): (JSC::consoleProtoFuncRecordEnd): Source/WebCore: No new tests, updated existing tests. * inspector/InspectorCanvas.h: * inspector/InspectorCanvas.cpp: (WebCore::InspectorCanvas::resetRecordingData): * inspector/InspectorCanvasAgent.h: * inspector/InspectorCanvasAgent.cpp: (WebCore::InspectorCanvasAgent::didFinishRecordingCanvasFrame): (WebCore::InspectorCanvasAgent::consoleStartRecordingCanvas): * inspector/InspectorInstrumentation.h: * inspector/InspectorInstrumentation.cpp: (WebCore::InspectorInstrumentation::consoleStartRecordingCanvas): (WebCore::InspectorInstrumentation::consoleStartRecordingCanvasImpl): * page/PageConsoleClient.h: * page/PageConsoleClient.cpp: (WebCore::PageConsoleClient::record): (WebCore::PageConsoleClient::recordEnd): * workers/WorkerConsoleClient.h: * workers/WorkerConsoleClient.cpp: (WebCore::WorkerConsoleClient::record): (WebCore::WorkerConsoleClient::recordEnd): Source/WebInspectorUI: * UserInterface/Controllers/CanvasManager.js: (WI.CanvasManager.prototype.recordingFinished): If a `name` is sent with the payload, use it as the suggested name. * UserInterface/Models/NativeFunctionParameters.js: Add `console.record` and `console.recordEnd`. * UserInterface/Views/CanvasTabContentView.js: (WI.CanvasTabContentView.prototype.showRepresentedObject): Drive-by: remove logic that toggled the collapsed state of the navigation sidebar, as this was not very controllable by the user and often was aggravating. (WI.CanvasTabContentView.prototype._recordingStopped): Only show the recording if it was not started from the console. This can determined by CanvasManager when it recieves a recording if the recording's source is not the same as the current canvas being recorded. LayoutTests: * inspector/canvas/recording-2d-expected.txt: * inspector/canvas/recording-2d.html: (performConsoleRecording): * inspector/canvas/recording-webgl-expected.txt: * inspector/canvas/recording-webgl.html: (performConsoleRecording): * inspector/canvas/resources/recording-utilities.js: (TestPage.registerInitializer): * js/console-expected.txt: * js/console.html: Canonical link: https://commits.webkit.org/196332@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@225488 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2017-12-04 21:40:55 +00:00
shouldNotThrow(`console.record({}, ${argument})`);
debug("");
debug("fuzzing of target for console.recordEnd");
shouldNotThrow(`console.recordEnd()`);
Web Inspector: provide a way to capture a screenshot of a node from within the page https://bugs.webkit.org/show_bug.cgi?id=194279 <rdar://problem/10731573> Reviewed by Joseph Pecoraro. Source/JavaScriptCore: Add `console.screenshot` functionality, which displays a screenshot of a given object (if able) within Web Inspector's Console tab. From there, it can be viewed and saved. Currently, `console.screenshot` will - capture an image of a `Node` (if provided) - capture an image of the viewport if nothing is provided * inspector/protocol/Console.json: Add `Image` enum value to `ConsoleMessage` type. * runtime/ConsoleTypes.h: * inspector/ConsoleMessage.h: * inspector/ConsoleMessage.cpp: (Inspector::messageTypeValue): * runtime/ConsoleClient.h: * runtime/ConsoleObject.cpp: (JSC::ConsoleObject::finishCreation): (JSC::consoleProtoFuncScreenshot): Added. * inspector/JSGlobalObjectConsoleClient.h: * inspector/JSGlobalObjectConsoleClient.cpp: (Inspector::JSGlobalObjectConsoleClient::screenshot): Added. Source/WebCore: Test: inspector/console/console-screenshot.html Add `console.screenshot` functionality, which displays a screenshot of a given object (if able) within Web Inspector's Console tab. From there, it can be viewed and saved. Currently, `console.screenshot` will - capture an image of a `Node` (if provided) - capture an image of the viewport if nothing is provided * page/PageConsoleClient.h: * page/PageConsoleClient.cpp: (WebCore::PageConsoleClient::addMessage): (WebCore::PageConsoleClient::screenshot): Added. * workers/WorkerConsoleClient.h: * workers/WorkerConsoleClient.cpp: (WebCore::WorkerConsoleClient::screenshot): Added. * worklets/WorkletConsoleClient.h: * worklets/WorkletConsoleClient.cpp: (WebCore::WorkletConsoleClient::screenshot): Added. * inspector/CommandLineAPIModuleSource.js: (CommandLineAPIImpl.prototype.screenshot): Added. * inspector/InspectorInstrumentation.h: Source/WebInspectorUI: Add `console.screenshot` functionality, which displays a screenshot of a given object (if able) within Web Inspector's Console tab. From there, it can be viewed and saved. Currently, `console.screenshot` will - capture an image of a `Node` (if provided) - capture an image of the viewport if nothing is provided * UserInterface/Models/ConsoleMessage.js: (WI.ConsoleMessage): * UserInterface/Views/ConsoleCommandView.js: (WI.ConsoleCommandView.prototype.render): * UserInterface/Views/ConsoleMessageView.js: (WI.ConsoleMessageView.prototype.render): (WI.ConsoleMessageView.prototype.toClipboardString): (WI.ConsoleMessageView.prototype._appendMessageTextAndArguments): (WI.ConsoleMessageView.prototype._appendSavedResultIndex): (WI.ConsoleMessageView.prototype._appendStackTrace): (WI.ConsoleMessageView.prototype._makeExpandable): (WI.ConsoleMessageView.prototype._handleContextMenu): Added. * UserInterface/Views/ConsoleMessageView.css: (.console-user-command.special-user-log > .console-message-body): Added. (.console-message-body): Added. (.console-message-body > span): Added. (.console-message-body > span > :matches(.console-message-enclosed, .console-message-preview, .console-message-preview-divider)): Added. (.console-message-body > .console-image): Added. (.console-message-body > .show-grid): Added. (.console-error-level .console-message-body): Added. (.console-warning-level .console-message-body): Added. (.console-log-level.console-image-container::before): Added. (.console-user-command > .console-message-body): Added. (.console-warning-level .console-message-body): Added. (.console-error-level .console-message-body): Added. (.console-user-command > .console-message-body): Added. (.console-user-command.special-user-log > .console-message-text): Deleted. (.console-message-text): Deleted. (.console-message-text > span): Deleted. (.console-message-text > span > :matches(.console-message-enclosed, .console-message-preview, .console-message-preview-divider)): Deleted. (.console-error-level .console-message-text): Deleted. (.console-warning-level .console-message-text): Deleted. (.console-user-command > .console-message-text): Deleted. (.console-warning-level .console-message-text): Deleted. (.console-error-level .console-message-text): Deleted. (.console-user-command > .console-message-text): Deleted. * UserInterface/Views/LogContentView.css: (.search-in-progress .console-item:not(.filtered-out-by-search).special-user-log .console-message-text .highlighted): Added. (.search-in-progress .console-item:not(.filtered-out-by-search).special-user-log .console-message-body .highlighted): Deleted. Renamed variables/classes to be more semantically correct when the content is an image. - `_messageTextElement` to `_messageBodyElement` (JS) - `.console-message-text` to `.console-message-body` (CSS) * UserInterface/Controllers/JavaScriptLogViewController.js: (WI.JavaScriptLogViewController.prototype.renderPendingMessages): * UserInterface/Views/Main.css: (:matches(img, canvas).show-grid): (@media (prefers-color-scheme: dark) :matches(img, canvas).show-grid): * UserInterface/Base/FileUtilities.js: (WI.FileUtilities.screenshotString): Added. * UserInterface/Models/NativeFunctionParameters.js: * UserInterface/Controllers/JavaScriptRuntimeCompletionProvider.js: * UserInterface/Images/ConsoleImage.svg: Copied from UserInterface/Images/Canvas.svg. * Localizations/en.lproj/localizedStrings.js: LayoutTests: * js/console.html: * js/console-expected.txt: * inspector/console/console-screenshot.html: Added. * inspector/console/console-screenshot-expected.txt: Added. * http/tests/inspector/dom/cross-domain-inspected-node-access-expected.txt: Canonical link: https://commits.webkit.org/210079@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@242992 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2019-03-15 08:12:21 +00:00
for (let argument of fuzzingArguments)
Web Inspector: provide method for recording CanvasRenderingContext2D from JavaScript https://bugs.webkit.org/show_bug.cgi?id=175166 <rdar://problem/34040740> Reviewed by Joseph Pecoraro. Source/JavaScriptCore: * inspector/protocol/Recording.json: Add optional `name` that will be used by the frontend for uniquely identifying the Recording. * inspector/JSGlobalObjectConsoleClient.h: * inspector/JSGlobalObjectConsoleClient.cpp: (Inspector::JSGlobalObjectConsoleClient::record): (Inspector::JSGlobalObjectConsoleClient::recordEnd): * runtime/ConsoleClient.h: * runtime/ConsoleObject.cpp: (JSC::ConsoleObject::finishCreation): (JSC::consoleProtoFuncRecord): (JSC::consoleProtoFuncRecordEnd): Source/WebCore: No new tests, updated existing tests. * inspector/InspectorCanvas.h: * inspector/InspectorCanvas.cpp: (WebCore::InspectorCanvas::resetRecordingData): * inspector/InspectorCanvasAgent.h: * inspector/InspectorCanvasAgent.cpp: (WebCore::InspectorCanvasAgent::didFinishRecordingCanvasFrame): (WebCore::InspectorCanvasAgent::consoleStartRecordingCanvas): * inspector/InspectorInstrumentation.h: * inspector/InspectorInstrumentation.cpp: (WebCore::InspectorInstrumentation::consoleStartRecordingCanvas): (WebCore::InspectorInstrumentation::consoleStartRecordingCanvasImpl): * page/PageConsoleClient.h: * page/PageConsoleClient.cpp: (WebCore::PageConsoleClient::record): (WebCore::PageConsoleClient::recordEnd): * workers/WorkerConsoleClient.h: * workers/WorkerConsoleClient.cpp: (WebCore::WorkerConsoleClient::record): (WebCore::WorkerConsoleClient::recordEnd): Source/WebInspectorUI: * UserInterface/Controllers/CanvasManager.js: (WI.CanvasManager.prototype.recordingFinished): If a `name` is sent with the payload, use it as the suggested name. * UserInterface/Models/NativeFunctionParameters.js: Add `console.record` and `console.recordEnd`. * UserInterface/Views/CanvasTabContentView.js: (WI.CanvasTabContentView.prototype.showRepresentedObject): Drive-by: remove logic that toggled the collapsed state of the navigation sidebar, as this was not very controllable by the user and often was aggravating. (WI.CanvasTabContentView.prototype._recordingStopped): Only show the recording if it was not started from the console. This can determined by CanvasManager when it recieves a recording if the recording's source is not the same as the current canvas being recorded. LayoutTests: * inspector/canvas/recording-2d-expected.txt: * inspector/canvas/recording-2d.html: (performConsoleRecording): * inspector/canvas/recording-webgl-expected.txt: * inspector/canvas/recording-webgl.html: (performConsoleRecording): * inspector/canvas/resources/recording-utilities.js: (TestPage.registerInitializer): * js/console-expected.txt: * js/console.html: Canonical link: https://commits.webkit.org/196332@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@225488 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2017-12-04 21:40:55 +00:00
shouldNotThrow(`console.recordEnd(${argument})`);
debug("");
debug("ensure multiple calls don't throw");
shouldNotThrow(`console.recordEnd(window.canvas)`);
shouldNotThrow(`console.recordEnd(window.canvas)`);
shouldNotThrow(`console.recordEnd(window.canvas)`);
shouldNotThrow(`console.record(window.canvas)`);
shouldNotThrow(`console.record(window.canvas)`);
shouldNotThrow(`console.record(window.canvas)`);
Web Inspector: provide a way to capture a screenshot of a node from within the page https://bugs.webkit.org/show_bug.cgi?id=194279 <rdar://problem/10731573> Reviewed by Joseph Pecoraro. Source/JavaScriptCore: Add `console.screenshot` functionality, which displays a screenshot of a given object (if able) within Web Inspector's Console tab. From there, it can be viewed and saved. Currently, `console.screenshot` will - capture an image of a `Node` (if provided) - capture an image of the viewport if nothing is provided * inspector/protocol/Console.json: Add `Image` enum value to `ConsoleMessage` type. * runtime/ConsoleTypes.h: * inspector/ConsoleMessage.h: * inspector/ConsoleMessage.cpp: (Inspector::messageTypeValue): * runtime/ConsoleClient.h: * runtime/ConsoleObject.cpp: (JSC::ConsoleObject::finishCreation): (JSC::consoleProtoFuncScreenshot): Added. * inspector/JSGlobalObjectConsoleClient.h: * inspector/JSGlobalObjectConsoleClient.cpp: (Inspector::JSGlobalObjectConsoleClient::screenshot): Added. Source/WebCore: Test: inspector/console/console-screenshot.html Add `console.screenshot` functionality, which displays a screenshot of a given object (if able) within Web Inspector's Console tab. From there, it can be viewed and saved. Currently, `console.screenshot` will - capture an image of a `Node` (if provided) - capture an image of the viewport if nothing is provided * page/PageConsoleClient.h: * page/PageConsoleClient.cpp: (WebCore::PageConsoleClient::addMessage): (WebCore::PageConsoleClient::screenshot): Added. * workers/WorkerConsoleClient.h: * workers/WorkerConsoleClient.cpp: (WebCore::WorkerConsoleClient::screenshot): Added. * worklets/WorkletConsoleClient.h: * worklets/WorkletConsoleClient.cpp: (WebCore::WorkletConsoleClient::screenshot): Added. * inspector/CommandLineAPIModuleSource.js: (CommandLineAPIImpl.prototype.screenshot): Added. * inspector/InspectorInstrumentation.h: Source/WebInspectorUI: Add `console.screenshot` functionality, which displays a screenshot of a given object (if able) within Web Inspector's Console tab. From there, it can be viewed and saved. Currently, `console.screenshot` will - capture an image of a `Node` (if provided) - capture an image of the viewport if nothing is provided * UserInterface/Models/ConsoleMessage.js: (WI.ConsoleMessage): * UserInterface/Views/ConsoleCommandView.js: (WI.ConsoleCommandView.prototype.render): * UserInterface/Views/ConsoleMessageView.js: (WI.ConsoleMessageView.prototype.render): (WI.ConsoleMessageView.prototype.toClipboardString): (WI.ConsoleMessageView.prototype._appendMessageTextAndArguments): (WI.ConsoleMessageView.prototype._appendSavedResultIndex): (WI.ConsoleMessageView.prototype._appendStackTrace): (WI.ConsoleMessageView.prototype._makeExpandable): (WI.ConsoleMessageView.prototype._handleContextMenu): Added. * UserInterface/Views/ConsoleMessageView.css: (.console-user-command.special-user-log > .console-message-body): Added. (.console-message-body): Added. (.console-message-body > span): Added. (.console-message-body > span > :matches(.console-message-enclosed, .console-message-preview, .console-message-preview-divider)): Added. (.console-message-body > .console-image): Added. (.console-message-body > .show-grid): Added. (.console-error-level .console-message-body): Added. (.console-warning-level .console-message-body): Added. (.console-log-level.console-image-container::before): Added. (.console-user-command > .console-message-body): Added. (.console-warning-level .console-message-body): Added. (.console-error-level .console-message-body): Added. (.console-user-command > .console-message-body): Added. (.console-user-command.special-user-log > .console-message-text): Deleted. (.console-message-text): Deleted. (.console-message-text > span): Deleted. (.console-message-text > span > :matches(.console-message-enclosed, .console-message-preview, .console-message-preview-divider)): Deleted. (.console-error-level .console-message-text): Deleted. (.console-warning-level .console-message-text): Deleted. (.console-user-command > .console-message-text): Deleted. (.console-warning-level .console-message-text): Deleted. (.console-error-level .console-message-text): Deleted. (.console-user-command > .console-message-text): Deleted. * UserInterface/Views/LogContentView.css: (.search-in-progress .console-item:not(.filtered-out-by-search).special-user-log .console-message-text .highlighted): Added. (.search-in-progress .console-item:not(.filtered-out-by-search).special-user-log .console-message-body .highlighted): Deleted. Renamed variables/classes to be more semantically correct when the content is an image. - `_messageTextElement` to `_messageBodyElement` (JS) - `.console-message-text` to `.console-message-body` (CSS) * UserInterface/Controllers/JavaScriptLogViewController.js: (WI.JavaScriptLogViewController.prototype.renderPendingMessages): * UserInterface/Views/Main.css: (:matches(img, canvas).show-grid): (@media (prefers-color-scheme: dark) :matches(img, canvas).show-grid): * UserInterface/Base/FileUtilities.js: (WI.FileUtilities.screenshotString): Added. * UserInterface/Models/NativeFunctionParameters.js: * UserInterface/Controllers/JavaScriptRuntimeCompletionProvider.js: * UserInterface/Images/ConsoleImage.svg: Copied from UserInterface/Images/Canvas.svg. * Localizations/en.lproj/localizedStrings.js: LayoutTests: * js/console.html: * js/console-expected.txt: * inspector/console/console-screenshot.html: Added. * inspector/console/console-screenshot-expected.txt: Added. * http/tests/inspector/dom/cross-domain-inspected-node-access-expected.txt: Canonical link: https://commits.webkit.org/210079@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@242992 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2019-03-15 08:12:21 +00:00
debug("");
debug("fuzzing of target for console.screenshot");
shouldNotThrow(`console.screenshot()`);
for (let argument of fuzzingArguments)
shouldNotThrow(`console.screenshot(${argument})`);
debug("");
Make console a namespace object (like Math/JSON), allowing functions to be called unbound https://bugs.webkit.org/show_bug.cgi?id=157286 <rdar://problem/26052830> Patch by Joseph Pecoraro <pecoraro@apple.com> on 2016-05-02 Reviewed by Timothy Hatcher. Source/JavaScriptCore: This changes `console` to be a global namespace object, like `Math` and `JSON`. It just holds a bunch of functions, that can be used on their own, unbound. For example, `[1,2,3].forEach(console.log)` and `var log = console.log; log(1)` used to throw exceptions and now do not. Previously console was an Object/Prototype pair, so functions were on ConsolePrototype (console.__proto__.log) and they needed to be called Console objects as the `this` value. Now, `console` is just a standard object with a bunch of functions. Since there is no console prototype the functions can be passed around and called as expected and they will just do the right thing. For compatability with other browsers, `console` was made enumerable on the global object. * CMakeLists.txt: * JavaScriptCore.xcodeproj/project.pbxproj: Add new files and remove old files. * runtime/CommonIdentifiers.h: Add "console". * runtime/ConsoleObject.cpp: Renamed from Source/JavaScriptCore/runtime/ConsolePrototype.cpp. (JSC::ConsoleObject::ConsoleObject): (JSC::ConsoleObject::finishCreation): (JSC::valueToStringWithUndefinedOrNullCheck): (JSC::consoleLogWithLevel): (JSC::consoleProtoFuncDebug): (JSC::consoleProtoFuncError): (JSC::consoleProtoFuncLog): (JSC::consoleProtoFuncInfo): (JSC::consoleProtoFuncWarn): (JSC::consoleProtoFuncClear): (JSC::consoleProtoFuncDir): (JSC::consoleProtoFuncDirXML): (JSC::consoleProtoFuncTable): (JSC::consoleProtoFuncTrace): (JSC::consoleProtoFuncAssert): (JSC::consoleProtoFuncCount): (JSC::consoleProtoFuncProfile): (JSC::consoleProtoFuncProfileEnd): (JSC::consoleProtoFuncTakeHeapSnapshot): (JSC::consoleProtoFuncTime): (JSC::consoleProtoFuncTimeEnd): (JSC::consoleProtoFuncTimeStamp): (JSC::consoleProtoFuncGroup): (JSC::consoleProtoFuncGroupCollapsed): (JSC::consoleProtoFuncGroupEnd): Console functions no longer need to check if the this object is a Console object. They will always just work now. * runtime/MathObject.cpp: * runtime/MathObject.h: * runtime/ConsoleObject.h: Renamed from Source/JavaScriptCore/runtime/ConsolePrototype.h. (JSC::ConsoleObject::create): (JSC::ConsoleObject::createStructure): ConsoleObject is a basic object like MathObject. * runtime/JSConsole.cpp: Removed. * runtime/JSConsole.h: Removed. * runtime/JSGlobalObject.h: * runtime/JSGlobalObject.cpp: (JSC::JSGlobalObject::init): (JSC::JSGlobalObject::visitChildren): Remove JSConsole / ConsolePrototype in favor of the single ConsoleObject. LayoutTests: * js/console-expected.txt: Added. * js/console.html: Added. Canonical link: https://commits.webkit.org/175386@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@200350 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2016-05-03 00:51:24 +00:00
</script>
<script src="../resources/js-test-post.js"></script>
Web Inspector: provide method for recording CanvasRenderingContext2D from JavaScript https://bugs.webkit.org/show_bug.cgi?id=175166 <rdar://problem/34040740> Reviewed by Joseph Pecoraro. Source/JavaScriptCore: * inspector/protocol/Recording.json: Add optional `name` that will be used by the frontend for uniquely identifying the Recording. * inspector/JSGlobalObjectConsoleClient.h: * inspector/JSGlobalObjectConsoleClient.cpp: (Inspector::JSGlobalObjectConsoleClient::record): (Inspector::JSGlobalObjectConsoleClient::recordEnd): * runtime/ConsoleClient.h: * runtime/ConsoleObject.cpp: (JSC::ConsoleObject::finishCreation): (JSC::consoleProtoFuncRecord): (JSC::consoleProtoFuncRecordEnd): Source/WebCore: No new tests, updated existing tests. * inspector/InspectorCanvas.h: * inspector/InspectorCanvas.cpp: (WebCore::InspectorCanvas::resetRecordingData): * inspector/InspectorCanvasAgent.h: * inspector/InspectorCanvasAgent.cpp: (WebCore::InspectorCanvasAgent::didFinishRecordingCanvasFrame): (WebCore::InspectorCanvasAgent::consoleStartRecordingCanvas): * inspector/InspectorInstrumentation.h: * inspector/InspectorInstrumentation.cpp: (WebCore::InspectorInstrumentation::consoleStartRecordingCanvas): (WebCore::InspectorInstrumentation::consoleStartRecordingCanvasImpl): * page/PageConsoleClient.h: * page/PageConsoleClient.cpp: (WebCore::PageConsoleClient::record): (WebCore::PageConsoleClient::recordEnd): * workers/WorkerConsoleClient.h: * workers/WorkerConsoleClient.cpp: (WebCore::WorkerConsoleClient::record): (WebCore::WorkerConsoleClient::recordEnd): Source/WebInspectorUI: * UserInterface/Controllers/CanvasManager.js: (WI.CanvasManager.prototype.recordingFinished): If a `name` is sent with the payload, use it as the suggested name. * UserInterface/Models/NativeFunctionParameters.js: Add `console.record` and `console.recordEnd`. * UserInterface/Views/CanvasTabContentView.js: (WI.CanvasTabContentView.prototype.showRepresentedObject): Drive-by: remove logic that toggled the collapsed state of the navigation sidebar, as this was not very controllable by the user and often was aggravating. (WI.CanvasTabContentView.prototype._recordingStopped): Only show the recording if it was not started from the console. This can determined by CanvasManager when it recieves a recording if the recording's source is not the same as the current canvas being recorded. LayoutTests: * inspector/canvas/recording-2d-expected.txt: * inspector/canvas/recording-2d.html: (performConsoleRecording): * inspector/canvas/recording-webgl-expected.txt: * inspector/canvas/recording-webgl.html: (performConsoleRecording): * inspector/canvas/resources/recording-utilities.js: (TestPage.registerInitializer): * js/console-expected.txt: * js/console.html: Canonical link: https://commits.webkit.org/196332@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@225488 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2017-12-04 21:40:55 +00:00
<canvas id="canvas"></canvas>
Make console a namespace object (like Math/JSON), allowing functions to be called unbound https://bugs.webkit.org/show_bug.cgi?id=157286 <rdar://problem/26052830> Patch by Joseph Pecoraro <pecoraro@apple.com> on 2016-05-02 Reviewed by Timothy Hatcher. Source/JavaScriptCore: This changes `console` to be a global namespace object, like `Math` and `JSON`. It just holds a bunch of functions, that can be used on their own, unbound. For example, `[1,2,3].forEach(console.log)` and `var log = console.log; log(1)` used to throw exceptions and now do not. Previously console was an Object/Prototype pair, so functions were on ConsolePrototype (console.__proto__.log) and they needed to be called Console objects as the `this` value. Now, `console` is just a standard object with a bunch of functions. Since there is no console prototype the functions can be passed around and called as expected and they will just do the right thing. For compatability with other browsers, `console` was made enumerable on the global object. * CMakeLists.txt: * JavaScriptCore.xcodeproj/project.pbxproj: Add new files and remove old files. * runtime/CommonIdentifiers.h: Add "console". * runtime/ConsoleObject.cpp: Renamed from Source/JavaScriptCore/runtime/ConsolePrototype.cpp. (JSC::ConsoleObject::ConsoleObject): (JSC::ConsoleObject::finishCreation): (JSC::valueToStringWithUndefinedOrNullCheck): (JSC::consoleLogWithLevel): (JSC::consoleProtoFuncDebug): (JSC::consoleProtoFuncError): (JSC::consoleProtoFuncLog): (JSC::consoleProtoFuncInfo): (JSC::consoleProtoFuncWarn): (JSC::consoleProtoFuncClear): (JSC::consoleProtoFuncDir): (JSC::consoleProtoFuncDirXML): (JSC::consoleProtoFuncTable): (JSC::consoleProtoFuncTrace): (JSC::consoleProtoFuncAssert): (JSC::consoleProtoFuncCount): (JSC::consoleProtoFuncProfile): (JSC::consoleProtoFuncProfileEnd): (JSC::consoleProtoFuncTakeHeapSnapshot): (JSC::consoleProtoFuncTime): (JSC::consoleProtoFuncTimeEnd): (JSC::consoleProtoFuncTimeStamp): (JSC::consoleProtoFuncGroup): (JSC::consoleProtoFuncGroupCollapsed): (JSC::consoleProtoFuncGroupEnd): Console functions no longer need to check if the this object is a Console object. They will always just work now. * runtime/MathObject.cpp: * runtime/MathObject.h: * runtime/ConsoleObject.h: Renamed from Source/JavaScriptCore/runtime/ConsolePrototype.h. (JSC::ConsoleObject::create): (JSC::ConsoleObject::createStructure): ConsoleObject is a basic object like MathObject. * runtime/JSConsole.cpp: Removed. * runtime/JSConsole.h: Removed. * runtime/JSGlobalObject.h: * runtime/JSGlobalObject.cpp: (JSC::JSGlobalObject::init): (JSC::JSGlobalObject::visitChildren): Remove JSConsole / ConsolePrototype in favor of the single ConsoleObject. LayoutTests: * js/console-expected.txt: Added. * js/console.html: Added. Canonical link: https://commits.webkit.org/175386@main git-svn-id: https://svn.webkit.org/repository/webkit/trunk@200350 268f45cc-cd09-0410-ab3c-d52691b4dbfc
2016-05-03 00:51:24 +00:00
</body>
</html>