Index: chrome/browser/chromeos/input_method/candidate_window.cc |
diff --git a/chrome/browser/chromeos/input_method/candidate_window.cc b/chrome/browser/chromeos/input_method/candidate_window.cc |
index 46ee983e73b9825a29b388eba864dcf7df9e0ffa..8533c0089b99d68d5e58c12d0cb3a73aeb3ecd61 100644 |
--- a/chrome/browser/chromeos/input_method/candidate_window.cc |
+++ b/chrome/browser/chromeos/input_method/candidate_window.cc |
@@ -1046,9 +1046,7 @@ void CandidateWindowView::MaybeInitializeCandidateViews( |
previous_annotation_column_width_ = annotation_column_width; |
// Clear the existing candidate_views if any. |
- for (size_t i = 0; i < candidate_views_.size(); ++i) { |
- candidate_area_contents->RemoveChildView(candidate_views_[i]); |
- } |
+ candidate_area_contents->RemoveAllChildViews(true); |
candidate_views_.clear(); |
views::GridLayout* layout = new views::GridLayout(candidate_area_contents); |