| 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/gtk/collected_cookies_gtk.h" | 5 #include "chrome/browser/ui/gtk/collected_cookies_gtk.h" |
| 6 | 6 |
| 7 #include <string> | 7 #include <string> |
| 8 #include "chrome/browser/browsing_data_appcache_helper.h" | 8 #include "chrome/browser/browsing_data_appcache_helper.h" |
| 9 #include "chrome/browser/browsing_data_cookie_helper.h" | 9 #include "chrome/browser/browsing_data_cookie_helper.h" |
| 10 #include "chrome/browser/browsing_data_database_helper.h" | 10 #include "chrome/browser/browsing_data_database_helper.h" |
| (...skipping 14 matching lines...) Expand all Loading... |
| 25 #include "chrome/browser/ui/gtk/constrained_window_gtk.h" | 25 #include "chrome/browser/ui/gtk/constrained_window_gtk.h" |
| 26 #include "chrome/browser/ui/gtk/gtk_chrome_cookie_view.h" | 26 #include "chrome/browser/ui/gtk/gtk_chrome_cookie_view.h" |
| 27 #include "chrome/browser/ui/gtk/gtk_util.h" | 27 #include "chrome/browser/ui/gtk/gtk_util.h" |
| 28 #include "chrome/browser/ui/tab_contents/tab_contents.h" | 28 #include "chrome/browser/ui/tab_contents/tab_contents.h" |
| 29 #include "chrome/common/chrome_notification_types.h" | 29 #include "chrome/common/chrome_notification_types.h" |
| 30 #include "chrome/common/pref_names.h" | 30 #include "chrome/common/pref_names.h" |
| 31 #include "content/public/browser/notification_source.h" | 31 #include "content/public/browser/notification_source.h" |
| 32 #include "content/public/browser/web_contents.h" | 32 #include "content/public/browser/web_contents.h" |
| 33 #include "content/public/browser/web_contents_view.h" | 33 #include "content/public/browser/web_contents_view.h" |
| 34 #include "grit/generated_resources.h" | 34 #include "grit/generated_resources.h" |
| 35 #include "net/cookies/canonical_cookie.h" |
| 35 #include "ui/base/gtk/gtk_hig_constants.h" | 36 #include "ui/base/gtk/gtk_hig_constants.h" |
| 36 #include "ui/base/l10n/l10n_util.h" | 37 #include "ui/base/l10n/l10n_util.h" |
| 37 | 38 |
| 38 namespace { | 39 namespace { |
| 39 // Width and height of the cookie tree view. | 40 // Width and height of the cookie tree view. |
| 40 const int kTreeViewWidth = 450; | 41 const int kTreeViewWidth = 450; |
| 41 const int kTreeViewHeight = 150; | 42 const int kTreeViewHeight = 150; |
| 42 | 43 |
| 43 // The page numbers of the pages in the notebook. | 44 // The page numbers of the pages in the notebook. |
| 44 const gint kAllowedPageNumber = 0; | 45 const gint kAllowedPageNumber = 0; |
| (...skipping 513 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 558 tree_view, reinterpret_cast<gpointer>(OnTreeViewRowExpandedThunk), this); | 559 tree_view, reinterpret_cast<gpointer>(OnTreeViewRowExpandedThunk), this); |
| 559 gtk_tree_view_expand_row(GTK_TREE_VIEW(tree_view), path, TRUE); | 560 gtk_tree_view_expand_row(GTK_TREE_VIEW(tree_view), path, TRUE); |
| 560 g_signal_handlers_unblock_by_func( | 561 g_signal_handlers_unblock_by_func( |
| 561 tree_view, reinterpret_cast<gpointer>(OnTreeViewRowExpandedThunk), this); | 562 tree_view, reinterpret_cast<gpointer>(OnTreeViewRowExpandedThunk), this); |
| 562 } | 563 } |
| 563 | 564 |
| 564 void CollectedCookiesGtk::OnTreeViewSelectionChange(GtkWidget* selection) { | 565 void CollectedCookiesGtk::OnTreeViewSelectionChange(GtkWidget* selection) { |
| 565 EnableControls(); | 566 EnableControls(); |
| 566 ShowCookieInfo(gtk_notebook_get_current_page(GTK_NOTEBOOK(notebook_))); | 567 ShowCookieInfo(gtk_notebook_get_current_page(GTK_NOTEBOOK(notebook_))); |
| 567 } | 568 } |
| OLD | NEW |