| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 COMPONENTS_MUS_WS_SERVER_WINDOW_H_ | 5 #ifndef COMPONENTS_MUS_WS_SERVER_WINDOW_H_ |
| 6 #define COMPONENTS_MUS_WS_SERVER_WINDOW_H_ | 6 #define COMPONENTS_MUS_WS_SERVER_WINDOW_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <map> | 10 #include <map> |
| (...skipping 64 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 75 // area to fill the whole bounds. | 75 // area to fill the whole bounds. |
| 76 void SetBounds(const gfx::Rect& bounds); | 76 void SetBounds(const gfx::Rect& bounds); |
| 77 | 77 |
| 78 const std::vector<gfx::Rect>& additional_client_areas() const { | 78 const std::vector<gfx::Rect>& additional_client_areas() const { |
| 79 return additional_client_areas_; | 79 return additional_client_areas_; |
| 80 } | 80 } |
| 81 const gfx::Insets& client_area() const { return client_area_; } | 81 const gfx::Insets& client_area() const { return client_area_; } |
| 82 void SetClientArea(const gfx::Insets& insets, | 82 void SetClientArea(const gfx::Insets& insets, |
| 83 const std::vector<gfx::Rect>& additional_client_areas); | 83 const std::vector<gfx::Rect>& additional_client_areas); |
| 84 | 84 |
| 85 const gfx::Rect* hit_test_mask() const { return hit_test_mask_.get(); } |
| 86 void SetHitTestMask(const gfx::Rect& mask); |
| 87 void ClearHitTestMask(); |
| 88 |
| 85 int32_t cursor() const { return static_cast<int32_t>(cursor_id_); } | 89 int32_t cursor() const { return static_cast<int32_t>(cursor_id_); } |
| 86 int32_t non_client_cursor() const { | 90 int32_t non_client_cursor() const { |
| 87 return static_cast<int32_t>(non_client_cursor_id_); | 91 return static_cast<int32_t>(non_client_cursor_id_); |
| 88 } | 92 } |
| 89 | 93 |
| 90 const ServerWindow* parent() const { return parent_; } | 94 const ServerWindow* parent() const { return parent_; } |
| 91 ServerWindow* parent() { return parent_; } | 95 ServerWindow* parent() { return parent_; } |
| 92 | 96 |
| 93 const ServerWindow* GetRoot() const; | 97 const ServerWindow* GetRoot() const; |
| 94 ServerWindow* GetRoot() { | 98 ServerWindow* GetRoot() { |
| (...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 223 ui::TextInputState text_input_state_; | 227 ui::TextInputState text_input_state_; |
| 224 | 228 |
| 225 Properties properties_; | 229 Properties properties_; |
| 226 | 230 |
| 227 gfx::Vector2d underlay_offset_; | 231 gfx::Vector2d underlay_offset_; |
| 228 | 232 |
| 229 // The hit test for windows extends outside the bounds of the window by this | 233 // The hit test for windows extends outside the bounds of the window by this |
| 230 // amount. | 234 // amount. |
| 231 gfx::Insets extended_hit_test_region_; | 235 gfx::Insets extended_hit_test_region_; |
| 232 | 236 |
| 237 // Mouse events outside the hit test mask don't hit the window. An empty mask |
| 238 // means all events miss the window. If null there is no mask. |
| 239 std::unique_ptr<gfx::Rect> hit_test_mask_; |
| 240 |
| 233 base::ObserverList<ServerWindowObserver> observers_; | 241 base::ObserverList<ServerWindowObserver> observers_; |
| 234 | 242 |
| 235 DISALLOW_COPY_AND_ASSIGN(ServerWindow); | 243 DISALLOW_COPY_AND_ASSIGN(ServerWindow); |
| 236 }; | 244 }; |
| 237 | 245 |
| 238 } // namespace ws | 246 } // namespace ws |
| 239 } // namespace mus | 247 } // namespace mus |
| 240 | 248 |
| 241 #endif // COMPONENTS_MUS_WS_SERVER_WINDOW_H_ | 249 #endif // COMPONENTS_MUS_WS_SERVER_WINDOW_H_ |
| OLD | NEW |