| 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_CLEAN_CHROME_BROWSER_UI_TOOLS_TOOLS_MEDIATOR_H_ | 5 #ifndef IOS_CLEAN_CHROME_BROWSER_UI_TOOLS_TOOLS_MEDIATOR_H_ |
| 6 #define IOS_CLEAN_CHROME_BROWSER_UI_TOOLS_TOOLS_MEDIATOR_H_ | 6 #define IOS_CLEAN_CHROME_BROWSER_UI_TOOLS_TOOLS_MEDIATOR_H_ |
| 7 | 7 |
| 8 #import <Foundation/Foundation.h> | 8 #import <Foundation/Foundation.h> |
| 9 | 9 |
| 10 @protocol ToolsConsumer; | 10 @protocol ToolsConsumer; |
| 11 @class ToolsMenuConfiguration; | 11 @class ToolsMenuConfiguration; |
| 12 namespace web { |
| 13 class WebState; |
| 14 } |
| 12 | 15 |
| 13 // A mediator object that sets a ToolsMenuVC appeareance based on various data | 16 // A mediator object that sets a ToolsMenuVC appeareance based on various data |
| 14 // sources. | 17 // sources. |
| 15 @interface ToolsMediator : NSObject | 18 @interface ToolsMediator : NSObject |
| 16 - (instancetype)initWithConsumer:(id<ToolsConsumer>)consumer | 19 - (nullable instancetype)initWithConsumer:(nonnull id<ToolsConsumer>)consumer |
| 17 andConfiguration:(ToolsMenuConfiguration*)menuConfiguration | 20 configuration:(nonnull ToolsMenuConfiguration*) |
| 21 menuConfiguration |
| 18 NS_DESIGNATED_INITIALIZER; | 22 NS_DESIGNATED_INITIALIZER; |
| 19 - (instancetype)init NS_UNAVAILABLE; | 23 - (nullable instancetype)init NS_UNAVAILABLE; |
| 24 |
| 25 // The WebState whose properties this object mediates. This can change during |
| 26 // the lifetime of this object and may be null. |
| 27 @property(nonatomic, assign, nullable) web::WebState* webState; |
| 20 @end | 28 @end |
| 21 | 29 |
| 22 #endif // IOS_CLEAN_CHROME_BROWSER_UI_TOOLS_TOOLS_MEDIATOR_H_ | 30 #endif // IOS_CLEAN_CHROME_BROWSER_UI_TOOLS_TOOLS_MEDIATOR_H_ |
| OLD | NEW |