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

Side by Side Diff: ui/aura/mus/window_tree_host_mus_init_params.h

Issue 2823903005: Extracts parameters to WindowTreeHostMus into structure (Closed)
Patch Set: cleanup Created 3 years, 8 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 | « ui/aura/mus/window_tree_host_mus.cc ('k') | ui/aura/mus/window_tree_host_mus_init_params.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef UI_AURA_MUS_WINDOW_TREE_HOST_MUS_INIT_PARAMS_H_
6 #define UI_AURA_MUS_WINDOW_TREE_HOST_MUS_INIT_PARAMS_H_
7
8 #include <stdint.h>
9
10 #include <map>
11 #include <memory>
12 #include <string>
13 #include <vector>
14
15 #include "cc/surfaces/frame_sink_id.h"
16 #include "ui/aura/aura_export.h"
17
18 namespace aura {
19
20 class WindowPortMus;
21 class WindowTreeClient;
22
23 // Used to create a WindowTreeHostMus. The typical case is to use
24 // CreateInitParamsForTopLevel().
25 struct AURA_EXPORT WindowTreeHostMusInitParams {
26 WindowTreeHostMusInitParams();
27 ~WindowTreeHostMusInitParams();
28
29 // The WindowTreeClient; must be specified.
30 WindowTreeClient* window_tree_client = nullptr;
31
32 // Used to create the Window; must be specified.
33 std::unique_ptr<WindowPortMus> window_port;
34
35 // Properties to send to the server as well as to set on the Window.
36 std::map<std::string, std::vector<uint8_t>> properties;
37
38 cc::FrameSinkId frame_sink_id;
39
40 // Id of the display the window should be created on.
41 int64_t display_id = 0;
42 };
43
44 // Creates a WindowTreeHostMusInitParams that is used when creating a top-level
45 // window.
46 AURA_EXPORT std::unique_ptr<WindowTreeHostMusInitParams>
Elliot Glaysher 2017/04/19 17:17:33 Is there a reason you're using a unique_ptr instea
47 CreateInitParamsForTopLevel(
48 WindowTreeClient* window_tree_client,
49 std::map<std::string, std::vector<uint8_t>> properties =
50 std::map<std::string, std::vector<uint8_t>>());
51
52 } // namespace aura
53
54 #endif // UI_AURA_MUS_WINDOW_TREE_HOST_MUS_INIT_PARAMS_H_
OLDNEW
« no previous file with comments | « ui/aura/mus/window_tree_host_mus.cc ('k') | ui/aura/mus/window_tree_host_mus_init_params.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698