| 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
reserved. | 6 * Copyright (C) 2004, 2005, 2006, 2007, 2008, 2009, 2010 Apple Inc. All rights
reserved. |
| 7 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) | 7 * Copyright (C) 2008, 2009 Torch Mobile Inc. All rights reserved. (http://www.t
orchmobile.com/) |
| 8 * Copyright (C) Research In Motion Limited 2010. All rights reserved. | 8 * Copyright (C) Research In Motion Limited 2010. All rights reserved. |
| 9 * | 9 * |
| 10 * This library is free software; you can redistribute it and/or | 10 * This library is free software; you can redistribute it and/or |
| (...skipping 328 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 339 return result; | 339 return result; |
| 340 | 340 |
| 341 for (size_t i = 0; i < list->size(); ++i) { | 341 for (size_t i = 0; i < list->size(); ++i) { |
| 342 if (markerTypes.contains(list->at(i).type())) | 342 if (markerTypes.contains(list->at(i).type())) |
| 343 result.append(&(list->at(i))); | 343 result.append(&(list->at(i))); |
| 344 } | 344 } |
| 345 | 345 |
| 346 return result; | 346 return result; |
| 347 } | 347 } |
| 348 | 348 |
| 349 // FIXME: Should be removed after all relevant patches are landed | |
| 350 Vector<DocumentMarker> DocumentMarkerController::markersForNode(Node* node) | |
| 351 { | |
| 352 Vector<DocumentMarker> result; | |
| 353 MarkerList* list = m_markers.get(node); | |
| 354 if (!list) | |
| 355 return result; | |
| 356 | |
| 357 for (size_t i = 0; i < list->size(); ++i) | |
| 358 result.append(list->at(i)); | |
| 359 | |
| 360 return result; | |
| 361 } | |
| 362 | |
| 363 Vector<DocumentMarker*> DocumentMarkerController::markers() | 349 Vector<DocumentMarker*> DocumentMarkerController::markers() |
| 364 { | 350 { |
| 365 Vector<DocumentMarker*> result; | 351 Vector<DocumentMarker*> result; |
| 366 for (MarkerMap::iterator i = m_markers.begin(); i != m_markers.end(); ++i) { | 352 for (MarkerMap::iterator i = m_markers.begin(); i != m_markers.end(); ++i) { |
| 367 for (size_t j = 0; j < i->value->size(); ++j) | 353 for (size_t j = 0; j < i->value->size(); ++j) |
| 368 result.append(&(i->value->at(j))); | 354 result.append(&(i->value->at(j))); |
| 369 } | 355 } |
| 370 return result; | 356 return result; |
| 371 } | 357 } |
| 372 | 358 |
| (...skipping 297 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 670 | 656 |
| 671 } // namespace WebCore | 657 } // namespace WebCore |
| 672 | 658 |
| 673 #ifndef NDEBUG | 659 #ifndef NDEBUG |
| 674 void showDocumentMarkers(const WebCore::DocumentMarkerController* controller) | 660 void showDocumentMarkers(const WebCore::DocumentMarkerController* controller) |
| 675 { | 661 { |
| 676 if (controller) | 662 if (controller) |
| 677 controller->showMarkers(); | 663 controller->showMarkers(); |
| 678 } | 664 } |
| 679 #endif | 665 #endif |
| OLD | NEW |