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

Unified Diff: chrome/browser/captive_portal/captive_portal_tab_reloader.cc

Issue 242483003: Move CaptivePortalDetector to src/components/captive_portal (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 6 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/captive_portal/captive_portal_tab_reloader.cc
diff --git a/chrome/browser/captive_portal/captive_portal_tab_reloader.cc b/chrome/browser/captive_portal/captive_portal_tab_reloader.cc
index f77caea95cfb61436eac33cf5e8d35031925fcf9..9df405e0edfad6d1f0d9c664a630d8297d07442c 100644
--- a/chrome/browser/captive_portal/captive_portal_tab_reloader.cc
+++ b/chrome/browser/captive_portal/captive_portal_tab_reloader.cc
@@ -15,7 +15,7 @@
#include "content/public/browser/web_contents.h"
#include "net/base/net_errors.h"
-namespace captive_portal {
+using captive_portal::CaptivePortalResult;
namespace {
@@ -127,9 +127,9 @@ void CaptivePortalTabReloader::OnRedirect(bool is_ssl) {
}
void CaptivePortalTabReloader::OnCaptivePortalResults(
- Result previous_result,
- Result result) {
- if (result == RESULT_BEHIND_CAPTIVE_PORTAL) {
+ CaptivePortalResult previous_result,
+ CaptivePortalResult result) {
+ if (result == captive_portal::RESULT_BEHIND_CAPTIVE_PORTAL) {
if (state_ == STATE_MAYBE_BROKEN_BY_PORTAL) {
SetState(STATE_BROKEN_BY_PORTAL);
MaybeOpenCaptivePortalLoginTab();
@@ -146,7 +146,7 @@ void CaptivePortalTabReloader::OnCaptivePortalResults(
// page, so if the page ends up at an error caused by a captive portal, it
// will be reloaded. If not, the state will just be reset. The helps in
// the case that a user tries to reload a tab, and then quickly logs in.
- if (previous_result == RESULT_BEHIND_CAPTIVE_PORTAL) {
+ if (previous_result == captive_portal::RESULT_BEHIND_CAPTIVE_PORTAL) {
SetState(STATE_NEEDS_RELOAD);
return;
}
@@ -279,5 +279,3 @@ void CaptivePortalTabReloader::CheckForCaptivePortal() {
if (service)
service->DetectCaptivePortal();
}
-
-} // namespace captive_portal

Powered by Google App Engine
This is Rietveld 408576698