| OLD | NEW |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 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 IOS_SHARED_CHROME_BROWSER_TABS_WEB_STATE_LIST_OBSERVER_H_ | 5 #ifndef IOS_SHARED_CHROME_BROWSER_TABS_WEB_STATE_LIST_OBSERVER_H_ |
| 6 #define IOS_SHARED_CHROME_BROWSER_TABS_WEB_STATE_LIST_OBSERVER_H_ | 6 #define IOS_SHARED_CHROME_BROWSER_TABS_WEB_STATE_LIST_OBSERVER_H_ |
| 7 | 7 |
| 8 #include "base/macros.h" | 8 #include "base/macros.h" |
| 9 | 9 |
| 10 class WebStateList; | 10 class WebStateList; |
| (...skipping 27 matching lines...) Expand all Loading... |
| 38 web::WebState* old_web_state, | 38 web::WebState* old_web_state, |
| 39 web::WebState* new_web_state, | 39 web::WebState* new_web_state, |
| 40 int index); | 40 int index); |
| 41 | 41 |
| 42 // Invoked after the WebState at the specified index has been detached. The | 42 // Invoked after the WebState at the specified index has been detached. The |
| 43 // WebState is still valid but is no longer in the WebStateList. | 43 // WebState is still valid but is no longer in the WebStateList. |
| 44 virtual void WebStateDetachedAt(WebStateList* web_state_list, | 44 virtual void WebStateDetachedAt(WebStateList* web_state_list, |
| 45 web::WebState* web_state, | 45 web::WebState* web_state, |
| 46 int index); | 46 int index); |
| 47 | 47 |
| 48 // Invoked after |new_web_state| was activated at the specified index. Both |
| 49 // WebState are either valid or null (if there was no selection or there is |
| 50 // no selection). If the change is due to an user action, |user_action| will |
| 51 // be true. |
| 52 virtual void WebStateActivatedAt(WebStateList* web_state_list, |
| 53 web::WebState* old_web_state, |
| 54 web::WebState* new_web_state, |
| 55 int active_index, |
| 56 bool user_action); |
| 57 |
| 48 private: | 58 private: |
| 49 DISALLOW_COPY_AND_ASSIGN(WebStateListObserver); | 59 DISALLOW_COPY_AND_ASSIGN(WebStateListObserver); |
| 50 }; | 60 }; |
| 51 | 61 |
| 52 #endif // IOS_SHARED_CHROME_BROWSER_TABS_WEB_STATE_LIST_OBSERVER_H_ | 62 #endif // IOS_SHARED_CHROME_BROWSER_TABS_WEB_STATE_LIST_OBSERVER_H_ |
| OLD | NEW |