File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -218,20 +218,20 @@ def _scroll_viewport(self, event: tk.Event):
218218 """
219219 match _system :
220220 case "Linux" if event .num == 4 :
221- scroll_amount = - 1
221+ amount = - 1
222222 case "Linux" if event .num == 5 :
223- scroll_amount = 1
223+ amount = 1
224224 case "Darwin" :
225- scroll_amount = - event .delta
225+ amount = - event .delta
226226 case "Windows" :
227- scroll_amount = - event .delta // 120
227+ amount = - event .delta // 120
228228 case _:
229229 message = f"event { event .num } on OS { _system !r} is not supported"
230230 raise ValueError (message )
231231
232232 # Select the method to call based on whether Shift was held down. This
233233 # is indicated by the LSB of the state.
234234 if event .state & 1 :
235- self ._xview (tk .SCROLL , scroll_amount , tk .UNITS )
235+ self ._xview (tk .SCROLL , amount , tk .UNITS )
236236 else :
237- self ._yview (tk .SCROLL , scroll_amount , tk .UNITS )
237+ self ._yview (tk .SCROLL , amount , tk .UNITS )
You can’t perform that action at this time.
0 commit comments