This repository has been archived on 2024-03-23. You can view files and clone it, but cannot push or open issues or pull requests.
2019-01-08 04:16:01 +00:00
|
|
|
// Copyright 2019 yuzu Emulator Project
|
|
|
|
// Licensed under GPLv2 or any later version
|
|
|
|
// Refer to the license.txt file included.
|
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include "common/common_types.h"
|
|
|
|
|
|
|
|
namespace Core::Frontend {
|
|
|
|
|
2020-02-17 20:38:56 +00:00
|
|
|
class GraphicsContext;
|
2019-01-08 04:16:01 +00:00
|
|
|
|
|
|
|
/// Helper class to acquire/release window context within a given scope
|
2020-02-17 20:38:56 +00:00
|
|
|
class ScopeAcquireContext : NonCopyable {
|
2019-01-08 04:16:01 +00:00
|
|
|
public:
|
2020-02-17 20:38:56 +00:00
|
|
|
explicit ScopeAcquireContext(Core::Frontend::GraphicsContext& context);
|
|
|
|
~ScopeAcquireContext();
|
2019-01-08 04:16:01 +00:00
|
|
|
|
|
|
|
private:
|
2020-02-17 20:38:56 +00:00
|
|
|
Core::Frontend::GraphicsContext& context;
|
2019-01-08 04:16:01 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
} // namespace Core::Frontend
|