Chromium Code Reviews| OLD | NEW |
|---|---|
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 UI_VIEWS_WIDGET_WIDGET_H_ | 5 #ifndef UI_VIEWS_WIDGET_WIDGET_H_ |
| 6 #define UI_VIEWS_WIDGET_WIDGET_H_ | 6 #define UI_VIEWS_WIDGET_WIDGET_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <set> | 9 #include <set> |
| 10 #include <stack> | 10 #include <stack> |
| (...skipping 588 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 599 | 599 |
| 600 // True if the widget is considered top level widget. Top level widget | 600 // True if the widget is considered top level widget. Top level widget |
| 601 // is a widget of TYPE_WINDOW, TYPE_PANEL, TYPE_WINDOW_FRAMELESS, BUBBLE, | 601 // is a widget of TYPE_WINDOW, TYPE_PANEL, TYPE_WINDOW_FRAMELESS, BUBBLE, |
| 602 // POPUP or MENU, and has a focus manager and input method object associated | 602 // POPUP or MENU, and has a focus manager and input method object associated |
| 603 // with it. TYPE_CONTROL and TYPE_TOOLTIP is not considered top level. | 603 // with it. TYPE_CONTROL and TYPE_TOOLTIP is not considered top level. |
| 604 bool is_top_level() const { return is_top_level_; } | 604 bool is_top_level() const { return is_top_level_; } |
| 605 | 605 |
| 606 // Returns the bounds of work area in the screen that Widget belongs to. | 606 // Returns the bounds of work area in the screen that Widget belongs to. |
| 607 gfx::Rect GetWorkAreaBoundsInScreen() const; | 607 gfx::Rect GetWorkAreaBoundsInScreen() const; |
| 608 | 608 |
| 609 // Notification that our owned parent is closing. | |
| 610 virtual void OnOwnedParentClosing(); | |
|
Ben Goodger (Google)
2012/04/26 02:34:54
owning parent?
or how about
OnOwnerClosing()?
| |
| 611 | |
| 609 // Overridden from NativeWidgetDelegate: | 612 // Overridden from NativeWidgetDelegate: |
| 610 virtual bool IsModal() const OVERRIDE; | 613 virtual bool IsModal() const OVERRIDE; |
| 611 virtual bool IsDialogBox() const OVERRIDE; | 614 virtual bool IsDialogBox() const OVERRIDE; |
| 612 virtual bool CanActivate() const OVERRIDE; | 615 virtual bool CanActivate() const OVERRIDE; |
| 613 virtual bool IsInactiveRenderingDisabled() const OVERRIDE; | 616 virtual bool IsInactiveRenderingDisabled() const OVERRIDE; |
| 614 virtual void EnableInactiveRendering() OVERRIDE; | 617 virtual void EnableInactiveRendering() OVERRIDE; |
| 615 virtual void OnNativeWidgetActivationChanged(bool active) OVERRIDE; | 618 virtual void OnNativeWidgetActivationChanged(bool active) OVERRIDE; |
| 616 virtual void OnNativeFocus(gfx::NativeView focused_view) OVERRIDE; | 619 virtual void OnNativeFocus(gfx::NativeView focused_view) OVERRIDE; |
| 617 virtual void OnNativeBlur(gfx::NativeView focused_view) OVERRIDE; | 620 virtual void OnNativeBlur(gfx::NativeView focused_view) OVERRIDE; |
| 618 virtual void OnNativeWidgetVisibilityChanged(bool visible) OVERRIDE; | 621 virtual void OnNativeWidgetVisibilityChanged(bool visible) OVERRIDE; |
| (...skipping 155 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 774 // duplicate move events even though the mouse hasn't moved. | 777 // duplicate move events even though the mouse hasn't moved. |
| 775 bool last_mouse_event_was_move_; | 778 bool last_mouse_event_was_move_; |
| 776 gfx::Point last_mouse_event_position_; | 779 gfx::Point last_mouse_event_position_; |
| 777 | 780 |
| 778 DISALLOW_COPY_AND_ASSIGN(Widget); | 781 DISALLOW_COPY_AND_ASSIGN(Widget); |
| 779 }; | 782 }; |
| 780 | 783 |
| 781 } // namespace views | 784 } // namespace views |
| 782 | 785 |
| 783 #endif // UI_VIEWS_WIDGET_WIDGET_H_ | 786 #endif // UI_VIEWS_WIDGET_WIDGET_H_ |
| OLD | NEW |