Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(417)

Unified Diff: ui/aura/mus/window_tree_client.cc

Issue 2739213003: aura-mus: wire up drag and drop. (Closed)
Patch Set: msvc doesn't understand that this is impossible. Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ui/aura/mus/window_tree_client.cc
diff --git a/ui/aura/mus/window_tree_client.cc b/ui/aura/mus/window_tree_client.cc
index 3574d71869b49e99c77187a926118eda7c4e9e75..82f54f0d6d4d97dc79c56cebfb063cc8c2b5661e 100644
--- a/ui/aura/mus/window_tree_client.cc
+++ b/ui/aura/mus/window_tree_client.cc
@@ -826,9 +826,10 @@ void WindowTreeClient::RemoveTestObserver(
test_observers_.RemoveObserver(observer);
}
-void WindowTreeClient::SetCanAcceptDrops(Id window_id, bool can_accept_drops) {
+void WindowTreeClient::SetCanAcceptDrops(WindowMus* window,
+ bool can_accept_drops) {
DCHECK(tree_);
- tree_->SetCanAcceptDrops(window_id, can_accept_drops);
+ tree_->SetCanAcceptDrops(window->server_id(), can_accept_drops);
}
void WindowTreeClient::SetEventTargetingPolicy(
@@ -1268,10 +1269,9 @@ void WindowTreeClient::OnCompleteDrop(Id window_id,
void WindowTreeClient::OnPerformDragDropCompleted(uint32_t change_id,
bool success,
uint32_t action_taken) {
- if (drag_drop_controller_->DoesChangeIdMatchDragChangeId(change_id)) {
- OnChangeCompleted(change_id, success);
+ OnChangeCompleted(change_id, success);
+ if (drag_drop_controller_->DoesChangeIdMatchDragChangeId(change_id))
drag_drop_controller_->OnPerformDragDropCompleted(action_taken);
- }
}
void WindowTreeClient::OnChangeCompleted(uint32_t change_id, bool success) {

Powered by Google App Engine
This is Rietveld 408576698