Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(133)

Side by Side Diff: ios/clean/chrome/browser/ui/toolbar/toolbar_mediator.h

Issue 2908623004: [ios clean] Toolbar displays total number of tabs. (Closed)
Patch Set: Add comment. Created 3 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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_TOOLBAR_TOOLBAR_MEDIATOR_H_ 5 #ifndef IOS_CLEAN_CHROME_BROWSER_UI_TOOLBAR_TOOLBAR_MEDIATOR_H_
6 #define IOS_CLEAN_CHROME_BROWSER_UI_TOOLBAR_TOOLBAR_MEDIATOR_H_ 6 #define IOS_CLEAN_CHROME_BROWSER_UI_TOOLBAR_TOOLBAR_MEDIATOR_H_
7 7
8 #import <Foundation/Foundation.h> 8 #import <Foundation/Foundation.h>
9 9
10 #import "ios/shared/chrome/browser/ui/broadcaster/chrome_broadcast_observer.h" 10 #import "ios/shared/chrome/browser/ui/broadcaster/chrome_broadcast_observer.h"
11 11
12 @protocol ToolbarConsumer; 12 @protocol ToolbarConsumer;
13 13
14 namespace web { 14 namespace web {
15 class WebState; 15 class WebState;
16 } 16 }
17 class WebStateList;
17 18
18 // A mediator object that provides the relevant properties of a web state 19 // A mediator object that provides the relevant properties of a web state
19 // to a consumer. 20 // to a consumer.
20 @interface ToolbarMediator : NSObject<ChromeBroadcastObserver> 21 @interface ToolbarMediator : NSObject<ChromeBroadcastObserver>
21 22
22 // The WebState whose properties this object mediates. This can change during 23 // The WebState whose properties this object mediates. This can change during
23 // the lifetime of this object and may be null. 24 // the lifetime of this object and may be null.
24 @property(nonatomic, assign) web::WebState* webState; 25 @property(nonatomic, assign) web::WebState* webState;
25 26
27 // The WebStateList that this mediator listens for any changes on the total
28 // number of Webstates.
29 @property(nonatomic, assign) WebStateList* webStateList;
30
26 // The consumer for this object. This can change during the lifetime of this 31 // The consumer for this object. This can change during the lifetime of this
27 // object and may be nil. 32 // object and may be nil.
28 @property(nonatomic, strong) id<ToolbarConsumer> consumer; 33 @property(nonatomic, strong) id<ToolbarConsumer> consumer;
29 34
35 // Stops observing all objects.
36 - (void)disconnect;
37
30 @end 38 @end
31 39
32 #endif // IOS_CLEAN_CHROME_BROWSER_UI_TOOLBAR_TOOLBAR_MEDIATOR_H_ 40 #endif // IOS_CLEAN_CHROME_BROWSER_UI_TOOLBAR_TOOLBAR_MEDIATOR_H_
OLDNEW
« no previous file with comments | « ios/clean/chrome/browser/ui/toolbar/toolbar_coordinator.mm ('k') | ios/clean/chrome/browser/ui/toolbar/toolbar_mediator.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698