OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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_TEST_THREAD_OBSERVER_HELPER_H__ | 5 #ifndef CHROME_TEST_BASE_THREAD_OBSERVER_HELPER_H_ |
6 #define CHROME_TEST_THREAD_OBSERVER_HELPER_H__ | 6 #define CHROME_TEST_BASE_THREAD_OBSERVER_HELPER_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
10 #include "base/synchronization/waitable_event.h" | 10 #include "base/synchronization/waitable_event.h" |
11 #include "content/browser/browser_thread.h" | 11 #include "content/browser/browser_thread.h" |
12 #include "content/common/notification_observer_mock.h" | 12 #include "content/common/notification_observer_mock.h" |
13 #include "content/common/notification_registrar.h" | 13 #include "content/common/notification_registrar.h" |
14 | 14 |
15 // Helper class to add and remove observers on a non-UI thread from | 15 // Helper class to add and remove observers on a non-UI thread from |
16 // the UI thread. | 16 // the UI thread. |
(...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
60 class DBThreadObserverHelper; | 60 class DBThreadObserverHelper; |
61 typedef ThreadObserverHelper< | 61 typedef ThreadObserverHelper< |
62 DBThreadObserverHelper, | 62 DBThreadObserverHelper, |
63 BrowserThread::DeleteOnDBThread> DBThreadObserverHelperBase; | 63 BrowserThread::DeleteOnDBThread> DBThreadObserverHelperBase; |
64 | 64 |
65 class DBThreadObserverHelper : public DBThreadObserverHelperBase { | 65 class DBThreadObserverHelper : public DBThreadObserverHelperBase { |
66 public: | 66 public: |
67 DBThreadObserverHelper() : DBThreadObserverHelperBase(BrowserThread::DB) {} | 67 DBThreadObserverHelper() : DBThreadObserverHelperBase(BrowserThread::DB) {} |
68 }; | 68 }; |
69 | 69 |
70 #endif // CHROME_TEST_THREAD_OBSERVER_HELPER_H__ | 70 #endif // CHROME_TEST_BASE_THREAD_OBSERVER_HELPER_H_ |
OLD | NEW |