| 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 | 7 |
| 8 #include <set> | 8 #include <set> |
| 9 #include <stack> | 9 #include <stack> |
| 10 #include <vector> | 10 #include <vector> |
| (...skipping 412 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 423 // TODO(beng): Move off public API. | 423 // TODO(beng): Move off public API. |
| 424 // Closes the widget immediately. Compare to |Close|. This will destroy the | 424 // Closes the widget immediately. Compare to |Close|. This will destroy the |
| 425 // window handle associated with this Widget, so should not be called from | 425 // window handle associated with this Widget, so should not be called from |
| 426 // any code that expects it to be valid beyond this call. | 426 // any code that expects it to be valid beyond this call. |
| 427 void CloseNow(); | 427 void CloseNow(); |
| 428 | 428 |
| 429 // Whether the widget has been asked to close itself. In particular this is | 429 // Whether the widget has been asked to close itself. In particular this is |
| 430 // set to true after Close() has been invoked on the NativeWidget. | 430 // set to true after Close() has been invoked on the NativeWidget. |
| 431 bool IsClosed() const; | 431 bool IsClosed() const; |
| 432 | 432 |
| 433 // Shows or hides the widget, without changing activation state. | 433 // Shows the widget and activates it. |
| 434 virtual void Show(); | 434 virtual void Show(); |
| 435 // Hides the widget. |
| 435 void Hide(); | 436 void Hide(); |
| 436 | 437 |
| 437 // Like Show(), but does not activate the window. | 438 // Like Show(), but does not activate the window. |
| 438 void ShowInactive(); | 439 void ShowInactive(); |
| 439 | 440 |
| 440 // Activates the widget, assuming it already exists and is visible. | 441 // Activates the widget, assuming it already exists and is visible. |
| 441 void Activate(); | 442 void Activate(); |
| 442 | 443 |
| 443 // Deactivates the widget, making the next window in the Z order the active | 444 // Deactivates the widget, making the next window in the Z order the active |
| 444 // window. | 445 // window. |
| (...skipping 442 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 887 // True when window movement via mouse interaction with the frame should be | 888 // True when window movement via mouse interaction with the frame should be |
| 888 // disabled. | 889 // disabled. |
| 889 bool movement_disabled_; | 890 bool movement_disabled_; |
| 890 | 891 |
| 891 DISALLOW_COPY_AND_ASSIGN(Widget); | 892 DISALLOW_COPY_AND_ASSIGN(Widget); |
| 892 }; | 893 }; |
| 893 | 894 |
| 894 } // namespace views | 895 } // namespace views |
| 895 | 896 |
| 896 #endif // UI_VIEWS_WIDGET_WIDGET_H_ | 897 #endif // UI_VIEWS_WIDGET_WIDGET_H_ |
| OLD | NEW |