| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2009 Google Inc. All rights reserved. | 2 * Copyright (C) 2009 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 1638 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1649 ownerElement->csp(), ownerElement->allowedFeatures()); | 1649 ownerElement->csp(), ownerElement->allowedFeatures()); |
| 1650 // FIXME: Using subResourceAttributeName as fallback is not a perfect | 1650 // FIXME: Using subResourceAttributeName as fallback is not a perfect |
| 1651 // solution. subResourceAttributeName returns just one attribute name. The | 1651 // solution. subResourceAttributeName returns just one attribute name. The |
| 1652 // element might not have the attribute, and there might be other attributes | 1652 // element might not have the attribute, and there might be other attributes |
| 1653 // which can identify the element. | 1653 // which can identify the element. |
| 1654 WebLocalFrameImpl* webframeChild = | 1654 WebLocalFrameImpl* webframeChild = |
| 1655 toWebLocalFrameImpl(m_client->createChildFrame( | 1655 toWebLocalFrameImpl(m_client->createChildFrame( |
| 1656 this, scope, name, | 1656 this, scope, name, |
| 1657 ownerElement->getAttribute(ownerElement->subResourceAttributeName()), | 1657 ownerElement->getAttribute(ownerElement->subResourceAttributeName()), |
| 1658 static_cast<WebSandboxFlags>(ownerElement->getSandboxFlags()), | 1658 static_cast<WebSandboxFlags>(ownerElement->getSandboxFlags()), |
| 1659 ownerProperties)); | 1659 ownerElement->containerPolicy(), ownerProperties)); |
| 1660 if (!webframeChild) | 1660 if (!webframeChild) |
| 1661 return nullptr; | 1661 return nullptr; |
| 1662 | 1662 |
| 1663 webframeChild->initializeCoreFrame(*frame()->page(), ownerElement, name); | 1663 webframeChild->initializeCoreFrame(*frame()->page(), ownerElement, name); |
| 1664 // Initializing the core frame may cause the new child to be detached, since | 1664 // Initializing the core frame may cause the new child to be detached, since |
| 1665 // it may dispatch a load event in the parent. | 1665 // it may dispatch a load event in the parent. |
| 1666 if (!webframeChild->parent()) | 1666 if (!webframeChild->parent()) |
| 1667 return nullptr; | 1667 return nullptr; |
| 1668 | 1668 |
| 1669 // If we're moving in the back/forward list, we might want to replace the | 1669 // If we're moving in the back/forward list, we might want to replace the |
| (...skipping 844 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2514 createMarkup(startPosition, endPosition, AnnotateForInterchange, | 2514 createMarkup(startPosition, endPosition, AnnotateForInterchange, |
| 2515 ConvertBlocksToInlines::NotConvert, ResolveNonLocalURLs); | 2515 ConvertBlocksToInlines::NotConvert, ResolveNonLocalURLs); |
| 2516 } else { | 2516 } else { |
| 2517 clipHtml = | 2517 clipHtml = |
| 2518 createMarkup(endPosition, startPosition, AnnotateForInterchange, | 2518 createMarkup(endPosition, startPosition, AnnotateForInterchange, |
| 2519 ConvertBlocksToInlines::NotConvert, ResolveNonLocalURLs); | 2519 ConvertBlocksToInlines::NotConvert, ResolveNonLocalURLs); |
| 2520 } | 2520 } |
| 2521 } | 2521 } |
| 2522 | 2522 |
| 2523 } // namespace blink | 2523 } // namespace blink |
| OLD | NEW |