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 #include "services/ui/public/cpp/window.h" | 5 #include "services/ui/public/cpp/window.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <set> | 10 #include <set> |
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
158 } | 158 } |
159 | 159 |
160 bool OwnsWindowOrIsRoot(Window* window) { | 160 bool OwnsWindowOrIsRoot(Window* window) { |
161 return OwnsWindow(window->window_tree(), window) || IsClientRoot(window); | 161 return OwnsWindow(window->window_tree(), window) || IsClientRoot(window); |
162 } | 162 } |
163 | 163 |
164 void EmptyEmbedCallback(bool result) {} | 164 void EmptyEmbedCallback(bool result) {} |
165 | 165 |
166 } // namespace | 166 } // namespace |
167 | 167 |
| 168 const char kWindowForAcceleratedWidget[] = "__UI_WINDOW_ACCELERATED_WIDGET__"; |
| 169 |
168 //////////////////////////////////////////////////////////////////////////////// | 170 //////////////////////////////////////////////////////////////////////////////// |
169 // Window, public: | 171 // Window, public: |
170 | 172 |
171 void Window::Destroy() { | 173 void Window::Destroy() { |
172 if (!OwnsWindowOrIsRoot(this)) | 174 if (!OwnsWindowOrIsRoot(this)) |
173 return; | 175 return; |
174 | 176 |
175 if (client_) | 177 if (client_) |
176 client_->DestroyWindow(this); | 178 client_->DestroyWindow(this); |
177 while (!children_.empty()) { | 179 while (!children_.empty()) { |
(...skipping 722 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
900 notifier->NotifyWindowReordered(); | 902 notifier->NotifyWindowReordered(); |
901 | 903 |
902 return true; | 904 return true; |
903 } | 905 } |
904 | 906 |
905 // static | 907 // static |
906 Window** Window::GetStackingTarget(Window* window) { | 908 Window** Window::GetStackingTarget(Window* window) { |
907 return &window->stacking_target_; | 909 return &window->stacking_target_; |
908 } | 910 } |
909 } // namespace ui | 911 } // namespace ui |
OLD | NEW |