Index: ios/chrome/browser/tabs/tab_parenting_observer.h |
diff --git a/ios/chrome/browser/tabs/tab_parenting_observer.h b/ios/chrome/browser/tabs/tab_parenting_observer.h |
new file mode 100644 |
index 0000000000000000000000000000000000000000..acb47dc860a5519acd478125552e9fe3bd44dd75 |
--- /dev/null |
+++ b/ios/chrome/browser/tabs/tab_parenting_observer.h |
@@ -0,0 +1,36 @@ |
+// Copyright 2017 The Chromium Authors. All rights reserved. |
+// Use of this source code is governed by a BSD-style license that can be |
+// found in the LICENSE file. |
+ |
+#ifndef IOS_CHROME_BROWSER_TABS_TAB_PARENTING_OBSERVER_H_ |
+#define IOS_CHROME_BROWSER_TABS_TAB_PARENTING_OBSERVER_H_ |
+ |
+#include "base/macros.h" |
+#import "ios/shared/chrome/browser/tabs/web_state_list_observer.h" |
+ |
+class TabParentingObserver : public WebStateListObserver { |
+ public: |
+ TabParentingObserver(); |
+ ~TabParentingObserver() override; |
+ |
+ // WebStateListObserver implementation. |
+ void WebStateInsertedAt(WebStateList* web_state_list, |
+ web::WebState* web_state, |
+ int index) override; |
+ void WebStateMoved(WebStateList* web_state_list, |
+ web::WebState* web_state, |
+ int from_index, |
+ int to_index) override; |
+ void WebStateReplacedAt(WebStateList* web_state_list, |
+ web::WebState* old_web_state, |
+ web::WebState* new_web_state, |
+ int index) override; |
+ void WebStateDetachedAt(WebStateList* web_state_list, |
+ web::WebState* web_state, |
+ int index) override; |
+ |
+ private: |
+ DISALLOW_COPY_AND_ASSIGN(TabParentingObserver); |
+}; |
+ |
+#endif // IOS_CHROME_BROWSER_TABS_TAB_PARENTING_OBSERVER_H_ |