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

Side by Side Diff: Source/devtools/front_end/SourceCSSTokenizer.js

Issue 22638008: DevTools: Use CodeMirror modes instead of highlight tokenizers (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: address comments Created 7 years, 4 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 | Annotate | Revision Log
OLDNEW
(Empty)
1 /* Generated by re2c 0.13.5 on Fri Sep 7 17:09:30 2012 */
2 /*
3 * Copyright (C) 2009 Google Inc. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are
7 * met:
8 *
9 * * Redistributions of source code must retain the above copyright
10 * notice, this list of conditions and the following disclaimer.
11 * * Redistributions in binary form must reproduce the above
12 * copyright notice, this list of conditions and the following disclaimer
13 * in the documentation and/or other materials provided with the
14 * distribution.
15 * * Neither the name of Google Inc. nor the names of its
16 * contributors may be used to endorse or promote products derived from
17 * this software without specific prior written permission.
18 *
19 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
20 * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
21 * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
22 * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
23 * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
24 * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
25 * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
26 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
27 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
28 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
29 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
30 */
31
32 // Generate js file as follows:
33
34 /*
35 re2c -isc devtools/front_end/SourceCSSTokenizer.re2js \
36 | sed 's|^yy\([^:]*\)*\:|case \1:|' \
37 | sed 's|[*]cursor[+][+]|this._charAt(cursor++)|' \
38 | sed 's|[[*][+][+]cursor|this._charAt(++cursor)|' \
39 | sed 's|[*]cursor|this._charAt(cursor)|' \
40 | sed 's|yych = \*\([^;]*\)|yych = this._charAt\1|' \
41 | sed 's|{ gotoCase = \([^; continue; };]*\)|{ gotoCase = \1; continue; }|' \
42 | sed 's|yych <= \(0x[0-9a-fA-F]*\)|yych \<\= String.fromCharCode(\1)|' \
43 | sed 's|unsigned\ int|var|' \
44 | sed 's|var\ yych|case 1: case 1: var yych|' > devtools/front_end/SourceCSSTo kenizer.js
45 */
46
47 /**
48 * @constructor
49 * @extends {WebInspector.SourceTokenizer}
50 */
51 WebInspector.SourceCSSTokenizer = function()
52 {
53 WebInspector.SourceTokenizer.call(this);
54
55 this._propertyKeywords = WebInspector.CSSMetadata.cssPropertiesMetainfoKeySe t();
56 this._colorKeywords = WebInspector.CSSMetadata.colors();
57
58 this._valueKeywords = [
59 "above", "absolute", "activeborder", "activecaption", "afar", "after-whi te-space", "ahead", "alias", "all", "all-scroll",
60 "alternate", "always", "amharic", "amharic-abegede", "antialiased", "app workspace", "arabic-indic", "armenian", "asterisks",
61 "auto", "avoid", "background", "backwards", "baseline", "below", "bidi-o verride", "binary", "bengali", "blink",
62 "block", "block-axis", "bold", "bolder", "border", "border-box", "both", "bottom", "break-all", "break-word", "button",
63 "button-bevel", "buttonface", "buttonhighlight", "buttonshadow", "button text", "cambodian", "capitalize", "caps-lock-indicator",
64 "caption", "captiontext", "caret", "cell", "center", "checkbox", "circle ", "cjk-earthly-branch", "cjk-heavenly-stem", "cjk-ideographic",
65 "clear", "clip", "close-quote", "col-resize", "collapse", "compact", "co ndensed", "contain", "content", "content-box", "context-menu",
66 "continuous", "copy", "cover", "crop", "cross", "crosshair", "currentcol or", "cursive", "dashed", "decimal", "decimal-leading-zero", "default",
67 "default-button", "destination-atop", "destination-in", "destination-out ", "destination-over", "devanagari", "disc", "discard", "document",
68 "dot-dash", "dot-dot-dash", "dotted", "double", "down", "e-resize", "eas e", "ease-in", "ease-in-out", "ease-out", "element",
69 "ellipsis", "embed", "end", "ethiopic", "ethiopic-abegede", "ethiopic-ab egede-am-et", "ethiopic-abegede-gez",
70 "ethiopic-abegede-ti-er", "ethiopic-abegede-ti-et", "ethiopic-halehame-a a-er", "ethiopic-halehame-aa-et",
71 "ethiopic-halehame-am-et", "ethiopic-halehame-gez", "ethiopic-halehame-o m-et", "ethiopic-halehame-sid-et",
72 "ethiopic-halehame-so-et", "ethiopic-halehame-ti-er", "ethiopic-halehame -ti-et", "ethiopic-halehame-tig", "ew-resize", "expanded",
73 "extra-condensed", "extra-expanded", "fantasy", "fast", "fill", "fixed", "flat", "footnotes", "forwards", "from", "geometricPrecision",
74 "georgian", "graytext", "groove", "gujarati", "gurmukhi", "hand", "hangu l", "hangul-consonant", "hebrew", "help",
75 "hidden", "hide", "higher", "highlight", "highlighttext", "hiragana", "h iragana-iroha", "horizontal", "hsl", "hsla", "icon", "ignore",
76 "inactiveborder", "inactivecaption", "inactivecaptiontext", "infinite", "infobackground", "infotext", "inherit", "initial", "inline",
77 "inline-axis", "inline-block", "inline-table", "inset", "inside", "intri nsic", "invert", "italic", "justify", "kannada", "katakana",
78 "katakana-iroha", "khmer", "landscape", "lao", "large", "larger", "left" , "level", "lighter", "line-through", "linear", "lines",
79 "list-item", "listbox", "listitem", "local", "logical", "loud", "lower", "lower-alpha", "lower-armenian", "lower-greek",
80 "lower-hexadecimal", "lower-latin", "lower-norwegian", "lower-roman", "l owercase", "ltr", "malayalam", "match", "media-controls-background",
81 "media-current-time-display", "media-fullscreen-button", "media-mute-but ton", "media-play-button", "media-return-to-realtime-button",
82 "media-rewind-button", "media-seek-back-button", "media-seek-forward-but ton", "media-slider", "media-sliderthumb", "media-time-remaining-display",
83 "media-volume-slider", "media-volume-slider-container", "media-volume-sl iderthumb", "medium", "menu", "menulist", "menulist-button",
84 "menulist-text", "menulist-textfield", "menutext", "message-box", "middl e", "min-intrinsic", "mix", "mongolian", "monospace", "move", "multiple",
85 "myanmar", "n-resize", "narrower", "navy", "ne-resize", "nesw-resize", " no-close-quote", "no-drop", "no-open-quote", "no-repeat", "none",
86 "normal", "not-allowed", "nowrap", "ns-resize", "nw-resize", "nwse-resiz e", "oblique", "octal", "open-quote", "optimizeLegibility",
87 "optimizeSpeed", "oriya", "oromo", "outset", "outside", "overlay", "over line", "padding", "padding-box", "painted", "paused",
88 "persian", "plus-darker", "plus-lighter", "pointer", "portrait", "pre", "pre-line", "pre-wrap", "preserve-3d", "progress",
89 "push-button", "radio", "read-only", "read-write", "read-write-plaintext -only", "relative", "repeat", "repeat-x",
90 "repeat-y", "reset", "reverse", "rgb", "rgba", "ridge", "right", "round" , "row-resize", "rtl", "run-in", "running", "s-resize", "sans-serif",
91 "scroll", "scrollbar", "se-resize", "searchfield", "searchfield-cancel-b utton", "searchfield-decoration", "searchfield-results-button",
92 "searchfield-results-decoration", "semi-condensed", "semi-expanded", "se parate", "serif", "show", "sidama", "single",
93 "skip-white-space", "slide", "slider-horizontal", "slider-vertical", "sl iderthumb-horizontal", "sliderthumb-vertical", "slow",
94 "small", "small-caps", "small-caption", "smaller", "solid", "somali", "s ource-atop", "source-in", "source-out", "source-over",
95 "space", "square", "square-button", "start", "static", "status-bar", "st retch", "stroke", "sub", "subpixel-antialiased", "super",
96 "sw-resize", "table", "table-caption", "table-cell", "table-column", "ta ble-column-group", "table-footer-group", "table-header-group",
97 "table-row", "table-row-group", "telugu", "text", "text-bottom", "text-t op", "textarea", "textfield", "thai", "thick", "thin",
98 "threeddarkshadow", "threedface", "threedhighlight", "threedlightshadow" , "threedshadow", "tibetan", "tigre", "tigrinya-er", "tigrinya-er-abegede",
99 "tigrinya-et", "tigrinya-et-abegede", "to", "top", "transparent", "ultra -condensed", "ultra-expanded", "underline", "up", "upper-alpha", "upper-armenian ",
100 "upper-greek", "upper-hexadecimal", "upper-latin", "upper-norwegian", "u pper-roman", "uppercase", "urdu", "url", "vertical", "vertical-text", "visible",
101 "visibleFill", "visiblePainted", "visibleStroke", "visual", "w-resize", "wait", "wave", "white", "wider", "window", "windowframe", "windowtext",
102 "x-large", "x-small", "xor", "xx-large", "xx-small", "yellow", "-wap-mar quee", "-webkit-activelink", "-webkit-auto", "-webkit-baseline-middle",
103 "-webkit-body", "-webkit-box", "-webkit-center", "-webkit-control", "-we bkit-focus-ring-color", "-webkit-grab", "-webkit-grabbing",
104 "-webkit-gradient", "-webkit-inline-box", "-webkit-left", "-webkit-link" , "-webkit-marquee", "-webkit-mini-control", "-webkit-nowrap", "-webkit-pictogra ph",
105 "-webkit-right", "-webkit-small-control", "-webkit-text", "-webkit-xxx-l arge", "-webkit-zoom-in", "-webkit-zoom-out",
106 ].keySet();
107
108 this._scssValueKeywords = [
109 "abs", "adjust-color", "adjust-hue", "alpha", "append", "ceil", "change- color", "comparable", "complement", "darken", "desaturate",
110 "fade-in", "fade-out", "floor", "grayscale", "hue", "ie-hex-str", "inver t", "join", "length", "lighten",
111 "lightness", "max", "min", "mix", "nth", "opacify", "opacity", "percenta ge", "quote", "round", "saturate",
112 "saturation", "scale-color", "transparentize", "type-of", "unit", "unitl ess", "unquote", "zip"
113 ].keySet();
114
115 this._lexConditions = {
116 INITIAL: 0,
117 COMMENT: 1,
118 DSTRING: 2,
119 SSTRING: 3
120 };
121
122 this._parseConditions = {
123 INITIAL: 0,
124 PROPERTY: 1,
125 PROPERTY_VALUE: 2,
126 AT_RULE: 3,
127 AT_MEDIA_RULE: 4
128 };
129
130 this.case_INITIAL = 1000;
131 this.case_COMMENT = 1002;
132 this.case_DSTRING = 1003;
133 this.case_SSTRING = 1004;
134
135 this.condition = this.createInitialCondition();
136 }
137
138 WebInspector.SourceCSSTokenizer.SCSSAtRelatedKeywords = ["from", "if", "in", "th rough"].keySet();
139
140 WebInspector.SourceCSSTokenizer.MediaTypes = ["all", "aural", "braille", "emboss ed", "handheld", "import", "print", "projection", "screen", "tty", "tv"].keySet( );
141
142 WebInspector.SourceCSSTokenizer.prototype = {
143 createInitialCondition: function()
144 {
145 return { lexCondition: this._lexConditions.INITIAL, parseCondition: this ._parseConditions.INITIAL };
146 },
147
148 /**
149 * @param {boolean=} stringEnds
150 */
151 _stringToken: function(cursor, stringEnds)
152 {
153 if (this._isPropertyValue())
154 this.tokenType = "css-string";
155 else
156 this.tokenType = null;
157 return cursor;
158 },
159
160 _isPropertyValue: function()
161 {
162 return this._condition.parseCondition === this._parseConditions.PROPERTY _VALUE || this._condition.parseCondition === this._parseConditions.AT_RULE;
163 },
164
165 _setParseCondition: function(condition)
166 {
167 this._condition.parseCondition = condition;
168 },
169
170 nextToken: function(cursor)
171 {
172 var cursorOnEnter = cursor;
173 var gotoCase = 1;
174 var YYMARKER;
175 while (1) {
176 switch (gotoCase)
177 // Following comment is replaced with generated state machine.
178
179 {
180 case 1: var yych;
181 var yyaccept = 0;
182 if (this.getLexCondition() < 2) {
183 if (this.getLexCondition() < 1) {
184 { gotoCase = this.case_INITIAL; continue; };
185 } else {
186 { gotoCase = this.case_COMMENT; continue; };
187 }
188 } else {
189 if (this.getLexCondition() < 3) {
190 { gotoCase = this.case_DSTRING; continue; };
191 } else {
192 { gotoCase = this.case_SSTRING; continue; };
193 }
194 }
195 /* *********************************** */
196 case this.case_COMMENT:
197
198 yych = this._charAt(cursor);
199 if (yych <= '\f') {
200 if (yych == '\n') { gotoCase = 4; continue; };
201 { gotoCase = 3; continue; };
202 } else {
203 if (yych <= '\r') { gotoCase = 4; continue; };
204 if (yych == '*') { gotoCase = 6; continue; };
205 { gotoCase = 3; continue; };
206 }
207 case 2:
208 { this.tokenType = "css-comment"; return cursor; }
209 case 3:
210 yyaccept = 0;
211 yych = this._charAt(YYMARKER = ++cursor);
212 { gotoCase = 12; continue; };
213 case 4:
214 ++cursor;
215 { this.tokenType = null; return cursor; }
216 case 6:
217 yyaccept = 1;
218 yych = this._charAt(YYMARKER = ++cursor);
219 if (yych == '*') { gotoCase = 9; continue; };
220 if (yych != '/') { gotoCase = 11; continue; };
221 case 7:
222 ++cursor;
223 this.setLexCondition(this._lexConditions.INITIAL);
224 { this.tokenType = "css-comment"; return cursor; }
225 case 9:
226 ++cursor;
227 yych = this._charAt(cursor);
228 if (yych == '*') { gotoCase = 9; continue; };
229 if (yych == '/') { gotoCase = 7; continue; };
230 case 11:
231 yyaccept = 0;
232 YYMARKER = ++cursor;
233 yych = this._charAt(cursor);
234 case 12:
235 if (yych <= '\f') {
236 if (yych == '\n') { gotoCase = 2; continue; };
237 { gotoCase = 11; continue; };
238 } else {
239 if (yych <= '\r') { gotoCase = 2; continue; };
240 if (yych == '*') { gotoCase = 9; continue; };
241 { gotoCase = 11; continue; };
242 }
243 /* *********************************** */
244 case this.case_DSTRING:
245 yych = this._charAt(cursor);
246 if (yych <= '\r') {
247 if (yych == '\n') { gotoCase = 17; continue; };
248 if (yych <= '\f') { gotoCase = 16; continue; };
249 { gotoCase = 17; continue; };
250 } else {
251 if (yych <= '"') {
252 if (yych <= '!') { gotoCase = 16; continue; };
253 { gotoCase = 19; continue; };
254 } else {
255 if (yych == '\\') { gotoCase = 21; continue; };
256 { gotoCase = 16; continue; };
257 }
258 }
259 case 15:
260 { return this._stringToken(cursor); }
261 case 16:
262 yyaccept = 0;
263 yych = this._charAt(YYMARKER = ++cursor);
264 { gotoCase = 23; continue; };
265 case 17:
266 ++cursor;
267 case 18:
268 { this.tokenType = null; return cursor; }
269 case 19:
270 ++cursor;
271 case 20:
272 this.setLexCondition(this._lexConditions.INITIAL);
273 { return this._stringToken(cursor, true); }
274 case 21:
275 yych = this._charAt(++cursor);
276 if (yych <= 'e') {
277 if (yych <= '\'') {
278 if (yych == '"') { gotoCase = 22; continue; };
279 if (yych <= '&') { gotoCase = 18; continue; };
280 } else {
281 if (yych <= '\\') {
282 if (yych <= '[') { gotoCase = 18; continue; };
283 } else {
284 if (yych != 'b') { gotoCase = 18; continue; };
285 }
286 }
287 } else {
288 if (yych <= 'r') {
289 if (yych <= 'm') {
290 if (yych >= 'g') { gotoCase = 18; continue; };
291 } else {
292 if (yych <= 'n') { gotoCase = 22; continue; };
293 if (yych <= 'q') { gotoCase = 18; continue; };
294 }
295 } else {
296 if (yych <= 't') {
297 if (yych <= 's') { gotoCase = 18; continue; };
298 } else {
299 if (yych != 'v') { gotoCase = 18; continue; };
300 }
301 }
302 }
303 case 22:
304 yyaccept = 0;
305 YYMARKER = ++cursor;
306 yych = this._charAt(cursor);
307 case 23:
308 if (yych <= '\r') {
309 if (yych == '\n') { gotoCase = 15; continue; };
310 if (yych <= '\f') { gotoCase = 22; continue; };
311 { gotoCase = 15; continue; };
312 } else {
313 if (yych <= '"') {
314 if (yych <= '!') { gotoCase = 22; continue; };
315 { gotoCase = 26; continue; };
316 } else {
317 if (yych != '\\') { gotoCase = 22; continue; };
318 }
319 }
320 ++cursor;
321 yych = this._charAt(cursor);
322 if (yych <= 'e') {
323 if (yych <= '\'') {
324 if (yych == '"') { gotoCase = 22; continue; };
325 if (yych >= '\'') { gotoCase = 22; continue; };
326 } else {
327 if (yych <= '\\') {
328 if (yych >= '\\') { gotoCase = 22; continue; };
329 } else {
330 if (yych == 'b') { gotoCase = 22; continue; };
331 }
332 }
333 } else {
334 if (yych <= 'r') {
335 if (yych <= 'm') {
336 if (yych <= 'f') { gotoCase = 22; continue; };
337 } else {
338 if (yych <= 'n') { gotoCase = 22; continue; };
339 if (yych >= 'r') { gotoCase = 22; continue; };
340 }
341 } else {
342 if (yych <= 't') {
343 if (yych >= 't') { gotoCase = 22; continue; };
344 } else {
345 if (yych == 'v') { gotoCase = 22; continue; };
346 }
347 }
348 }
349 cursor = YYMARKER;
350 { gotoCase = 15; continue; };
351 case 26:
352 ++cursor;
353 yych = this._charAt(cursor);
354 { gotoCase = 20; continue; };
355 /* *********************************** */
356 case this.case_INITIAL:
357 yych = this._charAt(cursor);
358 if (yych <= ':') {
359 if (yych <= '&') {
360 if (yych <= '"') {
361 if (yych <= ' ') { gotoCase = 29; continue; };
362 if (yych <= '!') { gotoCase = 31; continue; };
363 { gotoCase = 33; continue; };
364 } else {
365 if (yych <= '#') { gotoCase = 34; continue; };
366 if (yych <= '$') { gotoCase = 35; continue; };
367 if (yych >= '&') { gotoCase = 31; continue; };
368 }
369 } else {
370 if (yych <= '-') {
371 if (yych <= '\'') { gotoCase = 36; continue; };
372 if (yych >= '-') { gotoCase = 37; continue; };
373 } else {
374 if (yych <= '.') { gotoCase = 38; continue; };
375 if (yych <= '/') { gotoCase = 39; continue; };
376 if (yych <= '9') { gotoCase = 40; continue; };
377 { gotoCase = 42; continue; };
378 }
379 }
380 } else {
381 if (yych <= ']') {
382 if (yych <= '=') {
383 if (yych <= ';') { gotoCase = 44; continue; };
384 if (yych >= '=') { gotoCase = 31; continue; };
385 } else {
386 if (yych <= '?') { gotoCase = 29; continue; };
387 if (yych != '\\') { gotoCase = 31; continue; };
388 }
389 } else {
390 if (yych <= 'z') {
391 if (yych == '_') { gotoCase = 31; continue; };
392 if (yych >= 'a') { gotoCase = 31; continue; };
393 } else {
394 if (yych <= '{') { gotoCase = 46; continue; };
395 if (yych == '}') { gotoCase = 48; continue; };
396 }
397 }
398 }
399 case 29:
400 ++cursor;
401 case 30:
402 { this.tokenType = null; return cursor; }
403 case 31:
404 ++cursor;
405 yych = this._charAt(cursor);
406 { gotoCase = 51; continue; };
407 case 32:
408 {
409 var token = this._line.substring(cursorOnEnter, cursor);
410 this.tokenType = null;
411 if (this._condition.parseCondition === this._parseConditions .INITIAL || this._condition.parseCondition === this._parseConditions.PROPERTY) {
412 if (token.charAt(0) === "@") {
413 this.tokenType = "css-at-rule";
414 this._setParseCondition(token === "@media" ? this._p arseConditions.AT_MEDIA_RULE : this._parseConditions.AT_RULE);
415 this._condition.atKeyword = token;
416 } else if (this._condition.parseCondition === this._pars eConditions.INITIAL)
417 this.tokenType = "css-selector";
418 else if (this._propertyKeywords.hasOwnProperty(token))
419 this.tokenType = "css-property";
420 } else if (this._condition.parseCondition === this._parseCon ditions.AT_MEDIA_RULE || this._condition.parseCondition === this._parseCondition s.AT_RULE) {
421 if (WebInspector.SourceCSSTokenizer.SCSSAtRelatedKeyword s.hasOwnProperty(token))
422 this.tokenType = "css-at-rule";
423 else if (WebInspector.SourceCSSTokenizer.MediaTypes.hasO wnProperty(token))
424 this.tokenType = "css-keyword";
425 }
426 if (this.tokenType)
427 return cursor;
428
429 if (this._isPropertyValue()) {
430 var firstChar = token.charAt(0);
431 if (firstChar === "$")
432 this.tokenType = "scss-variable";
433 else if (firstChar === "!")
434 this.tokenType = "css-bang-keyword";
435 else if (this._condition.atKeyword === "@extend")
436 this.tokenType = "css-selector";
437 else if (this._valueKeywords.hasOwnProperty(token) || th is._scssValueKeywords.hasOwnProperty(token))
438 this.tokenType = "css-keyword";
439 else if (this._colorKeywords.hasOwnProperty(token)) {
440 // FIXME: this does not convert tokens toLowerCase() for the sake of speed.
441 this.tokenType = "css-color";
442 }
443 } else if (this._condition.parseCondition !== this._parseCon ditions.PROPERTY_VALUE)
444 this.tokenType = "css-selector";
445 return cursor;
446 }
447 case 33:
448 yyaccept = 0;
449 yych = this._charAt(YYMARKER = ++cursor);
450 if (yych <= '.') {
451 if (yych <= '!') {
452 if (yych <= '\f') {
453 if (yych == '\n') { gotoCase = 32; continue; };
454 { gotoCase = 132; continue; };
455 } else {
456 if (yych <= '\r') { gotoCase = 32; continue; };
457 if (yych <= ' ') { gotoCase = 132; continue; };
458 { gotoCase = 130; continue; };
459 }
460 } else {
461 if (yych <= '\'') {
462 if (yych <= '"') { gotoCase = 116; continue; };
463 if (yych <= '%') { gotoCase = 132; continue; };
464 { gotoCase = 130; continue; };
465 } else {
466 if (yych == '-') { gotoCase = 130; continue; };
467 { gotoCase = 132; continue; };
468 }
469 }
470 } else {
471 if (yych <= '\\') {
472 if (yych <= '=') {
473 if (yych <= '9') { gotoCase = 130; continue; };
474 if (yych <= '<') { gotoCase = 132; continue; };
475 { gotoCase = 130; continue; };
476 } else {
477 if (yych <= '?') { gotoCase = 132; continue; };
478 if (yych <= '[') { gotoCase = 130; continue; };
479 { gotoCase = 134; continue; };
480 }
481 } else {
482 if (yych <= '_') {
483 if (yych == '^') { gotoCase = 132; continue; };
484 { gotoCase = 130; continue; };
485 } else {
486 if (yych <= '`') { gotoCase = 132; continue; };
487 if (yych <= 'z') { gotoCase = 130; continue; };
488 { gotoCase = 132; continue; };
489 }
490 }
491 }
492 case 34:
493 yych = this._charAt(++cursor);
494 if (yych <= '@') {
495 if (yych <= '/') { gotoCase = 30; continue; };
496 if (yych <= '9') { gotoCase = 127; continue; };
497 { gotoCase = 30; continue; };
498 } else {
499 if (yych <= 'Z') { gotoCase = 127; continue; };
500 if (yych <= '`') { gotoCase = 30; continue; };
501 if (yych <= 'z') { gotoCase = 127; continue; };
502 { gotoCase = 30; continue; };
503 }
504 case 35:
505 yych = this._charAt(++cursor);
506 if (yych <= '<') {
507 if (yych <= '\'') {
508 if (yych <= ' ') { gotoCase = 30; continue; };
509 if (yych <= '"') { gotoCase = 124; continue; };
510 if (yych <= '%') { gotoCase = 30; continue; };
511 { gotoCase = 124; continue; };
512 } else {
513 if (yych <= '-') {
514 if (yych <= ',') { gotoCase = 30; continue; };
515 { gotoCase = 124; continue; };
516 } else {
517 if (yych <= '.') { gotoCase = 30; continue; };
518 if (yych <= '9') { gotoCase = 124; continue; };
519 { gotoCase = 30; continue; };
520 }
521 }
522 } else {
523 if (yych <= ']') {
524 if (yych <= '?') {
525 if (yych <= '=') { gotoCase = 124; continue; };
526 { gotoCase = 30; continue; };
527 } else {
528 if (yych == '\\') { gotoCase = 30; continue; };
529 { gotoCase = 124; continue; };
530 }
531 } else {
532 if (yych <= '_') {
533 if (yych <= '^') { gotoCase = 30; continue; };
534 { gotoCase = 124; continue; };
535 } else {
536 if (yych <= '`') { gotoCase = 30; continue; };
537 if (yych <= 'z') { gotoCase = 124; continue; };
538 { gotoCase = 30; continue; };
539 }
540 }
541 }
542 case 36:
543 yyaccept = 0;
544 yych = this._charAt(YYMARKER = ++cursor);
545 if (yych <= '.') {
546 if (yych <= '"') {
547 if (yych <= '\f') {
548 if (yych == '\n') { gotoCase = 32; continue; };
549 { gotoCase = 118; continue; };
550 } else {
551 if (yych <= '\r') { gotoCase = 32; continue; };
552 if (yych <= ' ') { gotoCase = 118; continue; };
553 { gotoCase = 114; continue; };
554 }
555 } else {
556 if (yych <= '\'') {
557 if (yych <= '%') { gotoCase = 118; continue; };
558 if (yych <= '&') { gotoCase = 114; continue; };
559 { gotoCase = 116; continue; };
560 } else {
561 if (yych == '-') { gotoCase = 114; continue; };
562 { gotoCase = 118; continue; };
563 }
564 }
565 } else {
566 if (yych <= '\\') {
567 if (yych <= '=') {
568 if (yych <= '9') { gotoCase = 114; continue; };
569 if (yych <= '<') { gotoCase = 118; continue; };
570 { gotoCase = 114; continue; };
571 } else {
572 if (yych <= '?') { gotoCase = 118; continue; };
573 if (yych <= '[') { gotoCase = 114; continue; };
574 { gotoCase = 120; continue; };
575 }
576 } else {
577 if (yych <= '_') {
578 if (yych == '^') { gotoCase = 118; continue; };
579 { gotoCase = 114; continue; };
580 } else {
581 if (yych <= '`') { gotoCase = 118; continue; };
582 if (yych <= 'z') { gotoCase = 114; continue; };
583 { gotoCase = 118; continue; };
584 }
585 }
586 }
587 case 37:
588 yyaccept = 0;
589 yych = this._charAt(YYMARKER = ++cursor);
590 if (yych == '.') { gotoCase = 67; continue; };
591 if (yych <= '/') { gotoCase = 51; continue; };
592 if (yych <= '9') { gotoCase = 52; continue; };
593 { gotoCase = 51; continue; };
594 case 38:
595 yych = this._charAt(++cursor);
596 if (yych <= '/') { gotoCase = 30; continue; };
597 if (yych <= '9') { gotoCase = 70; continue; };
598 { gotoCase = 30; continue; };
599 case 39:
600 yyaccept = 0;
601 yych = this._charAt(YYMARKER = ++cursor);
602 if (yych == '*') { gotoCase = 106; continue; };
603 { gotoCase = 51; continue; };
604 case 40:
605 yyaccept = 1;
606 yych = this._charAt(YYMARKER = ++cursor);
607 switch (yych) {
608 case '!':
609 case '"':
610 case '&':
611 case '\'':
612 case '-':
613 case '/':
614 case '=':
615 case '@':
616 case 'A':
617 case 'B':
618 case 'C':
619 case 'D':
620 case 'E':
621 case 'F':
622 case 'G':
623 case 'I':
624 case 'J':
625 case 'K':
626 case 'L':
627 case 'M':
628 case 'N':
629 case 'O':
630 case 'P':
631 case 'Q':
632 case 'R':
633 case 'S':
634 case 'T':
635 case 'U':
636 case 'V':
637 case 'W':
638 case 'X':
639 case 'Y':
640 case 'Z':
641 case '[':
642 case ']':
643 case 'a':
644 case 'b':
645 case 'f':
646 case 'h':
647 case 'j':
648 case 'l':
649 case 'n':
650 case 'o':
651 case 'q':
652 case 'u':
653 case 'v':
654 case 'w':
655 case 'x':
656 case 'y':
657 case 'z': { gotoCase = 50; continue; };
658 case '%': { gotoCase = 69; continue; };
659 case '.': { gotoCase = 67; continue; };
660 case '0':
661 case '1':
662 case '2':
663 case '3':
664 case '4':
665 case '5':
666 case '6':
667 case '7':
668 case '8':
669 case '9': { gotoCase = 52; continue; };
670 case 'H': { gotoCase = 54; continue; };
671 case '_': { gotoCase = 55; continue; };
672 case 'c': { gotoCase = 56; continue; };
673 case 'd': { gotoCase = 57; continue; };
674 case 'e': { gotoCase = 58; continue; };
675 case 'g': { gotoCase = 59; continue; };
676 case 'i': { gotoCase = 60; continue; };
677 case 'k': { gotoCase = 61; continue; };
678 case 'm': { gotoCase = 62; continue; };
679 case 'p': { gotoCase = 63; continue; };
680 case 'r': { gotoCase = 64; continue; };
681 case 's': { gotoCase = 65; continue; };
682 case 't': { gotoCase = 66; continue; };
683 default: { gotoCase = 41; continue; };
684 }
685 case 41:
686 {
687 if (this._isPropertyValue())
688 this.tokenType = "css-number";
689 else
690 this.tokenType = null;
691 return cursor;
692 }
693 case 42:
694 ++cursor;
695 {
696 this.tokenType = null;
697 if (this._condition.parseCondition === this._parseConditions .PROPERTY || this._condition.parseCondition === this._parseConditions.INITIAL)
698 this._setParseCondition(this._parseConditions.PROPERTY_V ALUE);
699 return cursor;
700 }
701 case 44:
702 ++cursor;
703 {
704 this.tokenType = null;
705 this._setParseCondition(this._condition.openBraces ? this._p arseConditions.PROPERTY : this._parseConditions.INITIAL);
706 delete this._condition.atKeyword;
707 return cursor;
708 }
709 case 46:
710 ++cursor;
711 {
712 this.tokenType = "block-start";
713 this._condition.openBraces = (this._condition.openBraces || 0) + 1;
714 if (this._condition.parseCondition === this._parseConditions .AT_MEDIA_RULE)
715 this._setParseCondition(this._parseConditions.INITIAL);
716 else
717 this._setParseCondition(this._parseConditions.PROPERTY);
718 return cursor;
719 }
720 case 48:
721 ++cursor;
722 {
723 this.tokenType = "block-end";
724 if (this._condition.openBraces > 0)
725 --this._condition.openBraces;
726 this._setParseCondition(this._condition.openBraces ? this._p arseConditions.PROPERTY : this._parseConditions.INITIAL);
727 delete this._condition.atKeyword;
728 return cursor;
729 }
730 case 50:
731 ++cursor;
732 yych = this._charAt(cursor);
733 case 51:
734 if (yych <= '<') {
735 if (yych <= '\'') {
736 if (yych <= ' ') { gotoCase = 32; continue; };
737 if (yych <= '"') { gotoCase = 50; continue; };
738 if (yych <= '%') { gotoCase = 32; continue; };
739 { gotoCase = 50; continue; };
740 } else {
741 if (yych <= '-') {
742 if (yych <= ',') { gotoCase = 32; continue; };
743 { gotoCase = 50; continue; };
744 } else {
745 if (yych <= '.') { gotoCase = 32; continue; };
746 if (yych <= '9') { gotoCase = 50; continue; };
747 { gotoCase = 32; continue; };
748 }
749 }
750 } else {
751 if (yych <= ']') {
752 if (yych <= '?') {
753 if (yych <= '=') { gotoCase = 50; continue; };
754 { gotoCase = 32; continue; };
755 } else {
756 if (yych == '\\') { gotoCase = 32; continue; };
757 { gotoCase = 50; continue; };
758 }
759 } else {
760 if (yych <= '_') {
761 if (yych <= '^') { gotoCase = 32; continue; };
762 { gotoCase = 50; continue; };
763 } else {
764 if (yych <= '`') { gotoCase = 32; continue; };
765 if (yych <= 'z') { gotoCase = 50; continue; };
766 { gotoCase = 32; continue; };
767 }
768 }
769 }
770 case 52:
771 yyaccept = 1;
772 YYMARKER = ++cursor;
773 yych = this._charAt(cursor);
774 switch (yych) {
775 case '!':
776 case '"':
777 case '&':
778 case '\'':
779 case '-':
780 case '/':
781 case '=':
782 case '@':
783 case 'A':
784 case 'B':
785 case 'C':
786 case 'D':
787 case 'E':
788 case 'F':
789 case 'G':
790 case 'I':
791 case 'J':
792 case 'K':
793 case 'L':
794 case 'M':
795 case 'N':
796 case 'O':
797 case 'P':
798 case 'Q':
799 case 'R':
800 case 'S':
801 case 'T':
802 case 'U':
803 case 'V':
804 case 'W':
805 case 'X':
806 case 'Y':
807 case 'Z':
808 case '[':
809 case ']':
810 case 'a':
811 case 'b':
812 case 'f':
813 case 'h':
814 case 'j':
815 case 'l':
816 case 'n':
817 case 'o':
818 case 'q':
819 case 'u':
820 case 'v':
821 case 'w':
822 case 'x':
823 case 'y':
824 case 'z': { gotoCase = 50; continue; };
825 case '%': { gotoCase = 69; continue; };
826 case '.': { gotoCase = 67; continue; };
827 case '0':
828 case '1':
829 case '2':
830 case '3':
831 case '4':
832 case '5':
833 case '6':
834 case '7':
835 case '8':
836 case '9': { gotoCase = 52; continue; };
837 case 'H': { gotoCase = 54; continue; };
838 case '_': { gotoCase = 55; continue; };
839 case 'c': { gotoCase = 56; continue; };
840 case 'd': { gotoCase = 57; continue; };
841 case 'e': { gotoCase = 58; continue; };
842 case 'g': { gotoCase = 59; continue; };
843 case 'i': { gotoCase = 60; continue; };
844 case 'k': { gotoCase = 61; continue; };
845 case 'm': { gotoCase = 62; continue; };
846 case 'p': { gotoCase = 63; continue; };
847 case 'r': { gotoCase = 64; continue; };
848 case 's': { gotoCase = 65; continue; };
849 case 't': { gotoCase = 66; continue; };
850 default: { gotoCase = 41; continue; };
851 }
852 case 54:
853 yych = this._charAt(++cursor);
854 if (yych == 'z') { gotoCase = 65; continue; };
855 { gotoCase = 51; continue; };
856 case 55:
857 yych = this._charAt(++cursor);
858 if (yych == '_') { gotoCase = 103; continue; };
859 { gotoCase = 51; continue; };
860 case 56:
861 yych = this._charAt(++cursor);
862 if (yych == 'm') { gotoCase = 65; continue; };
863 { gotoCase = 51; continue; };
864 case 57:
865 yych = this._charAt(++cursor);
866 if (yych == 'e') { gotoCase = 102; continue; };
867 { gotoCase = 51; continue; };
868 case 58:
869 yych = this._charAt(++cursor);
870 if (yych == 'm') { gotoCase = 65; continue; };
871 if (yych == 'x') { gotoCase = 65; continue; };
872 { gotoCase = 51; continue; };
873 case 59:
874 yych = this._charAt(++cursor);
875 if (yych == 'r') { gotoCase = 100; continue; };
876 { gotoCase = 51; continue; };
877 case 60:
878 yych = this._charAt(++cursor);
879 if (yych == 'n') { gotoCase = 65; continue; };
880 { gotoCase = 51; continue; };
881 case 61:
882 yych = this._charAt(++cursor);
883 if (yych == 'H') { gotoCase = 99; continue; };
884 { gotoCase = 51; continue; };
885 case 62:
886 yych = this._charAt(++cursor);
887 if (yych == 'm') { gotoCase = 65; continue; };
888 if (yych == 's') { gotoCase = 65; continue; };
889 { gotoCase = 51; continue; };
890 case 63:
891 yych = this._charAt(++cursor);
892 if (yych <= 's') {
893 if (yych == 'c') { gotoCase = 65; continue; };
894 { gotoCase = 51; continue; };
895 } else {
896 if (yych <= 't') { gotoCase = 65; continue; };
897 if (yych == 'x') { gotoCase = 65; continue; };
898 { gotoCase = 51; continue; };
899 }
900 case 64:
901 yych = this._charAt(++cursor);
902 if (yych == 'a') { gotoCase = 97; continue; };
903 if (yych == 'e') { gotoCase = 98; continue; };
904 { gotoCase = 51; continue; };
905 case 65:
906 yych = this._charAt(++cursor);
907 if (yych <= '<') {
908 if (yych <= '\'') {
909 if (yych <= ' ') { gotoCase = 41; continue; };
910 if (yych <= '"') { gotoCase = 50; continue; };
911 if (yych <= '%') { gotoCase = 41; continue; };
912 { gotoCase = 50; continue; };
913 } else {
914 if (yych <= '-') {
915 if (yych <= ',') { gotoCase = 41; continue; };
916 { gotoCase = 50; continue; };
917 } else {
918 if (yych <= '.') { gotoCase = 41; continue; };
919 if (yych <= '9') { gotoCase = 50; continue; };
920 { gotoCase = 41; continue; };
921 }
922 }
923 } else {
924 if (yych <= ']') {
925 if (yych <= '?') {
926 if (yych <= '=') { gotoCase = 50; continue; };
927 { gotoCase = 41; continue; };
928 } else {
929 if (yych == '\\') { gotoCase = 41; continue; };
930 { gotoCase = 50; continue; };
931 }
932 } else {
933 if (yych <= '_') {
934 if (yych <= '^') { gotoCase = 41; continue; };
935 { gotoCase = 50; continue; };
936 } else {
937 if (yych <= '`') { gotoCase = 41; continue; };
938 if (yych <= 'z') { gotoCase = 50; continue; };
939 { gotoCase = 41; continue; };
940 }
941 }
942 }
943 case 66:
944 yych = this._charAt(++cursor);
945 if (yych == 'u') { gotoCase = 95; continue; };
946 { gotoCase = 51; continue; };
947 case 67:
948 yych = this._charAt(++cursor);
949 if (yych <= '/') { gotoCase = 68; continue; };
950 if (yych <= '9') { gotoCase = 70; continue; };
951 case 68:
952 cursor = YYMARKER;
953 if (yyaccept <= 0) {
954 { gotoCase = 32; continue; };
955 } else {
956 { gotoCase = 41; continue; };
957 }
958 case 69:
959 yych = this._charAt(++cursor);
960 { gotoCase = 41; continue; };
961 case 70:
962 yyaccept = 1;
963 YYMARKER = ++cursor;
964 yych = this._charAt(cursor);
965 if (yych <= 'f') {
966 if (yych <= 'H') {
967 if (yych <= '/') {
968 if (yych == '%') { gotoCase = 69; continue; };
969 { gotoCase = 41; continue; };
970 } else {
971 if (yych <= '9') { gotoCase = 70; continue; };
972 if (yych <= 'G') { gotoCase = 41; continue; };
973 { gotoCase = 82; continue; };
974 }
975 } else {
976 if (yych <= 'b') {
977 if (yych == '_') { gotoCase = 74; continue; };
978 { gotoCase = 41; continue; };
979 } else {
980 if (yych <= 'c') { gotoCase = 76; continue; };
981 if (yych <= 'd') { gotoCase = 79; continue; };
982 if (yych >= 'f') { gotoCase = 41; continue; };
983 }
984 }
985 } else {
986 if (yych <= 'm') {
987 if (yych <= 'i') {
988 if (yych <= 'g') { gotoCase = 80; continue; };
989 if (yych <= 'h') { gotoCase = 41; continue; };
990 { gotoCase = 78; continue; };
991 } else {
992 if (yych == 'k') { gotoCase = 83; continue; };
993 if (yych <= 'l') { gotoCase = 41; continue; };
994 { gotoCase = 77; continue; };
995 }
996 } else {
997 if (yych <= 'q') {
998 if (yych == 'p') { gotoCase = 75; continue; };
999 { gotoCase = 41; continue; };
1000 } else {
1001 if (yych <= 'r') { gotoCase = 73; continue; };
1002 if (yych <= 's') { gotoCase = 69; continue; };
1003 if (yych <= 't') { gotoCase = 81; continue; };
1004 { gotoCase = 41; continue; };
1005 }
1006 }
1007 }
1008 yych = this._charAt(++cursor);
1009 if (yych == 'm') { gotoCase = 69; continue; };
1010 if (yych == 'x') { gotoCase = 69; continue; };
1011 { gotoCase = 68; continue; };
1012 case 73:
1013 yych = this._charAt(++cursor);
1014 if (yych == 'a') { gotoCase = 93; continue; };
1015 if (yych == 'e') { gotoCase = 94; continue; };
1016 { gotoCase = 68; continue; };
1017 case 74:
1018 yych = this._charAt(++cursor);
1019 if (yych == '_') { gotoCase = 90; continue; };
1020 { gotoCase = 68; continue; };
1021 case 75:
1022 yych = this._charAt(++cursor);
1023 if (yych <= 's') {
1024 if (yych == 'c') { gotoCase = 69; continue; };
1025 { gotoCase = 68; continue; };
1026 } else {
1027 if (yych <= 't') { gotoCase = 69; continue; };
1028 if (yych == 'x') { gotoCase = 69; continue; };
1029 { gotoCase = 68; continue; };
1030 }
1031 case 76:
1032 yych = this._charAt(++cursor);
1033 if (yych == 'm') { gotoCase = 69; continue; };
1034 { gotoCase = 68; continue; };
1035 case 77:
1036 yych = this._charAt(++cursor);
1037 if (yych == 'm') { gotoCase = 69; continue; };
1038 if (yych == 's') { gotoCase = 69; continue; };
1039 { gotoCase = 68; continue; };
1040 case 78:
1041 yych = this._charAt(++cursor);
1042 if (yych == 'n') { gotoCase = 69; continue; };
1043 { gotoCase = 68; continue; };
1044 case 79:
1045 yych = this._charAt(++cursor);
1046 if (yych == 'e') { gotoCase = 89; continue; };
1047 { gotoCase = 68; continue; };
1048 case 80:
1049 yych = this._charAt(++cursor);
1050 if (yych == 'r') { gotoCase = 87; continue; };
1051 { gotoCase = 68; continue; };
1052 case 81:
1053 yych = this._charAt(++cursor);
1054 if (yych == 'u') { gotoCase = 85; continue; };
1055 { gotoCase = 68; continue; };
1056 case 82:
1057 yych = this._charAt(++cursor);
1058 if (yych == 'z') { gotoCase = 69; continue; };
1059 { gotoCase = 68; continue; };
1060 case 83:
1061 yych = this._charAt(++cursor);
1062 if (yych != 'H') { gotoCase = 68; continue; };
1063 yych = this._charAt(++cursor);
1064 if (yych == 'z') { gotoCase = 69; continue; };
1065 { gotoCase = 68; continue; };
1066 case 85:
1067 yych = this._charAt(++cursor);
1068 if (yych != 'r') { gotoCase = 68; continue; };
1069 yych = this._charAt(++cursor);
1070 if (yych == 'n') { gotoCase = 69; continue; };
1071 { gotoCase = 68; continue; };
1072 case 87:
1073 yych = this._charAt(++cursor);
1074 if (yych != 'a') { gotoCase = 68; continue; };
1075 yych = this._charAt(++cursor);
1076 if (yych == 'd') { gotoCase = 69; continue; };
1077 { gotoCase = 68; continue; };
1078 case 89:
1079 yych = this._charAt(++cursor);
1080 if (yych == 'g') { gotoCase = 69; continue; };
1081 { gotoCase = 68; continue; };
1082 case 90:
1083 yych = this._charAt(++cursor);
1084 if (yych != 'q') { gotoCase = 68; continue; };
1085 yych = this._charAt(++cursor);
1086 if (yych != 'e') { gotoCase = 68; continue; };
1087 yych = this._charAt(++cursor);
1088 if (yych == 'm') { gotoCase = 69; continue; };
1089 { gotoCase = 68; continue; };
1090 case 93:
1091 yych = this._charAt(++cursor);
1092 if (yych == 'd') { gotoCase = 69; continue; };
1093 { gotoCase = 68; continue; };
1094 case 94:
1095 yych = this._charAt(++cursor);
1096 if (yych == 'm') { gotoCase = 69; continue; };
1097 { gotoCase = 68; continue; };
1098 case 95:
1099 yych = this._charAt(++cursor);
1100 if (yych != 'r') { gotoCase = 51; continue; };
1101 yych = this._charAt(++cursor);
1102 if (yych == 'n') { gotoCase = 65; continue; };
1103 { gotoCase = 51; continue; };
1104 case 97:
1105 yych = this._charAt(++cursor);
1106 if (yych == 'd') { gotoCase = 65; continue; };
1107 { gotoCase = 51; continue; };
1108 case 98:
1109 yych = this._charAt(++cursor);
1110 if (yych == 'm') { gotoCase = 65; continue; };
1111 { gotoCase = 51; continue; };
1112 case 99:
1113 yych = this._charAt(++cursor);
1114 if (yych == 'z') { gotoCase = 65; continue; };
1115 { gotoCase = 51; continue; };
1116 case 100:
1117 yych = this._charAt(++cursor);
1118 if (yych != 'a') { gotoCase = 51; continue; };
1119 yych = this._charAt(++cursor);
1120 if (yych == 'd') { gotoCase = 65; continue; };
1121 { gotoCase = 51; continue; };
1122 case 102:
1123 yych = this._charAt(++cursor);
1124 if (yych == 'g') { gotoCase = 65; continue; };
1125 { gotoCase = 51; continue; };
1126 case 103:
1127 yych = this._charAt(++cursor);
1128 if (yych != 'q') { gotoCase = 51; continue; };
1129 yych = this._charAt(++cursor);
1130 if (yych != 'e') { gotoCase = 51; continue; };
1131 yych = this._charAt(++cursor);
1132 if (yych == 'm') { gotoCase = 65; continue; };
1133 { gotoCase = 51; continue; };
1134 case 106:
1135 ++cursor;
1136 yych = this._charAt(cursor);
1137 if (yych <= '\f') {
1138 if (yych == '\n') { gotoCase = 110; continue; };
1139 { gotoCase = 106; continue; };
1140 } else {
1141 if (yych <= '\r') { gotoCase = 110; continue; };
1142 if (yych != '*') { gotoCase = 106; continue; };
1143 }
1144 case 108:
1145 ++cursor;
1146 yych = this._charAt(cursor);
1147 if (yych == '*') { gotoCase = 108; continue; };
1148 if (yych == '/') { gotoCase = 112; continue; };
1149 { gotoCase = 106; continue; };
1150 case 110:
1151 ++cursor;
1152 this.setLexCondition(this._lexConditions.COMMENT);
1153 { this.tokenType = "css-comment"; return cursor; }
1154 case 112:
1155 ++cursor;
1156 { this.tokenType = "css-comment"; return cursor; }
1157 case 114:
1158 yyaccept = 0;
1159 YYMARKER = ++cursor;
1160 yych = this._charAt(cursor);
1161 if (yych <= '.') {
1162 if (yych <= '"') {
1163 if (yych <= '\f') {
1164 if (yych == '\n') { gotoCase = 32; continue; };
1165 { gotoCase = 118; continue; };
1166 } else {
1167 if (yych <= '\r') { gotoCase = 32; continue; };
1168 if (yych <= ' ') { gotoCase = 118; continue; };
1169 { gotoCase = 114; continue; };
1170 }
1171 } else {
1172 if (yych <= '\'') {
1173 if (yych <= '%') { gotoCase = 118; continue; };
1174 if (yych <= '&') { gotoCase = 114; continue; };
1175 } else {
1176 if (yych == '-') { gotoCase = 114; continue; };
1177 { gotoCase = 118; continue; };
1178 }
1179 }
1180 } else {
1181 if (yych <= '\\') {
1182 if (yych <= '=') {
1183 if (yych <= '9') { gotoCase = 114; continue; };
1184 if (yych <= '<') { gotoCase = 118; continue; };
1185 { gotoCase = 114; continue; };
1186 } else {
1187 if (yych <= '?') { gotoCase = 118; continue; };
1188 if (yych <= '[') { gotoCase = 114; continue; };
1189 { gotoCase = 120; continue; };
1190 }
1191 } else {
1192 if (yych <= '_') {
1193 if (yych == '^') { gotoCase = 118; continue; };
1194 { gotoCase = 114; continue; };
1195 } else {
1196 if (yych <= '`') { gotoCase = 118; continue; };
1197 if (yych <= 'z') { gotoCase = 114; continue; };
1198 { gotoCase = 118; continue; };
1199 }
1200 }
1201 }
1202 case 116:
1203 ++cursor;
1204 if ((yych = this._charAt(cursor)) <= '<') {
1205 if (yych <= '\'') {
1206 if (yych <= ' ') { gotoCase = 117; continue; };
1207 if (yych <= '"') { gotoCase = 50; continue; };
1208 if (yych >= '&') { gotoCase = 50; continue; };
1209 } else {
1210 if (yych <= '-') {
1211 if (yych >= '-') { gotoCase = 50; continue; };
1212 } else {
1213 if (yych <= '.') { gotoCase = 117; continue; };
1214 if (yych <= '9') { gotoCase = 50; continue; };
1215 }
1216 }
1217 } else {
1218 if (yych <= ']') {
1219 if (yych <= '?') {
1220 if (yych <= '=') { gotoCase = 50; continue; };
1221 } else {
1222 if (yych != '\\') { gotoCase = 50; continue; };
1223 }
1224 } else {
1225 if (yych <= '_') {
1226 if (yych >= '_') { gotoCase = 50; continue; };
1227 } else {
1228 if (yych <= '`') { gotoCase = 117; continue; };
1229 if (yych <= 'z') { gotoCase = 50; continue; };
1230 }
1231 }
1232 }
1233 case 117:
1234 { return this._stringToken(cursor, true); }
1235 case 118:
1236 ++cursor;
1237 yych = this._charAt(cursor);
1238 if (yych <= '\r') {
1239 if (yych == '\n') { gotoCase = 68; continue; };
1240 if (yych <= '\f') { gotoCase = 118; continue; };
1241 { gotoCase = 68; continue; };
1242 } else {
1243 if (yych <= '\'') {
1244 if (yych <= '&') { gotoCase = 118; continue; };
1245 { gotoCase = 123; continue; };
1246 } else {
1247 if (yych != '\\') { gotoCase = 118; continue; };
1248 }
1249 }
1250 case 120:
1251 ++cursor;
1252 yych = this._charAt(cursor);
1253 if (yych <= 'a') {
1254 if (yych <= '!') {
1255 if (yych <= '\n') {
1256 if (yych <= '\t') { gotoCase = 68; continue; };
1257 } else {
1258 if (yych != '\r') { gotoCase = 68; continue; };
1259 }
1260 } else {
1261 if (yych <= '\'') {
1262 if (yych <= '"') { gotoCase = 118; continue; };
1263 if (yych <= '&') { gotoCase = 68; continue; };
1264 { gotoCase = 118; continue; };
1265 } else {
1266 if (yych == '\\') { gotoCase = 118; continue; };
1267 { gotoCase = 68; continue; };
1268 }
1269 }
1270 } else {
1271 if (yych <= 'q') {
1272 if (yych <= 'f') {
1273 if (yych <= 'b') { gotoCase = 118; continue; };
1274 if (yych <= 'e') { gotoCase = 68; continue; };
1275 { gotoCase = 118; continue; };
1276 } else {
1277 if (yych == 'n') { gotoCase = 118; continue; };
1278 { gotoCase = 68; continue; };
1279 }
1280 } else {
1281 if (yych <= 't') {
1282 if (yych == 's') { gotoCase = 68; continue; };
1283 { gotoCase = 118; continue; };
1284 } else {
1285 if (yych == 'v') { gotoCase = 118; continue; };
1286 { gotoCase = 68; continue; };
1287 }
1288 }
1289 }
1290 ++cursor;
1291 this.setLexCondition(this._lexConditions.SSTRING);
1292 { return this._stringToken(cursor); }
1293 case 123:
1294 yych = this._charAt(++cursor);
1295 { gotoCase = 117; continue; };
1296 case 124:
1297 ++cursor;
1298 yych = this._charAt(cursor);
1299 if (yych <= '<') {
1300 if (yych <= '\'') {
1301 if (yych <= ' ') { gotoCase = 126; continue; };
1302 if (yych <= '"') { gotoCase = 124; continue; };
1303 if (yych >= '&') { gotoCase = 124; continue; };
1304 } else {
1305 if (yych <= '-') {
1306 if (yych >= '-') { gotoCase = 124; continue; };
1307 } else {
1308 if (yych <= '.') { gotoCase = 126; continue; };
1309 if (yych <= '9') { gotoCase = 124; continue; };
1310 }
1311 }
1312 } else {
1313 if (yych <= ']') {
1314 if (yych <= '?') {
1315 if (yych <= '=') { gotoCase = 124; continue; };
1316 } else {
1317 if (yych != '\\') { gotoCase = 124; continue; };
1318 }
1319 } else {
1320 if (yych <= '_') {
1321 if (yych >= '_') { gotoCase = 124; continue; };
1322 } else {
1323 if (yych <= '`') { gotoCase = 126; continue; };
1324 if (yych <= 'z') { gotoCase = 124; continue; };
1325 }
1326 }
1327 }
1328 case 126:
1329 {
1330 if (this._condition.parseCondition === this._condition.parse Condition.INITIAL || this._condition.parseCondition === this._condition.parseCon dition.AT_RULE)
1331 this._setParseCondition(this._parseConditions.PROPERTY);
1332 this.tokenType = "scss-variable";
1333 return cursor;
1334 }
1335 case 127:
1336 ++cursor;
1337 yych = this._charAt(cursor);
1338 if (yych <= '@') {
1339 if (yych <= '/') { gotoCase = 129; continue; };
1340 if (yych <= '9') { gotoCase = 127; continue; };
1341 } else {
1342 if (yych <= 'Z') { gotoCase = 127; continue; };
1343 if (yych <= '`') { gotoCase = 129; continue; };
1344 if (yych <= 'z') { gotoCase = 127; continue; };
1345 }
1346 case 129:
1347 {
1348 if (this._isPropertyValue())
1349 this.tokenType = "css-color";
1350 else if (this._condition.parseCondition === this._parseCondi tions.INITIAL)
1351 this.tokenType = "css-selector";
1352 else
1353 this.tokenType = null;
1354 return cursor;
1355 }
1356 case 130:
1357 yyaccept = 0;
1358 YYMARKER = ++cursor;
1359 yych = this._charAt(cursor);
1360 if (yych <= '.') {
1361 if (yych <= '!') {
1362 if (yych <= '\f') {
1363 if (yych == '\n') { gotoCase = 32; continue; };
1364 } else {
1365 if (yych <= '\r') { gotoCase = 32; continue; };
1366 if (yych >= '!') { gotoCase = 130; continue; };
1367 }
1368 } else {
1369 if (yych <= '\'') {
1370 if (yych <= '"') { gotoCase = 116; continue; };
1371 if (yych >= '&') { gotoCase = 130; continue; };
1372 } else {
1373 if (yych == '-') { gotoCase = 130; continue; };
1374 }
1375 }
1376 } else {
1377 if (yych <= '\\') {
1378 if (yych <= '=') {
1379 if (yych <= '9') { gotoCase = 130; continue; };
1380 if (yych >= '=') { gotoCase = 130; continue; };
1381 } else {
1382 if (yych <= '?') { gotoCase = 132; continue; };
1383 if (yych <= '[') { gotoCase = 130; continue; };
1384 { gotoCase = 134; continue; };
1385 }
1386 } else {
1387 if (yych <= '_') {
1388 if (yych != '^') { gotoCase = 130; continue; };
1389 } else {
1390 if (yych <= '`') { gotoCase = 132; continue; };
1391 if (yych <= 'z') { gotoCase = 130; continue; };
1392 }
1393 }
1394 }
1395 case 132:
1396 ++cursor;
1397 yych = this._charAt(cursor);
1398 if (yych <= '\r') {
1399 if (yych == '\n') { gotoCase = 68; continue; };
1400 if (yych <= '\f') { gotoCase = 132; continue; };
1401 { gotoCase = 68; continue; };
1402 } else {
1403 if (yych <= '"') {
1404 if (yych <= '!') { gotoCase = 132; continue; };
1405 { gotoCase = 123; continue; };
1406 } else {
1407 if (yych != '\\') { gotoCase = 132; continue; };
1408 }
1409 }
1410 case 134:
1411 ++cursor;
1412 yych = this._charAt(cursor);
1413 if (yych <= 'a') {
1414 if (yych <= '!') {
1415 if (yych <= '\n') {
1416 if (yych <= '\t') { gotoCase = 68; continue; };
1417 } else {
1418 if (yych != '\r') { gotoCase = 68; continue; };
1419 }
1420 } else {
1421 if (yych <= '\'') {
1422 if (yych <= '"') { gotoCase = 132; continue; };
1423 if (yych <= '&') { gotoCase = 68; continue; };
1424 { gotoCase = 132; continue; };
1425 } else {
1426 if (yych == '\\') { gotoCase = 132; continue; };
1427 { gotoCase = 68; continue; };
1428 }
1429 }
1430 } else {
1431 if (yych <= 'q') {
1432 if (yych <= 'f') {
1433 if (yych <= 'b') { gotoCase = 132; continue; };
1434 if (yych <= 'e') { gotoCase = 68; continue; };
1435 { gotoCase = 132; continue; };
1436 } else {
1437 if (yych == 'n') { gotoCase = 132; continue; };
1438 { gotoCase = 68; continue; };
1439 }
1440 } else {
1441 if (yych <= 't') {
1442 if (yych == 's') { gotoCase = 68; continue; };
1443 { gotoCase = 132; continue; };
1444 } else {
1445 if (yych == 'v') { gotoCase = 132; continue; };
1446 { gotoCase = 68; continue; };
1447 }
1448 }
1449 }
1450 ++cursor;
1451 this.setLexCondition(this._lexConditions.DSTRING);
1452 { return this._stringToken(cursor); }
1453 /* *********************************** */
1454 case this.case_SSTRING:
1455 yych = this._charAt(cursor);
1456 if (yych <= '\r') {
1457 if (yych == '\n') { gotoCase = 141; continue; };
1458 if (yych <= '\f') { gotoCase = 140; continue; };
1459 { gotoCase = 141; continue; };
1460 } else {
1461 if (yych <= '\'') {
1462 if (yych <= '&') { gotoCase = 140; continue; };
1463 { gotoCase = 143; continue; };
1464 } else {
1465 if (yych == '\\') { gotoCase = 145; continue; };
1466 { gotoCase = 140; continue; };
1467 }
1468 }
1469 case 139:
1470 { return this._stringToken(cursor); }
1471 case 140:
1472 yyaccept = 0;
1473 yych = this._charAt(YYMARKER = ++cursor);
1474 { gotoCase = 147; continue; };
1475 case 141:
1476 ++cursor;
1477 case 142:
1478 { this.tokenType = null; return cursor; }
1479 case 143:
1480 ++cursor;
1481 case 144:
1482 this.setLexCondition(this._lexConditions.INITIAL);
1483 { return this._stringToken(cursor, true); }
1484 case 145:
1485 yych = this._charAt(++cursor);
1486 if (yych <= 'e') {
1487 if (yych <= '\'') {
1488 if (yych == '"') { gotoCase = 146; continue; };
1489 if (yych <= '&') { gotoCase = 142; continue; };
1490 } else {
1491 if (yych <= '\\') {
1492 if (yych <= '[') { gotoCase = 142; continue; };
1493 } else {
1494 if (yych != 'b') { gotoCase = 142; continue; };
1495 }
1496 }
1497 } else {
1498 if (yych <= 'r') {
1499 if (yych <= 'm') {
1500 if (yych >= 'g') { gotoCase = 142; continue; };
1501 } else {
1502 if (yych <= 'n') { gotoCase = 146; continue; };
1503 if (yych <= 'q') { gotoCase = 142; continue; };
1504 }
1505 } else {
1506 if (yych <= 't') {
1507 if (yych <= 's') { gotoCase = 142; continue; };
1508 } else {
1509 if (yych != 'v') { gotoCase = 142; continue; };
1510 }
1511 }
1512 }
1513 case 146:
1514 yyaccept = 0;
1515 YYMARKER = ++cursor;
1516 yych = this._charAt(cursor);
1517 case 147:
1518 if (yych <= '\r') {
1519 if (yych == '\n') { gotoCase = 139; continue; };
1520 if (yych <= '\f') { gotoCase = 146; continue; };
1521 { gotoCase = 139; continue; };
1522 } else {
1523 if (yych <= '\'') {
1524 if (yych <= '&') { gotoCase = 146; continue; };
1525 { gotoCase = 150; continue; };
1526 } else {
1527 if (yych != '\\') { gotoCase = 146; continue; };
1528 }
1529 }
1530 ++cursor;
1531 yych = this._charAt(cursor);
1532 if (yych <= 'e') {
1533 if (yych <= '\'') {
1534 if (yych == '"') { gotoCase = 146; continue; };
1535 if (yych >= '\'') { gotoCase = 146; continue; };
1536 } else {
1537 if (yych <= '\\') {
1538 if (yych >= '\\') { gotoCase = 146; continue; };
1539 } else {
1540 if (yych == 'b') { gotoCase = 146; continue; };
1541 }
1542 }
1543 } else {
1544 if (yych <= 'r') {
1545 if (yych <= 'm') {
1546 if (yych <= 'f') { gotoCase = 146; continue; };
1547 } else {
1548 if (yych <= 'n') { gotoCase = 146; continue; };
1549 if (yych >= 'r') { gotoCase = 146; continue; };
1550 }
1551 } else {
1552 if (yych <= 't') {
1553 if (yych >= 't') { gotoCase = 146; continue; };
1554 } else {
1555 if (yych == 'v') { gotoCase = 146; continue; };
1556 }
1557 }
1558 }
1559 cursor = YYMARKER;
1560 { gotoCase = 139; continue; };
1561 case 150:
1562 ++cursor;
1563 yych = this._charAt(cursor);
1564 { gotoCase = 144; continue; };
1565 }
1566
1567 }
1568 },
1569
1570 __proto__: WebInspector.SourceTokenizer.prototype
1571 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698