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

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

Issue 1289673008: Get rid of a redundant argument DOWNSTREAM from VisbileSelection constructor call sites (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: 2015-08-19T10:28:45 Created 5 years, 4 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
« no previous file with comments | « Source/core/page/DragController.cpp ('k') | Source/modules/accessibility/AXLayoutObject.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) 2006, 2007 Apple Inc. All rights reserved. 2 * Copyright (C) 2006, 2007 Apple Inc. All rights reserved.
3 * Copyright (C) 2008 Nuanti Ltd. 3 * Copyright (C) 2008 Nuanti Ltd.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions 6 * modification, are permitted provided that the following conditions
7 * are met: 7 * are met:
8 * 1. Redistributions of source code must retain the above copyright 8 * 1. Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright 10 * 2. Redistributions in binary form must reproduce the above copyright
(...skipping 728 matching lines...) Expand 10 before | Expand all | Expand 10 after
739 739
740 if (&newDocument != document) { 740 if (&newDocument != document) {
741 // Focus is going away from this document, so clear the focused node. 741 // Focus is going away from this document, so clear the focused node.
742 document->setFocusedElement(nullptr); 742 document->setFocusedElement(nullptr);
743 } 743 }
744 744
745 setFocusedFrame(newDocument.frame()); 745 setFocusedFrame(newDocument.frame());
746 746
747 if (caretBrowsing) { 747 if (caretBrowsing) {
748 Position position = firstPositionInOrBeforeNode(element.get()); 748 Position position = firstPositionInOrBeforeNode(element.get());
749 VisibleSelection newSelection(position, position, DOWNSTREAM); 749 VisibleSelection newSelection(position, position);
750 frame->selection().setSelection(newSelection); 750 frame->selection().setSelection(newSelection);
751 } 751 }
752 752
753 element->focus(false, type, sourceCapabilities); 753 element->focus(false, type, sourceCapabilities);
754 return true; 754 return true;
755 } 755 }
756 756
757 Element* FocusController::findFocusableElement(WebFocusType type, Node& node) 757 Element* FocusController::findFocusableElement(WebFocusType type, Node& node)
758 { 758 {
759 // FIXME: No spacial navigation code yet. 759 // FIXME: No spacial navigation code yet.
(...skipping 289 matching lines...) Expand 10 before | Expand all | Expand 10 after
1049 return consumed; 1049 return consumed;
1050 } 1050 }
1051 1051
1052 DEFINE_TRACE(FocusController) 1052 DEFINE_TRACE(FocusController)
1053 { 1053 {
1054 visitor->trace(m_page); 1054 visitor->trace(m_page);
1055 visitor->trace(m_focusedFrame); 1055 visitor->trace(m_focusedFrame);
1056 } 1056 }
1057 1057
1058 } // namespace blink 1058 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/page/DragController.cpp ('k') | Source/modules/accessibility/AXLayoutObject.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698