| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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_editor_view.h" | 5 #include "chrome/browser/ui/views/bookmarks/bookmark_editor_view.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 | 8 |
| 9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| (...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 161 const base::string16& new_contents) { | 161 const base::string16& new_contents) { |
| 162 UserInputChanged(); | 162 UserInputChanged(); |
| 163 } | 163 } |
| 164 | 164 |
| 165 bool BookmarkEditorView::HandleKeyEvent(views::Textfield* sender, | 165 bool BookmarkEditorView::HandleKeyEvent(views::Textfield* sender, |
| 166 const ui::KeyEvent& key_event) { | 166 const ui::KeyEvent& key_event) { |
| 167 return false; | 167 return false; |
| 168 } | 168 } |
| 169 | 169 |
| 170 void BookmarkEditorView::GetAccessibleState(ui::AXViewState* state) { | 170 void BookmarkEditorView::GetAccessibleState(ui::AXViewState* state) { |
| 171 views::DialogDelegateView::GetAccessibleState(state); |
| 171 state->name = | 172 state->name = |
| 172 l10n_util::GetStringUTF16(IDS_BOOKMARK_EDITOR_TITLE); | 173 l10n_util::GetStringUTF16(IDS_BOOKMARK_EDITOR_TITLE); |
| 173 state->role = ui::AX_ROLE_DIALOG; | |
| 174 } | 174 } |
| 175 | 175 |
| 176 void BookmarkEditorView::ButtonPressed(views::Button* sender, | 176 void BookmarkEditorView::ButtonPressed(views::Button* sender, |
| 177 const ui::Event& event) { | 177 const ui::Event& event) { |
| 178 DCHECK_EQ(new_folder_button_.get(), sender); | 178 DCHECK_EQ(new_folder_button_.get(), sender); |
| 179 NewFolder(); | 179 NewFolder(); |
| 180 } | 180 } |
| 181 | 181 |
| 182 bool BookmarkEditorView::IsCommandIdChecked(int command_id) const { | 182 bool BookmarkEditorView::IsCommandIdChecked(int command_id) const { |
| 183 return false; | 183 return false; |
| (...skipping 456 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 640 } | 640 } |
| 641 return context_menu_model_.get(); | 641 return context_menu_model_.get(); |
| 642 } | 642 } |
| 643 | 643 |
| 644 void BookmarkEditorView::EditorTreeModel::SetTitle( | 644 void BookmarkEditorView::EditorTreeModel::SetTitle( |
| 645 ui::TreeModelNode* node, | 645 ui::TreeModelNode* node, |
| 646 const base::string16& title) { | 646 const base::string16& title) { |
| 647 if (!title.empty()) | 647 if (!title.empty()) |
| 648 ui::TreeNodeModel<EditorNode>::SetTitle(node, title); | 648 ui::TreeNodeModel<EditorNode>::SetTitle(node, title); |
| 649 } | 649 } |
| OLD | NEW |