OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 COMPONENTS_HISTORY_CORE_TEST_WAIT_TOP_SITES_LOADED_OBSERVER_H_ | 5 #ifndef COMPONENTS_HISTORY_CORE_TEST_WAIT_TOP_SITES_LOADED_OBSERVER_H_ |
6 #define COMPONENTS_HISTORY_CORE_TEST_WAIT_TOP_SITES_LOADED_OBSERVER_H_ | 6 #define COMPONENTS_HISTORY_CORE_TEST_WAIT_TOP_SITES_LOADED_OBSERVER_H_ |
7 | 7 |
| 8 #include "base/macros.h" |
8 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
9 #include "base/run_loop.h" | 10 #include "base/run_loop.h" |
10 #include "components/history/core/browser/top_sites_observer.h" | 11 #include "components/history/core/browser/top_sites_observer.h" |
11 | 12 |
12 namespace history { | 13 namespace history { |
13 | 14 |
14 class TopSites; | 15 class TopSites; |
15 | 16 |
16 // Used to make sure TopSites has finished loading | 17 // Used to make sure TopSites has finished loading |
17 class WaitTopSitesLoadedObserver : public TopSitesObserver { | 18 class WaitTopSitesLoadedObserver : public TopSitesObserver { |
(...skipping 13 matching lines...) Expand all Loading... |
31 | 32 |
32 scoped_refptr<TopSites> top_sites_; | 33 scoped_refptr<TopSites> top_sites_; |
33 base::RunLoop run_loop_; | 34 base::RunLoop run_loop_; |
34 | 35 |
35 DISALLOW_COPY_AND_ASSIGN(WaitTopSitesLoadedObserver); | 36 DISALLOW_COPY_AND_ASSIGN(WaitTopSitesLoadedObserver); |
36 }; | 37 }; |
37 | 38 |
38 } // namespace history | 39 } // namespace history |
39 | 40 |
40 #endif // COMPONENTS_HISTORY_CORE_TEST_WAIT_TOP_SITES_LOADED_OBSERVER_H_ | 41 #endif // COMPONENTS_HISTORY_CORE_TEST_WAIT_TOP_SITES_LOADED_OBSERVER_H_ |
OLD | NEW |