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

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

Issue 10545115: TabContentsWrapper -> TabContents, part 41. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 6 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) 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 #ifndef CHROME_BROWSER_UI_GTK_CREATE_APPLICATION_SHORTCUTS_DIALOG_GTK_H_ 5 #ifndef CHROME_BROWSER_UI_GTK_CREATE_APPLICATION_SHORTCUTS_DIALOG_GTK_H_
6 #define CHROME_BROWSER_UI_GTK_CREATE_APPLICATION_SHORTCUTS_DIALOG_GTK_H_ 6 #define CHROME_BROWSER_UI_GTK_CREATE_APPLICATION_SHORTCUTS_DIALOG_GTK_H_
7 #pragma once 7 #pragma once
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/compiler_specific.h" 10 #include "base/compiler_specific.h"
11 #include "base/memory/ref_counted.h" 11 #include "base/memory/ref_counted.h"
12 #include "base/message_loop_helpers.h" 12 #include "base/message_loop_helpers.h"
13 #include "chrome/browser/extensions/image_loading_tracker.h" 13 #include "chrome/browser/extensions/image_loading_tracker.h"
14 #include "chrome/browser/shell_integration.h" 14 #include "chrome/browser/shell_integration.h"
15 #include "content/public/browser/browser_thread.h" 15 #include "content/public/browser/browser_thread.h"
16 #include "googleurl/src/gurl.h" 16 #include "googleurl/src/gurl.h"
17 #include "ui/base/gtk/gtk_signal.h" 17 #include "ui/base/gtk/gtk_signal.h"
18 18
19 using content::BrowserThread; 19 using content::BrowserThread;
20 20
21 typedef struct _GdkPixbuf GdkPixbuf; 21 typedef struct _GdkPixbuf GdkPixbuf;
22 typedef struct _GtkWidget GtkWidget; 22 typedef struct _GtkWidget GtkWidget;
23 typedef struct _GtkWindow GtkWindow; 23 typedef struct _GtkWindow GtkWindow;
24 24
25 class Profile; 25 class Profile;
26 class TabContents; 26 class TabContents;
27 typedef TabContents TabContentsWrapper;
28 27
29 namespace extensions{ 28 namespace extensions{
30 class Extension; 29 class Extension;
31 } 30 }
32 31
33 class CreateApplicationShortcutsDialogGtk 32 class CreateApplicationShortcutsDialogGtk
34 : public base::RefCountedThreadSafe<CreateApplicationShortcutsDialogGtk, 33 : public base::RefCountedThreadSafe<CreateApplicationShortcutsDialogGtk,
35 BrowserThread::DeleteOnUIThread> { 34 BrowserThread::DeleteOnUIThread> {
36 protected: 35 protected:
37 explicit CreateApplicationShortcutsDialogGtk(GtkWindow* parent); 36 explicit CreateApplicationShortcutsDialogGtk(GtkWindow* parent);
(...skipping 40 matching lines...) Expand 10 before | Expand all | Expand 10 after
78 private: 77 private:
79 friend struct BrowserThread::DeleteOnThread<BrowserThread::UI>; 78 friend struct BrowserThread::DeleteOnThread<BrowserThread::UI>;
80 friend class base::DeleteHelper<CreateApplicationShortcutsDialogGtk>; 79 friend class base::DeleteHelper<CreateApplicationShortcutsDialogGtk>;
81 DISALLOW_COPY_AND_ASSIGN(CreateApplicationShortcutsDialogGtk); 80 DISALLOW_COPY_AND_ASSIGN(CreateApplicationShortcutsDialogGtk);
82 }; 81 };
83 82
84 class CreateWebApplicationShortcutsDialogGtk 83 class CreateWebApplicationShortcutsDialogGtk
85 : public CreateApplicationShortcutsDialogGtk { 84 : public CreateApplicationShortcutsDialogGtk {
86 public: 85 public:
87 // Displays the dialog box to create application shortcuts for |tab_contents|. 86 // Displays the dialog box to create application shortcuts for |tab_contents|.
88 static void Show(GtkWindow* parent, TabContentsWrapper* tab_contents); 87 static void Show(GtkWindow* parent, TabContents* tab_contents);
89 88
90 CreateWebApplicationShortcutsDialogGtk(GtkWindow* parent, 89 CreateWebApplicationShortcutsDialogGtk(GtkWindow* parent,
91 TabContentsWrapper* tab_contents); 90 TabContents* tab_contents);
92 91
93 virtual void OnCreatedShortcut(void) OVERRIDE; 92 virtual void OnCreatedShortcut(void) OVERRIDE;
94 93
95 protected: 94 protected:
96 virtual ~CreateWebApplicationShortcutsDialogGtk() {} 95 virtual ~CreateWebApplicationShortcutsDialogGtk() {}
97 96
98 private: 97 private:
99 // TabContentsWrapper for which the shortcut will be created. 98 // TabContents for which the shortcut will be created.
100 TabContentsWrapper* tab_contents_; 99 TabContents* tab_contents_;
101 100
102 DISALLOW_COPY_AND_ASSIGN(CreateWebApplicationShortcutsDialogGtk); 101 DISALLOW_COPY_AND_ASSIGN(CreateWebApplicationShortcutsDialogGtk);
103 }; 102 };
104 103
105 class CreateChromeApplicationShortcutsDialogGtk 104 class CreateChromeApplicationShortcutsDialogGtk
106 : public CreateApplicationShortcutsDialogGtk, 105 : public CreateApplicationShortcutsDialogGtk,
107 public ImageLoadingTracker::Observer { 106 public ImageLoadingTracker::Observer {
108 public: 107 public:
109 // Displays the dialog box to create application shortcuts for |app|. 108 // Displays the dialog box to create application shortcuts for |app|.
110 static void Show(GtkWindow* parent, Profile* profile, 109 static void Show(GtkWindow* parent, Profile* profile,
(...skipping 17 matching lines...) Expand all
128 const ShellIntegration::ShortcutInfo& shortcut_info) OVERRIDE; 127 const ShellIntegration::ShortcutInfo& shortcut_info) OVERRIDE;
129 128
130 private: 129 private:
131 const extensions::Extension* app_; 130 const extensions::Extension* app_;
132 FilePath profile_path_; 131 FilePath profile_path_;
133 ImageLoadingTracker tracker_; 132 ImageLoadingTracker tracker_;
134 DISALLOW_COPY_AND_ASSIGN(CreateChromeApplicationShortcutsDialogGtk); 133 DISALLOW_COPY_AND_ASSIGN(CreateChromeApplicationShortcutsDialogGtk);
135 }; 134 };
136 135
137 #endif // CHROME_BROWSER_UI_GTK_CREATE_APPLICATION_SHORTCUTS_DIALOG_GTK_H_ 136 #endif // CHROME_BROWSER_UI_GTK_CREATE_APPLICATION_SHORTCUTS_DIALOG_GTK_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/gtk/constrained_window_gtk.cc ('k') | chrome/browser/ui/gtk/create_application_shortcuts_dialog_gtk.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698