OLD | NEW |
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "chrome/browser/views/keyword_editor_view.h" | 5 #include "chrome/browser/views/keyword_editor_view.h" |
6 | 6 |
7 #include <vector> | 7 #include <vector> |
8 | 8 |
9 #include "base/gfx/png_decoder.h" | 9 #include "base/gfx/png_decoder.h" |
10 #include "base/string_util.h" | 10 #include "base/string_util.h" |
11 #include "chrome/app/locales/locale_settings.h" | 11 #include "chrome/app/locales/locale_settings.h" |
12 #include "chrome/app/theme/theme_resources.h" | 12 #include "grit/theme_resources.h" |
13 #include "chrome/browser/history/history.h" | 13 #include "chrome/browser/history/history.h" |
14 #include "chrome/browser/profile.h" | 14 #include "chrome/browser/profile.h" |
15 #include "chrome/browser/metrics/user_metrics.h" | 15 #include "chrome/browser/metrics/user_metrics.h" |
16 #include "chrome/browser/search_engines/template_url.h" | 16 #include "chrome/browser/search_engines/template_url.h" |
17 #include "chrome/browser/search_engines/template_url_model.h" | 17 #include "chrome/browser/search_engines/template_url_model.h" |
18 #include "chrome/browser/views/edit_keyword_controller.h" | 18 #include "chrome/browser/views/edit_keyword_controller.h" |
19 #include "chrome/browser/views/standard_layout.h" | 19 #include "chrome/browser/views/standard_layout.h" |
20 #include "chrome/common/l10n_util.h" | 20 #include "chrome/common/l10n_util.h" |
21 #include "chrome/common/pref_names.h" | 21 #include "chrome/common/pref_names.h" |
22 #include "chrome/common/pref_service.h" | 22 #include "chrome/common/pref_service.h" |
(...skipping 613 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
636 } | 636 } |
637 const int new_index = table_model_->IndexOfTemplateURL(keyword); | 637 const int new_index = table_model_->IndexOfTemplateURL(keyword); |
638 table_model_->NotifyChanged(new_index); | 638 table_model_->NotifyChanged(new_index); |
639 | 639 |
640 // Make sure the new default is in the main group. | 640 // Make sure the new default is in the main group. |
641 table_model_->MoveToMainGroup(index); | 641 table_model_->MoveToMainGroup(index); |
642 | 642 |
643 // And select it. | 643 // And select it. |
644 table_view_->Select(table_model_->IndexOfTemplateURL(keyword)); | 644 table_view_->Select(table_model_->IndexOfTemplateURL(keyword)); |
645 } | 645 } |
OLD | NEW |