Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(203)

Side by Side Diff: chrome/browser/ui/gtk/collected_cookies_gtk.h

Issue 7831051: content: Move collected cookies constrained window to TabContentsWrapper. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Compile failures for everyone\! Created 9 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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 // This is the Gtk implementation of the collected Cookies dialog. 5 // This is the Gtk implementation of the collected Cookies dialog.
6 6
7 #ifndef CHROME_BROWSER_UI_GTK_COLLECTED_COOKIES_GTK_H_ 7 #ifndef CHROME_BROWSER_UI_GTK_COLLECTED_COOKIES_GTK_H_
8 #define CHROME_BROWSER_UI_GTK_COLLECTED_COOKIES_GTK_H_ 8 #define CHROME_BROWSER_UI_GTK_COLLECTED_COOKIES_GTK_H_
9 #pragma once 9 #pragma once
10 10
11 #include <gtk/gtk.h> 11 #include <gtk/gtk.h>
12 12
13 #include "base/memory/scoped_ptr.h" 13 #include "base/memory/scoped_ptr.h"
14 #include "chrome/browser/ui/gtk/constrained_window_gtk.h" 14 #include "chrome/browser/ui/gtk/constrained_window_gtk.h"
15 #include "chrome/browser/ui/gtk/gtk_tree.h" 15 #include "chrome/browser/ui/gtk/gtk_tree.h"
16 #include "chrome/common/content_settings.h" 16 #include "chrome/common/content_settings.h"
17 #include "content/common/notification_observer.h" 17 #include "content/common/notification_observer.h"
18 #include "content/common/notification_registrar.h" 18 #include "content/common/notification_registrar.h"
19 #include "ui/base/gtk/gtk_signal.h" 19 #include "ui/base/gtk/gtk_signal.h"
20 20
21 class CookiesTreeModel; 21 class CookiesTreeModel;
22 class TabContentsWrapper;
22 23
23 // CollectedCookiesGtk is a dialog that displays the allowed and blocked 24 // CollectedCookiesGtk is a dialog that displays the allowed and blocked
24 // cookies of the current tab contents. To display the dialog, invoke 25 // cookies of the current tab contents. To display the dialog, invoke
25 // ShowCollectedCookiesDialog() on the delegate of the tab contents wrapper's 26 // ShowCollectedCookiesDialog() on the delegate of the tab contents wrapper's
26 // content settings tab helper. 27 // content settings tab helper.
27 28
28 class CollectedCookiesGtk : public ConstrainedWindowGtkDelegate, 29 class CollectedCookiesGtk : public ConstrainedWindowGtkDelegate,
29 gtk_tree::TreeAdapter::Delegate, 30 public gtk_tree::TreeAdapter::Delegate,
30 NotificationObserver { 31 public NotificationObserver {
31 public: 32 public:
32 CollectedCookiesGtk(GtkWindow* parent, TabContents* tab_contents); 33 CollectedCookiesGtk(GtkWindow* parent, TabContentsWrapper* wrapper);
33 34
34 // ConstrainedWindowGtkDelegate methods. 35 // ConstrainedWindowGtkDelegate methods.
35 virtual GtkWidget* GetWidgetRoot(); 36 virtual GtkWidget* GetWidgetRoot();
36 virtual GtkWidget* GetFocusWidget(); 37 virtual GtkWidget* GetFocusWidget();
37 virtual void DeleteDelegate(); 38 virtual void DeleteDelegate();
38 39
39 private: 40 private:
40 virtual ~CollectedCookiesGtk(); 41 virtual ~CollectedCookiesGtk();
41 42
42 // Initialize all widgets of this dialog. 43 // Initialize all widgets of this dialog.
(...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after
105 GtkTreeSelection* allowed_selection_; 106 GtkTreeSelection* allowed_selection_;
106 GtkTreeSelection* blocked_selection_; 107 GtkTreeSelection* blocked_selection_;
107 108
108 // The infobar widget. 109 // The infobar widget.
109 GtkWidget* infobar_; 110 GtkWidget* infobar_;
110 GtkWidget* infobar_label_; 111 GtkWidget* infobar_label_;
111 112
112 // Displays information about selected cookie. 113 // Displays information about selected cookie.
113 GtkWidget* cookie_info_view_; 114 GtkWidget* cookie_info_view_;
114 115
115 // The tab contents. 116 // The tab contents wrapper.
116 TabContents* tab_contents_; 117 TabContentsWrapper* wrapper_;
117 118
118 bool status_changed_; 119 bool status_changed_;
119 120
120 // The Cookies Table model. 121 // The Cookies Table model.
121 scoped_ptr<CookiesTreeModel> allowed_cookies_tree_model_; 122 scoped_ptr<CookiesTreeModel> allowed_cookies_tree_model_;
122 scoped_ptr<CookiesTreeModel> blocked_cookies_tree_model_; 123 scoped_ptr<CookiesTreeModel> blocked_cookies_tree_model_;
123 scoped_ptr<gtk_tree::TreeAdapter> allowed_cookies_tree_adapter_; 124 scoped_ptr<gtk_tree::TreeAdapter> allowed_cookies_tree_adapter_;
124 scoped_ptr<gtk_tree::TreeAdapter> blocked_cookies_tree_adapter_; 125 scoped_ptr<gtk_tree::TreeAdapter> blocked_cookies_tree_adapter_;
125 126
126 DISALLOW_COPY_AND_ASSIGN(CollectedCookiesGtk); 127 DISALLOW_COPY_AND_ASSIGN(CollectedCookiesGtk);
127 }; 128 };
128 129
129 #endif // CHROME_BROWSER_UI_GTK_COLLECTED_COOKIES_GTK_H_ 130 #endif // CHROME_BROWSER_UI_GTK_COLLECTED_COOKIES_GTK_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/gtk/browser_window_gtk.cc ('k') | chrome/browser/ui/gtk/collected_cookies_gtk.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698