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

Side by Side Diff: chrome/browser/views/infobars/infobars.h

Issue 1037006: Finish implementing the geolocation infobar; adds a Learn more link pointing ... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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_VIEWS_INFOBARS_INFOBARS_H_ 5 #ifndef CHROME_BROWSER_VIEWS_INFOBARS_INFOBARS_H_
6 #define CHROME_BROWSER_VIEWS_INFOBARS_INFOBARS_H_ 6 #define CHROME_BROWSER_VIEWS_INFOBARS_INFOBARS_H_
7 7
8 #include "app/animation.h" 8 #include "app/animation.h"
9 #include "chrome/browser/tab_contents/infobar_delegate.h" 9 #include "chrome/browser/tab_contents/infobar_delegate.h"
10 #include "views/controls/button/button.h" 10 #include "views/controls/button/button.h"
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after
179 LinkInfoBarDelegate* GetDelegate(); 179 LinkInfoBarDelegate* GetDelegate();
180 180
181 views::ImageView* icon_; 181 views::ImageView* icon_;
182 views::Label* label_1_; 182 views::Label* label_1_;
183 views::Label* label_2_; 183 views::Label* label_2_;
184 views::Link* link_; 184 views::Link* link_;
185 185
186 DISALLOW_COPY_AND_ASSIGN(LinkInfoBar); 186 DISALLOW_COPY_AND_ASSIGN(LinkInfoBar);
187 }; 187 };
188 188
189 class ConfirmInfoBar : public AlertInfoBar { 189 class ConfirmInfoBar : public AlertInfoBar,
190 public views::LinkController {
190 public: 191 public:
191 explicit ConfirmInfoBar(ConfirmInfoBarDelegate* delegate); 192 explicit ConfirmInfoBar(ConfirmInfoBarDelegate* delegate);
192 virtual ~ConfirmInfoBar(); 193 virtual ~ConfirmInfoBar();
193 194
195 // Overridden from views::LinkController:
196 virtual void LinkActivated(views::Link* source, int event_flags);
197
194 // Overridden from views::View: 198 // Overridden from views::View:
195 virtual void Layout(); 199 virtual void Layout();
196 200
197 protected: 201 protected:
198 // Overridden from views::View: 202 // Overridden from views::View:
199 virtual void ViewHierarchyChanged(bool is_add, 203 virtual void ViewHierarchyChanged(bool is_add,
200 views::View* parent, 204 views::View* parent,
201 views::View* child); 205 views::View* child);
202 206
203 // Overridden from views::ButtonListener: 207 // Overridden from views::ButtonListener:
204 virtual void ButtonPressed(views::Button* sender, const views::Event& event); 208 virtual void ButtonPressed(views::Button* sender, const views::Event& event);
205 209
206 // Overridden from InfoBar: 210 // Overridden from InfoBar:
207 virtual int GetAvailableWidth() const; 211 virtual int GetAvailableWidth() const;
208 212
209 private: 213 private:
210 void Init(); 214 void Init();
211 215
212 ConfirmInfoBarDelegate* GetDelegate(); 216 ConfirmInfoBarDelegate* GetDelegate();
213 217
214 views::NativeButton* ok_button_; 218 views::NativeButton* ok_button_;
215 views::NativeButton* cancel_button_; 219 views::NativeButton* cancel_button_;
220 views::Link* link_;
216 221
217 bool initialized_; 222 bool initialized_;
218 223
219 DISALLOW_COPY_AND_ASSIGN(ConfirmInfoBar); 224 DISALLOW_COPY_AND_ASSIGN(ConfirmInfoBar);
220 }; 225 };
221 226
222 227
223 #endif // CHROME_BROWSER_VIEWS_INFOBARS_INFOBARS_H_ 228 #endif // CHROME_BROWSER_VIEWS_INFOBARS_INFOBARS_H_
OLDNEW
« no previous file with comments | « chrome/browser/tab_contents/infobar_delegate.h ('k') | chrome/browser/views/infobars/infobars.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698