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

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

Issue 736883002: Implement <select> Popup Menu using PagePopup (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 years 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
Index: Source/core/html/HTMLSelectElement.cpp
diff --git a/Source/core/html/HTMLSelectElement.cpp b/Source/core/html/HTMLSelectElement.cpp
index 1c1dc110fdc428bdd5f5ab7fa0d90137499f579e..8376127b45993d73de2268c53d4c8a215c005ca0 100644
--- a/Source/core/html/HTMLSelectElement.cpp
+++ b/Source/core/html/HTMLSelectElement.cpp
@@ -1204,10 +1204,6 @@ void HTMLSelectElement::handlePopupOpenKeyboardEvent(Event* event)
saveLastSelection();
if (RenderMenuList* menuList = toRenderMenuList(renderer()))
menuList->showPopup();
- int index = selectedIndex();
- ASSERT(index >= 0);
- ASSERT_WITH_SECURITY_IMPLICATION(index < static_cast<int>(listItems().size()));
- setSelectedIndex(index);
event->setDefaultHandled();
return;
}
@@ -1762,7 +1758,7 @@ void HTMLSelectElement::trace(Visitor* visitor)
void HTMLSelectElement::didAddUserAgentShadowRoot(ShadowRoot& root)
{
RefPtrWillBeRawPtr<HTMLContentElement> content = HTMLContentElement::create(document());
- content->setAttribute(selectAttr, "option,optgroup");
+ content->setAttribute(selectAttr, "option,optgroup,hr");
root.appendChild(content);
}

Powered by Google App Engine
This is Rietveld 408576698