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

Side by Side Diff: third_party/WebKit/Source/core/html/HTMLSelectElement.cpp

Issue 2084833002: Merge "Menulist SELECT element should update layout when an OPTION content is changed." to M52. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2743
Patch Set: Created 4 years, 6 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 | « third_party/WebKit/Source/core/html/HTMLSelectElement.h ('k') | no next file » | 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) 2010 Nokia Corporation and/or its subsidiary(-ies). 2 * Copyright (C) 2010 Nokia Corporation and/or its subsidiary(-ies).
3 * Copyright (C) 1999 Lars Knoll (knoll@kde.org) 3 * Copyright (C) 1999 Lars Knoll (knoll@kde.org)
4 * (C) 1999 Antti Koivisto (koivisto@kde.org) 4 * (C) 1999 Antti Koivisto (koivisto@kde.org)
5 * (C) 2001 Dirk Mueller (mueller@kde.org) 5 * (C) 2001 Dirk Mueller (mueller@kde.org)
6 * Copyright (C) 2004, 2005, 2006, 2007, 2009, 2010, 2011 Apple Inc. All rights reserved. 6 * Copyright (C) 2004, 2005, 2006, 2007, 2009, 2010, 2011 Apple Inc. All rights reserved.
7 * (C) 2006 Alexey Proskuryakov (ap@nypop.com) 7 * (C) 2006 Alexey Proskuryakov (ap@nypop.com)
8 * Copyright (C) 2010 Google Inc. All rights reserved. 8 * Copyright (C) 2010 Google Inc. All rights reserved.
9 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo bile.com/) 9 * Copyright (C) 2009 Torch Mobile Inc. All rights reserved. (http://www.torchmo bile.com/)
10 * 10 *
(...skipping 413 matching lines...) Expand 10 before | Expand all | Expand 10 after
424 424
425 void HTMLSelectElement::childrenChanged(const ChildrenChange& change) 425 void HTMLSelectElement::childrenChanged(const ChildrenChange& change)
426 { 426 {
427 setRecalcListItems(); 427 setRecalcListItems();
428 setNeedsValidityCheck(); 428 setNeedsValidityCheck();
429 m_lastOnChangeSelection.clear(); 429 m_lastOnChangeSelection.clear();
430 430
431 HTMLFormControlElementWithState::childrenChanged(change); 431 HTMLFormControlElementWithState::childrenChanged(change);
432 } 432 }
433 433
434 void HTMLSelectElement::optionElementChildrenChanged() 434 void HTMLSelectElement::optionElementChildrenChanged(const HTMLOptionElement& op tion)
435 { 435 {
436 setNeedsValidityCheck(); 436 setNeedsValidityCheck();
437 setOptionsChangedOnLayoutObject(); 437 setOptionsChangedOnLayoutObject();
438 438
439 if (layoutObject()) { 439 if (layoutObject()) {
440 if (option.selected() && usesMenuList())
441 layoutObject()->updateFromElement();
440 if (AXObjectCache* cache = layoutObject()->document().existingAXObjectCa che()) 442 if (AXObjectCache* cache = layoutObject()->document().existingAXObjectCa che())
441 cache->childrenChanged(this); 443 cache->childrenChanged(this);
442 } 444 }
443 } 445 }
444 446
445 void HTMLSelectElement::accessKeyAction(bool sendMouseEvents) 447 void HTMLSelectElement::accessKeyAction(bool sendMouseEvents)
446 { 448 {
447 focus(); 449 focus();
448 dispatchSimulatedClick(nullptr, sendMouseEvents ? SendMouseUpDownEvents : Se ndNoEvents); 450 dispatchSimulatedClick(nullptr, sendMouseEvents ? SendMouseUpDownEvents : Se ndNoEvents);
449 } 451 }
(...skipping 1625 matching lines...) Expand 10 before | Expand all | Expand 10 after
2075 } 2077 }
2076 2078
2077 void HTMLSelectElement::didMutateSubtree() 2079 void HTMLSelectElement::didMutateSubtree()
2078 { 2080 {
2079 DCHECK(popupIsVisible()); 2081 DCHECK(popupIsVisible());
2080 DCHECK(m_popup); 2082 DCHECK(m_popup);
2081 m_popup->updateFromElement(PopupMenu::ByDOMChange); 2083 m_popup->updateFromElement(PopupMenu::ByDOMChange);
2082 } 2084 }
2083 2085
2084 } // namespace blink 2086 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/html/HTMLSelectElement.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698