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

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

Issue 10494004: Implements a zoom icon in the Omnibox for Views. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
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
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_ZOOM_BUBBLE_GTK_H_ 5 #ifndef CHROME_BROWSER_UI_GTK_ZOOM_BUBBLE_GTK_H_
6 #define CHROME_BROWSER_UI_GTK_ZOOM_BUBBLE_GTK_H_ 6 #define CHROME_BROWSER_UI_GTK_ZOOM_BUBBLE_GTK_H_
7 #pragma once 7 #pragma once
8 8
9 #include "base/basictypes.h" 9 #include "base/basictypes.h"
10 #include "base/memory/weak_ptr.h" 10 #include "base/memory/weak_ptr.h"
(...skipping 19 matching lines...) Expand all
30 30
31 // BubbleDelegateGtk: 31 // BubbleDelegateGtk:
32 virtual void BubbleClosing(BubbleGtk* bubble, bool closed_by_escape) OVERRIDE; 32 virtual void BubbleClosing(BubbleGtk* bubble, bool closed_by_escape) OVERRIDE;
33 33
34 // content::NotificationObserver: 34 // content::NotificationObserver:
35 virtual void Observe(int type, 35 virtual void Observe(int type,
36 const content::NotificationSource& source, 36 const content::NotificationSource& source,
37 const content::NotificationDetails& details) OVERRIDE; 37 const content::NotificationDetails& details) OVERRIDE;
38 38
39 private: 39 private:
40 ZoomBubbleGtk(GtkWidget* anchor, 40 ZoomBubbleGtk(GtkWidget* anchor, Profile* profile,
Ben Goodger (Google) 2012/06/04 15:16:49 leave it the way it was
Kyle Horimoto 2012/06/05 05:03:59 Oops - this was changed in my other CL and must ha
41 Profile* profile, 41 int zoomPercent, bool autoclose);
42 int zoom_percent,
43 bool autoclose);
44 virtual ~ZoomBubbleGtk(); 42 virtual ~ZoomBubbleGtk();
45 43
46 // Closes the zoom bubble. 44 // Closes the zoom bubble.
47 void CloseBubble(); 45 void CloseBubble();
48 46
49 // Notified when |content_| is destroyed so this instance can be deleted. 47 // Notified when |content_| is destroyed so this instance can be deleted.
50 CHROMEGTK_CALLBACK_0(ZoomBubbleGtk, void, OnDestroy); 48 CHROMEGTK_CALLBACK_0(ZoomBubbleGtk, void, OnDestroy);
51 49
52 // Provides colors. 50 // Provides colors.
53 GtkThemeService* theme_service_; 51 GtkThemeService* theme_service_;
54 52
55 // Label showing zoom percentage. 53 // Label showing zoom percentage.
56 GtkWidget* label_; 54 GtkWidget* label_;
57 55
58 // The BubbleGtk object containing the zoom bubble's content. 56 // The BubbleGtk object containing the zoom bubble's content.
59 BubbleGtk* bubble_; 57 BubbleGtk* bubble_;
60 58
61 base::WeakPtrFactory<ZoomBubbleGtk> factory_; 59 base::WeakPtrFactory<ZoomBubbleGtk> factory_;
62 60
63 content::NotificationRegistrar registrar_; 61 content::NotificationRegistrar registrar_;
64 62
65 DISALLOW_COPY_AND_ASSIGN(ZoomBubbleGtk); 63 DISALLOW_COPY_AND_ASSIGN(ZoomBubbleGtk);
66 }; 64 };
67 65
68 #endif // CHROME_BROWSER_UI_GTK_ZOOM_BUBBLE_GTK_H_ 66 #endif // CHROME_BROWSER_UI_GTK_ZOOM_BUBBLE_GTK_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698