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

Side by Side Diff: third_party/WebKit/Source/modules/accessibility/AXLayoutObject.cpp

Issue 2268893008: Remove NeedToDispatchSelectEvent argument of HTMLTextFormControlElement::setSelectedRange(). (Closed)
Patch Set: Remove NeedToDispatchSelectEvent argument of HTMLTextFormControlElement::setSelectedRange(). Created 4 years, 3 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2008 Apple Inc. All rights reserved. 2 * Copyright (C) 2008 Apple Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 7 *
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 2046 matching lines...) Expand 10 before | Expand all | Expand 10 after
2057 return; 2057 return;
2058 } 2058 }
2059 2059
2060 if (anchorObject == focusObject 2060 if (anchorObject == focusObject
2061 && anchorObject->getLayoutObject()->isTextControl()) { 2061 && anchorObject->getLayoutObject()->isTextControl()) {
2062 HTMLTextFormControlElement* textControl = toLayoutTextControl( 2062 HTMLTextFormControlElement* textControl = toLayoutTextControl(
2063 anchorObject->getLayoutObject())->textFormControlElement(); 2063 anchorObject->getLayoutObject())->textFormControlElement();
2064 if (selection.anchorOffset <= selection.focusOffset) { 2064 if (selection.anchorOffset <= selection.focusOffset) {
2065 textControl->setSelectionRange( 2065 textControl->setSelectionRange(
2066 selection.anchorOffset, selection.focusOffset, 2066 selection.anchorOffset, selection.focusOffset,
2067 SelectionHasForwardDirection, NotDispatchSelectEvent); 2067 SelectionHasForwardDirection);
2068 } else { 2068 } else {
2069 textControl->setSelectionRange( 2069 textControl->setSelectionRange(
2070 selection.focusOffset, selection.anchorOffset, 2070 selection.focusOffset, selection.anchorOffset,
2071 SelectionHasBackwardDirection, NotDispatchSelectEvent); 2071 SelectionHasBackwardDirection);
2072 } 2072 }
2073 return; 2073 return;
2074 } 2074 }
2075 2075
2076 LocalFrame* frame = getLayoutObject()->frame(); 2076 LocalFrame* frame = getLayoutObject()->frame();
2077 if (!frame) 2077 if (!frame)
2078 return; 2078 return;
2079 2079
2080 // TODO(dglazkov): The use of updateStyleAndLayoutIgnorePendingStylesheets n eeds to be audited. 2080 // TODO(dglazkov): The use of updateStyleAndLayoutIgnorePendingStylesheets n eeds to be audited.
2081 // see http://crbug.com/590369 for more details. 2081 // see http://crbug.com/590369 for more details.
(...skipping 541 matching lines...) Expand 10 before | Expand all | Expand 10 after
2623 result.unite(labelRect); 2623 result.unite(labelRect);
2624 } 2624 }
2625 } 2625 }
2626 } 2626 }
2627 } 2627 }
2628 2628
2629 return result; 2629 return result;
2630 } 2630 }
2631 2631
2632 } // namespace blink 2632 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698