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

Side by Side Diff: Source/core/html/forms/SearchInputType.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) 2010 Google Inc. All rights reserved. 2 * Copyright (C) 2010 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 are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after
102 input->setValueForUser(""); 102 input->setValueForUser("");
103 input->onSearch(); 103 input->onSearch();
104 event->setDefaultHandled(); 104 event->setDefaultHandled();
105 return; 105 return;
106 } 106 }
107 TextFieldInputType::handleKeydownEvent(event); 107 TextFieldInputType::handleKeydownEvent(event);
108 } 108 }
109 109
110 void SearchInputType::startSearchEventTimer() 110 void SearchInputType::startSearchEventTimer()
111 { 111 {
112 ASSERT(element().renderer()); 112 ASSERT(element().layoutObject());
113 unsigned length = element().innerEditorValue().length(); 113 unsigned length = element().innerEditorValue().length();
114 114
115 if (!length) { 115 if (!length) {
116 stopSearchEventTimer(); 116 stopSearchEventTimer();
117 element().onSearch(); 117 element().onSearch();
118 return; 118 return;
119 } 119 }
120 120
121 // After typing the first key, we wait 0.5 seconds. 121 // After typing the first key, we wait 0.5 seconds.
122 // After the second key, 0.4 seconds, then 0.3, then 0.2 from then on. 122 // After the second key, 0.4 seconds, then 0.3, then 0.2 from then on.
(...skipping 45 matching lines...) Expand 10 before | Expand all | Expand 10 after
168 button->removeInlineStyleProperty(CSSPropertyPointerEvents); 168 button->removeInlineStyleProperty(CSSPropertyPointerEvents);
169 } 169 }
170 } 170 }
171 171
172 bool SearchInputType::supportsInputModeAttribute() const 172 bool SearchInputType::supportsInputModeAttribute() const
173 { 173 {
174 return true; 174 return true;
175 } 175 }
176 176
177 } // namespace blink 177 } // namespace blink
OLDNEW
« no previous file with comments | « Source/core/html/forms/RangeInputType.cpp ('k') | Source/core/html/forms/TextFieldInputType.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698