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

Side by Side Diff: ios/chrome/browser/tabs/legacy_tab_helper.h

Issue 2681843002: Add mechanism to get the Tab from the associated WebState. (Closed)
Patch Set: Created 3 years, 10 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
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef IOS_CHROME_BROWSER_TABS_LEGACY_TAB_HELPER_H_
6 #define IOS_CHROME_BROWSER_TABS_LEGACY_TAB_HELPER_H_
7
8 #import "base/ios/weak_nsobject.h"
9 #include "base/macros.h"
10 #import "ios/web/public/web_state/web_state_user_data.h"
11
12 @class Tab;
13
14 class LegacyTabHelper : public web::WebStateUserData<LegacyTabHelper> {
rohitrao (ping after 24h) 2017/02/08 14:07:17 Class could use a comment explaining what it does
sdefresne 2017/02/08 14:45:34 Done.
15 public:
16 static void CreateForWebState(web::WebState* web_state, Tab* tab);
17
18 Tab* tab() const { return tab_.get(); }
19
20 private:
21 LegacyTabHelper(web::WebState* web_state, Tab* tab);
22 ~LegacyTabHelper() override;
23
24 base::WeakNSObject<Tab> tab_;
25
26 DISALLOW_COPY_AND_ASSIGN(LegacyTabHelper);
27 };
28
29 #endif // IOS_CHROME_BROWSER_TABS_LEGACY_TAB_HELPER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698