OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) Research In Motion Limited 2010. All rights reserved. | 2 * Copyright (C) Research In Motion Limited 2010. All rights reserved. |
3 * Copyright (C) 2006 Apple Computer, Inc. | 3 * Copyright (C) 2006 Apple Computer, Inc. |
4 * | 4 * |
5 * This library is free software; you can redistribute it and/or | 5 * This library is free software; you can redistribute it and/or |
6 * modify it under the terms of the GNU Library General Public | 6 * modify it under the terms of the GNU Library General Public |
7 * License as published by the Free Software Foundation; either | 7 * License as published by the Free Software Foundation; either |
8 * version 2 of the License, or (at your option) any later version. | 8 * version 2 of the License, or (at your option) any later version. |
9 * | 9 * |
10 * This library is distributed in the hope that it will be useful, | 10 * This library is distributed in the hope that it will be useful, |
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
65 { | 65 { |
66 m_name = name; | 66 m_name = name; |
67 if (!parent()) { | 67 if (!parent()) { |
68 m_uniqueName = name; | 68 m_uniqueName = name; |
69 return; | 69 return; |
70 } | 70 } |
71 m_uniqueName = AtomicString(); // Remove our old frame name so it's not cons
idered in uniqueChildName. | 71 m_uniqueName = AtomicString(); // Remove our old frame name so it's not cons
idered in uniqueChildName. |
72 m_uniqueName = parent()->tree().uniqueChildName(name.isEmpty() ? fallbackNam
e : name); | 72 m_uniqueName = parent()->tree().uniqueChildName(name.isEmpty() ? fallbackNam
e : name); |
73 } | 73 } |
74 | 74 |
| 75 void FrameTree::setNameForReplacementFrame(const AtomicString& name, const Atomi
cString& uniqueName) |
| 76 { |
| 77 m_name = name; |
| 78 m_uniqueName = uniqueName; |
| 79 } |
| 80 |
75 Frame* FrameTree::parent() const | 81 Frame* FrameTree::parent() const |
76 { | 82 { |
77 if (!m_thisFrame->client()) | 83 if (!m_thisFrame->client()) |
78 return nullptr; | 84 return nullptr; |
79 return m_thisFrame->client()->parent(); | 85 return m_thisFrame->client()->parent(); |
80 } | 86 } |
81 | 87 |
82 Frame* FrameTree::top() const | 88 Frame* FrameTree::top() const |
83 { | 89 { |
84 // FIXME: top() should never return null, so here are some hacks to deal | 90 // FIXME: top() should never return null, so here are some hacks to deal |
(...skipping 322 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
407 { | 413 { |
408 if (!frame) { | 414 if (!frame) { |
409 printf("Null input frame\n"); | 415 printf("Null input frame\n"); |
410 return; | 416 return; |
411 } | 417 } |
412 | 418 |
413 printFrames(frame->tree().top(), frame, 0); | 419 printFrames(frame->tree().top(), frame, 0); |
414 } | 420 } |
415 | 421 |
416 #endif | 422 #endif |
OLD | NEW |