2020-08-20 00:25:42 +02:00
|
|
|
// Copyright (c) 2013 The Chromium Embedded Framework Authors. All rights
|
|
|
|
// reserved. Use of this source code is governed by a BSD-style license that
|
|
|
|
// can be found in the LICENSE file.
|
|
|
|
|
|
|
|
#ifndef CEF_TESTS_CEFTESTS_TRACK_CALLBACK_H_
|
|
|
|
#define CEF_TESTS_CEFTESTS_TRACK_CALLBACK_H_
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
class TrackCallback {
|
|
|
|
public:
|
2024-01-20 18:00:09 +01:00
|
|
|
TrackCallback() = default;
|
2020-08-20 00:25:42 +02:00
|
|
|
void yes() { gotit_ = true; }
|
|
|
|
bool isSet() { return gotit_; }
|
|
|
|
void reset() { gotit_ = false; }
|
2024-01-20 18:00:09 +01:00
|
|
|
|
|
|
|
// Code relies on this not being marked explicit. NOLINTNEXTLINE
|
2020-08-20 00:25:42 +02:00
|
|
|
operator bool() const { return gotit_; }
|
|
|
|
|
|
|
|
protected:
|
2024-01-20 18:00:09 +01:00
|
|
|
bool gotit_ = false;
|
2020-08-20 00:25:42 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
#endif // CEF_TESTS_CEFTESTS_TRACK_CALLBACK_H_
|