| 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) 2000 Simon Hausmann (hausmann@kde.org) |    4  *           (C) 2000 Simon Hausmann (hausmann@kde.org) | 
|    5  *           (C) 2001 Dirk Mueller (mueller@kde.org) |    5  *           (C) 2001 Dirk Mueller (mueller@kde.org) | 
|    6  * Copyright (C) 2004, 2006, 2008, 2009 Apple Inc. All rights reserved. |    6  * Copyright (C) 2004, 2006, 2008, 2009 Apple Inc. All rights reserved. | 
|    7  * |    7  * | 
|    8  * This library is free software; you can redistribute it and/or |    8  * This library is free software; you can redistribute it and/or | 
|    9  * modify it under the terms of the GNU Library General Public |    9  * modify it under the terms of the GNU Library General Public | 
|   10  * License as published by the Free Software Foundation; either |   10  * License as published by the Free Software Foundation; either | 
| (...skipping 145 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|  156   } else if (name == onbeforeunloadAttr) { |  156   } else if (name == onbeforeunloadAttr) { | 
|  157     // FIXME: should <frame> elements have beforeunload handlers? |  157     // FIXME: should <frame> elements have beforeunload handlers? | 
|  158     SetAttributeEventListener( |  158     SetAttributeEventListener( | 
|  159         EventTypeNames::beforeunload, |  159         EventTypeNames::beforeunload, | 
|  160         CreateAttributeEventListener(this, name, value, EventParameterName())); |  160         CreateAttributeEventListener(this, name, value, EventParameterName())); | 
|  161   } else { |  161   } else { | 
|  162     HTMLFrameOwnerElement::ParseAttribute(params); |  162     HTMLFrameOwnerElement::ParseAttribute(params); | 
|  163   } |  163   } | 
|  164 } |  164 } | 
|  165  |  165  | 
 |  166 const RefPtr<SecurityOrigin> HTMLFrameElementBase::GetOriginForFeaturePolicy() | 
 |  167     const { | 
 |  168   KURL url = GetDocument().CompleteURL(url_); | 
 |  169   // Sandboxed frames have a unique origin. | 
 |  170   if (url.ProtocolIsData() || (GetSandboxFlags() & kSandboxOrigin)) | 
 |  171     return SecurityOrigin::CreateUnique(); | 
 |  172  | 
 |  173   // If the frame will inherit its origin from the owner, then use the owner's | 
 |  174   // origin when constructing the container policy. | 
 |  175   if (Document::ShouldInheritSecurityOriginFromOwner(url)) | 
 |  176     return GetDocument().GetSecurityOrigin(); | 
 |  177  | 
 |  178   // Other frames should use the origin defined by the absolute URL (this will | 
 |  179   // be a unique origin for data: URLs) | 
 |  180   return SecurityOrigin::Create(url); | 
 |  181 } | 
 |  182  | 
|  166 void HTMLFrameElementBase::SetNameAndOpenURL() { |  183 void HTMLFrameElementBase::SetNameAndOpenURL() { | 
|  167   frame_name_ = GetNameAttribute(); |  184   frame_name_ = GetNameAttribute(); | 
|  168   OpenURL(); |  185   OpenURL(); | 
|  169 } |  186 } | 
|  170  |  187  | 
|  171 Node::InsertionNotificationRequest HTMLFrameElementBase::InsertedInto( |  188 Node::InsertionNotificationRequest HTMLFrameElementBase::InsertedInto( | 
|  172     ContainerNode* insertion_point) { |  189     ContainerNode* insertion_point) { | 
|  173   HTMLFrameOwnerElement::InsertedInto(insertion_point); |  190   HTMLFrameOwnerElement::InsertedInto(insertion_point); | 
|  174   return kInsertionShouldCallDidNotifySubtreeInsertions; |  191   return kInsertionShouldCallDidNotifySubtreeInsertions; | 
|  175 } |  192 } | 
| (...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
|  271  |  288  | 
|  272   if (contentDocument()) { |  289   if (contentDocument()) { | 
|  273     contentDocument()->WillChangeFrameOwnerProperties( |  290     contentDocument()->WillChangeFrameOwnerProperties( | 
|  274         margin_width_, margin_height, scrolling_mode_, IsDisplayNone()); |  291         margin_width_, margin_height, scrolling_mode_, IsDisplayNone()); | 
|  275   } |  292   } | 
|  276   margin_height_ = margin_height; |  293   margin_height_ = margin_height; | 
|  277   FrameOwnerPropertiesChanged(); |  294   FrameOwnerPropertiesChanged(); | 
|  278 } |  295 } | 
|  279  |  296  | 
|  280 }  // namespace blink |  297 }  // namespace blink | 
| OLD | NEW |