Index: chrome/browser/api/infobars/infobar_delegate.h |
diff --git a/chrome/browser/api/infobars/infobar_delegate.h b/chrome/browser/api/infobars/infobar_delegate.h |
index 26b2438162a6d7139d19dceedb7d1c0c198174a5..4c96cfd69ff4e805bf423f023b26b8a036e42e37 100644 |
--- a/chrome/browser/api/infobars/infobar_delegate.h |
+++ b/chrome/browser/api/infobars/infobar_delegate.h |
@@ -13,7 +13,7 @@ class AutoLoginInfoBarDelegate; |
class ConfirmInfoBarDelegate; |
class ExtensionInfoBarDelegate; |
class InfoBar; |
-class InfoBarTabHelper; |
+class InfoBarTabService; |
class InsecureContentInfoBarDelegate; |
class LinkInfoBarDelegate; |
class MediaStreamInfoBarDelegate; |
@@ -58,17 +58,14 @@ class InfoBarDelegate { |
// Called to create the InfoBar. Implementation of this method is |
// platform-specific. |
- virtual InfoBar* CreateInfoBar(InfoBarTabHelper* owner) = 0; |
- |
- // Called by the InfoBarTabHelper when it removes us. |
- void clear_owner() { owner_ = NULL; } |
+ virtual InfoBar* CreateInfoBar(InfoBarTabService* owner) = 0; |
// TODO(pkasting): Move to InfoBar once InfoBars own their delegates. |
- InfoBarTabHelper* owner() { return owner_; } |
+ InfoBarTabService* owner() { return owner_; } |
// Returns true if the supplied |delegate| is equal to this one. Equality is |
// left to the implementation to define. This function is called by the |
- // InfoBarTabHelper when determining whether or not a delegate should be |
+ // InfoBarTabService when determining whether or not a delegate should be |
// added because a matching one already exists. If this function returns true, |
// the InfoBarTabHelper will not add the new delegate because it considers |
erikwright (departed)
2012/08/16 17:25:38
Helper->Service
Jói
2012/08/17 15:51:24
Done.
|
// one to already be present. |
@@ -111,12 +108,12 @@ class InfoBarDelegate { |
protected: |
// If |contents| is non-NULL, its active entry's unique ID will be stored |
// using StoreActiveEntryUniqueID automatically. |
- explicit InfoBarDelegate(InfoBarTabHelper* infobar_helper); |
+ explicit InfoBarDelegate(InfoBarTabService* infobar_helper); |
erikwright (departed)
2012/08/16 17:25:38
rename
Jói
2012/08/17 15:51:24
Done.
|
// Store the unique id for the active entry in the specified WebContents, to |
// be used later upon navigation to determine if this InfoBarDelegate should |
// be expired from |contents_|. |
- void StoreActiveEntryUniqueID(InfoBarTabHelper* infobar_helper); |
+ void StoreActiveEntryUniqueID(InfoBarTabService* infobar_helper); |
erikwright (departed)
2012/08/16 17:25:38
rename
Jói
2012/08/17 15:51:24
Done.
|
// Direct accessors for subclasses that need to do something special. |
int contents_unique_id() const { return contents_unique_id_; } |
@@ -133,12 +130,17 @@ class InfoBarDelegate { |
void RemoveSelf(); |
private: |
+ friend class InfoBarTabHelper; |
+ |
+ // Called by the InfoBarTabHelper when it removes us. |
+ void clear_owner() { owner_ = NULL; } |
erikwright (departed)
2012/08/16 17:25:38
This implies that one could not simply write an al
Jói
2012/08/17 15:51:24
Moved it back to public. Removed the comment.
|
+ |
// The unique id of the active NavigationEntry of the WebContents that we were |
// opened for. Used to help expire on navigations. |
int contents_unique_id_; |
// TODO(pkasting): Remove. |
- InfoBarTabHelper* owner_; |
+ InfoBarTabService* owner_; |
DISALLOW_COPY_AND_ASSIGN(InfoBarDelegate); |
}; |