OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2004, 2008, 2009, 2010 Apple Inc. All rights reserved. | 2 * Copyright (C) 2004, 2008, 2009, 2010 Apple 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 | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
(...skipping 1123 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1134 void FrameSelection::prepareForDestruction() | 1134 void FrameSelection::prepareForDestruction() |
1135 { | 1135 { |
1136 m_granularity = CharacterGranularity; | 1136 m_granularity = CharacterGranularity; |
1137 | 1137 |
1138 m_caretBlinkTimer.stop(); | 1138 m_caretBlinkTimer.stop(); |
1139 | 1139 |
1140 RenderView* view = m_frame->contentRenderer(); | 1140 RenderView* view = m_frame->contentRenderer(); |
1141 if (view) | 1141 if (view) |
1142 view->clearSelection(); | 1142 view->clearSelection(); |
1143 | 1143 |
| 1144 m_frame = 0; |
| 1145 |
1144 setSelection(VisibleSelection(), CloseTyping | ClearTypingStyle | DoNotUpdat
eAppearance); | 1146 setSelection(VisibleSelection(), CloseTyping | ClearTypingStyle | DoNotUpdat
eAppearance); |
1145 } | 1147 } |
1146 | 1148 |
1147 void FrameSelection::setStart(const VisiblePosition &pos, EUserTriggered trigger
) | 1149 void FrameSelection::setStart(const VisiblePosition &pos, EUserTriggered trigger
) |
1148 { | 1150 { |
1149 if (m_selection.isBaseFirst()) | 1151 if (m_selection.isBaseFirst()) |
1150 setBase(pos, trigger); | 1152 setBase(pos, trigger); |
1151 else | 1153 else |
1152 setExtent(pos, trigger); | 1154 setExtent(pos, trigger); |
1153 } | 1155 } |
(...skipping 469 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1623 sel.showTreeForThis(); | 1625 sel.showTreeForThis(); |
1624 } | 1626 } |
1625 | 1627 |
1626 void showTree(const blink::FrameSelection* sel) | 1628 void showTree(const blink::FrameSelection* sel) |
1627 { | 1629 { |
1628 if (sel) | 1630 if (sel) |
1629 sel->showTreeForThis(); | 1631 sel->showTreeForThis(); |
1630 } | 1632 } |
1631 | 1633 |
1632 #endif | 1634 #endif |
OLD | NEW |