OLD | NEW |
| (Empty) |
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 | |
3 // found in the LICENSE file. | |
4 | |
5 #include "components/mus/public/cpp/lib/window_private.h" | |
6 | |
7 namespace mus { | |
8 | |
9 WindowPrivate::WindowPrivate(Window* window) : window_(window) { | |
10 CHECK(window); | |
11 } | |
12 | |
13 WindowPrivate::~WindowPrivate() {} | |
14 | |
15 // static | |
16 Window* WindowPrivate::LocalCreate() { | |
17 return new Window; | |
18 } | |
19 | |
20 void WindowPrivate::LocalSetSharedProperty(const std::string& name, | |
21 mojo::Array<uint8_t> new_data) { | |
22 std::vector<uint8_t> data; | |
23 std::vector<uint8_t>* data_ptr = nullptr; | |
24 if (!new_data.is_null()) { | |
25 data = new_data.To<std::vector<uint8_t>>(); | |
26 data_ptr = &data; | |
27 } | |
28 LocalSetSharedProperty(name, data_ptr); | |
29 } | |
30 | |
31 } // namespace mus | |
OLD | NEW |