From 9d0f75244dfac10c47a0d770ec596f86b4b8a923 Mon Sep 17 00:00:00 2001 From: kallaballa Date: Wed, 8 Mar 2023 07:04:58 +0100 Subject: [PATCH] remove custom key handlers --- src/common/viz2d.cpp | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) diff --git a/src/common/viz2d.cpp b/src/common/viz2d.cpp index 8c271e876..f8e7226e6 100644 --- a/src/common/viz2d.cpp +++ b/src/common/viz2d.cpp @@ -319,17 +319,14 @@ nanogui::FormHelper* Viz2D::form() { bool Viz2D::keyboard_event(int key, int scancode, int action, int modifiers) { if (screen().keyboard_event(key, scancode, action, modifiers)) return true; - if (key == GLFW_KEY_ESCAPE && action == GLFW_PRESS) { - setOffscreen(!isOffscreen()); - return true; - } else if (key == GLFW_KEY_TAB && action == GLFW_PRESS) { - auto children = screen().children(); - for(auto* child : children) { - child->set_visible(!child->visible()); - } - - return true; - } +// if (key == GLFW_KEY_TAB && action == GLFW_PRESS) { +// auto children = screen().children(); +// for(auto* child : children) { +// child->set_visible(!child->visible()); +// } +// +// return true; +// } return false; }