Web Inspector: highlight undefined word in JavaScript
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 20 Feb 2013 09:44:37 +0000 (09:44 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Wed, 20 Feb 2013 09:44:37 +0000 (09:44 +0000)
commit6f6c22af61a528d0423faf60ef7309432560070c
treee87f610ee9cdb5131621700b98e1371138f3d707
parent7f2def70f1fd2b065e050675fcddc9ef1461ed79
Web Inspector: highlight undefined word in JavaScript
https://bugs.webkit.org/show_bug.cgi?id=109585

Patch by Andrey Lushnikov <lushnikov@chromium.org> on 2013-02-20
Reviewed by Vsevolod Vlasov.

Source/WebCore:

Test enhancement: inspector/syntax-highlight-javascript.html

Add global object value properties to tokenizer and add a css style
class to highlight "undefined" with gray color.

* inspector/front-end/SourceJavaScriptTokenizer.js:
(WebInspector.SourceJavaScriptTokenizer.prototype.nextToken):
* inspector/front-end/SourceJavaScriptTokenizer.re2js:
* inspector/front-end/inspectorSyntaxHighlight.css:
(.webkit-javascript-undef):

LayoutTests:

Enhance layout test to verify highlighting of global object value properties.

* inspector/syntax-highlight-javascript-expected.txt:
* inspector/syntax-highlight-javascript.html:

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@143440 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/inspector/syntax-highlight-javascript-expected.txt
LayoutTests/inspector/syntax-highlight-javascript.html
Source/WebCore/ChangeLog
Source/WebCore/inspector/front-end/SourceJavaScriptTokenizer.js
Source/WebCore/inspector/front-end/SourceJavaScriptTokenizer.re2js
Source/WebCore/inspector/front-end/inspectorSyntaxHighlight.css