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

Unified Diff: chrome/browser/ui/gtk/zoom_bubble_gtk.cc

Issue 10985069: [test fixlet] Add tests for the zoom icon in the location bar on GTK. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 8 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/gtk/zoom_bubble_gtk.cc
diff --git a/chrome/browser/ui/gtk/zoom_bubble_gtk.cc b/chrome/browser/ui/gtk/zoom_bubble_gtk.cc
index 89bdbf577d56632623070911732e83a91a854dbf..62f4fa790767f1876623019680f33aa1a239a6a8 100644
--- a/chrome/browser/ui/gtk/zoom_bubble_gtk.cc
+++ b/chrome/browser/ui/gtk/zoom_bubble_gtk.cc
@@ -20,9 +20,6 @@
namespace {
-// Pointer to singleton object (NULL if no bubble is open).
-ZoomBubbleGtk* g_bubble = NULL;
-
// Number of milliseconds the bubble should stay open for if it will auto-close.
const int kBubbleCloseDelay = 1500;
@@ -34,6 +31,9 @@ const int kBubbleAnchorHeight = 25;
} // namespace
// static
+ZoomBubbleGtk* ZoomBubbleGtk::g_bubble = NULL;
+
+// static
void ZoomBubbleGtk::Show(GtkWidget* anchor,
TabContents* tab_contents,
bool auto_close) {
@@ -61,6 +61,11 @@ void ZoomBubbleGtk::Close() {
g_bubble->CloseBubble();
}
+// static
+bool ZoomBubbleGtk::IsShowing() {
+ return g_bubble != NULL;
+}
+
ZoomBubbleGtk::ZoomBubbleGtk(GtkWidget* anchor,
TabContents* tab_contents,
bool auto_close)

Powered by Google App Engine
This is Rietveld 408576698