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

Unified Diff: chrome/browser/ui/views/first_run_bubble.h

Issue 1443253004: Fix a regression caused by my change to make the first run bubble window display as an inactive win… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 1 month 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
« no previous file with comments | « no previous file | chrome/browser/ui/views/first_run_bubble.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/views/first_run_bubble.h
diff --git a/chrome/browser/ui/views/first_run_bubble.h b/chrome/browser/ui/views/first_run_bubble.h
index 470e985c8e0509502bd22441d1bf179609105555..c6b9ba30d2a218bf8d0c1bacb5f9addb2598e6d5 100644
--- a/chrome/browser/ui/views/first_run_bubble.h
+++ b/chrome/browser/ui/views/first_run_bubble.h
@@ -6,6 +6,7 @@
#define CHROME_BROWSER_UI_VIEWS_FIRST_RUN_BUBBLE_H_
#include "base/macros.h"
+#include "ui/events/event.h"
#include "ui/views/bubble/bubble_delegate.h"
#include "ui/views/controls/link_listener.h"
@@ -25,8 +26,9 @@ class FirstRunBubble : public views::BubbleDelegateView,
FirstRunBubble(Browser* browser, views::View* anchor_view);
~FirstRunBubble() override;
- // This class observes keyboard events targeted towards the target view
- // dismisses the first run bubble accordingly.
+ // This class observes keyboard events, mouse clicks and touch down events
+ // targeted towards the anchor widget and dismisses the first run bubble
+ // accordingly.
class FirstRunBubbleCloser : public ui::EventHandler {
public:
FirstRunBubbleCloser(FirstRunBubble* bubble, views::View* anchor_view);
@@ -34,10 +36,14 @@ class FirstRunBubble : public views::BubbleDelegateView,
// ui::EventHandler overrides.
void OnKeyEvent(ui::KeyEvent* event) override;
+ void OnMouseEvent(ui::MouseEvent* event) override;
+ void OnGestureEvent(ui::GestureEvent* event) override;
private:
- void AddKeyboardEventObserver();
- void RemoveKeyboardEventObserver();
+ void AddEventObservers();
+ void RemoveEventObservers();
+
+ void CloseBubble();
// The bubble instance.
FirstRunBubble* bubble_;
« no previous file with comments | « no previous file | chrome/browser/ui/views/first_run_bubble.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698