OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2005 Frerich Raabe <raabe@kde.org> | 2 * Copyright (C) 2005 Frerich Raabe <raabe@kde.org> |
3 * Copyright (C) 2006, 2009 Apple Inc. All rights reserved. | 3 * Copyright (C) 2006, 2009 Apple Inc. All rights reserved. |
4 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org> | 4 * Copyright (C) 2007 Alexey Proskuryakov <ap@webkit.org> |
5 * | 5 * |
6 * Redistribution and use in source and binary forms, with or without | 6 * Redistribution and use in source and binary forms, with or without |
7 * modification, are permitted provided that the following conditions | 7 * modification, are permitted provided that the following conditions |
8 * are met: | 8 * are met: |
9 * | 9 * |
10 * 1. Redistributions of source code must retain the above copyright | 10 * 1. Redistributions of source code must retain the above copyright |
(...skipping 334 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
345 nodes.append(n.release()); | 345 nodes.append(n.release()); |
346 } | 346 } |
347 return; | 347 return; |
348 } | 348 } |
349 | 349 |
350 if (!contextElement->hasAttributes()) | 350 if (!contextElement->hasAttributes()) |
351 return; | 351 return; |
352 | 352 |
353 unsigned attributeCount = contextElement->attributeCount(); | 353 unsigned attributeCount = contextElement->attributeCount(); |
354 for (unsigned i = 0; i < attributeCount; ++i) { | 354 for (unsigned i = 0; i < attributeCount; ++i) { |
355 RefPtr<Attr> attr = contextElement->ensureAttr(contextElement->a
ttributeItem(i)->name()); | 355 RefPtr<Attr> attr = contextElement->ensureAttr(contextElement->a
ttributeItem(i).name()); |
356 if (nodeMatches(attr.get(), AttributeAxis, m_nodeTest)) | 356 if (nodeMatches(attr.get(), AttributeAxis, m_nodeTest)) |
357 nodes.append(attr.release()); | 357 nodes.append(attr.release()); |
358 } | 358 } |
359 return; | 359 return; |
360 } | 360 } |
361 case NamespaceAxis: | 361 case NamespaceAxis: |
362 // XPath namespace nodes are not implemented. | 362 // XPath namespace nodes are not implemented. |
363 return; | 363 return; |
364 case SelfAxis: | 364 case SelfAxis: |
365 if (nodeMatches(context, SelfAxis, m_nodeTest)) | 365 if (nodeMatches(context, SelfAxis, m_nodeTest)) |
(...skipping 25 matching lines...) Expand all Loading... |
391 nodes.markSorted(false); | 391 nodes.markSorted(false); |
392 return; | 392 return; |
393 } | 393 } |
394 } | 394 } |
395 ASSERT_NOT_REACHED(); | 395 ASSERT_NOT_REACHED(); |
396 } | 396 } |
397 | 397 |
398 | 398 |
399 } | 399 } |
400 } | 400 } |
OLD | NEW |