Chromium Code Reviews| Index: chrome/renderer/searchbox/searchbox.cc |
| diff --git a/chrome/renderer/searchbox/searchbox.cc b/chrome/renderer/searchbox/searchbox.cc |
| index 348e894c10f0eb085743fb247910e5f3bdc04957..e008a1df9fc094178208f79ba128f027be21f3b7 100644 |
| --- a/chrome/renderer/searchbox/searchbox.cc |
| +++ b/chrome/renderer/searchbox/searchbox.cc |
| @@ -194,7 +194,10 @@ void SearchBox::OnChange(const string16& query, |
| } |
| void SearchBox::OnSubmit(const string16& query) { |
| - query_ = query; |
| + if (!query.empty()) { |
| + query_ = query; |
| + } |
| + |
| verbatim_ = true; |
| selection_start_ = selection_end_ = query_.size(); |
|
sreeram
2013/04/01 20:08:46
Put all these other things also into the 'if' bloc
robertshield
2013/04/08 16:02:47
Done.
|
| if (render_view()->GetWebView() && render_view()->GetWebView()->mainFrame()) { |