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

Side by Side Diff: mash/wm/user_window_controller_impl.cc

Issue 1832133002: mus: Remove unnecessary const from property TypeConverter templates (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: format Created 4 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 | « mash/wm/property_util.cc ('k') | ui/views/mus/native_widget_mus.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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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 "mash/wm/user_window_controller_impl.h" 5 #include "mash/wm/user_window_controller_impl.h"
6 6
7 #include "components/mus/public/cpp/property_type_converters.h" 7 #include "components/mus/public/cpp/property_type_converters.h"
8 #include "components/mus/public/cpp/window.h" 8 #include "components/mus/public/cpp/window.h"
9 #include "components/mus/public/cpp/window_property.h" 9 #include "components/mus/public/cpp/window_property.h"
10 #include "components/mus/public/cpp/window_tree_connection.h" 10 #include "components/mus/public/cpp/window_tree_connection.h"
(...skipping 14 matching lines...) Expand all
25 mus::mojom::WindowManager::kWindowTitle_Property)); 25 mus::mojom::WindowManager::kWindowTitle_Property));
26 } 26 }
27 return mojo::String(std::string()); 27 return mojo::String(std::string());
28 } 28 }
29 29
30 // Get the serialized app icon bitmap from a mus::Window. 30 // Get the serialized app icon bitmap from a mus::Window.
31 mojo::Array<uint8_t> GetWindowAppIcon(mus::Window* window) { 31 mojo::Array<uint8_t> GetWindowAppIcon(mus::Window* window) {
32 if (window->HasSharedProperty( 32 if (window->HasSharedProperty(
33 mus::mojom::WindowManager::kWindowAppIcon_Property)) { 33 mus::mojom::WindowManager::kWindowAppIcon_Property)) {
34 return mojo::Array<uint8_t>::From( 34 return mojo::Array<uint8_t>::From(
35 window->GetSharedProperty<const std::vector<uint8_t>>( 35 window->GetSharedProperty<std::vector<uint8_t>>(
36 mus::mojom::WindowManager::kWindowAppIcon_Property)); 36 mus::mojom::WindowManager::kWindowAppIcon_Property));
37 } 37 }
38 return mojo::Array<uint8_t>(); 38 return mojo::Array<uint8_t>();
39 } 39 }
40 40
41 // Returns |window|, or an ancestor thereof, parented to |container|, or null. 41 // Returns |window|, or an ancestor thereof, parented to |container|, or null.
42 mus::Window* GetTopLevelWindow(mus::Window* window, mus::Window* container) { 42 mus::Window* GetTopLevelWindow(mus::Window* window, mus::Window* container) {
43 while (window && window->parent() != container) 43 while (window && window->parent() != container)
44 window = window->parent(); 44 window = window->parent();
45 return window; 45 return window;
(...skipping 125 matching lines...) Expand 10 before | Expand all | Expand 10 after
171 } 171 }
172 172
173 void UserWindowControllerImpl::FocusUserWindow(uint32_t window_id) { 173 void UserWindowControllerImpl::FocusUserWindow(uint32_t window_id) {
174 mus::Window* window = GetUserWindowContainer()->GetChildById(window_id); 174 mus::Window* window = GetUserWindowContainer()->GetChildById(window_id);
175 if (window) 175 if (window)
176 window->SetFocus(); 176 window->SetFocus();
177 } 177 }
178 178
179 } // namespace wm 179 } // namespace wm
180 } // namespace mash 180 } // namespace mash
OLDNEW
« no previous file with comments | « mash/wm/property_util.cc ('k') | ui/views/mus/native_widget_mus.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698