refactor: Chromium code style for enum classes (#26165)

This commit is contained in:
Milan Burda 2020-10-27 18:51:45 +01:00 committed by GitHub
parent dbf2931f0e
commit 1c99a9b425
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
34 changed files with 300 additions and 295 deletions

View file

@ -380,15 +380,15 @@ void ProxyingWebSocket::OnAuthRequiredComplete(AuthRequiredResponse rv) {
CHECK(auth_required_callback_);
ResumeIncomingMethodCallProcessing();
switch (rv) {
case AuthRequiredResponse::AUTH_REQUIRED_RESPONSE_NO_ACTION:
case AuthRequiredResponse::AUTH_REQUIRED_RESPONSE_CANCEL_AUTH:
case AuthRequiredResponse::kNoAction:
case AuthRequiredResponse::kCancelAuth:
std::move(auth_required_callback_).Run(base::nullopt);
break;
case AuthRequiredResponse::AUTH_REQUIRED_RESPONSE_SET_AUTH:
case AuthRequiredResponse::kSetAuth:
std::move(auth_required_callback_).Run(auth_credentials_);
break;
case AuthRequiredResponse::AUTH_REQUIRED_RESPONSE_IO_PENDING:
case AuthRequiredResponse::kIoPending:
NOTREACHED();
break;
}
@ -406,7 +406,7 @@ void ProxyingWebSocket::OnHeadersReceivedCompleteForAuth(
auto continuation = base::BindRepeating(
&ProxyingWebSocket::OnAuthRequiredComplete, weak_factory_.GetWeakPtr());
auto auth_rv = AuthRequiredResponse::AUTH_REQUIRED_RESPONSE_IO_PENDING;
auto auth_rv = AuthRequiredResponse::kIoPending;
PauseIncomingMethodCallProcessing();
OnAuthRequiredComplete(auth_rv);