OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. | 2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. |
3 * Copyright (C) 2009 Torch Mobile, Inc. http://www.torchmobile.com/ | 3 * Copyright (C) 2009 Torch Mobile, Inc. http://www.torchmobile.com/ |
4 * Copyright (C) 2010 Google Inc. All Rights Reserved. | 4 * Copyright (C) 2010 Google Inc. All Rights Reserved. |
5 * | 5 * |
6 * Redistribution and use in source and binary forms, with or without | 6 * Redistribution and use in source and binary forms, with or without |
7 * modification, are permitted provided that the following conditions | 7 * modification, are permitted provided that the following conditions |
8 * are met: | 8 * are met: |
9 * 1. Redistributions of source code must retain the above copyright | 9 * 1. Redistributions of source code must retain the above copyright |
10 * notice, this list of conditions and the following disclaimer. | 10 * notice, this list of conditions and the following disclaimer. |
(...skipping 363 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
374 ASSERT(isMainThread()); // HTMLTokenizer::updateStateFor only works on the m
ain thread. | 374 ASSERT(isMainThread()); // HTMLTokenizer::updateStateFor only works on the m
ain thread. |
375 | 375 |
376 // When we start scanning, our best prediction of the baseElementURL is the
real one! | 376 // When we start scanning, our best prediction of the baseElementURL is the
real one! |
377 if (!startingBaseElementURL.isEmpty()) | 377 if (!startingBaseElementURL.isEmpty()) |
378 m_scanner.setPredictedBaseElementURL(startingBaseElementURL); | 378 m_scanner.setPredictedBaseElementURL(startingBaseElementURL); |
379 | 379 |
380 PreloadRequestStream requests; | 380 PreloadRequestStream requests; |
381 | 381 |
382 while (m_tokenizer->nextToken(m_source, m_token)) { | 382 while (m_tokenizer->nextToken(m_source, m_token)) { |
383 if (m_token.type() == HTMLToken::StartTag) | 383 if (m_token.type() == HTMLToken::StartTag) |
384 m_tokenizer->updateStateFor(AtomicString(m_token.name())); | 384 m_tokenizer->updateStateFor(HTMLIdentifier(m_token.name(), Likely8Bi
t)); |
385 m_scanner.scan(m_token, m_source, requests); | 385 m_scanner.scan(m_token, m_source, requests); |
386 m_token.clear(); | 386 m_token.clear(); |
387 } | 387 } |
388 | 388 |
389 preloader->takeAndPreload(requests); | 389 preloader->takeAndPreload(requests); |
390 } | 390 } |
391 | 391 |
392 } | 392 } |
OLD | NEW |