Chromium Code Reviews| 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/ws/window_tree.h" | 5 #include "services/ui/ws/window_tree.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include <utility> | 9 #include <utility> |
| 10 | 10 |
| (...skipping 1357 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1368 nullptr, std::move(compositor_frame_sink), | 1368 nullptr, std::move(compositor_frame_sink), |
| 1369 std::move(client)); | 1369 std::move(client)); |
| 1370 } | 1370 } |
| 1371 | 1371 |
| 1372 void WindowTree::OnWindowSurfaceDetached(Id transport_window_id, | 1372 void WindowTree::OnWindowSurfaceDetached(Id transport_window_id, |
| 1373 const cc::SurfaceSequence& sequence) { | 1373 const cc::SurfaceSequence& sequence) { |
| 1374 ServerWindow* window = | 1374 ServerWindow* window = |
| 1375 GetWindowByClientId(ClientWindowId(transport_window_id)); | 1375 GetWindowByClientId(ClientWindowId(transport_window_id)); |
| 1376 if (!window) | 1376 if (!window) |
| 1377 return; | 1377 return; |
| 1378 window_server_->GetDisplayCompositor()->ReturnSurfaceReference(sequence); | 1378 std::vector<uint32_t> sequences; |
| 1379 sequences.push_back(sequence.sequence); | |
|
kylechar
2016/11/04 15:53:51
Optional change:
std::vector<uint32_t> sequences(
Fady Samuel
2016/11/04 17:17:06
Done.
| |
| 1380 window_server_->GetDisplayCompositor()->ReturnSurfaceReferences( | |
| 1381 sequence.frame_sink_id, std::move(sequences)); | |
| 1379 } | 1382 } |
| 1380 | 1383 |
| 1381 void WindowTree::SetWindowTextInputState(Id transport_window_id, | 1384 void WindowTree::SetWindowTextInputState(Id transport_window_id, |
| 1382 mojo::TextInputStatePtr state) { | 1385 mojo::TextInputStatePtr state) { |
| 1383 ServerWindow* window = | 1386 ServerWindow* window = |
| 1384 GetWindowByClientId(ClientWindowId(transport_window_id)); | 1387 GetWindowByClientId(ClientWindowId(transport_window_id)); |
| 1385 bool success = window && access_policy_->CanSetWindowTextInputState(window); | 1388 bool success = window && access_policy_->CanSetWindowTextInputState(window); |
| 1386 if (success) | 1389 if (success) |
| 1387 window->SetTextInputState(state.To<ui::TextInputState>()); | 1390 window->SetTextInputState(state.To<ui::TextInputState>()); |
| 1388 } | 1391 } |
| (...skipping 556 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1945 client()->OnCompleteDrop(client_window_id.id, event_flags, cursor_offset, | 1948 client()->OnCompleteDrop(client_window_id.id, event_flags, cursor_offset, |
| 1946 effect_bitmask, callback); | 1949 effect_bitmask, callback); |
| 1947 } | 1950 } |
| 1948 | 1951 |
| 1949 void WindowTree::PerformOnDragDropDone() { | 1952 void WindowTree::PerformOnDragDropDone() { |
| 1950 client()->OnDragDropDone(); | 1953 client()->OnDragDropDone(); |
| 1951 } | 1954 } |
| 1952 | 1955 |
| 1953 } // namespace ws | 1956 } // namespace ws |
| 1954 } // namespace ui | 1957 } // namespace ui |
| OLD | NEW |