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

Side by Side Diff: Source/core/html/shadow/ClearButtonElement.cpp

Issue 977113003: Rename renderer() to layoutObject(). (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 5 years, 9 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2013 Google Inc. All rights reserved. 2 * Copyright (C) 2013 Google 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 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 return; 63 return;
64 } 64 }
65 65
66 if (!m_clearButtonOwner->shouldClearButtonRespondToMouseEvents()) { 66 if (!m_clearButtonOwner->shouldClearButtonRespondToMouseEvents()) {
67 if (!event->defaultHandled()) 67 if (!event->defaultHandled())
68 HTMLDivElement::defaultEventHandler(event); 68 HTMLDivElement::defaultEventHandler(event);
69 return; 69 return;
70 } 70 }
71 71
72 if (event->type() == EventTypeNames::click) { 72 if (event->type() == EventTypeNames::click) {
73 if (renderer() && renderer()->visibleToHitTesting()) { 73 if (layoutObject() && layoutObject()->visibleToHitTesting()) {
74 m_clearButtonOwner->focusAndSelectClearButtonOwner(); 74 m_clearButtonOwner->focusAndSelectClearButtonOwner();
75 m_clearButtonOwner->clearValue(); 75 m_clearButtonOwner->clearValue();
76 event->setDefaultHandled(); 76 event->setDefaultHandled();
77 } 77 }
78 } 78 }
79 79
80 if (!event->defaultHandled()) 80 if (!event->defaultHandled())
81 HTMLDivElement::defaultEventHandler(event); 81 HTMLDivElement::defaultEventHandler(event);
82 } 82 }
83 83
84 bool ClearButtonElement::isClearButtonElement() const 84 bool ClearButtonElement::isClearButtonElement() const
85 { 85 {
86 return true; 86 return true;
87 } 87 }
88 88
89 DEFINE_TRACE(ClearButtonElement) 89 DEFINE_TRACE(ClearButtonElement)
90 { 90 {
91 visitor->trace(m_clearButtonOwner); 91 visitor->trace(m_clearButtonOwner);
92 HTMLDivElement::trace(visitor); 92 HTMLDivElement::trace(visitor);
93 } 93 }
94 94
95 } 95 }
OLDNEW
« no previous file with comments | « Source/core/html/forms/TextFieldInputType.cpp ('k') | Source/core/html/shadow/MediaControlElementTypes.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698