Index: chrome/browser/ui/fullscreen_exit_bubble.h |
diff --git a/chrome/browser/ui/fullscreen_exit_bubble.h b/chrome/browser/ui/fullscreen_exit_bubble.h |
index 0f2c14c094ad1e9aa38c42c22b3d9a90943ede7c..ab4ddb887dd05605365417bee03ece11ff404a4a 100644 |
--- a/chrome/browser/ui/fullscreen_exit_bubble.h |
+++ b/chrome/browser/ui/fullscreen_exit_bubble.h |
@@ -9,9 +9,12 @@ |
#include "base/memory/scoped_ptr.h" |
#include "base/timer.h" |
#include "chrome/browser/command_updater.h" |
+#include "googleurl/src/gurl.h" |
#include "ui/base/animation/animation_delegate.h" |
#include "ui/gfx/point.h" |
+class Browser; |
+ |
namespace ui { |
class SlideAnimation; |
} |
@@ -22,18 +25,18 @@ class Rect; |
class FullscreenExitBubble : public ui::AnimationDelegate { |
public: |
- explicit FullscreenExitBubble( |
- CommandUpdater::CommandUpdaterDelegate* delegate); |
+ explicit FullscreenExitBubble(Browser* browser); |
virtual ~FullscreenExitBubble(); |
protected: |
- static const double kOpacity; // Opacity of the bubble, 0.0 - 1.0 |
static const int kPaddingPx; // Amount of padding around the link |
static const int kInitialDelayMs; // Initial time bubble remains onscreen |
static const int kIdleTimeMs; // Time before mouse idle triggers hide |
static const int kPositionCheckHz; // How fast to check the mouse position |
- static const int kSlideInRegionHeightPx; |
- // Height of region triggering slide-in |
+ static const int kSlideInRegionHeightPx; // Height of region triggering |
+ // slide-in |
+ static const int kPopupTopPx; // Space between the popup and the top |
+ // of the screen. |
static const int kSlideInDurationMs; // Duration of slide-in animation |
static const int kSlideOutDurationMs; // Duration of slide-out animation |
@@ -41,9 +44,7 @@ class FullscreenExitBubble : public ui::AnimationDelegate { |
// |ignore_animation_state| is true this returns the rect assuming the popup |
// is fully onscreen. |
virtual gfx::Rect GetPopupRect(bool ignore_animation_state) const = 0; |
- |
virtual gfx::Point GetCursorScreenPoint() = 0; |
- |
virtual bool WindowContainsPoint(gfx::Point pos) = 0; |
// Returns true if the window is active. |
@@ -65,12 +66,13 @@ class FullscreenExitBubble : public ui::AnimationDelegate { |
void StartWatchingMouse(); |
void ToggleFullscreen(); |
+ void AcceptFullscreen(const GURL& url); |
+ void CancelFullscreen(); |
- private: |
- // Someone who can toggle fullscreen mode on and off when the user requests |
- // it. |
- CommandUpdater::CommandUpdaterDelegate* delegate_; |
+ // The browser this bubble is in. |
+ Browser* browser_; |
+ private: |
// Timer to delay before allowing the bubble to hide after it's initially |
// shown. |
base::OneShotTimer<FullscreenExitBubble> initial_delay_; |