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

Side by Side Diff: chrome/browser/ui/cocoa/infobars/mock_confirm_infobar_delegate.h

Issue 1520543004: Add method for identifying different InfoBars (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Nit again Created 4 years, 11 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 (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 CHROME_BROWSER_UI_COCOA_INFOBARS_MOCK_CONFIRM_INFOBAR_DELEGATE_H_ 5 #ifndef CHROME_BROWSER_UI_COCOA_INFOBARS_MOCK_CONFIRM_INFOBAR_DELEGATE_H_
6 #define CHROME_BROWSER_UI_COCOA_INFOBARS_MOCK_CONFIRM_INFOBAR_DELEGATE_H_ 6 #define CHROME_BROWSER_UI_COCOA_INFOBARS_MOCK_CONFIRM_INFOBAR_DELEGATE_H_
7 7
8 #include "base/compiler_specific.h" 8 #include "base/compiler_specific.h"
9 #include "base/macros.h" 9 #include "base/macros.h"
10 #include "base/strings/string16.h" 10 #include "base/strings/string16.h"
(...skipping 19 matching lines...) Expand all
30 bool message_text_accessed() const { return message_text_accessed_; } 30 bool message_text_accessed() const { return message_text_accessed_; }
31 bool link_text_accessed() const { return link_text_accessed_; } 31 bool link_text_accessed() const { return link_text_accessed_; }
32 bool ok_clicked() const { return ok_clicked_; } 32 bool ok_clicked() const { return ok_clicked_; }
33 bool cancel_clicked() const { return cancel_clicked_; } 33 bool cancel_clicked() const { return cancel_clicked_; }
34 bool link_clicked() const { return link_clicked_; } 34 bool link_clicked() const { return link_clicked_; }
35 35
36 static const char kMessage[]; 36 static const char kMessage[];
37 37
38 private: 38 private:
39 // ConfirmInfoBarDelegate: 39 // ConfirmInfoBarDelegate:
40 infobars::InfoBarDelegate::InfoBarIdentifier GetIdentifier() const override;
40 int GetIconId() const override; 41 int GetIconId() const override;
41 base::string16 GetMessageText() const override; 42 base::string16 GetMessageText() const override;
42 base::string16 GetButtonLabel(InfoBarButton button) const override; 43 base::string16 GetButtonLabel(InfoBarButton button) const override;
43 bool Accept() override; 44 bool Accept() override;
44 bool Cancel() override; 45 bool Cancel() override;
45 base::string16 GetLinkText() const override; 46 base::string16 GetLinkText() const override;
46 bool LinkClicked(WindowOpenDisposition disposition) override; 47 bool LinkClicked(WindowOpenDisposition disposition) override;
47 48
48 Owner* owner_; 49 Owner* owner_;
49 // Determines whether the infobar closes when an action is taken or not. 50 // Determines whether the infobar closes when an action is taken or not.
50 bool closes_on_action_; 51 bool closes_on_action_;
51 mutable bool icon_accessed_; 52 mutable bool icon_accessed_;
52 mutable bool message_text_accessed_; 53 mutable bool message_text_accessed_;
53 mutable bool link_text_accessed_; 54 mutable bool link_text_accessed_;
54 bool ok_clicked_; 55 bool ok_clicked_;
55 bool cancel_clicked_; 56 bool cancel_clicked_;
56 bool link_clicked_; 57 bool link_clicked_;
57 58
58 DISALLOW_COPY_AND_ASSIGN(MockConfirmInfoBarDelegate); 59 DISALLOW_COPY_AND_ASSIGN(MockConfirmInfoBarDelegate);
59 }; 60 };
60 61
61 #endif // CHROME_BROWSER_UI_COCOA_INFOBARS_MOCK_CONFIRM_INFOBAR_DELEGATE_H_ 62 #endif // CHROME_BROWSER_UI_COCOA_INFOBARS_MOCK_CONFIRM_INFOBAR_DELEGATE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698