Upstreaming browser/ui/uikit_ui_util from iOS.
[chromium-blink-merge.git] / chromecast / net / fake_connectivity_checker.cc
blobfc3caed6ae3e9396a796c2659150d7e84f1ec253
1 // Copyright 2015 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.
5 #include "chromecast/net/fake_connectivity_checker.h"
7 namespace chromecast {
9 FakeConnectivityChecker::FakeConnectivityChecker()
10 : ConnectivityChecker(),
11 connected_(true) {
14 FakeConnectivityChecker::~FakeConnectivityChecker() {}
16 bool FakeConnectivityChecker::Connected() const {
17 return connected_;
20 void FakeConnectivityChecker::Check() {
23 void FakeConnectivityChecker::SetConnectedForTest(bool connected) {
24 if (connected_ == connected)
25 return;
27 connected_ = connected;
28 Notify(connected);
31 } // namespace chromecast