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

Side by Side Diff: chrome/browser/gtk/location_bar_view_gtk.h

Issue 306004: Revert 29457, because this is making ExtensionBrowserTest.PageAction crash on... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 11 years, 2 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) 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 #ifndef CHROME_BROWSER_GTK_LOCATION_BAR_VIEW_GTK_H_ 5 #ifndef CHROME_BROWSER_GTK_LOCATION_BAR_VIEW_GTK_H_
6 #define CHROME_BROWSER_GTK_LOCATION_BAR_VIEW_GTK_H_ 6 #define CHROME_BROWSER_GTK_LOCATION_BAR_VIEW_GTK_H_
7 7
8 #include <gtk/gtk.h> 8 #include <gtk/gtk.h>
9 9
10 #include <string> 10 #include <string>
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 // visible or hidden. |contents| is the TabContents that is active, |url| 113 // visible or hidden. |contents| is the TabContents that is active, |url|
114 // is the current page URL. 114 // is the current page URL.
115 void UpdateVisibility(TabContents* contents, GURL url); 115 void UpdateVisibility(TabContents* contents, GURL url);
116 116
117 // A callback from ImageLoadingTracker for when the image has loaded. 117 // A callback from ImageLoadingTracker for when the image has loaded.
118 virtual void OnImageLoaded(SkBitmap* image, size_t index); 118 virtual void OnImageLoaded(SkBitmap* image, size_t index);
119 119
120 private: 120 private:
121 static gboolean OnButtonPressed(GtkWidget* sender, GdkEventButton* event, 121 static gboolean OnButtonPressed(GtkWidget* sender, GdkEventButton* event,
122 PageActionViewGtk* page_action_view); 122 PageActionViewGtk* page_action_view);
123 static gboolean OnExposeEvent(GtkWidget* widget,
124 GdkEventExpose* event,
125 PageActionViewGtk* page_action_view);
126 123
127 // The location bar view that owns us. 124 // The location bar view that owns us.
128 LocationBarViewGtk* owner_; 125 LocationBarViewGtk* owner_;
129 126
130 // The current profile (not owned by us). 127 // The current profile (not owned by us).
131 Profile* profile_; 128 Profile* profile_;
132 129
133 // The PageAction that this view represents. The PageAction is not owned by 130 // The PageAction that this view represents. The PageAction is not owned by
134 // us, it resides in the extension of this particular profile. 131 // us, it resides in the extension of this particular profile.
135 const ExtensionAction* page_action_; 132 const ExtensionAction* page_action_;
(...skipping 16 matching lines...) Expand all
152 OwnedWidgetGtk image_; 149 OwnedWidgetGtk image_;
153 150
154 // The tab id we are currently showing the icon for. 151 // The tab id we are currently showing the icon for.
155 int current_tab_id_; 152 int current_tab_id_;
156 153
157 // The URL we are currently showing the icon for. 154 // The URL we are currently showing the icon for.
158 GURL current_url_; 155 GURL current_url_;
159 156
160 DISALLOW_COPY_AND_ASSIGN(PageActionViewGtk); 157 DISALLOW_COPY_AND_ASSIGN(PageActionViewGtk);
161 }; 158 };
162 friend class PageActionViewGtk;
163 159
164 static gboolean HandleExposeThunk(GtkWidget* widget, GdkEventExpose* event, 160 static gboolean HandleExposeThunk(GtkWidget* widget, GdkEventExpose* event,
165 gpointer userdata) { 161 gpointer userdata) {
166 return reinterpret_cast<LocationBarViewGtk*>(userdata)-> 162 return reinterpret_cast<LocationBarViewGtk*>(userdata)->
167 HandleExpose(widget, event); 163 HandleExpose(widget, event);
168 } 164 }
169 165
170 gboolean HandleExpose(GtkWidget* widget, GdkEventExpose* event); 166 gboolean HandleExpose(GtkWidget* widget, GdkEventExpose* event);
171 167
172 static gboolean OnSecurityIconPressed(GtkWidget* sender, 168 static gboolean OnSecurityIconPressed(GtkWidget* sender,
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
243 239
244 // Provides colors and rendering mode. 240 // Provides colors and rendering mode.
245 GtkThemeProvider* theme_provider_; 241 GtkThemeProvider* theme_provider_;
246 242
247 NotificationRegistrar registrar_; 243 NotificationRegistrar registrar_;
248 244
249 DISALLOW_COPY_AND_ASSIGN(LocationBarViewGtk); 245 DISALLOW_COPY_AND_ASSIGN(LocationBarViewGtk);
250 }; 246 };
251 247
252 #endif // CHROME_BROWSER_GTK_LOCATION_BAR_VIEW_GTK_H_ 248 #endif // CHROME_BROWSER_GTK_LOCATION_BAR_VIEW_GTK_H_
OLDNEW
« no previous file with comments | « chrome/browser/extensions/extension_page_actions_module.cc ('k') | chrome/browser/gtk/location_bar_view_gtk.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698