| OLD | NEW |
| 1 // Copyright (c) 2009 The Chromium OS Authors. All rights reserved. | 1 // Copyright (c) 2009 The Chromium OS 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 "window_manager/x_connection.h" | 5 #include "window_manager/x_connection.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 | 8 |
| 9 namespace chromeos { | 9 namespace window_manager { |
| 10 | 10 |
| 11 const int XConnection::kByteFormat = 8; | 11 const int XConnection::kByteFormat = 8; |
| 12 const int XConnection::kLongFormat = 32; | 12 const int XConnection::kLongFormat = 32; |
| 13 | 13 |
| 14 | 14 |
| 15 bool XConnection::GetIntProperty(XWindow xid, XAtom xatom, int* value) { | 15 bool XConnection::GetIntProperty(XWindow xid, XAtom xatom, int* value) { |
| 16 CHECK(value); | 16 CHECK(value); |
| 17 std::vector<int> values; | 17 std::vector<int> values; |
| 18 if (!GetIntArrayProperty(xid, xatom, &values)) { | 18 if (!GetIntArrayProperty(xid, xatom, &values)) { |
| 19 return false; | 19 return false; |
| (...skipping 28 matching lines...) Expand all Loading... |
| 48 } | 48 } |
| 49 return false; | 49 return false; |
| 50 } | 50 } |
| 51 | 51 |
| 52 bool XConnection::SetIntProperty( | 52 bool XConnection::SetIntProperty( |
| 53 XWindow xid, XAtom xatom, XAtom type, int value) { | 53 XWindow xid, XAtom xatom, XAtom type, int value) { |
| 54 std::vector<int> values(1, value); | 54 std::vector<int> values(1, value); |
| 55 return SetIntArrayProperty(xid, xatom, type, values); | 55 return SetIntArrayProperty(xid, xatom, type, values); |
| 56 } | 56 } |
| 57 | 57 |
| 58 } // namespace chromeos | 58 } // namespace window_manager |
| OLD | NEW |