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

Side by Side Diff: ios/clean/chrome/browser/browser_coordinator.h

Issue 2734333003: Child coordinators notify their parent upon -start and -stop. (Closed)
Patch Set: Fix tests build (they were on the "all" target) Created 3 years, 9 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 // ====== New Architecture ===== 5 // ====== New Architecture =====
6 // = This code is only used in the new iOS Chrome architecture. = 6 // = This code is only used in the new iOS Chrome architecture. =
7 // ============================================================================ 7 // ============================================================================
8 8
9 #ifndef IOS_CLEAN_CHROME_BROWSER_BROWSER_COORDINATOR_H_ 9 #ifndef IOS_CLEAN_CHROME_BROWSER_BROWSER_COORDINATOR_H_
10 #define IOS_CLEAN_CHROME_BROWSER_BROWSER_COORDINATOR_H_ 10 #define IOS_CLEAN_CHROME_BROWSER_BROWSER_COORDINATOR_H_
(...skipping 12 matching lines...) Expand all
23 23
24 // The context object for this coordinator. 24 // The context object for this coordinator.
25 @property(nonatomic, strong, readonly) CoordinatorContext* context; 25 @property(nonatomic, strong, readonly) CoordinatorContext* context;
26 26
27 // The browser object used by this coordinator and passed into any child 27 // The browser object used by this coordinator and passed into any child
28 // coordinators added to it. This is a weak pointer, and setting this property 28 // coordinators added to it. This is a weak pointer, and setting this property
29 // doesn't transfer ownership of the browser. 29 // doesn't transfer ownership of the browser.
30 @property(nonatomic, assign) Browser* browser; 30 @property(nonatomic, assign) Browser* browser;
31 31
32 // The basic lifecycle methods for coordinators are -start and -stop. These 32 // The basic lifecycle methods for coordinators are -start and -stop. These
33 // are blank template methods; child classes are expected to implement them and 33 // implementations only notify the parent coordinator when this coordinator did
34 // do not need to invoke the superclass methods. 34 // start and will stop. Child classes are expected to override and call the
35 // superclass method at the end of -start and at the beginning of -stop.
36
35 // Starts the user interaction managed by the receiver. Typical implementations 37 // Starts the user interaction managed by the receiver. Typical implementations
36 // will create a view controller and then use |baseViewController| to present 38 // will create a view controller and then use |baseViewController| to present
37 // it. 39 // it. This method needs to be called at the end of the overriding
38 - (void)start; 40 // implementation.
41 - (void)start NS_REQUIRES_SUPER;
39 42
40 // Stops the user interaction managed by the receiver. 43 // Stops the user interaction managed by the receiver. This method needs to be
41 - (void)stop; 44 // called at the end of the overriding implementation.
rohitrao (ping after 24h) 2017/03/08 13:01:03 Called at the beginning, not the end?
lpromero 2017/03/08 13:45:41 Done.
45 - (void)stop NS_REQUIRES_SUPER;
42 46
43 @end 47 @end
44 48
45 #endif // IOS_CLEAN_CHROME_BROWSER_BROWSER_COORDINATOR_H_ 49 #endif // IOS_CLEAN_CHROME_BROWSER_BROWSER_COORDINATOR_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698