self.loginWindow.bind("<MouseWheel>",
lambda event: self.canvas.yview_scroll(int(-1 * (event.delta / 120)), "units"))
This was supposed to enable the scroll wheel in my tkinter project, but the problem is i want to stop that in a specific condition. How to do that ?
I tried to make it this way
self.loginWindow.bind(None)
but it is not working
You can Try
if (anything):
self.loginWindow.bind("<MouseWheel>",
lambda event: None)
else:
(otherwise)
This will stop the mouse wheel events