| 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 97 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 108 visitor->trace(m_position); | 108 visitor->trace(m_position); |
| 109 } | 109 } |
| 110 | 110 |
| 111 void CaretBase::clearCaretRect() | 111 void CaretBase::clearCaretRect() |
| 112 { | 112 { |
| 113 m_caretLocalRect = LayoutRect(); | 113 m_caretLocalRect = LayoutRect(); |
| 114 } | 114 } |
| 115 | 115 |
| 116 static inline bool caretRendersInsideNode(Node* node) | 116 static inline bool caretRendersInsideNode(Node* node) |
| 117 { | 117 { |
| 118 return node && !isRenderedTable(node) && !editingIgnoresContent(node); | 118 return node && !isRenderedTableElement(node) && !editingIgnoresContent(node)
; |
| 119 } | 119 } |
| 120 | 120 |
| 121 RenderBlock* CaretBase::caretRenderer(Node* node) | 121 RenderBlock* CaretBase::caretRenderer(Node* node) |
| 122 { | 122 { |
| 123 if (!node) | 123 if (!node) |
| 124 return 0; | 124 return 0; |
| 125 | 125 |
| 126 RenderObject* renderer = node->renderer(); | 126 RenderObject* renderer = node->renderer(); |
| 127 if (!renderer) | 127 if (!renderer) |
| 128 return 0; | 128 return 0; |
| (...skipping 138 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 267 context->fillRect(caret, caretColor); | 267 context->fillRect(caret, caretColor); |
| 268 } | 268 } |
| 269 | 269 |
| 270 void DragCaretController::paintDragCaret(LocalFrame* frame, GraphicsContext* p,
const LayoutPoint& paintOffset, const LayoutRect& clipRect) const | 270 void DragCaretController::paintDragCaret(LocalFrame* frame, GraphicsContext* p,
const LayoutPoint& paintOffset, const LayoutRect& clipRect) const |
| 271 { | 271 { |
| 272 if (m_position.deepEquivalent().deprecatedNode()->document().frame() == fram
e) | 272 if (m_position.deepEquivalent().deprecatedNode()->document().frame() == fram
e) |
| 273 paintCaret(m_position.deepEquivalent().deprecatedNode(), p, paintOffset,
clipRect); | 273 paintCaret(m_position.deepEquivalent().deprecatedNode(), p, paintOffset,
clipRect); |
| 274 } | 274 } |
| 275 | 275 |
| 276 } | 276 } |
| OLD | NEW |