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

Side by Side Diff: chrome/browser/chromeos/login/html_page_screen.h

Issue 3158023: OOBE screen with HTML page specified from command line it is going to be used for recovery screen. (Closed) Base URL: http://src.chromium.org/git/chromium.git
Patch Set: Removed useless explicit Created 10 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
« no previous file with comments | « no previous file | chrome/browser/chromeos/login/html_page_screen.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_HTML_PAGE_SCREEN_H_
6 #define CHROME_BROWSER_CHROMEOS_LOGIN_HTML_PAGE_SCREEN_H_
7 #pragma once
8
9 #include <string>
10
11 #include "base/scoped_ptr.h"
12 #include "chrome/browser/chromeos/login/screen_observer.h"
13 #include "chrome/browser/chromeos/login/view_screen.h"
14 #include "chrome/browser/chromeos/login/web_page_screen.h"
15 #include "chrome/browser/chromeos/login/web_page_view.h"
16
17 class WizardScreenDelegate;
18
19 namespace chromeos {
20
21 class HTMLPageDomView : public WebPageDomView {
22 public:
23 HTMLPageDomView() {}
24
25 protected:
26 // Overriden from DOMView:
27 virtual TabContents* CreateTabContents(Profile* profile,
28 SiteInstance* instance);
29
30 private:
31 DISALLOW_COPY_AND_ASSIGN(HTMLPageDomView);
32 };
33
34 class HTMLPageView : public WebPageView {
35 public:
36 HTMLPageView();
37
38 protected:
39 virtual WebPageDomView* dom_view() { return dom_view_; }
40
41 private:
42 // View that renders page.
43 HTMLPageDomView* dom_view_;
44
45 DISALLOW_COPY_AND_ASSIGN(HTMLPageView);
46 };
47
48 // HTMLPageScreen is used to show arbitrary HTML page. It is used to show
49 // simple screens like recover.
50 class HTMLPageScreen : public ViewScreen<HTMLPageView>,
51 public WebPageScreen,
52 public WebPageDelegate {
53 public:
54 HTMLPageScreen(WizardScreenDelegate* delegate, const std::string& url);
55
56 // WebPageDelegate implementation:
57 virtual void OnPageLoaded();
58 virtual void OnPageLoadFailed(const std::string& url);
59
60 private:
61 // ViewScreen implementation:
62 virtual void CreateView();
63 virtual void Refresh();
64 virtual HTMLPageView* AllocateView();
65
66 virtual void LoadingStateChanged(TabContents* source);
67 virtual void NavigationStateChanged(const TabContents* source,
68 unsigned changed_flags);
69 virtual void HandleKeyboardEvent(const NativeWebKeyboardEvent& event);
70
71 // WebPageScreen implementation:
72 virtual void CloseScreen(ScreenObserver::ExitCodes code);
73
74 // URL to navigate.
75 std::string url_;
76
77 DISALLOW_COPY_AND_ASSIGN(HTMLPageScreen);
78 };
79
80 } // namespace chromeos
81
82 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_HTML_PAGE_SCREEN_H_
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/chromeos/login/html_page_screen.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698