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

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

Issue 16194013: Mouse press should focus on any types of form controls. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: rebase Created 7 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 | Annotate | Revision Log
« no previous file with comments | « Source/core/html/HTMLSelectElement.h ('k') | Source/core/html/HTMLTextAreaElement.h » ('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) 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 301 matching lines...) Expand 10 before | Expand all | Expand 10 after
312 HTMLFormControlElementWithState::parseAttribute(name, value); 312 HTMLFormControlElementWithState::parseAttribute(name, value);
313 } 313 }
314 314
315 bool HTMLSelectElement::isKeyboardFocusable(KeyboardEvent* event) const 315 bool HTMLSelectElement::isKeyboardFocusable(KeyboardEvent* event) const
316 { 316 {
317 if (renderer()) 317 if (renderer())
318 return isFocusable(); 318 return isFocusable();
319 return HTMLFormControlElementWithState::isKeyboardFocusable(event); 319 return HTMLFormControlElementWithState::isKeyboardFocusable(event);
320 } 320 }
321 321
322 bool HTMLSelectElement::isMouseFocusable() const 322 bool HTMLSelectElement::shouldShowFocusRingOnMouseFocus() const
323 { 323 {
324 if (renderer()) 324 return true;
325 return isFocusable();
326 return HTMLFormControlElementWithState::isMouseFocusable();
327 } 325 }
328 326
329 bool HTMLSelectElement::canSelectAll() const 327 bool HTMLSelectElement::canSelectAll() const
330 { 328 {
331 return !usesMenuList(); 329 return !usesMenuList();
332 } 330 }
333 331
334 RenderObject* HTMLSelectElement::createRenderer(RenderStyle*) 332 RenderObject* HTMLSelectElement::createRenderer(RenderStyle*)
335 { 333 {
336 if (usesMenuList()) 334 if (usesMenuList())
(...skipping 1239 matching lines...) Expand 10 before | Expand all | Expand 10 after
1576 { 1574 {
1577 if (!value) { 1575 if (!value) {
1578 ec = TYPE_MISMATCH_ERR; 1576 ec = TYPE_MISMATCH_ERR;
1579 return false; 1577 return false;
1580 } 1578 }
1581 setOption(index, value.get(), ec); 1579 setOption(index, value.get(), ec);
1582 return true; 1580 return true;
1583 } 1581 }
1584 1582
1585 } // namespace 1583 } // namespace
OLDNEW
« no previous file with comments | « Source/core/html/HTMLSelectElement.h ('k') | Source/core/html/HTMLTextAreaElement.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698