| Index: ui/views/bubble/bubble_frame_view.h
|
| diff --git a/ui/views/bubble/bubble_frame_view.h b/ui/views/bubble/bubble_frame_view.h
|
| index a17a4f8f487eede0823a540e7654ceee3544b2cd..08dfc2cfca520309acedf50a4b0725de1fa74dba 100644
|
| --- a/ui/views/bubble/bubble_frame_view.h
|
| +++ b/ui/views/bubble/bubble_frame_view.h
|
| @@ -6,6 +6,7 @@
|
| #define UI_VIEWS_BUBBLE_BUBBLE_FRAME_VIEW_H_
|
|
|
| #include "base/basictypes.h"
|
| +#include "base/callback.h"
|
| #include "base/compiler_specific.h"
|
| #include "base/gtest_prod_util.h"
|
| #include "ui/gfx/insets.h"
|
| @@ -79,6 +80,10 @@ class VIEWS_EXPORT BubbleFrameView : public NonClientFrameView,
|
| gfx::Size client_size,
|
| bool adjust_if_offscreen);
|
|
|
| + void set_before_close_callback(base::Closure c) {
|
| + before_close_callback_ = c;
|
| + }
|
| +
|
| protected:
|
| // Returns the available screen bounds if the frame were to show in |rect|.
|
| virtual gfx::Rect GetAvailableScreenBounds(const gfx::Rect& rect);
|
| @@ -114,6 +119,10 @@ class VIEWS_EXPORT BubbleFrameView : public NonClientFrameView,
|
| // (x) close button.
|
| View* titlebar_extra_view_;
|
|
|
| + // The callback function is executed before bubble is closed. It can be used
|
| + // to customize bubble's close behavior.
|
| + base::Closure before_close_callback_;
|
| +
|
| DISALLOW_COPY_AND_ASSIGN(BubbleFrameView);
|
| };
|
|
|
|
|