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

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

Issue 8295024: GTK version of new fullscreen exit bubble. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 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
« no previous file with comments | « no previous file | chrome/browser/ui/gtk/fullscreen_exit_bubble_gtk.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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_FULLSCREEN_EXIT_BUBBLE_GTK_H_ 5 #ifndef CHROME_BROWSER_UI_GTK_FULLSCREEN_EXIT_BUBBLE_GTK_H_
6 #define CHROME_BROWSER_UI_GTK_FULLSCREEN_EXIT_BUBBLE_GTK_H_ 6 #define CHROME_BROWSER_UI_GTK_FULLSCREEN_EXIT_BUBBLE_GTK_H_
7 #pragma once 7 #pragma once
8 8
9 #include "chrome/browser/ui/fullscreen_exit_bubble.h" 9 #include "chrome/browser/ui/fullscreen_exit_bubble.h"
10 #include "chrome/browser/ui/gtk/slide_animator_gtk.h" 10 #include "chrome/browser/ui/gtk/slide_animator_gtk.h"
(...skipping 20 matching lines...) Expand all
31 virtual gfx::Rect GetPopupRect(bool ignore_animation_state) const OVERRIDE; 31 virtual gfx::Rect GetPopupRect(bool ignore_animation_state) const OVERRIDE;
32 virtual gfx::Point GetCursorScreenPoint() OVERRIDE; 32 virtual gfx::Point GetCursorScreenPoint() OVERRIDE;
33 virtual bool WindowContainsPoint(gfx::Point pos) OVERRIDE; 33 virtual bool WindowContainsPoint(gfx::Point pos) OVERRIDE;
34 virtual bool IsWindowActive() OVERRIDE; 34 virtual bool IsWindowActive() OVERRIDE;
35 virtual void Hide() OVERRIDE; 35 virtual void Hide() OVERRIDE;
36 virtual void Show() OVERRIDE; 36 virtual void Show() OVERRIDE;
37 virtual bool IsAnimating() OVERRIDE; 37 virtual bool IsAnimating() OVERRIDE;
38 38
39 private: 39 private:
40 void InitWidgets(); 40 void InitWidgets();
41 std::string GetMessage(const GURL& url);
42 void HideButtons();
41 43
42 GtkWidget* widget() const { 44 GtkWidget* widget() const {
43 return slide_widget_->widget(); 45 return slide_widget_->widget();
44 } 46 }
45 47
46 CHROMEGTK_CALLBACK_1(FullscreenExitBubbleGtk, void, OnSetFloatingPosition, 48 CHROMEGTK_CALLBACK_1(FullscreenExitBubbleGtk, void, OnSetFloatingPosition,
47 GtkAllocation*); 49 GtkAllocation*);
48 CHROMEGTK_CALLBACK_0(FullscreenExitBubbleGtk, void, OnLinkClicked); 50 CHROMEGTK_CALLBACK_0(FullscreenExitBubbleGtk, void, OnLinkClicked);
51 CHROMEGTK_CALLBACK_0(FullscreenExitBubbleGtk, void, OnAllowClicked);
52 CHROMEGTK_CALLBACK_0(FullscreenExitBubbleGtk, void, OnDenyClicked);
49 53
50 // A pointer to the floating container that is our parent. 54 // A pointer to the floating container that is our parent.
51 GtkFloatingContainer* container_; 55 GtkFloatingContainer* container_;
52 56
53 // The widget that contains the link. 57 // The widget that contains the UI.
54 ui::OwnedWidgetGtk link_container_; 58 ui::OwnedWidgetGtk ui_container_;
59 GtkWidget* link_;
60 GtkWidget* allow_button_;
61 GtkWidget* deny_button_;
55 62
56 // The widget that animates the slide-out of fullscreen exit bubble. 63 // The widget that animates the slide-out of fullscreen exit bubble.
57 scoped_ptr<SlideAnimatorGtk> slide_widget_; 64 scoped_ptr<SlideAnimatorGtk> slide_widget_;
58 65
59 // The timer that does the initial hiding of the exit bubble. 66 // The timer that does the initial hiding of the exit bubble.
60 base::OneShotTimer<FullscreenExitBubbleGtk> initial_delay_; 67 base::OneShotTimer<FullscreenExitBubbleGtk> initial_delay_;
61 68
62 ui::GtkSignalRegistrar signals_; 69 ui::GtkSignalRegistrar signals_;
63 70
64 const GURL& url_; 71 const GURL url_;
65 bool show_buttons_; 72 bool show_buttons_;
66 }; 73 };
67 74
68 #endif // CHROME_BROWSER_UI_GTK_FULLSCREEN_EXIT_BUBBLE_GTK_H_ 75 #endif // CHROME_BROWSER_UI_GTK_FULLSCREEN_EXIT_BUBBLE_GTK_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/gtk/fullscreen_exit_bubble_gtk.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698