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

Side by Side Diff: chrome/browser/extensions/theme_preview_infobar_delegate.h

Issue 165373: Merge 23055 - Make the theme install infobar have an 'undo' button instead... (Closed) Base URL: svn://chrome-svn/chrome/branches/195/src/
Patch Set: Created 11 years, 4 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
Property Changes:
Modified: svn:mergeinfo
Merged /trunk/src/chrome/browser/extensions/theme_preview_infobar_delegate.h:r23055
OLDNEW
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2009 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_EXTENSIONS_THEME_PREVIEW_INFOBAR_DELEGATE_H_ 5 #ifndef CHROME_BROWSER_VIEWS_EXTENSIONS_THEME_PREVIEW_INFOBAR_DELEGATE_H_
6 #define CHROME_BROWSER_VIEWS_EXTENSIONS_THEME_PREVIEW_INFOBAR_DELEGATE_H_ 6 #define CHROME_BROWSER_VIEWS_EXTENSIONS_THEME_PREVIEW_INFOBAR_DELEGATE_H_
7 7
8 #include "chrome/browser/tab_contents/infobar_delegate.h" 8 #include "chrome/browser/tab_contents/infobar_delegate.h"
9 9
10 class Extension;
11 class ExtensionsService;
12 class SkBitmap; 10 class SkBitmap;
13 class TabContents; 11 class TabContents;
14 12
15 // When a user installs a theme, we display it immediately, but provide an 13 // When a user installs a theme, we display it immediately, but provide an
16 // infobar allowing them to cancel. 14 // infobar allowing them to cancel.
17 // 15 //
18 // TODO(aa): Rename this to ThemeInstalledInfoBarDelegate, since it isn't 16 // TODO(aa): Rename this to ThemeInstalledInfoBarDelegate, since it isn't
19 // used for previewing anymore. 17 // used for previewing anymore.
20 class ThemePreviewInfobarDelegate : public ConfirmInfoBarDelegate { 18 class ThemePreviewInfobarDelegate : public ConfirmInfoBarDelegate {
21 public: 19 public:
22 ThemePreviewInfobarDelegate(TabContents* tab_contents, 20 ThemePreviewInfobarDelegate(TabContents* tab_contents,
23 const std::string& name); 21 const std::string& name,
22 const std::string& previous_theme);
24 virtual void InfoBarClosed(); 23 virtual void InfoBarClosed();
25 virtual std::wstring GetMessageText() const; 24 virtual std::wstring GetMessageText() const;
26 virtual SkBitmap* GetIcon() const; 25 virtual SkBitmap* GetIcon() const;
27 virtual ThemePreviewInfobarDelegate* AsThemePreviewInfobarDelegate(); 26 virtual ThemePreviewInfobarDelegate* AsThemePreviewInfobarDelegate();
28 virtual int GetButtons() const; 27 virtual int GetButtons() const;
29 virtual std::wstring GetButtonLabel( 28 virtual std::wstring GetButtonLabel(
30 ConfirmInfoBarDelegate::InfoBarButton button) const; 29 ConfirmInfoBarDelegate::InfoBarButton button) const;
31 virtual bool Cancel(); 30 virtual bool Cancel();
32 31
33 private: 32 private:
34 Profile* profile_; 33 Profile* profile_;
35 std::string name_; // name of theme to install 34 std::string name_; // name of theme to install
35 std::string previous_theme_id_; // used to undo theme install
36 }; 36 };
37 37
38 #endif // CHROME_BROWSER_VIEWS_EXTENSIONS_THEME_PREVIEW_INFOBAR_DELEGATE_H_ 38 #endif // CHROME_BROWSER_VIEWS_EXTENSIONS_THEME_PREVIEW_INFOBAR_DELEGATE_H_
OLDNEW
« no previous file with comments | « chrome/browser/extensions/extension_install_ui.cc ('k') | chrome/browser/extensions/theme_preview_infobar_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698