Chromium Code Reviews| OLD | NEW |
|---|---|
| 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 VIEWS_WIDGET_WIDGET_H_ | 5 #ifndef VIEWS_WIDGET_WIDGET_H_ |
| 6 #define VIEWS_WIDGET_WIDGET_H_ | 6 #define VIEWS_WIDGET_WIDGET_H_ |
| 7 #pragma once | 7 #pragma once |
| 8 | 8 |
| 9 #include <stack> | 9 #include <stack> |
| 10 | 10 |
| (...skipping 599 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 610 virtual internal::RootView* CreateRootView(); | 610 virtual internal::RootView* CreateRootView(); |
| 611 | 611 |
| 612 // Provided to allow the NativeWidget implementations to destroy the RootView | 612 // Provided to allow the NativeWidget implementations to destroy the RootView |
| 613 // _before_ the focus manager/tooltip manager. | 613 // _before_ the focus manager/tooltip manager. |
| 614 // TODO(beng): remove once we fold those objects onto this one. | 614 // TODO(beng): remove once we fold those objects onto this one. |
| 615 void DestroyRootView(); | 615 void DestroyRootView(); |
| 616 | 616 |
| 617 // TODO(beng): Remove NativeWidgetGtk's dependence on these: | 617 // TODO(beng): Remove NativeWidgetGtk's dependence on these: |
| 618 // TODO(msw): Make this mouse state member private. | 618 // TODO(msw): Make this mouse state member private. |
| 619 // If true, the mouse is currently down. | 619 // If true, the mouse is currently down. |
| 620 bool is_mouse_button_pressed_; | 620 bool is_mouse_button_pressed_; |
|
Ben Goodger (Google)
2011/09/19 20:31:59
How about these other members too? I'd rather move
tfarina
2011/09/19 20:44:02
They are still used by NativeWidgetGtk.
| |
| 621 | 621 |
| 622 // TODO(beng): Remove NativeWidgetGtk's dependence on these: | 622 // TODO(beng): Remove NativeWidgetGtk's dependence on these: |
| 623 // TODO(msw): Make these mouse state members private. | 623 // TODO(msw): Make these mouse state members private. |
| 624 // The following are used to detect duplicate mouse move events and not | 624 // The following are used to detect duplicate mouse move events and not |
| 625 // deliver them. Displaying a window may result in the system generating | 625 // deliver them. Displaying a window may result in the system generating |
| 626 // duplicate move events even though the mouse hasn't moved. | 626 // duplicate move events even though the mouse hasn't moved. |
| 627 bool last_mouse_event_was_move_; | 627 bool last_mouse_event_was_move_; |
| 628 gfx::Point last_mouse_event_position_; | |
| 629 | 628 |
| 630 private: | 629 private: |
| 631 friend class NativeTextfieldViewsTest; | 630 friend class NativeTextfieldViewsTest; |
| 632 friend class NativeComboboxViewsTest; | 631 friend class NativeComboboxViewsTest; |
| 633 friend class ScopedEvent; | 632 friend class ScopedEvent; |
| 634 | 633 |
| 635 // Returns whether capture should be released on mouse release. | 634 // Returns whether capture should be released on mouse release. |
| 636 virtual bool ShouldReleaseCaptureOnMouseReleased() const; | 635 virtual bool ShouldReleaseCaptureOnMouseReleased() const; |
| 637 | 636 |
| 638 // Persists the window's restored position and "show" state using the | 637 // Persists the window's restored position and "show" state using the |
| (...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 724 | 723 |
| 725 // See |is_top_leve()| accessor. | 724 // See |is_top_leve()| accessor. |
| 726 bool is_top_level_; | 725 bool is_top_level_; |
| 727 | 726 |
| 728 // Factory used to create Compositors. Settable by tests. | 727 // Factory used to create Compositors. Settable by tests. |
| 729 static ui::Compositor*(*compositor_factory_)(); | 728 static ui::Compositor*(*compositor_factory_)(); |
| 730 | 729 |
| 731 // Tracks whether native widget has been initialized. | 730 // Tracks whether native widget has been initialized. |
| 732 bool native_widget_initialized_; | 731 bool native_widget_initialized_; |
| 733 | 732 |
| 733 gfx::Point last_mouse_event_position_; | |
| 734 | |
| 734 DISALLOW_COPY_AND_ASSIGN(Widget); | 735 DISALLOW_COPY_AND_ASSIGN(Widget); |
| 735 }; | 736 }; |
| 736 | 737 |
| 737 } // namespace views | 738 } // namespace views |
| 738 | 739 |
| 739 #endif // VIEWS_WIDGET_WIDGET_H_ | 740 #endif // VIEWS_WIDGET_WIDGET_H_ |
| OLD | NEW |