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

Side by Side Diff: chrome/browser/chromeos/offline/offline_load_page.h

Issue 10375021: Move Extension into extensions namespace (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Take 6 Created 8 years, 7 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) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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_CHROMEOS_OFFLINE_OFFLINE_LOAD_PAGE_H_ 5 #ifndef CHROME_BROWSER_CHROMEOS_OFFLINE_OFFLINE_LOAD_PAGE_H_
6 #define CHROME_BROWSER_CHROMEOS_OFFLINE_OFFLINE_LOAD_PAGE_H_ 6 #define CHROME_BROWSER_CHROMEOS_OFFLINE_OFFLINE_LOAD_PAGE_H_
7 #pragma once 7 #pragma once
8 8
9 #include <string> 9 #include <string>
10 10
11 #include "base/callback.h" 11 #include "base/callback.h"
12 #include "base/compiler_specific.h" 12 #include "base/compiler_specific.h"
13 #include "content/public/browser/interstitial_page_delegate.h" 13 #include "content/public/browser/interstitial_page_delegate.h"
14 #include "googleurl/src/gurl.h" 14 #include "googleurl/src/gurl.h"
15 #include "net/base/network_change_notifier.h" 15 #include "net/base/network_change_notifier.h"
16 16
17 class Extension;
18
19 namespace base { 17 namespace base {
20 class DictionaryValue; 18 class DictionaryValue;
21 } 19 }
22 20
23 namespace content { 21 namespace content {
24 class InterstitialPage; 22 class InterstitialPage;
25 class WebContents; 23 class WebContents;
26 } 24 }
27 25
26 namespace extensions {
27 class Extension;
28 }
29
28 namespace chromeos { 30 namespace chromeos {
29 31
30 // OfflineLoadPage class shows the interstitial page that is shown 32 // OfflineLoadPage class shows the interstitial page that is shown
31 // when no network is available and hides when some network (either 33 // when no network is available and hides when some network (either
32 // one of wifi, 3g or ethernet) becomes available. 34 // one of wifi, 3g or ethernet) becomes available.
33 // It deletes itself when the interstitial page is closed. 35 // It deletes itself when the interstitial page is closed.
34 class OfflineLoadPage : public content::InterstitialPageDelegate, 36 class OfflineLoadPage : public content::InterstitialPageDelegate,
35 public net::NetworkChangeNotifier::OnlineStateObserver { 37 public net::NetworkChangeNotifier::OnlineStateObserver {
36 public: 38 public:
37 // Passed a boolean indicating whether or not it is OK to proceed with the 39 // Passed a boolean indicating whether or not it is OK to proceed with the
(...skipping 22 matching lines...) Expand all
60 virtual void OverrideRendererPrefs( 62 virtual void OverrideRendererPrefs(
61 content::RendererPreferences* prefs) OVERRIDE; 63 content::RendererPreferences* prefs) OVERRIDE;
62 virtual void OnProceed() OVERRIDE; 64 virtual void OnProceed() OVERRIDE;
63 virtual void OnDontProceed() OVERRIDE; 65 virtual void OnDontProceed() OVERRIDE;
64 66
65 // net::NetworkChangeNotifier::OnlineStateObserver overrides. 67 // net::NetworkChangeNotifier::OnlineStateObserver overrides.
66 virtual void OnOnlineStateChanged(bool online) OVERRIDE; 68 virtual void OnOnlineStateChanged(bool online) OVERRIDE;
67 69
68 // Retrieves template strings of the offline page for app and 70 // Retrieves template strings of the offline page for app and
69 // normal site. 71 // normal site.
70 void GetAppOfflineStrings(const Extension* app, 72 void GetAppOfflineStrings(const extensions::Extension* app,
71 const string16& faield_url, 73 const string16& faield_url,
72 base::DictionaryValue* strings) const; 74 base::DictionaryValue* strings) const;
73 void GetNormalOfflineStrings(const string16& faield_url, 75 void GetNormalOfflineStrings(const string16& faield_url,
74 base::DictionaryValue* strings) const; 76 base::DictionaryValue* strings) const;
75 77
76 // True if there is a mobile network is available but 78 // True if there is a mobile network is available but
77 // has not been activated. 79 // has not been activated.
78 bool ShowActivationMessage(); 80 bool ShowActivationMessage();
79 81
80 CompletionCallback callback_; 82 CompletionCallback callback_;
81 83
82 // True if the proceed is chosen. 84 // True if the proceed is chosen.
83 bool proceeded_; 85 bool proceeded_;
84 86
85 content::WebContents* web_contents_; 87 content::WebContents* web_contents_;
86 GURL url_; 88 GURL url_;
87 content::InterstitialPage* interstitial_page_; // Owns us. 89 content::InterstitialPage* interstitial_page_; // Owns us.
88 90
89 DISALLOW_COPY_AND_ASSIGN(OfflineLoadPage); 91 DISALLOW_COPY_AND_ASSIGN(OfflineLoadPage);
90 }; 92 };
91 93
92 } // namespace chromeos 94 } // namespace chromeos
93 95
94 #endif // CHROME_BROWSER_CHROMEOS_OFFLINE_OFFLINE_LOAD_PAGE_H_ 96 #endif // CHROME_BROWSER_CHROMEOS_OFFLINE_OFFLINE_LOAD_PAGE_H_
OLDNEW
« no previous file with comments | « chrome/browser/chromeos/kiosk_mode/kiosk_mode_screensaver.cc ('k') | chrome/browser/chromeos/offline/offline_load_page.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698