| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) | 2 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) |
| 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) | 3 * (C) 1999 Antti Koivisto (koivisto@kde.org) |
| 4 * (C) 2001 Dirk Mueller (mueller@kde.org) | 4 * (C) 2001 Dirk Mueller (mueller@kde.org) |
| 5 * Copyright (C) 2003, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv
ed. | 5 * Copyright (C) 2003, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights reserv
ed. |
| 6 * Copyright (C) 2009 Rob Buis (rwlbuis@gmail.com) | 6 * Copyright (C) 2009 Rob Buis (rwlbuis@gmail.com) |
| 7 * Copyright (C) 2011 Google Inc. All rights reserved. | 7 * Copyright (C) 2011 Google Inc. All rights reserved. |
| 8 * | 8 * |
| 9 * This library is free software; you can redistribute it and/or | 9 * This library is free software; you can redistribute it and/or |
| 10 * modify it under the terms of the GNU Library General Public | 10 * modify it under the terms of the GNU Library General Public |
| (...skipping 421 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 432 return m_owner->document(); | 432 return m_owner->document(); |
| 433 } | 433 } |
| 434 | 434 |
| 435 enum StyleSheetCacheStatus { | 435 enum StyleSheetCacheStatus { |
| 436 StyleSheetNewEntry, | 436 StyleSheetNewEntry, |
| 437 StyleSheetInDiskCache, | 437 StyleSheetInDiskCache, |
| 438 StyleSheetInMemoryCache, | 438 StyleSheetInMemoryCache, |
| 439 StyleSheetCacheStatusCount, | 439 StyleSheetCacheStatusCount, |
| 440 }; | 440 }; |
| 441 | 441 |
| 442 void LinkStyle::setCSSStyleSheet(const String& href, const KURL& baseURL, const
String& charset, const CSSStyleSheetResource* cachedStyleSheet) | 442 void LinkStyle::setCSSStyleSheet(const String& href, const KURL& baseURL, const
String& charset, CSSStyleSheetResource* cachedStyleSheet) |
| 443 { | 443 { |
| 444 if (!m_owner->isConnected()) { | 444 if (!m_owner->isConnected()) { |
| 445 // While the stylesheet is asynchronously loading, the owner can be disc
onnected from a document. | 445 // While the stylesheet is asynchronously loading, the owner can be disc
onnected from a document. |
| 446 // In that case, cancel any processing on the loaded content. | 446 // In that case, cancel any processing on the loaded content. |
| 447 m_loading = false; | 447 m_loading = false; |
| 448 removePendingSheet(); | 448 removePendingSheet(); |
| 449 if (m_sheet) | 449 if (m_sheet) |
| 450 clearSheet(); | 450 clearSheet(); |
| 451 return; | 451 return; |
| 452 } | 452 } |
| (...skipping 273 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 726 } | 726 } |
| 727 | 727 |
| 728 DEFINE_TRACE(LinkStyle) | 728 DEFINE_TRACE(LinkStyle) |
| 729 { | 729 { |
| 730 visitor->trace(m_sheet); | 730 visitor->trace(m_sheet); |
| 731 LinkResource::trace(visitor); | 731 LinkResource::trace(visitor); |
| 732 ResourceOwner<StyleSheetResource>::trace(visitor); | 732 ResourceOwner<StyleSheetResource>::trace(visitor); |
| 733 } | 733 } |
| 734 | 734 |
| 735 } // namespace blink | 735 } // namespace blink |
| OLD | NEW |