Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(36)

Side by Side Diff: Source/core/page/SpatialNavigation.cpp

Issue 171773008: Rename childNodeCount() / childNode() methods for clarity (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Further renaming for consistency Created 6 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « Source/core/page/DOMSelection.cpp ('k') | Source/core/rendering/RenderObject.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies) 2 * Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies)
3 * Copyright (C) 2009 Antonio Gomes <tonikitoo@webkit.org> 3 * Copyright (C) 2009 Antonio Gomes <tonikitoo@webkit.org>
4 * 4 *
5 * All rights reserved. 5 * All rights reserved.
6 * 6 *
7 * Redistribution and use in source and binary forms, with or without 7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions 8 * modification, are permitted provided that the following conditions
9 * are met: 9 * are met:
10 * 1. Redistributions of source code must retain the above copyright 10 * 1. Redistributions of source code must retain the above copyright
(...skipping 409 matching lines...) Expand 10 before | Expand all | Expand 10 after
420 } 420 }
421 421
422 bool isScrollableNode(const Node* node) 422 bool isScrollableNode(const Node* node)
423 { 423 {
424 ASSERT(!node->isDocumentNode()); 424 ASSERT(!node->isDocumentNode());
425 425
426 if (!node) 426 if (!node)
427 return false; 427 return false;
428 428
429 if (RenderObject* renderer = node->renderer()) 429 if (RenderObject* renderer = node->renderer())
430 return renderer->isBox() && toRenderBox(renderer)->canBeScrolledAndHasSc rollableArea() && node->hasChildNodes(); 430 return renderer->isBox() && toRenderBox(renderer)->canBeScrolledAndHasSc rollableArea() && node->hasChildren();
431 431
432 return false; 432 return false;
433 } 433 }
434 434
435 Node* scrollableEnclosingBoxOrParentFrameForNodeInDirection(FocusType type, Node * node) 435 Node* scrollableEnclosingBoxOrParentFrameForNodeInDirection(FocusType type, Node * node)
436 { 436 {
437 ASSERT(node); 437 ASSERT(node);
438 Node* parent = node; 438 Node* parent = node;
439 do { 439 do {
440 if (parent->isDocumentNode()) 440 if (parent->isDocumentNode())
(...skipping 290 matching lines...) Expand 10 before | Expand all | Expand 10 after
731 LayoutRect rect = virtualRectForDirection(type, rectToAbsoluteCoordinates(ar ea->document().frame(), area->computeRect(area->imageElement()->renderer())), 1) ; 731 LayoutRect rect = virtualRectForDirection(type, rectToAbsoluteCoordinates(ar ea->document().frame(), area->computeRect(area->imageElement()->renderer())), 1) ;
732 return rect; 732 return rect;
733 } 733 }
734 734
735 HTMLFrameOwnerElement* frameOwnerElement(FocusCandidate& candidate) 735 HTMLFrameOwnerElement* frameOwnerElement(FocusCandidate& candidate)
736 { 736 {
737 return candidate.isFrameOwnerElement() ? toHTMLFrameOwnerElement(candidate.v isibleNode) : 0; 737 return candidate.isFrameOwnerElement() ? toHTMLFrameOwnerElement(candidate.v isibleNode) : 0;
738 }; 738 };
739 739
740 } // namespace WebCore 740 } // namespace WebCore
OLDNEW
« no previous file with comments | « Source/core/page/DOMSelection.cpp ('k') | Source/core/rendering/RenderObject.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698