OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "remoting/host/linux/x_server_clipboard.h" | 5 #include "remoting/host/linux/x_server_clipboard.h" |
6 | 6 |
7 #include <X11/extensions/Xfixes.h> | 7 #include <X11/extensions/Xfixes.h> |
8 | 8 |
9 #include "base/basictypes.h" | 9 #include "base/basictypes.h" |
10 #include "base/callback.h" | 10 #include "base/callback.h" |
11 #include "remoting/base/constants.h" | 11 #include "remoting/base/constants.h" |
12 #include "remoting/base/logging.h" | 12 #include "remoting/base/logging.h" |
13 #include "remoting/base/util.h" | 13 #include "remoting/base/util.h" |
14 | 14 |
15 namespace remoting { | 15 namespace remoting { |
16 | 16 |
17 XServerClipboard::XServerClipboard() | 17 XServerClipboard::XServerClipboard() |
18 : display_(NULL), | 18 : display_(nullptr), |
19 clipboard_window_(BadValue), | 19 clipboard_window_(BadValue), |
20 xfixes_event_base_(-1), | 20 xfixes_event_base_(-1), |
21 clipboard_atom_(None), | 21 clipboard_atom_(None), |
22 large_selection_atom_(None), | 22 large_selection_atom_(None), |
23 selection_string_atom_(None), | 23 selection_string_atom_(None), |
24 targets_atom_(None), | 24 targets_atom_(None), |
25 timestamp_atom_(None), | 25 timestamp_atom_(None), |
26 utf8_string_atom_(None), | 26 utf8_string_atom_(None), |
27 large_selection_property_(None) { | 27 large_selection_property_(None) { |
28 } | 28 } |
(...skipping 337 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
366 } else { | 366 } else { |
367 LOG(ERROR) << "XSetSelectionOwner failed for selection " << selection; | 367 LOG(ERROR) << "XSetSelectionOwner failed for selection " << selection; |
368 } | 368 } |
369 } | 369 } |
370 | 370 |
371 bool XServerClipboard::IsSelectionOwner(Atom selection) { | 371 bool XServerClipboard::IsSelectionOwner(Atom selection) { |
372 return selections_owned_.find(selection) != selections_owned_.end(); | 372 return selections_owned_.find(selection) != selections_owned_.end(); |
373 } | 373 } |
374 | 374 |
375 } // namespace remoting | 375 } // namespace remoting |
OLD | NEW |