| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 // This is a port of ManifestParser.cc from WebKit/WebCore/loader/appcache. | 5 // This is a port of ManifestParser.cc from WebKit/WebCore/loader/appcache. |
| 6 | 6 |
| 7 /* | 7 /* |
| 8 * Copyright (C) 2008 Apple Inc. All Rights Reserved. | 8 * Copyright (C) 2008 Apple Inc. All Rights Reserved. |
| 9 * | 9 * |
| 10 * Redistribution and use in source and binary forms, with or without | 10 * Redistribution and use in source and binary forms, with or without |
| (...skipping 17 matching lines...) Expand all Loading... |
| 28 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE | 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. | 29 * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
| 30 */ | 30 */ |
| 31 | 31 |
| 32 #include "webkit/browser/appcache/manifest_parser.h" | 32 #include "webkit/browser/appcache/manifest_parser.h" |
| 33 | 33 |
| 34 #include "base/command_line.h" | 34 #include "base/command_line.h" |
| 35 #include "base/i18n/icu_string_conversions.h" | 35 #include "base/i18n/icu_string_conversions.h" |
| 36 #include "base/logging.h" | 36 #include "base/logging.h" |
| 37 #include "base/strings/utf_string_conversions.h" | 37 #include "base/strings/utf_string_conversions.h" |
| 38 #include "googleurl/src/gurl.h" | 38 #include "url/gurl.h" |
| 39 | 39 |
| 40 namespace appcache { | 40 namespace appcache { |
| 41 | 41 |
| 42 namespace { | 42 namespace { |
| 43 | 43 |
| 44 // Helper function used to identify 'isPattern' annotations. | 44 // Helper function used to identify 'isPattern' annotations. |
| 45 bool HasPatternMatchingAnnotation(const wchar_t* line_p, | 45 bool HasPatternMatchingAnnotation(const wchar_t* line_p, |
| 46 const wchar_t* line_end) { | 46 const wchar_t* line_end) { |
| 47 // Skip whitespace separating the resource url from the annotation. | 47 // Skip whitespace separating the resource url from the annotation. |
| 48 // Note: trailing whitespace has already been trimmed from the line. | 48 // Note: trailing whitespace has already been trimmed from the line. |
| (...skipping 312 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 361 fallback_url, is_pattern)); | 361 fallback_url, is_pattern)); |
| 362 } else { | 362 } else { |
| 363 NOTREACHED(); | 363 NOTREACHED(); |
| 364 } | 364 } |
| 365 } | 365 } |
| 366 | 366 |
| 367 return true; | 367 return true; |
| 368 } | 368 } |
| 369 | 369 |
| 370 } // namespace appcache | 370 } // namespace appcache |
| OLD | NEW |