mirror of
https://github.com/citra-emu/citra-nightly.git
synced 2024-12-23 15:55:31 +00:00
bootmanager: make main_context a unique_ptr
This commit is contained in:
parent
40849a8fa8
commit
5c50a26b38
|
@ -386,7 +386,7 @@ static Frontend::EmuWindow::WindowSystemInfo GetWindowSystemInfo(QWindow* window
|
|||
return wsi;
|
||||
}
|
||||
|
||||
std::shared_ptr<Frontend::GraphicsContext> GRenderWindow::main_context;
|
||||
std::unique_ptr<Frontend::GraphicsContext> GRenderWindow::main_context;
|
||||
|
||||
GRenderWindow::GRenderWindow(QWidget* parent_, EmuThread* emu_thread, bool is_secondary_)
|
||||
: QWidget(parent_), EmuWindow(is_secondary_), emu_thread(emu_thread) {
|
||||
|
@ -667,7 +667,7 @@ bool GRenderWindow::InitializeOpenGL() {
|
|||
child_widget->windowHandle()->create();
|
||||
|
||||
if (!main_context) {
|
||||
main_context = std::make_shared<OpenGLSharedContext>();
|
||||
main_context = std::make_unique<OpenGLSharedContext>();
|
||||
}
|
||||
|
||||
auto child_context = CreateSharedContext();
|
||||
|
|
|
@ -192,7 +192,7 @@ private:
|
|||
/// Main context that will be shared with all other contexts that are requested.
|
||||
/// If this is used in a shared context setting, then this should not be used directly, but
|
||||
/// should instead be shared from
|
||||
static std::shared_ptr<Frontend::GraphicsContext> main_context;
|
||||
static std::unique_ptr<Frontend::GraphicsContext> main_context;
|
||||
|
||||
/// Temporary storage of the screenshot taken
|
||||
QImage screenshot_image;
|
||||
|
|
Loading…
Reference in a new issue