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

Side by Side Diff: services/ui/public/cpp/window_tree_client.h

Issue 2349973010: mus drag and drop: return the completed effect to the caller. (Closed)
Patch Set: 80 chars Created 4 years, 3 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 unified diff | Download patch
OLDNEW
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 SERVICES_UI_PUBLIC_CPP_WINDOW_TREE_CLIENT_H_ 5 #ifndef SERVICES_UI_PUBLIC_CPP_WINDOW_TREE_CLIENT_H_
6 #define SERVICES_UI_PUBLIC_CPP_WINDOW_TREE_CLIENT_H_ 6 #define SERVICES_UI_PUBLIC_CPP_WINDOW_TREE_CLIENT_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <map> 10 #include <map>
(...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after
176 void StartPointerWatcher(bool want_moves); 176 void StartPointerWatcher(bool want_moves);
177 void StopPointerWatcher(); 177 void StopPointerWatcher();
178 178
179 void PerformDragDrop( 179 void PerformDragDrop(
180 Window* window, 180 Window* window,
181 int drag_pointer, 181 int drag_pointer,
182 const std::map<std::string, std::vector<uint8_t>>& drag_data, 182 const std::map<std::string, std::vector<uint8_t>>& drag_data,
183 int drag_operation, 183 int drag_operation,
184 const gfx::Point& cursor_location, 184 const gfx::Point& cursor_location,
185 const SkBitmap& bitmap, 185 const SkBitmap& bitmap,
186 const base::Callback<void(bool)>& callback); 186 const base::Callback<void(bool, uint32_t)>& callback);
187 187
188 // Performs a window move. |callback| will be asynchronously called with the 188 // Performs a window move. |callback| will be asynchronously called with the
189 // whether the move loop completed successfully. 189 // whether the move loop completed successfully.
190 void PerformWindowMove(Window* window, 190 void PerformWindowMove(Window* window,
191 ui::mojom::MoveLoopSource source, 191 ui::mojom::MoveLoopSource source,
192 const gfx::Point& cursor_location, 192 const gfx::Point& cursor_location,
193 const base::Callback<void(bool)>& callback); 193 const base::Callback<void(bool)>& callback);
194 194
195 // Cancels a in progress window move. (If no window is currently being moved, 195 // Cancels a in progress window move. (If no window is currently being moved,
196 // does nothing.) 196 // does nothing.)
(...skipping 134 matching lines...) Expand 10 before | Expand all | Expand 10 after
331 uint32_t event_flags, 331 uint32_t event_flags,
332 const gfx::Point& position, 332 const gfx::Point& position,
333 uint32_t effect_bitmask, 333 uint32_t effect_bitmask,
334 const OnDragOverCallback& callback) override; 334 const OnDragOverCallback& callback) override;
335 void OnDragLeave(Id window_id) override; 335 void OnDragLeave(Id window_id) override;
336 void OnCompleteDrop(Id window_id, 336 void OnCompleteDrop(Id window_id,
337 uint32_t event_flags, 337 uint32_t event_flags,
338 const gfx::Point& position, 338 const gfx::Point& position,
339 uint32_t effect_bitmask, 339 uint32_t effect_bitmask,
340 const OnCompleteDropCallback& callback) override; 340 const OnCompleteDropCallback& callback) override;
341 void OnDragCompletedReturnValue(uint32_t window,
342 uint32_t action_taken) override;
341 void OnDragDropDone() override; 343 void OnDragDropDone() override;
342 void OnChangeCompleted(uint32_t change_id, bool success) override; 344 void OnChangeCompleted(uint32_t change_id, bool success) override;
343 void RequestClose(uint32_t window_id) override; 345 void RequestClose(uint32_t window_id) override;
344 void GetWindowManager( 346 void GetWindowManager(
345 mojo::AssociatedInterfaceRequest<WindowManager> internal) override; 347 mojo::AssociatedInterfaceRequest<WindowManager> internal) override;
346 348
347 // Overridden from WindowManager: 349 // Overridden from WindowManager:
348 void OnConnect(ClientSpecificId client_id) override; 350 void OnConnect(ClientSpecificId client_id) override;
349 void WmNewDisplayAdded(const display::Display& display, 351 void WmNewDisplayAdded(const display::Display& display,
350 mojom::WindowDataPtr root_data, 352 mojom::WindowDataPtr root_data,
(...skipping 116 matching lines...) Expand 10 before | Expand all | Expand 10 after
467 std::set<Id> drag_entered_windows_; 469 std::set<Id> drag_entered_windows_;
468 470
469 base::WeakPtrFactory<WindowTreeClient> weak_factory_; 471 base::WeakPtrFactory<WindowTreeClient> weak_factory_;
470 472
471 DISALLOW_COPY_AND_ASSIGN(WindowTreeClient); 473 DISALLOW_COPY_AND_ASSIGN(WindowTreeClient);
472 }; 474 };
473 475
474 } // namespace ui 476 } // namespace ui
475 477
476 #endif // SERVICES_UI_PUBLIC_CPP_WINDOW_TREE_CLIENT_H_ 478 #endif // SERVICES_UI_PUBLIC_CPP_WINDOW_TREE_CLIENT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698