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

Side by Side Diff: components/offline_pages/background/connection_notifier.h

Issue 2546433004: [OfflinePages] Restarts immediate processing if stopped due to no net (Closed)
Patch Set: Created 4 years 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
(Empty)
1 // Copyright 2016 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 COMPONENTS_OFFLINE_PAGES_BACKGROUND_CONNECTION_NOTIFIER_H_
Pete Williamson 2016/12/01 01:34:08 I think I recall you saying something about NQE al
dougarnett 2016/12/01 19:25:22 I think there is no difference for what this class
6 #define COMPONENTS_OFFLINE_PAGES_BACKGROUND_CONNECTION_NOTIFIER_H_
7
8 #include "base/callback.h"
9 #include "net/base/network_change_notifier.h"
10
11 namespace offline_pages {
12
13 class ConnectionNotifier
14 : public net::NetworkChangeNotifier::ConnectionTypeObserver {
15 public:
16 // Callback to call when we become connected.
17 typedef base::Callback<void()> ConnectedCallback;
18
19 ConnectionNotifier(const ConnectionNotifier::ConnectedCallback& callback);
20 ~ConnectionNotifier() override;
21
22 private:
23 // net::NetworkChangeNotifier::ConnectionTypeObserver implementation.
24 void OnConnectionTypeChanged(
25 net::NetworkChangeNotifier::ConnectionType type) override;
26
27 base::Callback<void()> callback_;
28
29 DISALLOW_COPY_AND_ASSIGN(ConnectionNotifier);
30 };
31
32 } // namespace offline_pages
33
34 #endif // COMPONENTS_OFFLINE_PAGES_BACKGROUND_CONNECTION_NOTIFIER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698