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

Side by Side Diff: chrome/browser/ui/extensions/app_metro_infobar_delegate_win.h

Issue 22992003: Moved chrome/browser/ui/extensions apps code to chrome/browser/ui/apps (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Win compile Created 7 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
OLDNEW
(Empty)
1 // Copyright 2013 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 CHROME_BROWSER_UI_EXTENSIONS_APP_METRO_INFOBAR_DELEGATE_WIN_H_
6 #define CHROME_BROWSER_UI_EXTENSIONS_APP_METRO_INFOBAR_DELEGATE_WIN_H_
7
8 #include <string>
9
10 #include "chrome/browser/infobars/confirm_infobar_delegate.h"
11
12 class InfoBarService;
13 class Profile;
14
15 // This infobar operates by opening a new tab on about:blank, showing an
16 // infobar offering to relaunch the browser in metro mode, and then relaunching
17 // in Desktop mode if confirmed.
18 class AppMetroInfoBarDelegateWin : public ConfirmInfoBarDelegate {
19 public:
20 enum Mode {
21 SHOW_APP_LIST,
22 LAUNCH_PACKAGED_APP
23 };
24
25 // Creates an app metro infobar delegate, adds it to a new browser tab, then
26 // activates Metro mode.
27 static void Create(Profile* profile,
28 Mode mode,
29 const std::string& extension_id);
30
31 private:
32 AppMetroInfoBarDelegateWin(InfoBarService* infobar_service,
33 Mode mode,
34 const std::string& extension_id);
35 virtual ~AppMetroInfoBarDelegateWin();
36
37 // ConfirmInfoBarDelegate overrides:
38 virtual int GetIconID() const OVERRIDE;
39 virtual string16 GetMessageText() const OVERRIDE;
40 virtual string16 GetButtonLabel(InfoBarButton button) const OVERRIDE;
41 virtual bool Accept() OVERRIDE;
42 virtual bool Cancel() OVERRIDE;
43 virtual string16 GetLinkText() const OVERRIDE;
44 virtual bool LinkClicked(WindowOpenDisposition disposition) OVERRIDE;
45
46 Mode mode_;
47 std::string extension_id_;
48
49 DISALLOW_COPY_AND_ASSIGN(AppMetroInfoBarDelegateWin);
50 };
51
52 #endif // CHROME_BROWSER_UI_EXTENSIONS_APP_METRO_INFOBAR_DELEGATE_WIN_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/browser_command_controller.cc ('k') | chrome/browser/ui/extensions/app_metro_infobar_delegate_win.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698