rename GGLContext to just GLContext

This commit is contained in:
James Rowe 2019-09-16 23:29:21 -06:00
parent db94c017bf
commit 045eec282a
2 changed files with 6 additions and 6 deletions

View file

@ -305,10 +305,10 @@ void GRenderWindow::showEvent(QShowEvent* event) {
}
std::unique_ptr<Frontend::GraphicsContext> GRenderWindow::CreateSharedContext() const {
return std::make_unique<GGLContext>(QOpenGLContext::globalShareContext());
return std::make_unique<GLContext>(QOpenGLContext::globalShareContext());
}
GGLContext::GGLContext(QOpenGLContext* shared_context)
GLContext::GLContext(QOpenGLContext* shared_context)
: context(new QOpenGLContext(shared_context->parent())),
surface(new QOffscreenSurface(nullptr)) {
context->setShareContext(shared_context);
@ -318,10 +318,10 @@ GGLContext::GGLContext(QOpenGLContext* shared_context)
surface->create();
}
void GGLContext::MakeCurrent() {
void GLContext::MakeCurrent() {
context->makeCurrent(surface);
}
void GGLContext::DoneCurrent() {
void GLContext::DoneCurrent() {
context->doneCurrent();
}

View file

@ -22,9 +22,9 @@ class QOpenGLContext;
class GMainWindow;
class GRenderWindow;
class GGLContext : public Frontend::GraphicsContext {
class GLContext : public Frontend::GraphicsContext {
public:
explicit GGLContext(QOpenGLContext* shared_context);
explicit GLContext(QOpenGLContext* shared_context);
void MakeCurrent() override;