blob: 411906b6e32e8253d113f8df92b774c8a9bc5711 [file] [log] [blame]
// Copyright 2022 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#include "chrome/browser/ui/views/webid/fake_delegate.h"
namespace webid {
FakeDelegate::FakeDelegate(content::WebContents* web_contents)
: web_contents_(web_contents) {}
FakeDelegate::~FakeDelegate() = default;
void FakeDelegate::OnAccountSelected(
const GURL& idp_config_url,
const std::string& account_id,
const content::IdentityRequestAccount::LoginState& login_state) {
if (account_selected_cb_) {
std::move(account_selected_cb_).Run();
}
}
gfx::NativeView FakeDelegate::GetNativeView() {
return gfx::NativeView();
}
content::WebContents* FakeDelegate::GetWebContents() {
return web_contents_;
}
} // namespace webid