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

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

Issue 2349973010: mus drag and drop: return the completed effect to the caller. (Closed)
Patch Set: Rename some effect_taken to action_taken for consistency. 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
« no previous file with comments | « no previous file | services/ui/public/cpp/window.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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_H_ 5 #ifndef SERVICES_UI_PUBLIC_CPP_WINDOW_H_
6 #define SERVICES_UI_PUBLIC_CPP_WINDOW_H_ 6 #define SERVICES_UI_PUBLIC_CPP_WINDOW_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 213 matching lines...) Expand 10 before | Expand all | Expand 10 after
224 // NOTE: callback is run synchronously if Embed() is not allowed on this 224 // NOTE: callback is run synchronously if Embed() is not allowed on this
225 // Window. 225 // Window.
226 void Embed(ui::mojom::WindowTreeClientPtr client, 226 void Embed(ui::mojom::WindowTreeClientPtr client,
227 const EmbedCallback& callback, 227 const EmbedCallback& callback,
228 uint32_t flags = 0); 228 uint32_t flags = 0);
229 229
230 // TODO(sky): this API is only applicable to the WindowManager. Move it 230 // TODO(sky): this API is only applicable to the WindowManager. Move it
231 // to a better place. 231 // to a better place.
232 void RequestClose(); 232 void RequestClose();
233 233
234 // Starts an inter-process drag and drop operation. 234 // Starts an inter-process drag and drop operation. When this finishes, will
235 // return the tuple [success, action_taken] to |callback|, where action_taken
236 // is one of the ui::mojom::kDropEffect constants in
237 // window_tree_constants.mojom.
235 void PerformDragDrop( 238 void PerformDragDrop(
236 int drag_pointer, 239 int drag_pointer,
237 const std::map<std::string, std::vector<uint8_t>>& drag_data, 240 const std::map<std::string, std::vector<uint8_t>>& drag_data,
238 int drag_operation, 241 int drag_operation,
239 const gfx::Point& cursor_location, 242 const gfx::Point& cursor_location,
240 const SkBitmap& bitmap, 243 const SkBitmap& bitmap,
241 const base::Callback<void(bool)>& callback); 244 const base::Callback<void(bool, uint32_t)>& callback);
242 245
243 // Tells the window manager to take control of moving the window. Returns 246 // Tells the window manager to take control of moving the window. Returns
244 // true if the move wasn't canceled. 247 // true if the move wasn't canceled.
245 void PerformWindowMove(mojom::MoveLoopSource source, 248 void PerformWindowMove(mojom::MoveLoopSource source,
246 const gfx::Point& cursor_location, 249 const gfx::Point& cursor_location,
247 const base::Callback<void(bool)>& callback); 250 const base::Callback<void(bool)>& callback);
248 251
249 // Tells the window manager to abort any current move initiated by 252 // Tells the window manager to abort any current move initiated by
250 // PerformWindowMove(). 253 // PerformWindowMove().
251 void CancelWindowMove(); 254 void CancelWindowMove();
(...skipping 131 matching lines...) Expand 10 before | Expand all | Expand 10 after
383 }; 386 };
384 387
385 std::map<const void*, Value> prop_map_; 388 std::map<const void*, Value> prop_map_;
386 389
387 DISALLOW_COPY_AND_ASSIGN(Window); 390 DISALLOW_COPY_AND_ASSIGN(Window);
388 }; 391 };
389 392
390 } // namespace ui 393 } // namespace ui
391 394
392 #endif // SERVICES_UI_PUBLIC_CPP_WINDOW_H_ 395 #endif // SERVICES_UI_PUBLIC_CPP_WINDOW_H_
OLDNEW
« no previous file with comments | « no previous file | services/ui/public/cpp/window.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698