| OLD | NEW |
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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/gtk/bookmark_manager_gtk.h" | 5 #include "chrome/browser/gtk/bookmark_manager_gtk.h" |
| 6 | 6 |
| 7 #include <gdk/gdkkeysyms.h> | 7 #include <gdk/gdkkeysyms.h> |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "app/gtk_dnd_util.h" | 10 #include "app/gtk_dnd_util.h" |
| (...skipping 44 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 55 // wide enough to display only '...'. This will be overridden if the user | 55 // wide enough to display only '...'. This will be overridden if the user |
| 56 // resizes the column. | 56 // resizes the column. |
| 57 const int kDefaultColumnWidth = 200; | 57 const int kDefaultColumnWidth = 200; |
| 58 | 58 |
| 59 // The destination targets that the right tree view accepts for dragging. | 59 // The destination targets that the right tree view accepts for dragging. |
| 60 const int kDestTargetList[] = { GtkDndUtil::CHROME_BOOKMARK_ITEM, -1 }; | 60 const int kDestTargetList[] = { GtkDndUtil::CHROME_BOOKMARK_ITEM, -1 }; |
| 61 | 61 |
| 62 // The source targets that the right tree view supports for dragging. | 62 // The source targets that the right tree view supports for dragging. |
| 63 const int kSourceTargetMask = GtkDndUtil::CHROME_BOOKMARK_ITEM | | 63 const int kSourceTargetMask = GtkDndUtil::CHROME_BOOKMARK_ITEM | |
| 64 GtkDndUtil::TEXT_URI_LIST | | 64 GtkDndUtil::TEXT_URI_LIST | |
| 65 GtkDndUtil::TEXT_PLAIN; | 65 GtkDndUtil::TEXT_PLAIN | |
| 66 GtkDndUtil::NETSCAPE_URL; |
| 66 | 67 |
| 67 // We only have one manager open at a time. | 68 // We only have one manager open at a time. |
| 68 BookmarkManagerGtk* manager = NULL; | 69 BookmarkManagerGtk* manager = NULL; |
| 69 | 70 |
| 70 // Observer installed on the importer. When done importing the newly created | 71 // Observer installed on the importer. When done importing the newly created |
| 71 // folder is selected in the bookmark manager. | 72 // folder is selected in the bookmark manager. |
| 72 // This class is taken almost directly from BookmarkManagerView and should be | 73 // This class is taken almost directly from BookmarkManagerView and should be |
| 73 // kept in sync with it. | 74 // kept in sync with it. |
| 74 class ImportObserverImpl : public ImportObserver { | 75 class ImportObserverImpl : public ImportObserver { |
| 75 public: | 76 public: |
| (...skipping 1431 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1507 username); | 1508 username); |
| 1508 } else if (sync_service_->SetupInProgress()) { | 1509 } else if (sync_service_->SetupInProgress()) { |
| 1509 status_label = l10n_util::GetStringUTF16(IDS_SYNC_NTP_SETUP_IN_PROGRESS); | 1510 status_label = l10n_util::GetStringUTF16(IDS_SYNC_NTP_SETUP_IN_PROGRESS); |
| 1510 } else { | 1511 } else { |
| 1511 status_label = l10n_util::GetStringUTF16(IDS_SYNC_START_SYNC_BUTTON_LABEL); | 1512 status_label = l10n_util::GetStringUTF16(IDS_SYNC_START_SYNC_BUTTON_LABEL); |
| 1512 } | 1513 } |
| 1513 GtkWidget* sync_status_label = gtk_bin_get_child(GTK_BIN(sync_status_menu_)); | 1514 GtkWidget* sync_status_label = gtk_bin_get_child(GTK_BIN(sync_status_menu_)); |
| 1514 gtk_label_set_label(GTK_LABEL(sync_status_label), | 1515 gtk_label_set_label(GTK_LABEL(sync_status_label), |
| 1515 UTF16ToUTF8(status_label).c_str()); | 1516 UTF16ToUTF8(status_label).c_str()); |
| 1516 } | 1517 } |
| OLD | NEW |