From a2a4dc1f9f793ce1e263ece3e4540fdd5b60b3a1 Mon Sep 17 00:00:00 2001 From: chillpert Date: Mon, 5 Feb 2024 12:50:28 +0100 Subject: [PATCH] Fix tool bar can be right-clicked --- main.py | 1 + 1 file changed, 1 insertion(+) diff --git a/main.py b/main.py index 6bec6c6..4623a57 100644 --- a/main.py +++ b/main.py @@ -139,6 +139,7 @@ def _create_tool_bar_widget(self): tool_bar_widget = QToolBar() tool_bar_widget.setFloatable(False) tool_bar_widget.setMovable(False) + tool_bar_widget.setContextMenuPolicy(Qt.PreventContextMenu) # Disable the toolbar widget by default tool_bar_widget.setEnabled(False)