OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2006, 2007, 2008, 2010 Apple Inc. All rights reserved. | 2 * Copyright (C) 2006, 2007, 2008, 2010 Apple Inc. All rights reserved. |
3 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) | 3 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies) |
4 * | 4 * |
5 * Redistribution and use in source and binary forms, with or without | 5 * Redistribution and use in source and binary forms, with or without |
6 * modification, are permitted provided that the following conditions | 6 * modification, are permitted provided that the following conditions |
7 * are met: | 7 * are met: |
8 * 1. Redistributions of source code must retain the above copyright | 8 * 1. 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 * 2. Redistributions in binary form must reproduce the above copyright | 10 * 2. Redistributions in binary form must reproduce the above copyright |
(...skipping 1199 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1210 unsigned DOMWindow::length() const | 1210 unsigned DOMWindow::length() const |
1211 { | 1211 { |
1212 if (!isCurrentlyDisplayedInFrame()) | 1212 if (!isCurrentlyDisplayedInFrame()) |
1213 return 0; | 1213 return 0; |
1214 | 1214 |
1215 return m_frame->tree().scopedChildCount(); | 1215 return m_frame->tree().scopedChildCount(); |
1216 } | 1216 } |
1217 | 1217 |
1218 const AtomicString& DOMWindow::name() const | 1218 const AtomicString& DOMWindow::name() const |
1219 { | 1219 { |
1220 if (!m_frame) | 1220 if (!isCurrentlyDisplayedInFrame()) |
1221 return nullAtom; | 1221 return nullAtom; |
1222 | 1222 |
1223 return m_frame->tree().name(); | 1223 return m_frame->tree().name(); |
1224 } | 1224 } |
1225 | 1225 |
1226 void DOMWindow::setName(const AtomicString& name) | 1226 void DOMWindow::setName(const AtomicString& name) |
1227 { | 1227 { |
1228 if (!m_frame) | 1228 if (!isCurrentlyDisplayedInFrame()) |
1229 return; | 1229 return; |
1230 | 1230 |
1231 m_frame->tree().setName(name); | 1231 m_frame->tree().setName(name); |
| 1232 ASSERT(m_frame->loader().client()); |
1232 m_frame->loader().client()->didChangeName(name); | 1233 m_frame->loader().client()->didChangeName(name); |
1233 } | 1234 } |
1234 | 1235 |
1235 void DOMWindow::setStatus(const String& string) | 1236 void DOMWindow::setStatus(const String& string) |
1236 { | 1237 { |
1237 m_status = string; | 1238 m_status = string; |
1238 | 1239 |
1239 if (!m_frame) | 1240 if (!m_frame) |
1240 return; | 1241 return; |
1241 | 1242 |
(...skipping 648 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1890 return static_cast<DOMWindowLifecycleNotifier&>(LifecycleContext<DOMWindow>:
:lifecycleNotifier()); | 1891 return static_cast<DOMWindowLifecycleNotifier&>(LifecycleContext<DOMWindow>:
:lifecycleNotifier()); |
1891 } | 1892 } |
1892 | 1893 |
1893 PassOwnPtr<LifecycleNotifier<DOMWindow> > DOMWindow::createLifecycleNotifier() | 1894 PassOwnPtr<LifecycleNotifier<DOMWindow> > DOMWindow::createLifecycleNotifier() |
1894 { | 1895 { |
1895 return DOMWindowLifecycleNotifier::create(this); | 1896 return DOMWindowLifecycleNotifier::create(this); |
1896 } | 1897 } |
1897 | 1898 |
1898 | 1899 |
1899 } // namespace WebCore | 1900 } // namespace WebCore |
OLD | NEW |