OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/ui/views/bookmarks/bookmark_bubble_view.h" | 5 #include "chrome/browser/ui/views/bookmarks/bookmark_bubble_view.h" |
6 | 6 |
7 #include "base/string16.h" | 7 #include "base/string16.h" |
8 #include "base/string_util.h" | 8 #include "base/string_util.h" |
9 #include "base/utf_string_conversions.h" | 9 #include "base/utf_string_conversions.h" |
10 #include "chrome/app/chrome_command_ids.h" | 10 #include "chrome/app/chrome_command_ids.h" |
11 #include "chrome/browser/bookmarks/bookmark_editor.h" | 11 #include "chrome/browser/bookmarks/bookmark_editor.h" |
12 #include "chrome/browser/bookmarks/bookmark_model.h" | 12 #include "chrome/browser/bookmarks/bookmark_model.h" |
13 #include "chrome/browser/bookmarks/bookmark_utils.h" | 13 #include "chrome/browser/bookmarks/bookmark_utils.h" |
14 #include "chrome/browser/profiles/profile.h" | 14 #include "chrome/browser/profiles/profile.h" |
15 #include "chrome/browser/ui/browser.h" | 15 #include "chrome/browser/ui/browser.h" |
16 #include "chrome/browser/ui/browser_list.h" | 16 #include "chrome/browser/ui/browser_list.h" |
17 #include "chrome/browser/ui/views/window.h" | 17 #include "chrome/browser/ui/views/window.h" |
18 #include "chrome/common/chrome_notification_types.h" | 18 #include "chrome/common/chrome_notification_types.h" |
19 #include "content/browser/user_metrics.h" | 19 #include "content/browser/user_metrics.h" |
20 #include "content/public/browser/notification_service.h" | 20 #include "content/public/browser/notification_service.h" |
21 #include "grit/generated_resources.h" | 21 #include "grit/generated_resources.h" |
22 #include "grit/theme_resources.h" | 22 #include "grit/theme_resources.h" |
23 #include "ui/base/keycodes/keyboard_codes.h" | 23 #include "ui/base/keycodes/keyboard_codes.h" |
24 #include "ui/base/l10n/l10n_util.h" | 24 #include "ui/base/l10n/l10n_util.h" |
25 #include "ui/base/resource/resource_bundle.h" | 25 #include "ui/base/resource/resource_bundle.h" |
| 26 #include "ui/views/controls/combobox/combobox.h" |
26 #include "ui/views/events/event.h" | 27 #include "ui/views/events/event.h" |
27 #include "ui/views/layout/grid_layout.h" | 28 #include "ui/views/layout/grid_layout.h" |
28 #include "ui/views/layout/layout_constants.h" | 29 #include "ui/views/layout/layout_constants.h" |
29 #include "ui/views/widget/widget.h" | 30 #include "ui/views/widget/widget.h" |
30 #include "views/controls/button/text_button.h" | 31 #include "views/controls/button/text_button.h" |
31 #include "views/controls/combobox/combobox.h" | |
32 #include "views/controls/label.h" | 32 #include "views/controls/label.h" |
33 #include "views/controls/link.h" | 33 #include "views/controls/link.h" |
34 #include "views/controls/textfield/textfield.h" | 34 #include "views/controls/textfield/textfield.h" |
35 | 35 |
36 using views::ColumnSet; | 36 using views::ColumnSet; |
37 using views::GridLayout; | 37 using views::GridLayout; |
38 | 38 |
39 // Padding between "Title:" and the actual title. | 39 // Padding between "Title:" and the actual title. |
40 static const int kTitlePadding = 4; | 40 static const int kTitlePadding = 4; |
41 | 41 |
(...skipping 291 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
333 const BookmarkNode* new_parent = | 333 const BookmarkNode* new_parent = |
334 parent_model_.GetNodeAt(parent_combobox_->selected_item()); | 334 parent_model_.GetNodeAt(parent_combobox_->selected_item()); |
335 if (new_parent != node->parent()) { | 335 if (new_parent != node->parent()) { |
336 UserMetrics::RecordAction( | 336 UserMetrics::RecordAction( |
337 UserMetricsAction("BookmarkBubble_ChangeParent")); | 337 UserMetricsAction("BookmarkBubble_ChangeParent")); |
338 model->Move(node, new_parent, new_parent->child_count()); | 338 model->Move(node, new_parent, new_parent->child_count()); |
339 } | 339 } |
340 } | 340 } |
341 } | 341 } |
342 } | 342 } |
OLD | NEW |