Summary: | Web Inspector: add console.clear() | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Andrey Lushnikov <lushnikov> | ||||||||||
Component: | Web Inspector (Deprecated) | Assignee: | Nobody <webkit-unassigned> | ||||||||||
Status: | RESOLVED FIXED | ||||||||||||
Severity: | Normal | CC: | abarth, apavlov, brkemper, keishi, loislo, ojan, pfeldman, pmuellr, vsevik, web-inspector-bugs, webkit.review.bot, yurys | ||||||||||
Priority: | P2 | ||||||||||||
Version: | 528+ (Nightly build) | ||||||||||||
Hardware: | All | ||||||||||||
OS: | All | ||||||||||||
Attachments: |
|
Description
Andrey Lushnikov
2012-11-01 23:58:34 PDT
Created attachment 172003 [details]
Patch
Comment on attachment 172003 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=172003&action=review > Source/WebCore/inspector/ConsoleMessage.cpp:115 > + case ClearConsoleMessageType: return TypeBuilder::Console::ConsoleMessage::Type::Clear; Drop "Console", it's cleaner. > Source/WebCore/inspector/front-end/ConsoleMessage.js:80 > + this._messageElement = document.createTextNode("console.clear()"); I would say "Console was cleared" with gray. You'll need to put it into WebCore/English.lproj/localizedStrings.js > LayoutTests/inspector/console/console-clear-function-expected.txt:11 > +console.clear() Sounds like the source location is missing. > LayoutTests/inspector/console/console-clear-function.html:22 > + RuntimeAgent.evaluate("console.clear();", function() { Use named functions (step1) Created attachment 172064 [details]
Patch
Comment on attachment 172064 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=172064&action=review > LayoutTests/inspector/console/console-clear-function.html:42 > +Tests that console is cleared via console.clear() method Please add a link to the bug. Created attachment 172071 [details]
Patch
Comment on attachment 172071 [details] Patch Attachment 172071 [details] did not pass mac-ews (mac): Output: http://queues.webkit.org/results/14703008 Created attachment 172517 [details]
Patch
Comment on attachment 172517 [details] Patch Clearing flags on attachment: 172517 Committed r133614: <http://trac.webkit.org/changeset/133614> All reviewed patches have been landed. Closing bug. Seriously? It is fixed and closed because it now prints "Console was cleared"? Shouldn't it also, you know, clear the console too? That was the OP's expected behavior, and it does not do that currently. (In reply to comment #10) > Seriously? It is fixed and closed because it now prints "Console was cleared"? Shouldn't it also, you know, clear the console too? That was the OP's expected behavior, and it does not do that currently. This option has no effect when "Preserve Log upon navigation" is toggled. You could use "clear()" in console to clean it up in such cases. |