| 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) 2001 Dirk Mueller (mueller@kde.org) | 4 * (C) 2001 Dirk Mueller (mueller@kde.org) |
| 5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org) | 5 * (C) 2006 Alexey Proskuryakov (ap@webkit.org) |
| 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights | 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights |
| 7 * reserved. | 7 * reserved. |
| 8 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. | 8 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. |
| 9 * (http://www.torchmobile.com/) | 9 * (http://www.torchmobile.com/) |
| 10 * Copyright (C) Research In Motion Limited 2010. All rights reserved. | 10 * Copyright (C) Research In Motion Limited 2010. All rights reserved. |
| (...skipping 20 matching lines...) Expand all Loading... |
| 31 #include <algorithm> | 31 #include <algorithm> |
| 32 #include "core/dom/Node.h" | 32 #include "core/dom/Node.h" |
| 33 #include "core/dom/NodeTraversal.h" | 33 #include "core/dom/NodeTraversal.h" |
| 34 #include "core/dom/Range.h" | 34 #include "core/dom/Range.h" |
| 35 #include "core/dom/Text.h" | 35 #include "core/dom/Text.h" |
| 36 #include "core/editing/iterators/TextIterator.h" | 36 #include "core/editing/iterators/TextIterator.h" |
| 37 #include "core/editing/markers/CompositionMarkerListImpl.h" | 37 #include "core/editing/markers/CompositionMarkerListImpl.h" |
| 38 #include "core/editing/markers/DocumentMarkerListEditor.h" | 38 #include "core/editing/markers/DocumentMarkerListEditor.h" |
| 39 #include "core/editing/markers/GenericDocumentMarkerListImpl.h" | 39 #include "core/editing/markers/GenericDocumentMarkerListImpl.h" |
| 40 #include "core/editing/markers/RenderedDocumentMarker.h" | 40 #include "core/editing/markers/RenderedDocumentMarker.h" |
| 41 #include "core/editing/markers/SpellCheckMarkerListImpl.h" |
| 41 #include "core/frame/FrameView.h" | 42 #include "core/frame/FrameView.h" |
| 42 #include "core/layout/LayoutObject.h" | 43 #include "core/layout/LayoutObject.h" |
| 43 | 44 |
| 44 #ifndef NDEBUG | 45 #ifndef NDEBUG |
| 45 #include <stdio.h> | 46 #include <stdio.h> |
| 46 #endif | 47 #endif |
| 47 | 48 |
| 48 namespace blink { | 49 namespace blink { |
| 49 | 50 |
| 50 namespace { | 51 namespace { |
| (...skipping 12 matching lines...) Expand all Loading... |
| 63 } | 64 } |
| 64 | 65 |
| 65 NOTREACHED(); | 66 NOTREACHED(); |
| 66 return DocumentMarker::kSpellingMarkerIndex; | 67 return DocumentMarker::kSpellingMarkerIndex; |
| 67 } | 68 } |
| 68 | 69 |
| 69 DocumentMarkerList* CreateListForType(DocumentMarker::MarkerType type) { | 70 DocumentMarkerList* CreateListForType(DocumentMarker::MarkerType type) { |
| 70 switch (type) { | 71 switch (type) { |
| 71 case DocumentMarker::kComposition: | 72 case DocumentMarker::kComposition: |
| 72 return new CompositionMarkerListImpl(); | 73 return new CompositionMarkerListImpl(); |
| 74 case DocumentMarker::kSpelling: |
| 75 case DocumentMarker::kGrammar: |
| 76 return new SpellCheckMarkerListImpl(); |
| 73 default: | 77 default: |
| 74 return new GenericDocumentMarkerListImpl(); | 78 return new GenericDocumentMarkerListImpl(); |
| 75 } | 79 } |
| 76 } | 80 } |
| 77 | 81 |
| 78 } // namespace | 82 } // namespace |
| 79 | 83 |
| 80 Member<DocumentMarkerList>& DocumentMarkerController::ListForType( | 84 Member<DocumentMarkerList>& DocumentMarkerController::ListForType( |
| 81 MarkerLists* marker_lists, | 85 MarkerLists* marker_lists, |
| 82 DocumentMarker::MarkerType type) { | 86 DocumentMarker::MarkerType type) { |
| (...skipping 662 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 745 } | 749 } |
| 746 | 750 |
| 747 } // namespace blink | 751 } // namespace blink |
| 748 | 752 |
| 749 #ifndef NDEBUG | 753 #ifndef NDEBUG |
| 750 void showDocumentMarkers(const blink::DocumentMarkerController* controller) { | 754 void showDocumentMarkers(const blink::DocumentMarkerController* controller) { |
| 751 if (controller) | 755 if (controller) |
| 752 controller->ShowMarkers(); | 756 controller->ShowMarkers(); |
| 753 } | 757 } |
| 754 #endif | 758 #endif |
| OLD | NEW |