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

Side by Side Diff: components/mus/public/cpp/window.h

Issue 2060513002: Tab dragging as implemented as a mus API. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Use not not pattern to fix win compile Created 4 years, 6 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 COMPONENTS_MUS_PUBLIC_CPP_WINDOW_H_ 5 #ifndef COMPONENTS_MUS_PUBLIC_CPP_WINDOW_H_
6 #define COMPONENTS_MUS_PUBLIC_CPP_WINDOW_H_ 6 #define COMPONENTS_MUS_PUBLIC_CPP_WINDOW_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after
214 214
215 // NOTE: callback is run synchronously if Embed() is not allowed on this 215 // NOTE: callback is run synchronously if Embed() is not allowed on this
216 // Window. 216 // Window.
217 void Embed(mus::mojom::WindowTreeClientPtr client, 217 void Embed(mus::mojom::WindowTreeClientPtr client,
218 const EmbedCallback& callback); 218 const EmbedCallback& callback);
219 219
220 // TODO(sky): this API is only applicable to the WindowManager. Move it 220 // TODO(sky): this API is only applicable to the WindowManager. Move it
221 // to a better place. 221 // to a better place.
222 void RequestClose(); 222 void RequestClose();
223 223
224 // Tells the window manager to take control of moving the window. Locally,
sky 2016/06/24 19:59:00 Update comment.
225 // this spins up a nested message loop to handle all further ui messages; we
226 // don't use mojo's built in sync messages because we explicitly want to
227 // process all other messages. Returns true if the move wasn't canceled.
228 void PerformWindowMove(const gfx::Point& cursor_location,
229 const base::Callback<void(bool)>& callback);
230
231 // Tells the window manager to abort any current move initiated by
232 // PerformWindowMove().
233 void CancelWindowMove();
234
224 // Returns an internal name, set by a client app when it creates a window. 235 // Returns an internal name, set by a client app when it creates a window.
225 std::string GetName() const; 236 std::string GetName() const;
226 237
227 protected: 238 protected:
228 // This class is subclassed only by test classes that provide a public ctor. 239 // This class is subclassed only by test classes that provide a public ctor.
229 Window(); 240 Window();
230 ~Window(); 241 ~Window();
231 242
232 private: 243 private:
233 friend class WindowPrivate; 244 friend class WindowPrivate;
(...skipping 112 matching lines...) Expand 10 before | Expand all | Expand 10 after
346 }; 357 };
347 358
348 std::map<const void*, Value> prop_map_; 359 std::map<const void*, Value> prop_map_;
349 360
350 DISALLOW_COPY_AND_ASSIGN(Window); 361 DISALLOW_COPY_AND_ASSIGN(Window);
351 }; 362 };
352 363
353 } // namespace mus 364 } // namespace mus
354 365
355 #endif // COMPONENTS_MUS_PUBLIC_CPP_WINDOW_H_ 366 #endif // COMPONENTS_MUS_PUBLIC_CPP_WINDOW_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698