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

Side by Side Diff: ui/aura/mus/property_utils.cc

Issue 2908333003: [mus+ash] Removes WmWindow from ash (app_list, frame, metrics, session, system, wallpaper) (Closed)
Patch Set: [mus ash] Removes WmWindow from ash (rebase, nits and cleanup of use of ResizeHandleWindowTargeter) Created 3 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
« no previous file with comments | « components/exo/touch_unittest.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 #include "ui/aura/mus/property_utils.h" 5 #include "ui/aura/mus/property_utils.h"
6 6
7 #include "services/ui/public/interfaces/window_manager_constants.mojom.h" 7 #include "services/ui/public/interfaces/window_manager_constants.mojom.h"
8 #include "ui/aura/client/aura_constants.h" 8 #include "ui/aura/client/aura_constants.h"
9 #include "ui/aura/client/window_types.h" 9 #include "ui/aura/client/window_types.h"
10 #include "ui/aura/window.h" 10 #include "ui/aura/window.h"
11 11
12 namespace aura { 12 namespace aura {
13 namespace { 13 namespace {
14 14
15 client::WindowType UiWindowTypeToWmWindowType(ui::mojom::WindowType type) { 15 client::WindowType UiWindowTypeToWindowType(ui::mojom::WindowType type) {
16 switch (type) { 16 switch (type) {
17 case ui::mojom::WindowType::WINDOW: 17 case ui::mojom::WindowType::WINDOW:
18 return client::WINDOW_TYPE_NORMAL; 18 return client::WINDOW_TYPE_NORMAL;
19 case ui::mojom::WindowType::PANEL: 19 case ui::mojom::WindowType::PANEL:
20 return client::WINDOW_TYPE_PANEL; 20 return client::WINDOW_TYPE_PANEL;
21 case ui::mojom::WindowType::CONTROL: 21 case ui::mojom::WindowType::CONTROL:
22 return client::WINDOW_TYPE_CONTROL; 22 return client::WINDOW_TYPE_CONTROL;
23 case ui::mojom::WindowType::WINDOW_FRAMELESS: 23 case ui::mojom::WindowType::WINDOW_FRAMELESS:
24 case ui::mojom::WindowType::POPUP: 24 case ui::mojom::WindowType::POPUP:
25 case ui::mojom::WindowType::BUBBLE: 25 case ui::mojom::WindowType::BUBBLE:
26 case ui::mojom::WindowType::DRAG: 26 case ui::mojom::WindowType::DRAG:
27 return client::WINDOW_TYPE_POPUP; 27 return client::WINDOW_TYPE_POPUP;
28 case ui::mojom::WindowType::MENU: 28 case ui::mojom::WindowType::MENU:
29 return client::WINDOW_TYPE_MENU; 29 return client::WINDOW_TYPE_MENU;
30 case ui::mojom::WindowType::TOOLTIP: 30 case ui::mojom::WindowType::TOOLTIP:
31 return client::WINDOW_TYPE_TOOLTIP; 31 return client::WINDOW_TYPE_TOOLTIP;
32 case ui::mojom::WindowType::UNKNOWN: 32 case ui::mojom::WindowType::UNKNOWN:
33 return client::WINDOW_TYPE_UNKNOWN; 33 return client::WINDOW_TYPE_UNKNOWN;
34 } 34 }
35 NOTREACHED(); 35 NOTREACHED();
36 return client::WINDOW_TYPE_UNKNOWN; 36 return client::WINDOW_TYPE_UNKNOWN;
37 } 37 }
38 38
39 } // namespace 39 } // namespace
40 40
41 void SetWindowType(Window* window, ui::mojom::WindowType window_type) { 41 void SetWindowType(Window* window, ui::mojom::WindowType window_type) {
42 window->SetProperty(client::kWindowTypeKey, window_type); 42 window->SetProperty(client::kWindowTypeKey, window_type);
43 window->SetType(UiWindowTypeToWmWindowType(window_type)); 43 window->SetType(UiWindowTypeToWindowType(window_type));
44 } 44 }
45 45
46 } // namespace aura 46 } // namespace aura
OLDNEW
« no previous file with comments | « components/exo/touch_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698