OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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 #ifndef UI_BASE_X_SELECTION_OWNER_H_ | 5 #ifndef UI_BASE_X_SELECTION_OWNER_H_ |
6 #define UI_BASE_X_SELECTION_OWNER_H_ | 6 #define UI_BASE_X_SELECTION_OWNER_H_ |
7 | 7 |
8 #include <stddef.h> | 8 #include <stddef.h> |
9 | 9 |
10 #include <vector> | 10 #include <vector> |
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
112 std::vector<IncrementalTransfer>::iterator FindIncrementalTransferForEvent( | 112 std::vector<IncrementalTransfer>::iterator FindIncrementalTransferForEvent( |
113 const XEvent& event); | 113 const XEvent& event); |
114 | 114 |
115 // Our X11 state. | 115 // Our X11 state. |
116 XDisplay* x_display_; | 116 XDisplay* x_display_; |
117 XID x_window_; | 117 XID x_window_; |
118 | 118 |
119 // The X11 selection that this instance communicates on. | 119 // The X11 selection that this instance communicates on. |
120 XAtom selection_name_; | 120 XAtom selection_name_; |
121 | 121 |
| 122 // The time that this instance took ownership of its selection. |
| 123 Time acquired_selection_timestamp_; |
| 124 |
122 // The maximum size of data we can put in XChangeProperty(). | 125 // The maximum size of data we can put in XChangeProperty(). |
123 size_t max_request_size_; | 126 size_t max_request_size_; |
124 | 127 |
125 // The data we are currently serving. | 128 // The data we are currently serving. |
126 SelectionFormatMap format_map_; | 129 SelectionFormatMap format_map_; |
127 | 130 |
128 std::vector<IncrementalTransfer> incremental_transfers_; | 131 std::vector<IncrementalTransfer> incremental_transfers_; |
129 | 132 |
130 // Used to abort stale incremental data transfers. | 133 // Used to abort stale incremental data transfers. |
131 base::RepeatingTimer incremental_transfer_abort_timer_; | 134 base::RepeatingTimer incremental_transfer_abort_timer_; |
132 | 135 |
133 X11AtomCache atom_cache_; | 136 X11AtomCache atom_cache_; |
134 | 137 |
135 DISALLOW_COPY_AND_ASSIGN(SelectionOwner); | 138 DISALLOW_COPY_AND_ASSIGN(SelectionOwner); |
136 }; | 139 }; |
137 | 140 |
138 } // namespace ui | 141 } // namespace ui |
139 | 142 |
140 #endif // UI_BASE_X_SELECTION_OWNER_H_ | 143 #endif // UI_BASE_X_SELECTION_OWNER_H_ |
OLD | NEW |