| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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 CHROME_BROWSER_DATA_USE_MEASUREMENT_CHROME_DATA_USE_ASCRIBER_SERVICE_H_ | 5 #ifndef CHROME_BROWSER_DATA_USE_MEASUREMENT_CHROME_DATA_USE_ASCRIBER_SERVICE_H_ |
| 6 #define CHROME_BROWSER_DATA_USE_MEASUREMENT_CHROME_DATA_USE_ASCRIBER_SERVICE_H_ | 6 #define CHROME_BROWSER_DATA_USE_MEASUREMENT_CHROME_DATA_USE_ASCRIBER_SERVICE_H_ |
| 7 | 7 |
| 8 #include <list> | 8 #include <list> |
| 9 #include <unordered_set> | 9 #include <unordered_set> |
| 10 | 10 |
| (...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 79 bool is_initialized_; | 79 bool is_initialized_; |
| 80 | 80 |
| 81 // Frame events might arrive from the UI thread before |ascriber_| is set. A | 81 // Frame events might arrive from the UI thread before |ascriber_| is set. A |
| 82 // queue of frame events that arrive before |ascriber_| is set is maintained | 82 // queue of frame events that arrive before |ascriber_| is set is maintained |
| 83 // in this field so that they can be propagated immediately after |ascriber_| | 83 // in this field so that they can be propagated immediately after |ascriber_| |
| 84 // is set. The RenderFrameHost pointers in the queues are valid for the | 84 // is set. The RenderFrameHost pointers in the queues are valid for the |
| 85 // duration that they are in the queue. | 85 // duration that they are in the queue. |
| 86 std::list<content::RenderFrameHost*> pending_frames_queue_; | 86 std::list<content::RenderFrameHost*> pending_frames_queue_; |
| 87 | 87 |
| 88 // WebContents visibility change events might arrive from the UI thread before | 88 // WebContents visibility change events might arrive from the UI thread before |
| 89 // |ascriber_| is set. Sucn pending main render frame visibile events are | 89 // |ascriber_| is set. Sucn pending main render frame visible events are |
| 90 // maintained in this set and propagated immediately after |ascriber_| is set. | 90 // maintained in this set and propagated immediately after |ascriber_| is set. |
| 91 std::unordered_set<content::RenderFrameHost*> pending_visible_main_frames_; | 91 std::unordered_set<content::RenderFrameHost*> pending_visible_main_frames_; |
| 92 | 92 |
| 93 DISALLOW_COPY_AND_ASSIGN(ChromeDataUseAscriberService); | 93 DISALLOW_COPY_AND_ASSIGN(ChromeDataUseAscriberService); |
| 94 }; | 94 }; |
| 95 | 95 |
| 96 } // namespace data_use_measurement | 96 } // namespace data_use_measurement |
| 97 | 97 |
| 98 #endif // CHROME_BROWSER_DATA_USE_MEASUREMENT_CHROME_DATA_USE_ASCRIBER_SERVICE_
H_ | 98 #endif // CHROME_BROWSER_DATA_USE_MEASUREMENT_CHROME_DATA_USE_ASCRIBER_SERVICE_
H_ |
| OLD | NEW |