remote_webauthn_delegated_state_change_notifier.h 1.1 KB

123456789101112131415161718192021222324252627282930
  1. // Copyright 2022 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. #ifndef REMOTING_HOST_WEBAUTHN_REMOTE_WEBAUTHN_DELEGATED_STATE_CHANGE_NOTIFIER_H_
  5. #define REMOTING_HOST_WEBAUTHN_REMOTE_WEBAUTHN_DELEGATED_STATE_CHANGE_NOTIFIER_H_
  6. #include "base/callback.h"
  7. #include "remoting/host/webauthn/remote_webauthn_state_change_notifier.h"
  8. namespace remoting {
  9. // A RemoteWebAuthnStateChangeNotifier implementation that simply calls
  10. // |notify_state_change| when NotifyStateChange() is called.
  11. class RemoteWebAuthnDelegatedStateChangeNotifier
  12. : public RemoteWebAuthnStateChangeNotifier {
  13. public:
  14. explicit RemoteWebAuthnDelegatedStateChangeNotifier(
  15. const base::RepeatingClosure& notify_state_change);
  16. ~RemoteWebAuthnDelegatedStateChangeNotifier() override;
  17. void NotifyStateChange() override;
  18. protected:
  19. base::RepeatingClosure notify_state_change_;
  20. };
  21. } // namespace remoting
  22. #endif // REMOTING_HOST_WEBAUTHN_REMOTE_WEBAUTHN_DELEGATED_STATE_CHANGE_NOTIFIER_H_