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

Unified Diff: Source/core/html/HTMLSelectElement.cpp

Issue 761463002: Fix listbox selections with only disabled options. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: Created 6 years, 1 month 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « LayoutTests/fast/html/crash-on-invalid-selection-index-expected.txt ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/core/html/HTMLSelectElement.cpp
diff --git a/Source/core/html/HTMLSelectElement.cpp b/Source/core/html/HTMLSelectElement.cpp
index b7a185f684f5247b4664eb7aa09914e825ba1b27..ab9ba5e5d9ff6c374b238e2af20bab7a3cea8f6f 100644
--- a/Source/core/html/HTMLSelectElement.cpp
+++ b/Source/core/html/HTMLSelectElement.cpp
@@ -614,6 +614,9 @@ void HTMLSelectElement::selectAll()
setActiveSelectionAnchorIndex(nextSelectableListIndex(-1));
setActiveSelectionEndIndex(previousSelectableListIndex(-1));
+ if (m_activeSelectionAnchorIndex < 0)
keishi 2014/12/02 02:40:13 I think updateListBoxSelection should just be able
+ return;
+
updateListBoxSelection(false, false);
listBoxOnChange();
setNeedsValidityCheck();
« no previous file with comments | « LayoutTests/fast/html/crash-on-invalid-selection-index-expected.txt ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698