Change preference to only hide the xray message, not the visualization

This commit is contained in:
fieldOfView 2020-03-31 11:39:05 +02:00
parent a2f9eac23b
commit b7898b5a97
2 changed files with 33 additions and 44 deletions

View file

@ -133,17 +133,6 @@ class SolidView(View):
self._support_mesh_shader.setUniformValue("u_vertical_stripes", True)
self._support_mesh_shader.setUniformValue("u_width", 5.0)
if not Application.getInstance().getPreferences().getValue(self._show_xray_warning_preference):
self._xray_error_image = None
self._xray_shader = None
self._xray_composite_shader = None
if self._composite_pass and 'xray' in self._composite_pass.getLayerBindings():
self._composite_pass.setLayerBindings(self._old_layer_bindings)
self._composite_pass.setCompositeShader(self._old_composite_shader)
self._old_layer_bindings = None
self._old_composite_shader = None
self._xray_warning_message.hide()
else:
if not self._xray_error_image:
self._xray_error_image = OpenGL.getInstance().createTexture()
texture_file = "xray_error.png"

View file

@ -345,7 +345,7 @@ UM.PreferencesPage
width: childrenRect.width;
height: childrenRect.height;
text: catalog.i18nc("@info:tooltip", "Highlight missing or extraneous surfaces of the model using warning signs. The toolpaths will often be missing parts of the intended geometry.")
text: catalog.i18nc("@info:tooltip", "Show a message if missing or extraneous surfaces are detected. The toolpaths will often be missing parts of the intended geometry.")
CheckBox
{
@ -354,7 +354,7 @@ UM.PreferencesPage
checked: boolCheck(UM.Preferences.getValue("view/show_xray_warning"))
onClicked: UM.Preferences.setValue("view/show_xray_warning", checked)
text: catalog.i18nc("@option:check", "Display model errors");
text: catalog.i18nc("@option:check", "Display message if model errors are detected");
}
}