| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "config.h" | 5 #include "config.h" |
| 6 #include "core/css/parser/MediaQueryTokenizer.h" | 6 #include "core/css/parser/MediaQueryTokenizer.h" |
| 7 | 7 |
| 8 namespace WebCore { | 8 namespace WebCore { |
| 9 #include "MediaQueryTokenizerCodepoints.cpp" | 9 #include "MediaQueryTokenizerCodepoints.cpp" |
| 10 } | 10 } |
| (...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 70 MediaQueryToken MediaQueryTokenizer::leftParenthesis(UChar cc) | 70 MediaQueryToken MediaQueryTokenizer::leftParenthesis(UChar cc) |
| 71 { | 71 { |
| 72 return MediaQueryToken(LeftParenthesisToken); | 72 return MediaQueryToken(LeftParenthesisToken); |
| 73 } | 73 } |
| 74 | 74 |
| 75 MediaQueryToken MediaQueryTokenizer::rightParenthesis(UChar cc) | 75 MediaQueryToken MediaQueryTokenizer::rightParenthesis(UChar cc) |
| 76 { | 76 { |
| 77 return MediaQueryToken(RightParenthesisToken); | 77 return MediaQueryToken(RightParenthesisToken); |
| 78 } | 78 } |
| 79 | 79 |
| 80 MediaQueryToken MediaQueryTokenizer::leftBracket(UChar cc) |
| 81 { |
| 82 return MediaQueryToken(LeftBracketToken); |
| 83 } |
| 84 |
| 85 MediaQueryToken MediaQueryTokenizer::rightBracket(UChar cc) |
| 86 { |
| 87 return MediaQueryToken(RightBracketToken); |
| 88 } |
| 89 |
| 90 MediaQueryToken MediaQueryTokenizer::leftBrace(UChar cc) |
| 91 { |
| 92 return MediaQueryToken(LeftBraceToken); |
| 93 } |
| 94 |
| 95 MediaQueryToken MediaQueryTokenizer::rightBrace(UChar cc) |
| 96 { |
| 97 return MediaQueryToken(RightBraceToken); |
| 98 } |
| 99 |
| 80 MediaQueryToken MediaQueryTokenizer::plusOrFullStop(UChar cc) | 100 MediaQueryToken MediaQueryTokenizer::plusOrFullStop(UChar cc) |
| 81 { | 101 { |
| 82 if (nextCharsAreNumber()) { | 102 if (nextCharsAreNumber()) { |
| 83 reconsume(cc); | 103 reconsume(cc); |
| 84 return consumeNumericToken(); | 104 return consumeNumericToken(); |
| 85 } | 105 } |
| 86 return MediaQueryToken(DelimiterToken, cc); | 106 return MediaQueryToken(DelimiterToken, cc); |
| 87 } | 107 } |
| 88 | 108 |
| 89 MediaQueryToken MediaQueryTokenizer::comma(UChar cc) | 109 MediaQueryToken MediaQueryTokenizer::comma(UChar cc) |
| (...skipping 317 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 407 if (firstChar == '-') { | 427 if (firstChar == '-') { |
| 408 if (isNameStart(m_input.peek(1))) | 428 if (isNameStart(m_input.peek(1))) |
| 409 return true; | 429 return true; |
| 410 return nextTwoCharsAreValidEscape(); | 430 return nextTwoCharsAreValidEscape(); |
| 411 } | 431 } |
| 412 | 432 |
| 413 return false; | 433 return false; |
| 414 } | 434 } |
| 415 | 435 |
| 416 } // namespace WebCore | 436 } // namespace WebCore |
| OLD | NEW |