aboutsummaryrefslogtreecommitdiffstats
path: root/src/quick/scenegraph/qsgdefaultcontext.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/quick/scenegraph/qsgdefaultcontext.cpp')
-rw-r--r--src/quick/scenegraph/qsgdefaultcontext.cpp7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/quick/scenegraph/qsgdefaultcontext.cpp b/src/quick/scenegraph/qsgdefaultcontext.cpp
index 2df9c50898..fd448ee3a2 100644
--- a/src/quick/scenegraph/qsgdefaultcontext.cpp
+++ b/src/quick/scenegraph/qsgdefaultcontext.cpp
@@ -298,14 +298,11 @@ void *QSGDefaultContext::getResource(QQuickWindow *window, Resource resource) co
QQuickWindowPrivate::get(window)->context);
QSGRhiSupport *rhiSupport = QSGRhiSupport::instance();
- switch (resource) {
#if QT_CONFIG(vulkan)
- case VulkanInstanceResource:
+ if (resource == VulkanInstanceResource)
return window->vulkanInstance();
#endif
- default:
- return const_cast<void *>(rhiSupport->rifResource(resource, rc, window));
- }
+ return const_cast<void *>(rhiSupport->rifResource(resource, rc, window));
}
QSGRendererInterface::ShaderType QSGDefaultContext::shaderType() const