| 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 CHROME_BROWSER_SESSIONS_SESSION_RESTORE_TEST_HELPER_H_ | 5 #ifndef CHROME_BROWSER_SESSIONS_SESSION_RESTORE_TEST_HELPER_H_ |
| 6 #define CHROME_BROWSER_SESSIONS_SESSION_RESTORE_TEST_HELPER_H_ | 6 #define CHROME_BROWSER_SESSIONS_SESSION_RESTORE_TEST_HELPER_H_ |
| 7 | 7 |
| 8 #include "base/basictypes.h" | 8 #include "base/macros.h" |
| 9 #include "base/memory/scoped_ptr.h" | 9 #include "base/memory/scoped_ptr.h" |
| 10 #include "base/memory/weak_ptr.h" | 10 #include "base/memory/weak_ptr.h" |
| 11 #include "chrome/browser/sessions/session_restore.h" | 11 #include "chrome/browser/sessions/session_restore.h" |
| 12 | 12 |
| 13 namespace content { | 13 namespace content { |
| 14 class MessageLoopRunner; | 14 class MessageLoopRunner; |
| 15 } | 15 } |
| 16 | 16 |
| 17 // This class waits on the SessionRestore notification. It is a replacement for | 17 // This class waits on the SessionRestore notification. It is a replacement for |
| 18 // content::WindowedNotificationObserver, which uses notification service. This | 18 // content::WindowedNotificationObserver, which uses notification service. This |
| (...skipping 22 matching lines...) Expand all Loading... |
| 41 // For automatically unsubscribing from callback-based notifications. | 41 // For automatically unsubscribing from callback-based notifications. |
| 42 SessionRestore::CallbackSubscription callback_subscription_; | 42 SessionRestore::CallbackSubscription callback_subscription_; |
| 43 | 43 |
| 44 // For safely binding pointers to callbacks. | 44 // For safely binding pointers to callbacks. |
| 45 base::WeakPtrFactory<SessionRestoreTestHelper> weak_ptr_factory; | 45 base::WeakPtrFactory<SessionRestoreTestHelper> weak_ptr_factory; |
| 46 | 46 |
| 47 DISALLOW_COPY_AND_ASSIGN(SessionRestoreTestHelper); | 47 DISALLOW_COPY_AND_ASSIGN(SessionRestoreTestHelper); |
| 48 }; | 48 }; |
| 49 | 49 |
| 50 #endif // CHROME_BROWSER_SESSIONS_SESSION_RESTORE_TEST_HELPER_H_ | 50 #endif // CHROME_BROWSER_SESSIONS_SESSION_RESTORE_TEST_HELPER_H_ |
| OLD | NEW |