| 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/gtk/bookmarks/bookmark_editor_gtk.h" | 5 #include "chrome/browser/ui/gtk/bookmarks/bookmark_editor_gtk.h" |
| 6 | 6 |
| 7 #include <gtk/gtk.h> | 7 #include <gtk/gtk.h> |
| 8 #include <set> | 8 #include <set> |
| 9 | 9 |
| 10 #include "base/basictypes.h" | 10 #include "base/basictypes.h" |
| (...skipping 240 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 251 BookmarkEditorGtk* editor_; | 251 BookmarkEditorGtk* editor_; |
| 252 | 252 |
| 253 // If true, we're running the menu for the bookmark bar or other bookmarks | 253 // If true, we're running the menu for the bookmark bar or other bookmarks |
| 254 // nodes. | 254 // nodes. |
| 255 bool running_menu_for_root_; | 255 bool running_menu_for_root_; |
| 256 | 256 |
| 257 DISALLOW_COPY_AND_ASSIGN(ContextMenuController); | 257 DISALLOW_COPY_AND_ASSIGN(ContextMenuController); |
| 258 }; | 258 }; |
| 259 | 259 |
| 260 // static | 260 // static |
| 261 void BookmarkEditor::Show(gfx::NativeWindow parent_hwnd, | 261 void BookmarkEditor::ShowNative(gfx::NativeWindow parent_hwnd, |
| 262 Profile* profile, | 262 Profile* profile, |
| 263 const BookmarkNode* parent, | 263 const BookmarkNode* parent, |
| 264 const EditDetails& details, | 264 const EditDetails& details, |
| 265 Configuration configuration) { | 265 Configuration configuration) { |
| 266 DCHECK(profile); | 266 DCHECK(profile); |
| 267 BookmarkEditorGtk* editor = | 267 BookmarkEditorGtk* editor = |
| 268 new BookmarkEditorGtk(parent_hwnd, profile, parent, details, | 268 new BookmarkEditorGtk(parent_hwnd, profile, parent, details, |
| 269 configuration); | 269 configuration); |
| 270 editor->Show(); | 270 editor->Show(); |
| 271 } | 271 } |
| 272 | 272 |
| 273 BookmarkEditorGtk::BookmarkEditorGtk( | 273 BookmarkEditorGtk::BookmarkEditorGtk( |
| 274 GtkWindow* window, | 274 GtkWindow* window, |
| 275 Profile* profile, | 275 Profile* profile, |
| (...skipping 405 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 681 GTK_TREE_MODEL(tree_store_), &new_item_iter); | 681 GTK_TREE_MODEL(tree_store_), &new_item_iter); |
| 682 gtk_tree_view_expand_to_path(GTK_TREE_VIEW(tree_view_), path); | 682 gtk_tree_view_expand_to_path(GTK_TREE_VIEW(tree_view_), path); |
| 683 | 683 |
| 684 // Make the folder name editable. | 684 // Make the folder name editable. |
| 685 gtk_tree_view_set_cursor(GTK_TREE_VIEW(tree_view_), path, | 685 gtk_tree_view_set_cursor(GTK_TREE_VIEW(tree_view_), path, |
| 686 gtk_tree_view_get_column(GTK_TREE_VIEW(tree_view_), 0), | 686 gtk_tree_view_get_column(GTK_TREE_VIEW(tree_view_), 0), |
| 687 TRUE); | 687 TRUE); |
| 688 | 688 |
| 689 gtk_tree_path_free(path); | 689 gtk_tree_path_free(path); |
| 690 } | 690 } |
| OLD | NEW |